Ticket #11874: Portfile

File Portfile, 1.9 KB (added by gk5885@…, 17 years ago)

updated portfile for 2.0.6

Line 
1
2PortSystem 1.0
3
4name                    maven2
5version                 2.0.6
6
7categories              java devel
8maintainers             gk5885@kickstyle.net
9platforms               darwin
10
11description             A java-based build and project management environment.
12long_description        Maven is a Java project management and project comprehension \
13                                tool. Maven is based on the concept of a project object model (POM) \
14                                in that all the artifacts produced by Maven are a result of consulting \
15                                a well defined model for your project. Builds, documentation, source \
16                                metrics, and source  cross-references are all controlled by your POM.  \
17                                Maven 2.0 is a complete rewrite of Maven 1.0 and as such is better organized, \
18                                faster and easier to use.
19homepage                http://maven.apache.org/
20
21master_sites            apache:maven/binaries
22distname                maven-${version}-bin
23worksrcdir              maven-${version}
24use_bzip2               yes
25checksums               md5 733f99a0dc7370d6d9cd4df3740ffa47
26
27depends_build           bin:java:kaffe
28                                       
29use_configure           no
30use_bzip2                       yes
31
32# Source builds of maven are not possible. So, the default build is a binary
33# install of the jars.
34build.cmd               true
35
36destroot {
37        # Create the target java directory exists
38        xinstall -m 755 -d ${destroot}${prefix}/share/java/${name}
39       
40        # Copy over the needed elements of our directory tree
41        file copy \
42                ${worksrcpath}/bin \
43                ${worksrcpath}/lib \
44                ${worksrcpath}/core \
45                ${worksrcpath}/conf \
46                ${destroot}${prefix}/share/java/${name}
47               
48        # Remove extraneous bat files
49        foreach f [glob -directory ${destroot}${prefix}/share/java/${name}/bin *.bat] {
50                file delete $f
51        }
52       
53        # Fix permissions on shell scripts
54        foreach f { maven install_repo.sh } {
55                if [file exists ${destroot}${prefix}/share/java/${name}/bin/$f] {
56                        file attributes ${destroot}${prefix}/share/java/${name}/bin/$f -permissions +x
57                }
58        }
59       
60        # Symlink maven into the bin directory
61        system "cd ${destroot}${prefix}/bin && ln -s ${prefix}/share/java/${name}/bin/mvn"
62}
63