RE: Using multiple source directories to produce on artefact
I agree that a mavenized build probably does not need multiple source dirs. However, for most of us Maven is not the only tool we use. My use-case for multiple source dirs is to separate XDoclet-generated code. The Maven build will indeed perform fine with the generated source in the same directory as the main sources, but consider what happens outside Maven: (1) In Eclipse you get everything in a single source dir creating a huge tree in the Package Explorer. I know it's possible to filter out the generated source packages but it's not practical unless the maven-eclipse-plugin facilitates this by excluding them from the view for me. (2) When using SCM within Eclipse: because everything is in a single source dir you need to tell Eclipse (for ALL AND EVERY generated package) you want the generated sources excluded from SCM. Again, very impractical. Unless the maven-eclipse-plugin can exclude generated sources from SCM I want it in a separate directory. This separate directory can conveniently be excluded from SCM with a single ignore entry. Although I have things working like I want using the build-helper-maven-plugin I'd still like to be able to set multiple source dirs in the POM as it is much cleaner. I really don't see the argument against multiple source dirs in the POM either. True best-practices evangelists can still continue to use (and preach :) single source directory projects. Nothing is lost with multiple source dirs, it's just convenience that is gained. -Oorspronkelijk bericht- Van: dan tran [mailto:[EMAIL PROTECTED] Verzonden: donderdag 12 januari 2006 17:23 Aan: Maven Users List; [EMAIL PROTECTED] Onderwerp: Re: Using multiple source directories to produce on artefact Yes, build-helper is there for legacy build. However, if a build is completely mavenized, I see no need to have more than one primary source trees and adding a generated source tree the project , shoud be done by the generated source plugin itself. For now, i dont see a way out until at least 2.1, if it supports multiple main source trees ;-) -D - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Using multiple source directories to produce on artefact
By default (or maybe it is by design) the XDoclet plugin wants it generated output to go in target/generated-sources/xdoclet and it AUTOMATICALLY adds this path to the source directory list. It is bad practice to have XDoclet (or any other code generator) place its output under src. In NetBeans, the NetBeans plugin creates a separate source tree entry for the generated sources; I would think that the Eclipse plugin does the same (or it should if it doesn't). If you put the generated output where it belongs (in target, not in src), the problems you detailed will disappear, I believe. -Original Message- From: Peschier J. (Jeroen) [mailto:[EMAIL PROTECTED] Sent: Monday, January 16, 2006 07:25 To: Maven Users List Subject: RE: Using multiple source directories to produce on artefact I agree that a mavenized build probably does not need multiple source dirs. However, for most of us Maven is not the only tool we use. My use-case for multiple source dirs is to separate XDoclet-generated code. The Maven build will indeed perform fine with the generated source in the same directory as the main sources, but consider what happens outside Maven: (1) In Eclipse you get everything in a single source dir creating a huge tree in the Package Explorer. I know it's possible to filter out the generated source packages but it's not practical unless the maven-eclipse-plugin facilitates this by excluding them from the view for me. (2) When using SCM within Eclipse: because everything is in a single source dir you need to tell Eclipse (for ALL AND EVERY generated package) you want the generated sources excluded from SCM. Again, very impractical. Unless the maven-eclipse-plugin can exclude generated sources from SCM I want it in a separate directory. This separate directory can conveniently be excluded from SCM with a single ignore entry. Although I have things working like I want using the build-helper-maven-plugin I'd still like to be able to set multiple source dirs in the POM as it is much cleaner. I really don't see the argument against multiple source dirs in the POM either. True best-practices evangelists can still continue to use (and preach :) single source directory projects. Nothing is lost with multiple source dirs, it's just convenience that is gained. -Oorspronkelijk bericht- Van: dan tran [mailto:[EMAIL PROTECTED] Verzonden: donderdag 12 januari 2006 17:23 Aan: Maven Users List; [EMAIL PROTECTED] Onderwerp: Re: Using multiple source directories to produce on artefact Yes, build-helper is there for legacy build. However, if a build is completely mavenized, I see no need to have more than one primary source trees and adding a generated source tree the project , shoud be done by the generated source plugin itself. For now, i dont see a way out until at least 2.1, if it supports multiple main source trees ;-) -D - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Using multiple source directories to produce on artefact
I tried your suggestion and it seems indeed to add ${project.build.directory}/generated-sources/xdoclet to the source directory list. The maven-eclipse-plugin also adds this directory as a source directory in Eclipse's build classpath. Works conveniently since target is excluded from SCM anyway. In case anyone else wants to try it, I should mention that it will only work if you set the destDir attribute of the doclet to ${project.build.directory}/generated-sources/xdoclet as well. It would make sense to have the destDir attribute default to the generatedSourcesDirectory plugin parameter but I experienced the destDir is mandatory and cannot be omitted. Perhaps the usage example on the xdoclet-maven-plugin site could be updated to use a destDir of ${project.build.directory}/generated-sources/xdoclet as I don't see this quirk documented elsewhere. By quirk I mean that ${project.build.directory}/generated-sources/xdoclet needs to be set in two places making the POM a bit harder to maintain. Apart from that it is working fine now and I can thankfully remove the build-helper-maven-plugin dependency from my projects. -Oorspronkelijk bericht- Van: Allison, Bob [mailto:[EMAIL PROTECTED] Verzonden: maandag 16 januari 2006 14:13 Aan: Maven Users List Onderwerp: RE: Using multiple source directories to produce on artefact By default (or maybe it is by design) the XDoclet plugin wants it generated output to go in target/generated-sources/xdoclet and it AUTOMATICALLY adds this path to the source directory list. It is bad practice to have XDoclet (or any other code generator) place its output under src. In NetBeans, the NetBeans plugin creates a separate source tree entry for the generated sources; I would think that the Eclipse plugin does the same (or it should if it doesn't). If you put the generated output where it belongs (in target, not in src), the problems you detailed will disappear, I believe. -Original Message- From: Peschier J. (Jeroen) [mailto:[EMAIL PROTECTED] Sent: Monday, January 16, 2006 07:25 To: Maven Users List Subject: RE: Using multiple source directories to produce on artefact I agree that a mavenized build probably does not need multiple source dirs. However, for most of us Maven is not the only tool we use. My use-case for multiple source dirs is to separate XDoclet-generated code. The Maven build will indeed perform fine with the generated source in the same directory as the main sources, but consider what happens outside Maven: (1) In Eclipse you get everything in a single source dir creating a huge tree in the Package Explorer. I know it's possible to filter out the generated source packages but it's not practical unless the maven-eclipse-plugin facilitates this by excluding them from the view for me. (2) When using SCM within Eclipse: because everything is in a single source dir you need to tell Eclipse (for ALL AND EVERY generated package) you want the generated sources excluded from SCM. Again, very impractical. Unless the maven-eclipse-plugin can exclude generated sources from SCM I want it in a separate directory. This separate directory can conveniently be excluded from SCM with a single ignore entry. Although I have things working like I want using the build-helper-maven-plugin I'd still like to be able to set multiple source dirs in the POM as it is much cleaner. I really don't see the argument against multiple source dirs in the POM either. True best-practices evangelists can still continue to use (and preach :) single source directory projects. Nothing is lost with multiple source dirs, it's just convenience that is gained. -Oorspronkelijk bericht- Van: dan tran [mailto:[EMAIL PROTECTED] Verzonden: donderdag 12 januari 2006 17:23 Aan: Maven Users List; [EMAIL PROTECTED] Onderwerp: Re: Using multiple source directories to produce on artefact Yes, build-helper is there for legacy build. However, if a build is completely mavenized, I see no need to have more than one primary source trees and adding a generated source tree the project , shoud be done by the generated source plugin itself. For now, i dont see a way out until at least 2.1, if it supports multiple main source trees ;-) -D - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Using multiple source directories to produce on artefact
Hi, I have a question regarding maven 2 and the use of multiple source directories. I want to migrate from ant to maven and have a problem with compiling 2 source directories to one output directory. Directory structure is the following. ./src/ -- with the main source files ./gen-src/ -- with generated ejb-source files from xdoclet. ./target/ -- target of compiled files In the build section I can only state on source-directory. The documentation under http://maven.apache.org/guides/mini/guide-using-one-source-directory.html state there is no problem in using several source directories but they forgot to say how. Quote: There should be no limitations in this approach. Maven natively supports multiple source directories for the purposes of generated sources.: I already tried the approach to include the directories in the configuration section. The result was, that maven always reported that no files have changed. plugins plugin artifactIdmaven-compiler-plugin/artifactId configuration includes include${basedir}/src/include include${basedir}/gen-src/include /includes /configuration /plugin /plugins I already searched for a solution but the most answers were to change the directory layout which is in my case not possible. I really appreciate your help. Another question regarding documentation. Perhaps I was to stupid to find it, but is there any good documentation, or book out there for maven 2. The current docu on the website does not have the deep I would expect, for example a good plugin howto or an overview which xml-configurations tags are available for a plugin. Andreas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using multiple source directories to produce on artefact
oh mine this question is getting popular ;-) check out build-helper-maven-plugin at http://mojo.codehaus.org maven 2 books are comming out first quater of 2006, i heard ;-) On 1/12/06, Andreas Zschorn [EMAIL PROTECTED] wrote: Hi, I have a question regarding maven 2 and the use of multiple source directories. I want to migrate from ant to maven and have a problem with compiling 2 source directories to one output directory. Directory structure is the following. ./src/ -- with the main source files ./gen-src/ -- with generated ejb-source files from xdoclet. ./target/ -- target of compiled files In the build section I can only state on source-directory. The documentation under http://maven.apache.org/guides/mini/guide-using-one-source-directory.html state there is no problem in using several source directories but they forgot to say how. Quote: There should be no limitations in this approach. Maven natively supports multiple source directories for the purposes of generated sources.: I already tried the approach to include the directories in the configuration section. The result was, that maven always reported that no files have changed. plugins plugin artifactIdmaven-compiler-plugin/artifactId configuration includes include${basedir}/src/include include${basedir}/gen-src/include /includes /configuration /plugin /plugins I already searched for a solution but the most answers were to change the directory layout which is in my case not possible. I really appreciate your help. Another question regarding documentation. Perhaps I was to stupid to find it, but is there any good documentation, or book out there for maven 2. The current docu on the website does not have the deep I would expect, for example a good plugin howto or an overview which xml-configurations tags are available for a plugin. Andreas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using multiple source directories to produce on artefact
This functionality should be added to the core pom IMO. --jason -Original Message- From: dan tran To: Maven Users List Sent: Thu Jan 12 00:13:03 2006 Subject: Re: Using multiple source directories to produce on artefact oh mine this question is getting popular ;-) check out build-helper-maven-plugin at http://mojo.codehaus.org maven 2 books are comming out first quater of 2006, i heard ;-) On 1/12/06, Andreas Zschorn [EMAIL PROTECTED] wrote: Hi, I have a question regarding maven 2 and the use of multiple source directories. I want to migrate from ant to maven and have a problem with compiling 2 source directories to one output directory. Directory structure is the following. ./src/ -- with the main source files ./gen-src/ -- with generated ejb-source files from xdoclet. ./target/ -- target of compiled files In the build section I can only state on source-directory. The documentation under http://maven.apache.org/guides/mini/guide-using-one-source-directory.html state there is no problem in using several source directories but they forgot to say how. Quote: There should be no limitations in this approach. Maven natively supports multiple source directories for the purposes of generated sources.: I already tried the approach to include the directories in the configuration section. The result was, that maven always reported that no files have changed. plugins plugin artifactIdmaven-compiler-plugin/artifactId configuration includes include${basedir}/src/include include${basedir}/gen-src/include /includes /configuration /plugin /plugins I already searched for a solution but the most answers were to change the directory layout which is in my case not possible. I really appreciate your help. Another question regarding documentation. Perhaps I was to stupid to find it, but is there any good documentation, or book out there for maven 2. The current docu on the website does not have the deep I would expect, for example a good plugin howto or an overview which xml-configurations tags are available for a plugin. Andreas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] N�zfj|��֜�g���azފ{^�ם~�z�v���笝��v�z)ڝٚ��'��\��+���u�ݢ�(���z{bjX�~��jب���z���X�i�^��*.jaz)�zw^v�����zf��*.j��z���z-���u��v+,zh�jب�جب��ܢ��� ��zfj|��֜�g���az���+,\���bn+^tZ���q��y�a��(�k��ƭ�뢺ey���b+azǧu�ڷ�y��v�M(�n�w�j)Z��,�fk拜��jwiz��'^��^���(��\֧��)ʇڟ'�j)Z�֧ʚ���.��^��N��*.~ܢ�^��b�
RE: Using multiple source directories to produce on artefact
A repost from yesterday... The XDoclet plugin for Maven expects to place the generated sources in target/generated-sources/xdoclet and adds it to the compile source list. If you are specifying a different destination, that may be part of the problem if the plugin is not doing things quite right. Try changing your output directory to match the one mentioned above and see if that helps. -Original Message- From: Andreas Zschorn [mailto:[EMAIL PROTECTED] Sent: Thursday, January 12, 2006 03:08 To: users@maven.apache.org Subject: Using multiple source directories to produce on artefact Hi, I have a question regarding maven 2 and the use of multiple source directories. I want to migrate from ant to maven and have a problem with compiling 2 source directories to one output directory. Directory structure is the following. ./src/ -- with the main source files ./gen-src/ -- with generated ejb-source files from xdoclet. ./target/ -- target of compiled files In the build section I can only state on source-directory. The documentation under http://maven.apache.org/guides/mini/guide-using-one-source-directory.htm l state there is no problem in using several source directories but they forgot to say how. Quote: There should be no limitations in this approach. Maven natively supports multiple source directories for the purposes of generated sources.: I already tried the approach to include the directories in the configuration section. The result was, that maven always reported that no files have changed. plugins plugin artifactIdmaven-compiler-plugin/artifactId configuration includes include${basedir}/src/include include${basedir}/gen-src/include /includes /configuration /plugin /plugins I already searched for a solution but the most answers were to change the directory layout which is in my case not possible. I really appreciate your help. Another question regarding documentation. Perhaps I was to stupid to find it, but is there any good documentation, or book out there for maven 2. The current docu on the website does not have the deep I would expect, for example a good plugin howto or an overview which xml-configurations tags are available for a plugin. Andreas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using multiple source directories to produce on artefact
I needed it too, but I don't think it should be added to the POM, because it's a bad practice. The build helper plugin works well for legacy builds. Jason Dillon wrote: This functionality should be added to the core pom IMO. --jason -Original Message- From: dan tran To: Maven Users List Sent: Thu Jan 12 00:13:03 2006 Subject: Re: Using multiple source directories to produce on artefact oh mine this question is getting popular ;-) check out build-helper-maven-plugin at http://mojo.codehaus.org maven 2 books are comming out first quater of 2006, i heard ;-) On 1/12/06, Andreas Zschorn [EMAIL PROTECTED] wrote: Hi, I have a question regarding maven 2 and the use of multiple source directories. I want to migrate from ant to maven and have a problem with compiling 2 source directories to one output directory. Directory structure is the following. ./src/ -- with the main source files ./gen-src/ -- with generated ejb-source files from xdoclet. ./target/ -- target of compiled files In the build section I can only state on source-directory. The documentation under http://maven.apache.org/guides/mini/guide-using-one-source-directory.html state there is no problem in using several source directories but they forgot to say how. Quote: There should be no limitations in this approach. Maven natively supports multiple source directories for the purposes of generated sources.: I already tried the approach to include the directories in the configuration section. The result was, that maven always reported that no files have changed. plugins plugin artifactIdmaven-compiler-plugin/artifactId configuration includes include${basedir}/src/include include${basedir}/gen-src/include /includes /configuration /plugin /plugins I already searched for a solution but the most answers were to change the directory layout which is in my case not possible. I really appreciate your help. Another question regarding documentation. Perhaps I was to stupid to find it, but is there any good documentation, or book out there for maven 2. The current docu on the website does not have the deep I would expect, for example a good plugin howto or an overview which xml-configurations tags are available for a plugin. Andreas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] N�zfj|��֜�g���azފ{^�ם~���z���v���笝��v�z)ڝٚ��'��\��+��u�ݢ�(��z{bjX�~��jب���z���X�i�^��*.jaz)�zw^v�����zf��*.j��z���z-��u��v+,zh�jب�جب��ܢ��� ��zfj|��֜�g���az���+,\���bn+^t���Z���q�y�a��(�k��ƭ뢺ey���b+azǧu�ڷ�y��v�M(���n�w�j)Z��,�fk拜��jwiz�'^��^���(��\֧��)ʇڟ'�j)Z�֧ʚ��.��^��N��*.~���ܢ�^��bon== -- With kind regards, Geoffrey De Smet - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using multiple source directories to produce on artefact
I completely agree. If anything, generated source will become more and more common as time goes on, the pom really should support multiple sourceDirectory elements (its much cleaner and clearer than having to use a plugin for it). Jason Dillon wrote: This functionality should be added to the core pom IMO. --jason -Original Message- From: dan tran To: Maven Users List Sent: Thu Jan 12 00:13:03 2006 Subject: Re: Using multiple source directories to produce on artefact oh mine this question is getting popular ;-) check out build-helper-maven-plugin at http://mojo.codehaus.org maven 2 books are comming out first quater of 2006, i heard ;-) On 1/12/06, Andreas Zschorn [EMAIL PROTECTED] wrote: Hi, I have a question regarding maven 2 and the use of multiple source directories. I want to migrate from ant to maven and have a problem with compiling 2 source directories to one output directory. Directory structure is the following. ./src/ -- with the main source files ./gen-src/ -- with generated ejb-source files from xdoclet. ./target/ -- target of compiled files In the build section I can only state on source-directory. The documentation under http://maven.apache.org/guides/mini/guide-using-one-source-directory.html state there is no problem in using several source directories but they forgot to say how. Quote: There should be no limitations in this approach. Maven natively supports multiple source directories for the purposes of generated sources.: I already tried the approach to include the directories in the configuration section. The result was, that maven always reported that no files have changed. plugins plugin artifactIdmaven-compiler-plugin/artifactId configuration includes include${basedir}/src/include include${basedir}/gen-src/include /includes /configuration /plugin /plugins I already searched for a solution but the most answers were to change the directory layout which is in my case not possible. I really appreciate your help. Another question regarding documentation. Perhaps I was to stupid to find it, but is there any good documentation, or book out there for maven 2. The current docu on the website does not have the deep I would expect, for example a good plugin howto or an overview which xml-configurations tags are available for a plugin. Andreas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] N�zfj|��֜�g���azފ{^�ם~���z���v���笝��v�z)ڝٚ��'��\��+��u�ݢ�(��z{bjX�~��jب���z���X�i�^��*.jaz)�zw^v�����zf��*.j��z���z-��u��v+,zh�jب�جب��ܢ��� ��zfj|��֜�g���az���+,\���bn+^t���Z���q�y�a��(�k��ƭ뢺ey���b+azǧu�ڷ�y��v�M(���n�w�j)Z��,�fk拜��jwiz�'^��^���(��\֧��)ʇڟ'�j)Z�֧ʚ��.��^��N��*.~���ܢ�^��bon== - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using multiple source directories to produce on artefact
Yes, build-helper is there for legacy build. However, if a build is completely mavenized, I see no need to have more than one primary source trees and adding a generated source tree the project , shoud be done by the generated source plugin itself. For now, i dont see a way out until at least 2.1, if it supports multiple main source trees ;-) -D On 1/12/06, Chad Brandon [EMAIL PROTECTED] wrote: I completely agree. If anything, generated source will become more and more common as time goes on, the pom really should support multiple sourceDirectory elements (its much cleaner and clearer than having to use a plugin for it). Jason Dillon wrote: This functionality should be added to the core pom IMO. --jason -Original Message- From: dan tran To: Maven Users List Sent: Thu Jan 12 00:13:03 2006 Subject: Re: Using multiple source directories to produce on artefact oh mine this question is getting popular ;-) check out build-helper-maven-plugin at http://mojo.codehaus.org maven 2 books are comming out first quater of 2006, i heard ;-) On 1/12/06, Andreas Zschorn [EMAIL PROTECTED] wrote: Hi, I have a question regarding maven 2 and the use of multiple source directories. I want to migrate from ant to maven and have a problem with compiling 2 source directories to one output directory. Directory structure is the following. ./src/ -- with the main source files ./gen-src/ -- with generated ejb-source files from xdoclet. ./target/ -- target of compiled files In the build section I can only state on source-directory. The documentation under http://maven.apache.org/guides/mini/guide-using-one-source-directory.html state there is no problem in using several source directories but they forgot to say how. Quote: There should be no limitations in this approach. Maven natively supports multiple source directories for the purposes of generated sources.: I already tried the approach to include the directories in the configuration section. The result was, that maven always reported that no files have changed. plugins plugin artifactIdmaven-compiler-plugin/artifactId configuration includes include${basedir}/src/include include${basedir}/gen-src/include /includes /configuration /plugin /plugins I already searched for a solution but the most answers were to change the directory layout which is in my case not possible. I really appreciate your help. Another question regarding documentation. Perhaps I was to stupid to find it, but is there any good documentation, or book out there for maven 2. The current docu on the website does not have the deep I would expect, for example a good plugin howto or an overview which xml-configurations tags are available for a plugin. Andreas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] N�zfj|��֜�g���azފ{^�ם~���z���v���笝��v�z)ڝٚ��'��\��+��u�ݢ�(��z{bjX�~��jب���z���X�i�^��*.jaz)�zw^v�����zf��*.j��z���z-��u��v+,zh�jب�جب��ܢ��� ��zfj|��֜�g���az���+,\���bn+^t���Z���q�y�a��(�k��ƭ뢺ey���b+azǧu�ڷ�y��v�M(���n�w�j)Z��,�fk拜��jwiz�'^��^���(��\֧��)ʇڟ'�j)Z�֧ʚ��.��^��N��*.~���ܢ�^��bon== - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using multiple source directories to produce on artefact
dan tran wrote: Yes, build-helper is there for legacy build. However, if a build is completely mavenized, I see no need to have more than one primary source trees and adding a generated source tree the project , shoud be done by the generated source plugin itself. Well here's why it should be supported. I develop all my applications using AndroMDA (with a maven2 build, we previously used maven1). During the build, we generate sources from one mda module (this module contains the model of the application) into all other modules (each project has about 5 to 6 submodules). Generating source from the same model for each module wouldn't be time efficient (among other things), so its not possible to have the plugin add the source directory to each module because the andromda plugin isn't run for each module.. So in this case it makes sense to allow the pom.xml to have the multiple source directories specified. For now I created another simple plugin which adds the generated source to each module, however it would be much easier and clearer if multple source directories could be specified in the pom. For now, i dont see a way out until at least 2.1, if it supports multiple main source trees ;-) That's my point, it doesn't work now, but it *should* support multiple source directories,. -D On 1/12/06, *Chad Brandon* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: I completely agree. If anything, generated source will become more and more common as time goes on, the pom really should support multiple sourceDirectory elements (its much cleaner and clearer than having to use a plugin for it). Jason Dillon wrote: This functionality should be added to the core pom IMO. --jason -Original Message- From: dan tran To: Maven Users List Sent: Thu Jan 12 00:13:03 2006 Subject: Re: Using multiple source directories to produce on artefact oh mine this question is getting popular ;-) check out build-helper-maven-plugin at http://mojo.codehaus.org maven 2 books are comming out first quater of 2006, i heard ;-) On 1/12/06, Andreas Zschorn [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: Hi, I have a question regarding maven 2 and the use of multiple source directories. I want to migrate from ant to maven and have a problem with compiling 2 source directories to one output directory. Directory structure is the following. ./src/ -- with the main source files ./gen-src/ -- with generated ejb-source files from xdoclet. ./target/ -- target of compiled files In the build section I can only state on source-directory. The documentation under http://maven.apache.org/guides/mini/guide-using-one-source-directory.html state there is no problem in using several source directories but they forgot to say how. Quote: There should be no limitations in this approach. Maven natively supports multiple source directories for the purposes of generated sources.: I already tried the approach to include the directories in the configuration section. The result was, that maven always reported that no files have changed. plugins plugin artifactIdmaven-compiler-plugin/artifactId configuration includes include${basedir}/src/include include${basedir}/gen-src/include /includes /configuration /plugin /plugins I already searched for a solution but the most answers were to change the directory layout which is in my case not possible. I really appreciate your help. Another question regarding documentation. Perhaps I was to stupid to find it, but is there any good documentation, or book out there for maven 2. The current docu on the website does not have the deep I would expect, for example a good plugin howto or an overview which xml-configurations tags are available for a plugin. Andreas - To unsubscribe, e-mail: [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] N�zfj|��֜�g���azފ{^�ם~���z���v���笝��v�z)ڝٚ��'�� \��+�� u�ݢ�(��z{bjX�~��jب���z���X�i�^��*.jaz)�zw^v�����zf��*.j��z���z-��u��v+,zh�jب�جب��ܢ��� ��zfj|��֜�g���az���+,\���bn+^t���Z���q�y�a��(�k��ƭ 뢺ey���b +azǧu�ڷ�y��v�M(���n�w�j)Z��,�fk拜��jwiz�'^��^���(��\֧��)ʇڟ'�j)Z�֧ʚ��.��^��N��*.~���ܢ�^��bon
Re: Using multiple source directories to produce on artefact
multiple source directories support in the pom would definitely be cool +1 -- Wouter dan tran wrote: Yes, build-helper is there for legacy build. However, if a build is completely mavenized, I see no need to have more than one primary source trees and adding a generated source tree the project , shoud be done by the generated source plugin itself. For now, i dont see a way out until at least 2.1, if it supports multiple main source trees ;-) -D On 1/12/06, Chad Brandon [EMAIL PROTECTED] wrote: I completely agree. If anything, generated source will become more and more common as time goes on, the pom really should support multiple sourceDirectory elements (its much cleaner and clearer than having to use a plugin for it). Jason Dillon wrote: This functionality should be added to the core pom IMO. --jason - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]