[61577] trunk/dports/graphics/Box2D/Portfile

nox at macports.org nox at macports.org
Tue Dec 15 04:49:57 PST 2009


Revision: 61577
          http://trac.macports.org/changeset/61577
Author:   nox at macports.org
Date:     2009-12-15 04:49:55 -0800 (Tue, 15 Dec 2009)
Log Message:
-----------
Properly install every header of Box2D

Modified Paths:
--------------
    trunk/dports/graphics/Box2D/Portfile

Modified: trunk/dports/graphics/Box2D/Portfile
===================================================================
--- trunk/dports/graphics/Box2D/Portfile	2009-12-15 12:24:22 UTC (rev 61576)
+++ trunk/dports/graphics/Box2D/Portfile	2009-12-15 12:49:55 UTC (rev 61577)
@@ -5,7 +5,7 @@
                   
 name            Box2D
 version         2.0.2
-revision        1
+revision        2
 categories      graphics devel
 maintainers     nox openmaintainer
 license         as-is
@@ -24,9 +24,10 @@
                 sha1    e9a594eb51f57790f7b1b35eeddfce3735a16ca3 \
                 rmd160  68fc37a7ffe54747a837abed36b4e970d021c0ab
 
+set topsrcpath  ${workpath}/${distname}
 worksrcdir      ${distname}/Build/Xcode
 
-patch.dir       ${workpath}/${distname}
+patch.dir       ${topsrcpath}
 patchfiles      patch-osx-sl.diff
 
 xcode.configuration Release
@@ -36,8 +37,20 @@
     set app_path "${applications_dir}/Box2D Test Bed.app"
     set lib_path ${prefix}/lib/libbox2d.dylib
 
-    copy ${workpath}/${distname}/Include/Box2D.h \
+    set offset [expr [string length ${topsrcpath}/Source] + 1]
+    fs-traverse header ${topsrcpath}/Source {
+        if {[file extension ${header}] eq ".h"} {
+            set basename [string range ${header} ${offset} end]
+            set dest ${destroot}${prefix}/include/${basename}
+            xinstall -d [file dirname ${dest}]
+            xinstall -m 644 ${header} ${dest}
+        }
+    }
+
+    xinstall -m 644 ${topsrcpath}/Include/Box2D.h \
             ${destroot}${prefix}/include
+    reinplace s at ../Source/@@ ${destroot}${prefix}/include/Box2D.h
+
     delete ${destroot}${app_path}/Contents/MacOS/libBox2D.dylib
     move ${destroot}${applications_dir}/libBox2D.dylib \
             ${destroot}${lib_path}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20091215/a5f09024/attachment.html>


More information about the macports-changes mailing list