Skip to main content



      Home
Home » Eclipse Projects » Eclipse Platform » bin directory stays empty
bin directory stays empty [message #327724] Tue, 29 April 2008 11:52 Go to next message
Eclipse UserFriend
I am running Eclipse 3.3.1.1 and have been an eclipse user since 2.x.

Over the years, the following problem has occasionally recurred: A
javanature project simply stops creating class files in the bin directory.

I make serious changes in the code that show no errors in the editor,
then save them but bin/ remains empty. The menu action Project > Clear
does not regenerate the .class files. Nothing I do causes class files to
appear in bin/. If I add my own ant build script to the project's list
of builders, it runs fine, but the standard builder (Java Builder), does
not generate classes in bin/.

Perhaps the builder is compiling and is putting the class files
somewhere other than bin/, or perhaps it is not even trying to compile.
I don not know.

My workaround is to create a new project, copy the source files into it,
and then delete the stuck project. It seems that the stuck project has
some state data that causes the problem, but I have not been able to
find anything in the .project, .classpath, and project prefs that seems
relevant.

Can anybody suggest what I might be doing to cause this problem ?

Bill
Re: bin directory stays empty [message #327726 is a reply to message #327724] Tue, 29 April 2008 11:49 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: merks.ca.ibm.com

Bill,

I've never seen this in the last 6 years of using it. Are there any
exceptions in the Error Log view when it's in this state? Is the output
folder still set to "bin" in the project's properties? Does doing
"Refresh" on the project help?


Bill Winspur wrote:
> I am running Eclipse 3.3.1.1 and have been an eclipse user since 2.x.
>
> Over the years, the following problem has occasionally recurred: A
> javanature project simply stops creating class files in the bin
> directory.
>
> I make serious changes in the code that show no errors in the editor,
> then save them but bin/ remains empty. The menu action Project > Clear
> does not regenerate the .class files. Nothing I do causes class files
> to appear in bin/. If I add my own ant build script to the project's
> list of builders, it runs fine, but the standard builder (Java
> Builder), does not generate classes in bin/.
>
> Perhaps the builder is compiling and is putting the class files
> somewhere other than bin/, or perhaps it is not even trying to
> compile. I don not know.
>
> My workaround is to create a new project, copy the source files into
> it, and then delete the stuck project. It seems that the stuck project
> has some state data that causes the problem, but I have not been able
> to find anything in the .project, .classpath, and project prefs that
> seems relevant.
>
> Can anybody suggest what I might be doing to cause this problem ?
>
> Bill
Re: bin directory stays empty [message #327728 is a reply to message #327726] Tue, 29 April 2008 12:34 Go to previous messageGo to next message
Eclipse UserFriend
Ed, Thks for yr reply.

No exceptions in Error Log View, Refresh does not help. Where is bin
specified in the project properties ? I've looked for it previously but
not found it.
Bill.

> Bill,
>
> I've never seen this in the last 6 years of using it. Are there any
> exceptions in the Error Log view when it's in this state? Is the output
> folder still set to "bin" in the project's properties? Does doing
> "Refresh" on the project help?
>
>
> Bill Winspur wrote:
>> I am running Eclipse 3.3.1.1 and have been an eclipse user since 2.x.
>>
>> Over the years, the following problem has occasionally recurred: A
>> javanature project simply stops creating class files in the bin
>> directory.
>>
>> I make serious changes in the code that show no errors in the editor,
>> then save them but bin/ remains empty. The menu action Project > Clear
>> does not regenerate the .class files. Nothing I do causes class files
>> to appear in bin/. If I add my own ant build script to the project's
>> list of builders, it runs fine, but the standard builder (Java
>> Builder), does not generate classes in bin/.
>>
>> Perhaps the builder is compiling and is putting the class files
>> somewhere other than bin/, or perhaps it is not even trying to
>> compile. I don not know.
>>
>> My workaround is to create a new project, copy the source files into
>> it, and then delete the stuck project. It seems that the stuck project
>> has some state data that causes the problem, but I have not been able
>> to find anything in the .project, .classpath, and project prefs that
>> seems relevant.
>>
>> Can anybody suggest what I might be doing to cause this problem ?
>>
>> Bill
Re: bin directory stays empty [message #327730 is a reply to message #327728] Tue, 29 April 2008 12:31 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: merks.ca.ibm.com

Bill,

Under Properties...->Java Build Path on the "Source" tab at the bottom.


Bill Winspur wrote:
> Ed, Thks for yr reply.
>
> No exceptions in Error Log View, Refresh does not help. Where is bin
> specified in the project properties ? I've looked for it previously
> but not found it.
> Bill.
>
>> Bill,
>>
>> I've never seen this in the last 6 years of using it. Are there any
>> exceptions in the Error Log view when it's in this state? Is the
>> output folder still set to "bin" in the project's properties? Does
>> doing "Refresh" on the project help?
>>
>>
>> Bill Winspur wrote:
>>> I am running Eclipse 3.3.1.1 and have been an eclipse user since 2.x.
>>>
>>> Over the years, the following problem has occasionally recurred: A
>>> javanature project simply stops creating class files in the bin
>>> directory.
>>>
>>> I make serious changes in the code that show no errors in the
>>> editor, then save them but bin/ remains empty. The menu action
>>> Project > Clear does not regenerate the .class files. Nothing I do
>>> causes class files to appear in bin/. If I add my own ant build
>>> script to the project's list of builders, it runs fine, but the
>>> standard builder (Java Builder), does not generate classes in bin/.
>>>
>>> Perhaps the builder is compiling and is putting the class files
>>> somewhere other than bin/, or perhaps it is not even trying to
>>> compile. I don not know.
>>>
>>> My workaround is to create a new project, copy the source files into
>>> it, and then delete the stuck project. It seems that the stuck
>>> project has some state data that causes the problem, but I have not
>>> been able to find anything in the .project, .classpath, and project
>>> prefs that seems relevant.
>>>
>>> Can anybody suggest what I might be doing to cause this problem ?
>>>
>>> Bill
Re: bin directory stays empty [message #327732 is a reply to message #327724] Tue, 29 April 2008 12:40 Go to previous messageGo to next message
Eclipse UserFriend
On 29/04/2008 17:52 Bill Winspur ha scritto:

> Over the years, the following problem has occasionally recurred: A
> javanature project simply stops creating class files in the bin directory.
[...]
> Can anybody suggest what I might be doing to cause this problem ?

Occasionally I encounter the same problem. The reason is that the bin
directory loses the "derived" status, so the builder isn't able to use
it to place its files.

It happens when:

- Check-out a project from CVS or SVN that has already a bin directory.
- Import an existing project to the workspace without deleting the bin
directory first.

Sometimes it also happens when checking-out several projects at once
from SVN, but usually a Project -> Clean solves the problem in that case.

You should be able to fix it by deleting the bin directory from the
Navigator view. Eclipse should rebuild it immediately and compile correctly.

Hope this helps.

Regards,
Marco.
Re: bin directory stays empty [message #327733 is a reply to message #327730] Tue, 29 April 2008 14:20 Go to previous messageGo to next message
Eclipse UserFriend
Ed,

The bin/ directory spec points to ./bin in the project, as expected. But...

I have just finished my workaround (create a new project and copy in the
source), refactored the code a little, attached my builders, and
achieved the minor goal, blocked by the stuck project. Then, when I
re-opened the stuck project: it was stuck no more, and responded to a
trivial code change and save with a successful compile into bin/.

This is the reason I've held off reporting this problem - I have not
been able to create a stable test case, partly because I can work-around
the stuck project fairly quickly, and get on with my work. Here's what I
know so far:

============

Problem:
======= In the JDT, no class files are generated in the project's bin/
dir after a .java file change and save

While the problem lasts the following appear to be true:

- The .project file looks OK, just like compile-capable projects

- The .classpath file looks OK, no warnings, all libs, etc are as expected.

- The output dir is properly specified by an workspace-relative path in
the 'buildpath > source' page of the project prefs.

- user-defined ant script build, added to the project builders list, are
activated on change and save.of a .java file.

- I have not yet found a change to prefs/source/etc. that either caused
or cured the problem.

- Sometimes the project starts compiling again, the rest of the time it
doesn't.

============

I'm wondering if the problem is timestamp-related, caused by my
work-habits.

I often copy source files into projects from legacy source folders
outside Eclipse workspaces, using workstation tools. Perhaps incoming
timestamps are having some kind of adverse effect on the Java Builder
builder? The incoming files should have modification dates way before
the date on which they are copied. How could that be a problem ?

Anyway Ed, thanks for your questions and help. I'll keep an eye out for
this happening again, paying attention to my project-refactoring
activities outside eclipse, but for now I'm moving on. If I learn
anything, I'll repost to the group.

Bill.

Ed Merks wrote:
> Bill,
>
> Under Properties...->Java Build Path on the "Source" tab at the bottom.
>
>
> Bill Winspur wrote:
>> Ed, Thks for yr reply.
>>
>> No exceptions in Error Log View, Refresh does not help. Where is bin
>> specified in the project properties ? I've looked for it previously
>> but not found it.
>> Bill.
>>
>>> Bill,
>>>
>>> I've never seen this in the last 6 years of using it. Are there any
>>> exceptions in the Error Log view when it's in this state? Is the
>>> output folder still set to "bin" in the project's properties? Does
>>> doing "Refresh" on the project help?
>>>
>>>
>>> Bill Winspur wrote:
>>>> I am running Eclipse 3.3.1.1 and have been an eclipse user since 2.x.
>>>>
>>>> Over the years, the following problem has occasionally recurred: A
>>>> javanature project simply stops creating class files in the bin
>>>> directory.
>>>>
>>>> I make serious changes in the code that show no errors in the
>>>> editor, then save them but bin/ remains empty. The menu action
>>>> Project > Clear does not regenerate the .class files. Nothing I do
>>>> causes class files to appear in bin/. If I add my own ant build
>>>> script to the project's list of builders, it runs fine, but the
>>>> standard builder (Java Builder), does not generate classes in bin/.
>>>>
>>>> Perhaps the builder is compiling and is putting the class files
>>>> somewhere other than bin/, or perhaps it is not even trying to
>>>> compile. I don not know.
>>>>
>>>> My workaround is to create a new project, copy the source files into
>>>> it, and then delete the stuck project. It seems that the stuck
>>>> project has some state data that causes the problem, but I have not
>>>> been able to find anything in the .project, .classpath, and project
>>>> prefs that seems relevant.
>>>>
>>>> Can anybody suggest what I might be doing to cause this problem ?
>>>>
>>>> Bill
Re: bin directory stays empty [message #327734 is a reply to message #327733] Tue, 29 April 2008 14:17 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: merks.ca.ibm.com

Bill,

Marco's theory sounds like a good one. I.e., does deleting the bin
folder itself fix the problem? As long as the source time stamps are in
the future, I don't imagine that should cause a problem...


Bill Winspur wrote:
> Ed,
>
> The bin/ directory spec points to ./bin in the project, as expected.
> But...
>
> I have just finished my workaround (create a new project and copy in
> the source), refactored the code a little, attached my builders, and
> achieved the minor goal, blocked by the stuck project. Then, when I
> re-opened the stuck project: it was stuck no more, and responded to a
> trivial code change and save with a successful compile into bin/.
>
> This is the reason I've held off reporting this problem - I have not
> been able to create a stable test case, partly because I can
> work-around the stuck project fairly quickly, and get on with my work.
> Here's what I know so far:
>
> ============
>
> Problem:
> ======= In the JDT, no class files are generated in the project's bin/
> dir after a .java file change and save
>
> While the problem lasts the following appear to be true:
>
> - The .project file looks OK, just like compile-capable projects
>
> - The .classpath file looks OK, no warnings, all libs, etc are as
> expected.
>
> - The output dir is properly specified by an workspace-relative path
> in the 'buildpath > source' page of the project prefs.
>
> - user-defined ant script build, added to the project builders list,
> are activated on change and save.of a .java file.
>
> - I have not yet found a change to prefs/source/etc. that either
> caused or cured the problem.
>
> - Sometimes the project starts compiling again, the rest of the time
> it doesn't.
>
> ============
>
> I'm wondering if the problem is timestamp-related, caused by my
> work-habits.
>
> I often copy source files into projects from legacy source folders
> outside Eclipse workspaces, using workstation tools. Perhaps incoming
> timestamps are having some kind of adverse effect on the Java Builder
> builder? The incoming files should have modification dates way before
> the date on which they are copied. How could that be a problem ?
>
> Anyway Ed, thanks for your questions and help. I'll keep an eye out
> for this happening again, paying attention to my project-refactoring
> activities outside eclipse, but for now I'm moving on. If I learn
> anything, I'll repost to the group.
>
> Bill.
>
> Ed Merks wrote:
>> Bill,
>>
>> Under Properties...->Java Build Path on the "Source" tab at the bottom.
>>
>>
>> Bill Winspur wrote:
>>> Ed, Thks for yr reply.
>>>
>>> No exceptions in Error Log View, Refresh does not help. Where is bin
>>> specified in the project properties ? I've looked for it previously
>>> but not found it.
>>> Bill.
>>>
>>>> Bill,
>>>>
>>>> I've never seen this in the last 6 years of using it. Are there
>>>> any exceptions in the Error Log view when it's in this state? Is
>>>> the output folder still set to "bin" in the project's properties?
>>>> Does doing "Refresh" on the project help?
>>>>
>>>>
>>>> Bill Winspur wrote:
>>>>> I am running Eclipse 3.3.1.1 and have been an eclipse user since 2.x.
>>>>>
>>>>> Over the years, the following problem has occasionally recurred: A
>>>>> javanature project simply stops creating class files in the bin
>>>>> directory.
>>>>>
>>>>> I make serious changes in the code that show no errors in the
>>>>> editor, then save them but bin/ remains empty. The menu action
>>>>> Project > Clear does not regenerate the .class files. Nothing I do
>>>>> causes class files to appear in bin/. If I add my own ant build
>>>>> script to the project's list of builders, it runs fine, but the
>>>>> standard builder (Java Builder), does not generate classes in bin/.
>>>>>
>>>>> Perhaps the builder is compiling and is putting the class files
>>>>> somewhere other than bin/, or perhaps it is not even trying to
>>>>> compile. I don not know.
>>>>>
>>>>> My workaround is to create a new project, copy the source files
>>>>> into it, and then delete the stuck project. It seems that the
>>>>> stuck project has some state data that causes the problem, but I
>>>>> have not been able to find anything in the .project, .classpath,
>>>>> and project prefs that seems relevant.
>>>>>
>>>>> Can anybody suggest what I might be doing to cause this problem ?
>>>>>
>>>>> Bill
Re: bin directory stays empty [message #327736 is a reply to message #327724] Tue, 29 April 2008 16:56 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: eclipse-news.rizzoweb.com

Bill Winspur wrote:
> I am running Eclipse 3.3.1.1 and have been an eclipse user since 2.x.
>
> Over the years, the following problem has occasionally recurred: A
> javanature project simply stops creating class files in the bin directory.
>
> I make serious changes in the code that show no errors in the editor,
> then save them but bin/ remains empty. The menu action Project > Clear
> does not regenerate the .class files. Nothing I do causes class files to
> appear in bin/. If I add my own ant build script to the project's list
> of builders, it runs fine, but the standard builder (Java Builder), does
> not generate classes in bin/.

One possibility is that the project's build path has errors. There have
been occasional reports of Eclipse 3.3.x losing track of Classpath
Variables or User Libraries, so if you're project is using either of
those on its build path, that might be what is happening to you.
Even if you're not using CP Variables or a User Library, check that the
project's build path does not have any errors on any of the Source,
Libraries, etc. tabs - a project with build path problems will not
build, obviously.

Hope this helps,
Eric
Re: bin directory stays empty [message #327744 is a reply to message #327732] Wed, 30 April 2008 03:27 Go to previous messageGo to next message
Eclipse UserFriend
Marco, thanks for your the analysis and the workaround. Looking forward
to the next time this happens to try it.
Bill.
>
> On 29/04/2008 17:52 Bill Winspur ha scritto:
>
>> Over the years, the following problem has occasionally recurred: A
>> javanature project simply stops creating class files in the bin
>> directory.
> [...]
>> Can anybody suggest what I might be doing to cause this problem ?
>
> Occasionally I encounter the same problem. The reason is that the bin
> directory loses the "derived" status, so the builder isn't able to use
> it to place its files.
>
> It happens when:
>
> - Check-out a project from CVS or SVN that has already a bin directory.
> - Import an existing project to the workspace without deleting the bin
> directory first.
>
> Sometimes it also happens when checking-out several projects at once
> from SVN, but usually a Project -> Clean solves the problem in that case.
>
> You should be able to fix it by deleting the bin directory from the
> Navigator view. Eclipse should rebuild it immediately and compile
> correctly.
>
> Hope this helps.
>
> Regards,
> Marco.
Re: bin directory stays empty [message #327892 is a reply to message #327732] Wed, 07 May 2008 11:12 Go to previous messageGo to next message
Eclipse UserFriend
Marco,
the problem re-occurred, so I tried deleting the bin dir in
the navigation view: no change , and the bin never lost derived state,
according to its properties page. Thanks anyway.
Bill.
>
> On 29/04/2008 17:52 Bill Winspur ha scritto:
>
>> Over the years, the following problem has occasionally recurred: A
>> javanature project simply stops creating class files in the bin
>> directory.
> [...]
>> Can anybody suggest what I might be doing to cause this problem ?
>
> Occasionally I encounter the same problem. The reason is that the bin
> directory loses the "derived" status, so the builder isn't able to use
> it to place its files.
>
> It happens when:
>
> - Check-out a project from CVS or SVN that has already a bin directory.
> - Import an existing project to the workspace without deleting the bin
> directory first.
>
> Sometimes it also happens when checking-out several projects at once
> from SVN, but usually a Project -> Clean solves the problem in that case.
>
> You should be able to fix it by deleting the bin directory from the
> Navigator view. Eclipse should rebuild it immediately and compile
> correctly.
>
> Hope this helps.
>
> Regards,
> Marco.
Re: bin directory stays empty [message #327894 is a reply to message #327736] Wed, 07 May 2008 13:19 Go to previous message
Eclipse UserFriend
Thanks Eric,
I did find errors in my build path - caused by renaming something
outside the project - and when they were fixed the compiles to bin
happened normally.

Perhaps this is what I've been doing to cause the problem. Time will tell.
> Bill Winspur wrote:
>> I am running Eclipse 3.3.1.1 and have been an eclipse user since 2.x.
>>
>> Over the years, the following problem has occasionally recurred: A
>> javanature project simply stops creating class files in the bin
>> directory.
>>
>> I make serious changes in the code that show no errors in the editor,
>> then save them but bin/ remains empty. The menu action Project > Clear
>> does not regenerate the .class files. Nothing I do causes class files
>> to appear in bin/. If I add my own ant build script to the project's
>> list of builders, it runs fine, but the standard builder (Java
>> Builder), does not generate classes in bin/.
>
> One possibility is that the project's build path has errors. There have
> been occasional reports of Eclipse 3.3.x losing track of Classpath
> Variables or User Libraries, so if you're project is using either of
> those on its build path, that might be what is happening to you.
> Even if you're not using CP Variables or a User Library, check that the
> project's build path does not have any errors on any of the Source,
> Libraries, etc. tabs - a project with build path problems will not
> build, obviously.
>
> Hope this helps,
> Eric
Previous Topic:Externally using a plugin
Next Topic:Common Navigator view contents...
Goto Forum:
  


Current Time: Sat Apr 26 02:25:00 EDT 2025

Powered by FUDForum. Page generated in 0.04427 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top