Maven plugin to simplify spec %install section
Hello all,
As you know, %build section of the majority of all Java packages built with Maven is fairly simple, usually consisting of a single call to mvn-rpmbuild. But the install section can still be long and complicated, especially for large packages. As a solution I have created a plugin for Maven that can install the whole project in Fedora way. It creates all necessary directories in buildroot, installs pom.xml and jar files, creates depmaps as needed, installs javadocs. With this plugin the whole %install section of typical packages (including multi-artifact ones) can be reduced to a single line. What do you think about this idea? Would you like to see it implemented in Fedora? Mikolaj Izdebski -- java-devel mailing list java-devel@lists.fedoraproject.org https://admin.fedoraproject.org/mailman/listinfo/java-devel |
Maven plugin to simplify spec %install section
On 09/11/2012 01:58 PM, Mikolaj Izdebski wrote:
Hello all, As you know, %build section of the majority of all Java packages built with Maven is fairly simple, usually consisting of a single call to mvn-rpmbuild. But the install section can still be long and complicated, especially for large packages. As a solution I have created a plugin for Maven that can install the whole project in Fedora way. It creates all necessary directories in buildroot, installs pom.xml and jar files, creates depmaps as needed, installs javadocs. With this plugin the whole %install section of typical packages (including multi-artifact ones) can be reduced to a single line. What do you think about this idea? Would you like to see it implemented in Fedora? Mikolaj Izdebski -- java-devel mailing list java-devel@lists.fedoraproject.org https://admin.fedoraproject.org/mailman/listinfo/java-devel Although I'm not a packager I would like to see it in action. It sounds like a good thing. Is the source available somewhere? Carlo -- java-devel mailing list java-devel@lists.fedoraproject.org https://admin.fedoraproject.org/mailman/listinfo/java-devel |
Maven plugin to simplify spec %install section
On 09/11/2012 02:07 PM, Carlo de Wolf wrote:
On 09/11/2012 01:58 PM, Mikolaj Izdebski wrote: As a solution I have created a plugin for Maven that can install the whole project in Fedora way. It creates all necessary directories in buildroot, installs pom.xml and jar files, creates depmaps as needed, installs javadocs. With this plugin the whole %install section of typical packages (including multi-artifact ones) can be reduced to a single line. What do you think about this idea? Would you like to see it implemented in Fedora? Terrific. Although I'm not a packager I would like to see it in action. Let's talk about it at the Java SIG Meeting next week [1]. TR [1] https://fedoraproject.org/w/index.php?title=Meeting:Java_SIG_2012-09 -- Tomas Radej FAS, IRC nick tradej -- java-devel mailing list java-devel@lists.fedoraproject.org https://admin.fedoraproject.org/mailman/listinfo/java-devel |
Maven plugin to simplify spec %install section
> Is the source available somewhere?
Not yet. We still need to decide if this code should be a part of maven package or a separate package. I'm personally for the first solution. Mikolaj Izdebski -- java-devel mailing list java-devel@lists.fedoraproject.org https://admin.fedoraproject.org/mailman/listinfo/java-devel |
Maven plugin to simplify spec %install section
Quoting Mikolaj Izdebski (2012-09-11 14:23:14)
> > Is the source available somewhere? > > Not yet. We still need to decide if this code should be a part of maven > package or a separate package. I'm personally for the first solution. Yet another option is including it with javapackages-tools which contains rpm-packaging support already although not Maven specific. I see no problem with adding Maven-specific plugin even if javapackages-tools don't require Maven. The plugin is not going to be used outside Maven java artifacts anyway... -- Stanislav Ochotnicky <sochotnicky@redhat.com> Software Engineer - Base Operating Systems Brno PGP: 7B087241 Red Hat Inc. http://cz.redhat.com -- java-devel mailing list java-devel@lists.fedoraproject.org https://admin.fedoraproject.org/mailman/listinfo/java-devel |
Maven plugin to simplify spec %install section
> Yet another option is including it with javapackages-tools which
> contains rpm-packaging support already although not Maven specific. I > see no problem with adding Maven-specific plugin even if > javapackages-tools don't require Maven. The plugin is not going to be > used outside Maven java artifacts anyway... Let's say the script that invokes my plugin would be called mvn-rpminstall. Why mvn-rpmbuild would be part part of maven package, while mvn-rpminstall part of javapackages-tools? Both are Fedora-specific extensions to upstream Maven. For me it would be the best to package them in the same fashion. Mikolaj Izdebski -- java-devel mailing list java-devel@lists.fedoraproject.org https://admin.fedoraproject.org/mailman/listinfo/java-devel |
Maven plugin to simplify spec %install section
Quoting Mikolaj Izdebski (2012-09-11 14:33:47)
> > Yet another option is including it with javapackages-tools which > > contains rpm-packaging support already although not Maven specific. I > > see no problem with adding Maven-specific plugin even if > > javapackages-tools don't require Maven. The plugin is not going to be > > used outside Maven java artifacts anyway... > > Let's say the script that invokes my plugin would be called mvn-rpminstall. > Why mvn-rpmbuild would be part part of maven package, while mvn-rpminstall > part of javapackages-tools? Both are Fedora-specific extensions to upstream > Maven. For me it would be the best to package them in the same fashion. Indeed looking from that POV it looks sensible to put it in Maven. I am looking at it from my knowledge of patches that Maven itself carries. mvn-rpmbuild directly depends on those patches while mvn-rpminstall does not (AFAIK). In the end it's not *that* important since Maven pulls in javapackages-tools through jpackage-utils dependency anyway. I just wanted to keep our Maven package simple and close to upstream content. I basically boils down to: which option will confuse packagers and downstream distributions using our Java stack less... -- Stanislav Ochotnicky <sochotnicky@redhat.com> Software Engineer - Base Operating Systems Brno PGP: 7B087241 Red Hat Inc. http://cz.redhat.com -- java-devel mailing list java-devel@lists.fedoraproject.org https://admin.fedoraproject.org/mailman/listinfo/java-devel |
Maven plugin to simplify spec %install section
On 09/11/2012 02:43 PM, Stanislav Ochotnicky wrote:
Quoting Mikolaj Izdebski (2012-09-11 14:33:47) Yet another option is including it with javapackages-tools which contains rpm-packaging support already although not Maven specific. I see no problem with adding Maven-specific plugin even if javapackages-tools don't require Maven. The plugin is not going to be used outside Maven java artifacts anyway... Let's say the script that invokes my plugin would be called mvn-rpminstall. Why mvn-rpmbuild would be part part of maven package, while mvn-rpminstall part of javapackages-tools? Both are Fedora-specific extensions to upstream Maven. For me it would be the best to package them in the same fashion. Indeed looking from that POV it looks sensible to put it in Maven. I am looking at it from my knowledge of patches that Maven itself carries. mvn-rpmbuild directly depends on those patches while mvn-rpminstall does not (AFAIK). In the end it's not *that* important since Maven pulls in javapackages-tools through jpackage-utils dependency anyway. I just wanted to keep our Maven package simple and close to upstream content. I basically boils down to: which option will confuse packagers and downstream distributions using our Java stack less... If it is a clean plugin it could just be a separate package depending on maven. That way everything stays as clean as it currently is. Carlo -- java-devel mailing list java-devel@lists.fedoraproject.org https://admin.fedoraproject.org/mailman/listinfo/java-devel |
Maven plugin to simplify spec %install section
> If it is a clean plugin it could just be a separate package depending on
> maven. > That way everything stays as clean as it currently is. It is a clean plugin that requires only maven and java, but unless it has a corresponding script in /usr/bin or rpm macro in /etc/rpm it's invocation wouldn't be nice. Which one you prefer: mvn-rpmbuild org.fedoraproject.somelonggroupname:install-mojo:install or maybe: mvn-rpminstall I like the second one more :) Mikolaj Izdebski -- java-devel mailing list java-devel@lists.fedoraproject.org https://admin.fedoraproject.org/mailman/listinfo/java-devel |
Maven plugin to simplify spec %install section
On 09/11/2012 01:58 PM, Mikolaj Izdebski wrote:
Hello all, As you know, %build section of the majority of all Java packages built with Maven is fairly simple, usually consisting of a single call to mvn-rpmbuild. But the install section can still be long and complicated, especially for large packages. As a solution I have created a plugin for Maven that can install the whole project in Fedora way. It creates all necessary directories in buildroot, installs pom.xml and jar files, creates depmaps as needed, installs javadocs. With this plugin the whole %install section of typical packages (including multi-artifact ones) can be reduced to a single line. What do you think about this idea? Would you like to see it implemented in Fedora? Mikolaj Izdebski -- java-devel mailing list java-devel@lists.fedoraproject.org https://admin.fedoraproject.org/mailman/listinfo/java-devel I do want to add a blast from the past to this thread: On 02/17/2012 10:49 AM, Carlo de Wolf wrote: I just would like to see maven artifacts 'properly' installed in /usr/share/maven/repository. Then we can let upstream maven (and other tools) use that. Carlo It would need an extension to be able to use that repo if we let the pom fall in unchecked. Something like https://github.com/fmvn/foss-maven. But ultimately such a repository should be fully valid to the rules of Maven. We could use a tool like https://github.com/jdcasey/repository-validator to assert that. The only and very important gap is getting from 'world consuming' poms to sanctioned repo poms in some sort of automated way. Ultimately it would fall in the area of concern your tool is covering. Carlo -- java-devel mailing list java-devel@lists.fedoraproject.org https://admin.fedoraproject.org/mailman/listinfo/java-devel |
| All times are GMT. The time now is 06:12 PM. |
VBulletin, Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.