Board index » jbuilder » JB 2005 silent compiler problem - missing class files.

JB 2005 silent compiler problem - missing class files.


2005-07-20 04:25:37 PM
jbuilder3
I have just got to the bottom of a problem I have been having
with the JB2005 compiler. This problem has started appearing
since I upgraded from JB8 to JB2005.
I have been building a library (package) which has a number of
dependencies on other packages. Since the change-over I have
been finding that some of the '.java' files in the package are
not being compiled to '.class' files, they are then missing
from the package's archive, which then triggers problems
elsewhere.
It turns out that the java files that were not compiled have an
indirect dependency on a package that was missing from the
classpath. ie the library I am building 'A' has a direct
dependency on (imports classes from) package 'B', and 'B' has
similar dependency on package 'C'. If I rebuild 'A' with 'B'
but not 'C' on the classpath then the JB2005 compiler seems to
silently omit the classes in 'A' which have an indirect dependency on 'C'.
The issue that I have is that this seems to happen silently, as
far as I can see there are no errors or warning messages, just
part of the library is missing.
I get this problem with the build configured to use 'Borland
Make'. If (all else being the same) I use 'Borland Make
JBuilder 8' then the build succeeds, and all the class files
are generated. If I use 'javac', then the build fails with an
appropriate error message.
Is this a bug, or is there a compiler option that I need to set
in order for this not to happen, without at least producing an
error message.
Either way it has been the cause of some serious head scratching !
Thanks in advance,
Dr Andrew Gray.
 
 

Re:JB 2005 silent compiler problem - missing class files.

Andrew Gray wrote:
Quote
I have just got to the bottom of a problem I have been having
with the JB2005 compiler. This problem has started appearing
since I upgraded from JB8 to JB2005.

I have been building a library (package) which has a number of
dependencies on other packages. Since the change-over I have
been finding that some of the '.java' files in the package are
not being compiled to '.class' files, they are then missing
from the package's archive, which then triggers problems
elsewhere.

It turns out that the java files that were not compiled have an
indirect dependency on a package that was missing from the
classpath. ie the library I am building 'A' has a direct
dependency on (imports classes from) package 'B', and 'B' has
similar dependency on package 'C'. If I rebuild 'A' with 'B'
but not 'C' on the classpath then the JB2005 compiler seems to
silently omit the classes in 'A' which have an indirect dependency on 'C'.

The issue that I have is that this seems to happen silently, as
far as I can see there are no errors or warning messages, just
part of the library is missing.

I get this problem with the build configured to use 'Borland
Make'. If (all else being the same) I use 'Borland Make
JBuilder 8' then the build succeeds, and all the class files
are generated. If I use 'javac', then the build fails with an
appropriate error message.


Is this a bug, or is there a compiler option that I need to set
in order for this not to happen, without at least producing an
error message.

Either way it has been the cause of some serious head scratching !

Thanks in advance,

Dr Andrew Gray.

Are you using Automatic Source Discovery (ASD)? Or have you added
files/packages manually to the project?
Have you done a "clean" to make sure that all the old (JB8) dependency
caches have been cleared?
--
Regards,
Lori Olson [TeamB]
------------
Save yourself, and everyone else, some time and search the
newsgroups and the FAQ-O-Matic before posting your next
question.
Google Advanced Newsgroup Search
www.google.ca/advanced_group_search
Other Newsgroup Searches:
www.borland.com/newsgroups/ngsearch.html
Joi Ellis's FAQ-O-Matic:
www.visi.com/~gyles19/fom-serve/cache/1.html
 

Re:JB 2005 silent compiler problem - missing class files.

Hi,
I have done the build starting as 'clean'ly as I can. The src
files have been 'discovered' in the src directory, but the
packages on the classpath have been added manually.
I have now also seen this effect when building using an ant
script which does a build in a newly created build directory,
starting from a 'clean' set of source files - so I think that
the effect I am seeing is probably real.
Thanks,
Andrew Gray.
 

{smallsort}

Re:JB 2005 silent compiler problem - missing class files.

Andrew Gray wrote:
Quote
Hi,

I have done the build starting as 'clean'ly as I can. The src
files have been 'discovered' in the src directory, but the
packages on the classpath have been added manually.

I have now also seen this effect when building using an ant
script which does a build in a newly created build directory,
starting from a 'clean' set of source files - so I think that
the effect I am seeing is probably real.

Thanks,

Andrew Gray.


Explain exactly what you mean by "packages on the classpath have been
added manually"?
JBuilder does not use classpaths. It constructs a classpath from the
current project's output path and it's required libraries.
You ARE using libraries, are you not?
--
Regards,
Lori Olson [TeamB]
------------
Save yourself, and everyone else, some time and search the
newsgroups and the FAQ-O-Matic before posting your next
question.
Google Advanced Newsgroup Search
www.google.ca/advanced_group_search
Other Newsgroup Searches:
www.borland.com/newsgroups/ngsearch.html
Joi Ellis's FAQ-O-Matic:
www.visi.com/~gyles19/fom-serve/cache/1.html
 

Re:JB 2005 silent compiler problem - missing class files.

Yes,
Quote
Explain exactly what you mean by "packages on the classpath
have been
added manually"?

I mean that within the JBuilder ide I have added the packages
which are required to be on the classpath using the 'required
libraries' dialog, and configuring said libraries to map onto
the appropriate package class files/archives in the usual way.
By 'added manually' I mean that these libraries and the sets
of class files to which they correspond were added and
configured by me using the appropriate ide dialogs.
Quote
JBuilder does not use classpaths. It constructs a classpath
from the
current project's output path and it's required libraries.

I think that JBuilder does 'use classpaths', although the way
it arrives at them in part uses the convenient abstraction
of 'libraries'.
Quote
You ARE using libraries, are you not?
Within the JBuilder ide I am using 'libraries' to control what
is on the classpath when a build is executed from within the
ide, but not within the ant builds to which I referred. This
is not a construct available within ant, although I do build
classpaths using an approach which I imagine is completely
analagous to that used by the JB ide.
Unfortunately this is all somewhat tangential to the fact that
as far as I can see the 'Borland Make' in JB2005 appears to
silently fail to build class files under some circumstances,
which is repeatable in both normal ide and ant builds; and
this behaviour is not seen using either the JB8 or javac
options.
Thanks
Dr Andrew Gray