Name: xmvn Version: 0.5.1 Release: 3%{?dist} Summary: Local Extensions for Apache Maven License: ASL 2.0 URL: http://mizdebsk.fedorapeople.org/xmvn BuildArch: noarch Source0: https://fedorahosted.org/released/%{name}/%{name}-%{version}.tar.xz # from upstream commit ccc197d to fix NPE Patch0: 0001-Be-careful-when-unboxing-Boolean-that-can-be-null.patch # from upstream commits f62ca1f and f6b2c9 to fix handling of packages with dots # in groupid Patch1: 0002-Implement-desired-handling-dots-in-JPP-groupId.patch # from upstream commits 44d9c60 and bf7b9a7 to allow resolution # of tools.jar without specifying system scope or systemPath Patch2: 0003-Implement-Java-home-resolver.patch # Allow installation of Eclipse plugins in javadir Patch3: %{name}-eclipse-plugin.patch BuildRequires: maven >= 3.1.0 BuildRequires: maven-local BuildRequires: beust-jcommander BuildRequires: cglib BuildRequires: maven-dependency-plugin BuildRequires: maven-plugin-build-helper BuildRequires: maven-assembly-plugin Requires: maven >= 3.1.0 %description This package provides extensions for Apache Maven that can be used to manage system artifact repository and use it to resolve Maven artifacts in offline mode, as well as Maven plugins to help with creating RPM packages containing Maven artifacts. %package javadoc Summary: API documentation for %{name} %description javadoc This package provides %{summary}. %prep %setup -q %patch0 -p1 %patch1 -p1 %patch2 -p1 %patch3 # Add cglib test dependency as a workaround for rhbz#911365 %pom_add_dep cglib:cglib::test %{name}-core # remove dependency plugin, we provide apache-maven by symlink %pom_remove_plugin :maven-dependency-plugin # get mavenVersion that is expected mver=$(sed -n '//{s/.*>\(.*\)<.*/\1/;p}' \ xmvn-parent/pom.xml) mkdir -p target/dependency/ ln -s %{_datadir}/maven target/dependency/apache-maven-$mver %build %mvn_file ":{xmvn-{core,connector}}" %{name}/@1 %{_datadir}/%{name}/lib/@1 %mvn_build -X tar --delay-directory-restore -xvf target/*tar.bz2 chmod -R +rwX %{name}-%{version}* %install %mvn_install cp -r %{name}-%version/* %{buildroot}%{_datadir}/%{name}/ ln -sf %{_datadir}/maven/bin/mvn %{buildroot}%{_datadir}/%{name}/bin/mvn ln -sf %{_datadir}/maven/bin/mvnDebug %{buildroot}%{_datadir}/%{name}/bin/mvnDebug ln -sf %{_datadir}/maven/bin/mvnyjp %{buildroot}%{_datadir}/%{name}/bin/mvnyjp # helper scripts install -d -m 755 %{buildroot}%{_bindir} install -m 755 xmvn-tools/src/main/bin/tool-script \ %{buildroot}%{_datadir}/%{name}/bin/ for tool in subst resolve bisect;do rm %{buildroot}%{_datadir}/%{name}/bin/%{name}-$tool ln -s tool-script \ %{buildroot}%{_datadir}/%{name}/bin/%{name}-$tool cat <%{buildroot}%{_bindir}/%{name}-$tool #!/bin/sh -e exec %{_datadir}/%{name}/bin/%{name}-$tool "\${@}" EOF chmod +x %{buildroot}%{_bindir}/%{name}-$tool done # copy over maven lib directory cp -r %{_datadir}/maven/lib/* %{buildroot}%{_datadir}/%{name}/lib/ # possibly recreate symlinks that can be automated with xmvn-subst %{buildroot}%{_datadir}/%{name}/bin/%{name}-subst \ %{buildroot}%{_datadir}/%{name}/ for mod in api connector-wagon impl spi util; do ln -sf %{_javadir}/aether/aether-$mod.jar \ %{buildroot}%{_datadir}/%{name}/lib/aether_aether-$mod.jar done ln -s %{_sysconfdir}/maven/logging %{buildroot}%{_datadir}/%{name}/conf # /usr/bin/xmvn script cat <%{buildroot}%{_bindir}/%{name} #!/bin/sh -e export M2_HOME="\${M2_HOME:-%{_datadir}/%{name}}" exec mvn "\${@}" EOF # make sure our conf is identical to maven so yum won't freak out cp -P %{_datadir}/maven/conf/settings.xml %{buildroot}%{_datadir}/%{name}/conf/ %pretrans -p -- we changed symlink to dir in 0.5.0-1, workaround RPM issues for key, dir in pairs({"conf", "boot"}) do path = "%{_datadir}/%{name}/" .. dir if posix.readlink(path) then os.remove(path) end end %files -f .mfiles %doc LICENSE NOTICE %doc AUTHORS README %attr(755,-,-) %{_bindir}/* %{_datadir}/%{name} %files javadoc -f .mfiles-javadoc %doc LICENSE NOTICE %changelog * Tue Jul 23 2013 Mikolaj Izdebski - 0.5.1-3 - Rebuild without bootstrapping * Tue Jul 23 2013 Mikolaj Izdebski - 0.5.1-2 - Install symlink to simplelogger.properties in %{_sysconfdir} * Tue Jul 23 2013 Mikolaj Izdebski - 0.5.1-1 - Update to upstream version 0.5.1 * Tue Jul 23 2013 Mikolaj Izdebski - 0.5.0-7 - Allow installation of Eclipse plugins in javadir * Mon Jul 22 2013 Mikolaj Izdebski - 0.5.0-6 - Remove workaround for plexus-archiver bug - Use sonatype-aether symlinks * Wed Jun 5 2013 Mikolaj Izdebski - 0.5.0-5 - Fix resolution of tools.jar * Fri May 31 2013 Stanislav Ochotnicky - 0.5.0-4 - Fix handling of packages with dots in groupId - Previous versions also fixed bug #948731 * Tue May 28 2013 Stanislav Ochotnicky - 0.5.0-3 - Move pre scriptlet to pretrans and implement in lua * Fri May 24 2013 Stanislav Ochotnicky - 0.5.0-2 - Fix upgrade path scriptlet - Add patch to fix NPE when debugging is disabled * Fri May 24 2013 Stanislav Ochotnicky - 0.5.0-1 - Update to upstream version 0.5.0 * Fri May 17 2013 Mikolaj Izdebski - 0.4.2-3 - Add patch: install MOJO fix * Wed Apr 17 2013 Mikolaj Izdebski - 0.4.2-2 - Update plexus-containers-container-default JAR location * Tue Apr 9 2013 Mikolaj Izdebski - 0.4.2-1 - Update to upstream version 0.4.2 * Thu Mar 21 2013 Michal Srb - 0.4.1-1 - Update to upstream version 0.4.1 * Fri Mar 15 2013 Mikolaj Izdebski - 0.4.0-1 - Update to upstream version 0.4.0 * Fri Mar 15 2013 Mikolaj Izdebski - 0.4.0-0.7 - Enable tests * Thu Mar 14 2013 Mikolaj Izdebski - 0.4.0-0.6 - Update to newer snapshot * Wed Mar 13 2013 Mikolaj Izdebski - 0.4.0-0.5 - Update to newer snapshot * Wed Mar 13 2013 Mikolaj Izdebski - 0.4.0-0.4 - Set proper permissions for scripts in _bindir * Tue Mar 12 2013 Mikolaj Izdebski - 0.4.0-0.3 - Update to new upstream snapshot - Create custom /usr/bin/xmvn instead of using %%jpackage_script - Mirror maven directory structure - Add Plexus Classworlds config file * Wed Mar 6 2013 Mikolaj Izdebski - 0.4.0-0.2 - Update to newer snapshot * Wed Mar 6 2013 Mikolaj Izdebski - 0.4.0-0.1 - Update to upstream snapshot of version 0.4.0 * Mon Feb 25 2013 Mikolaj Izdebski - 0.3.1-2 - Install effective POMs into a separate directory * Thu Feb 7 2013 Mikolaj Izdebski - 0.3.1-1 - Update to upstream version 0.3.1 * Tue Feb 5 2013 Mikolaj Izdebski - 0.3.0-1 - Update to upstream version 0.3.0 - Don't rely on JPP symlinks when resolving artifacts - Blacklist more artifacts - Fix dependencies * Thu Jan 24 2013 Mikolaj Izdebski - 0.2.6-1 - Update to upstream version 0.2.6 * Mon Jan 21 2013 Mikolaj Izdebski - 0.2.5-1 - Update to upstream version 0.2.5 * Fri Jan 11 2013 Mikolaj Izdebski - 0.2.4-1 - Update to upstream version 0.2.4 * Wed Jan 9 2013 Mikolaj Izdebski - 0.2.3-1 - Update to upstream version 0.2.3 * Tue Jan 8 2013 Mikolaj Izdebski - 0.2.2-1 - Update to upstream version 0.2.2 * Tue Jan 8 2013 Mikolaj Izdebski - 0.2.1-1 - Update to upstream version 0.2.1 * Mon Jan 7 2013 Mikolaj Izdebski - 0.2.0-1 - Update to upstream version 0.2.0 - New major features: depmaps, compat symlinks, builddep MOJO - Install effective POMs for non-POM artifacts - Multiple major and minor bugfixes - Drop support for resolving artifacts from %%_javajnidir * Fri Dec 7 2012 Mikolaj Izdebski - 0.1.5-1 - Update to upstream version 0.1.5 * Fri Dec 7 2012 Mikolaj Izdebski - 0.1.4-1 - Update to upstream version 0.1.4 * Fri Dec 7 2012 Mikolaj Izdebski - 0.1.3-1 - Update to upstream version 0.1.3 * Fri Dec 7 2012 Mikolaj Izdebski - 0.1.2-1 - Update to upstream version 0.1.2 * Fri Dec 7 2012 Mikolaj Izdebski - 0.1.1-1 - Update to upstream version 0.1.1 * Thu Dec 6 2012 Mikolaj Izdebski - 0.1.0-1 - Update to upstream version 0.1.0 - Implement auto requires generator * Mon Dec 3 2012 Mikolaj Izdebski - 0.0.2-1 - Update to upstream version 0.0.2 * Thu Nov 29 2012 Mikolaj Izdebski - 0.0.1-1 - Update to upstream version 0.0.1 * Wed Nov 28 2012 Mikolaj Izdebski - 0-2 - Add jpackage scripts * Mon Nov 5 2012 Mikolaj Izdebski - 0-1 - Initial packaging