Quoting Brett Porter (2012-03-21 21:06:05)
>http://svn.apache.org/repos/asf/maven/sandbox/trunk/rpm
>
>$ mvn install
>$ sudo rpm -ivh 
>~/.m2/repository/org/apache/maven/rpm/maven/3.0.4/maven-3.0.4.rpm 
>
>Tested on CentOS 6.0.
>
>It installs to /usr/local/maven and /usr/local/bin/mvn. It also adds 
>/etc/profile.d/maven.sh to add the bin directory to the PATH and M2_HOME 
>variable, though neither are strictly necessary. Open to suggestions on 
>improvements.

I've had a look at the produced spec file and file layout and I do have
a few suggestions:

1. Put maven into /usr/share/maven instead of /usr/local/maven. Or if
   you really want to put it into /usr/local subtree then
   /usr/local/share/maven. /usr/local/maven is...at least weird from
   FHS perspective. And then just symlink scripts into
   /usr/[local/]bin.

2. Your license tag doesn't state license, just copyright. In most RPM Linux
   distributions this would probably contain "ASL 2.0". Full license name
   would be OK as well I guess

3. URL should probably be maven.apache.org instead of plain apache.org

4. Put settings.xml into /etc/ subtree (/etc/maven/ possibly) and
   symlink it back to M2_HOME (possibly same thing for m2.conf). It
   should also be marked as config file.

5. Handling of license/readme etc is different on different distros so I
   guess that can stay inside M2_HOME

6. A nice sensible %description copied from main site would be nice :-)

>
>I removed and requirement on a JDK package, to avoid requiring one alternative 
>over another. Open to suggestions if there is a better way to express that in 
>the spec file.

7. I have asked around a bit and it might make sense to add "Requires:
   java" (or java-devel) to the resulting RPM/spec. It would work at
   least on Fedora/SuSE/Mageia stack I would assume that works as well.
   But proprietary Oracle JDK rpm doesn't have this provides so it means
   we'd still pull in additional jdk. Oh well..


All in all seems we've both chosen to produce rpms of maven. I've taken
the approach from RPM side and you from Maven side, both producing
workable RPMS. Your approach could work in Jenkins more easily I guess
to produce new builds of maven.

By the time I got here I realized I could have just prepared a patch for
your pom.xml instead of writing all this :-/ Anyway, I if you want to
help with this feel free to get in touch off-list and I'll help when I
can. If nothing else I believe I have pretty good idea what Linux
distributions prefer/expect when dealing with rpms.



>On 22/03/2012, at 6:29 AM, Brett Porter wrote:
>
>> 
>> On 22/03/2012, at 1:01 AM, Brian Fox wrote:
>> 
>>> Has anyone considered making an rpm/deb bundle that essentially
>>> contains a script which can fetch the associated tar.gz from the
>>> apache site and unpack it?
>> 
>> We've had one at MaestroDev for a while. I'll clean it up, give it a spin, 
>> and put it in the sandbox. Interested users can at least build their own 
>> then.
>> 
>> Cheers,
>> Brett
>> 
>> --
>> Brett Porter
>> br...@apache.org
>> http://brettporter.wordpress.com/
>> http://au.linkedin.com/in/brettporter
>> http://twitter.com/brettporter
>> 
>> 
>> 
>> 
>> 
>
>--
>Brett Porter
>br...@apache.org
>http://brettporter.wordpress.com/
>http://au.linkedin.com/in/brettporter
>http://twitter.com/brettporter
>
>
>
>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
>For additional commands, e-mail: dev-h...@maven.apache.org

-- 
Stanislav Ochotnicky <sochotni...@redhat.com>
Software Engineer - Base Operating Systems Brno

PGP: 7B087241
Red Hat Inc.                               http://cz.redhat.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org

Reply via email to