[72311] trunk/dports/java/maven3/Portfile

blair at macports.org blair at macports.org
Sun Oct 10 07:32:06 PDT 2010


Revision: 72311
          http://trac.macports.org/changeset/72311
Author:   blair at macports.org
Date:     2010-10-10 07:32:04 -0700 (Sun, 10 Oct 2010)
Log Message:
-----------
Set and use ${mavendir} to make the port shorter and easier to read.

Modified Paths:
--------------
    trunk/dports/java/maven3/Portfile

Modified: trunk/dports/java/maven3/Portfile
===================================================================
--- trunk/dports/java/maven3/Portfile	2010-10-10 14:29:51 UTC (rev 72310)
+++ trunk/dports/java/maven3/Portfile	2010-10-10 14:32:04 UTC (rev 72311)
@@ -45,8 +45,10 @@
 build.cmd       true
 
 destroot {
+        set mavendir ${destroot}${prefix}/share/java/${name}
+
         # Create the target java directory exists
-        xinstall -m 755 -d ${destroot}${prefix}/share/java/${name}
+        xinstall -m 755 -d ${mavendir}
         
         # Copy over the needed elements of our directory tree
         file copy \
@@ -54,27 +56,27 @@
                 ${worksrcpath}/boot \
                 ${worksrcpath}/conf \
                 ${worksrcpath}/lib \
-                ${destroot}${prefix}/share/java/${name}
+                ${mavendir}
                 
         # Remove extraneous bat files
-        foreach f [glob -directory ${destroot}${prefix}/share/java/${name}/bin *.bat] {
+        foreach f [glob -directory ${mavendir}/bin *.bat] {
                 file delete $f
         }
         
         # Fix permissions on shell scripts
         foreach f { maven install_repo.sh } {
-                if [file exists ${destroot}${prefix}/share/java/${name}/bin/$f] {
-                        file attributes ${destroot}${prefix}/share/java/${name}/bin/$f -permissions +x
+                if [file exists ${mavendir}/bin/$f] {
+                        file attributes ${mavendir}/bin/$f -permissions +x
                 }
         }
 
         # Reduce the permissions on the distribution files.
-        file attributes ${destroot}${prefix}/share/java/${name}/conf -permissions 0755
-        file attributes ${destroot}${prefix}/share/java/${name}/conf/settings.xml -permissions 0644
-        foreach f [glob -directory ${destroot}${prefix}/share/java/${name}/boot *.jar] {
+        file attributes ${mavendir}/conf -permissions 0755
+        file attributes ${mavendir}/conf/settings.xml -permissions 0644
+        foreach f [glob -directory ${mavendir}/boot *.jar] {
                 file attributes $f -permissions 0644
         }
-        foreach f [glob -directory ${destroot}${prefix}/share/java/${name}/lib *.jar] {
+        foreach f [glob -directory ${mavendir}/lib *.jar] {
                 file attributes $f -permissions 0644
         }
         
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20101010/7cfa1acb/attachment.html>


More information about the macports-changes mailing list