I also wanted to endorse this separation of build directories,
particularly because Eclipse uses an incremental compiler that will
write incomplete class files when it can't resolve everything. If you
then try a command-line build with Ant or Maven, those incomplete class
files are newer than the source files and don't get compiled. This can
lead to some very annoying build breaks!
 
Chris


________________________________

        From: Thierry Lach [mailto:[EMAIL PROTECTED] 
        Sent: Wednesday, 07 February, 2007 11:52
        To: [email protected]
        Subject: Re: [m2eclipse-user] plugin 0.0.10 generating IDE
compilation errors
        
        
        I consider it a "best practice" to never have Eclipse and Maven
building into the same directory.  I normally set my Eclipse/Maven
projects up using standard Eclipse structure, building into
${basedir}/bin, while letting Maven always build into
${basedir}/target/classes.  (This, by the way, would be the default
location for each of them ;-) 
        
        
        On 2/7/07, Federico Yankelevich <[EMAIL PROTECTED]> wrote: 


                Hi Marc,
                we have seen similar problems when an eclipse project
(also a dependent
                project) build .class files under target directory.
                Maven clean-up the target and eclipse loose its compiled
classes.
                This make eclipse confused because it see the .java
classes (and you can do 
                Ctrl+Space to import classes) but then it gives you a
compile error similar
                to yours.
                
                hope this help,
                best regards,
                Federico
                
                
                marc wrote:
                >
                > Hi all,
                > since I've upgraded to 0.0.10, I get some build
problems in Eclipse.
                > While working with my classes, suddenly a lot of
compilation errors appear
                > in my Error view, first one is...
                >
                > "A class file was not written. The project may be
inconsistent, if so try 
                > refreshing this project and building it"
                >
                > followed by a list of errors of non being able to
resolve my project
                > classes.
                >
                > If a make a project clean, those errors disappear, but
it is annoying... 
                > has someone experienced this behaviour? do you think
that it is not
                > related to the plugin? (I'm sure that this happens
since I upgraded)...
                >
                > Thanks in advance,
                >
                > Marc
                > 
                >
                
                --
                View this message in context:
http://www.nabble.com/plugin-0.0.10-generating-IDE-compilation-errors-tf
3186499.html#a8849029 
                Sent from the Maven Eclipse - User mailing list archive
at Nabble.com.
                
                
        
---------------------------------------------------------------------
                To unsubscribe from this list please visit: 
                
                    http://xircles.codehaus.org/manage_email
                
                


Reply via email to