[26841] trunk/dports/sysutils/MacPorts/Portfile

source_changes at macosforge.org source_changes at macosforge.org
Mon Jul 9 12:12:54 PDT 2007


Revision: 26841
          http://trac.macosforge.org/projects/macports/changeset/26841
Author:   jmpp at macports.org
Date:     2007-07-09 12:12:53 -0700 (Mon, 09 Jul 2007)

Log Message:
-----------

Move the long and annoying destroot.keepdirs stuff to the end of the Portfile, making the platforms declarations easier to read.

Modified Paths:
--------------
    trunk/dports/sysutils/MacPorts/Portfile

Modified: trunk/dports/sysutils/MacPorts/Portfile
===================================================================
--- trunk/dports/sysutils/MacPorts/Portfile	2007-07-09 19:12:17 UTC (rev 26840)
+++ trunk/dports/sysutils/MacPorts/Portfile	2007-07-09 19:12:53 UTC (rev 26841)
@@ -20,6 +20,62 @@
 			sha1 8e1f83308eef5971112ccdd734a8d48fd77673b3 \
 			rmd160 1f35a7a7f2827794741bd57641ec5c32d8272467
 
+# Some of MacPort's default flags don't play well when we're building
+# MacPorts itself: nuke them
+configure.cppflags
+configure.ldflags
+
+post-pkg {
+	set resources ${workpath}/${name}-${version}.pkg/Contents/Resources/
+	file copy -force -- ${filespath}/ReadMe.rtf ${resources}
+	file copy -force -- ${filespath}/License.html ${resources}
+        file copy -force -- ${filespath}/preflight ${resources}
+	file copy -force -- ${filespath}/postflight ${resources}
+}
+
+platform darwin 7 {
+	 post-pkg {
+		  set resources ${workpath}/${name}-${version}.pkg/Contents/Resources/
+		  reinplace "s|__XVERS__|10.3|" ${resources}/ReadMe.rtf
+		  reinplace "s|or newer ||" ${resources}/Welcome.html
+	 }
+}
+
+platform darwin 8 {
+	 post-pkg {
+		  set resources ${workpath}/${name}-${version}.pkg/Contents/Resources/
+		  reinplace "s|is built|contains a Universal binary|" ${resources}/ReadMe.rtf
+		  reinplace "s|__XVERS__|10.4|" ${resources}/ReadMe.rtf
+		  reinplace "s|3|4|" ${resources}/Welcome.html
+		  reinplace "s|or newer ||" ${resources}/Welcome.html
+	 }
+}
+
+platform darwin 8 powerpc {
+	pre-configure {
+		set sdkrootpath /Developer/SDKs/MacOSX10.4u.sdk
+		if {[file exists ${sdkrootpath}]} {
+			# User has Universal SDK installed.
+			set tclstubpath /System/Library/Frameworks/Tcl.framework/Versions/8.4/libtclstub8.4.a
+			if {![file exists ${sdkrootpath}${tclstubpath}]} {
+				ui_msg "Fixing your MacOSX10.4u installation by copying libtclstub8.4.a to\
+				 ${sdkrootpath}${tclstubpath}"
+				 xinstall -p ${tclstubpath} ${sdkrootpath}${tclstubpath}
+			}
+			# Supply architecture flags to build MacPorts as fat
+            configure.cflags-append -isysroot ${sdkrootpath} -arch ppc -arch i386
+            configure.env-append SHLIB_LDFLAGS='-Wl,-syslibroot,${sdkrootpath} -arch ppc -arch i386'
+		}
+	}
+}
+
+platform darwin 8 i386 {
+	# Supply architecture flags to build MacPorts as fat on an Intel Mac
+	configure.cflags-append -arch ppc -arch i386
+    configure.args-append SHLIB_LDFLAGS='-arch ppc -arch i386'
+}
+
+
 destroot.keepdirs       ${destroot}${prefix}/include \
                         ${destroot}${prefix}/lib ${destroot}${prefix}/libexec \
                         ${destroot}${prefix}/sbin \
@@ -116,61 +172,3 @@
                         ${destroot}${prefix}/share/nls/zh_TW.Big5 \
                         ${destroot}${prefix}/var/macports/distfiles \
                         ${destroot}${prefix}/var/macports/receipts
-
-
-# Some of MacPort's default flags don't play well when we're building
-# MacPorts itself: nuke them
-configure.cppflags
-configure.ldflags
-
-
-post-pkg {
-	set resources ${workpath}/${name}-${version}.pkg/Contents/Resources/
-	file copy -force -- ${filespath}/ReadMe.rtf ${resources}
-	file copy -force -- ${filespath}/License.html ${resources}
-        file copy -force -- ${filespath}/preflight ${resources}
-	file copy -force -- ${filespath}/postflight ${resources}
-}
-
-platform darwin 7 {
-	 post-pkg {
-		  set resources ${workpath}/${name}-${version}.pkg/Contents/Resources/
-		  reinplace "s|__XVERS__|10.3|" ${resources}/ReadMe.rtf
-		  reinplace "s|or newer ||" ${resources}/Welcome.html
-	 }
-}
-
-platform darwin 8 {
-	 post-pkg {
-		  set resources ${workpath}/${name}-${version}.pkg/Contents/Resources/
-		  reinplace "s|is built|contains a Universal binary|" ${resources}/ReadMe.rtf
-		  reinplace "s|__XVERS__|10.4|" ${resources}/ReadMe.rtf
-		  reinplace "s|3|4|" ${resources}/Welcome.html
-		  reinplace "s|or newer ||" ${resources}/Welcome.html
-	 }
-}
-
-platform darwin 8 powerpc {
-	pre-configure {
-		set sdkrootpath /Developer/SDKs/MacOSX10.4u.sdk
-		if {[file exists ${sdkrootpath}]} {
-			# User has Universal SDK installed.
-			set tclstubpath /System/Library/Frameworks/Tcl.framework/Versions/8.4/libtclstub8.4.a
-			if {![file exists ${sdkrootpath}${tclstubpath}]} {
-				ui_msg "Fixing your MacOSX10.4u installation by copying libtclstub8.4.a to\
-				 ${sdkrootpath}${tclstubpath}"
-				 xinstall -p ${tclstubpath} ${sdkrootpath}${tclstubpath}
-			}
-			# Supply architecture flags to build MacPorts as fat
-            configure.cflags-append -isysroot ${sdkrootpath} -arch ppc -arch i386
-            configure.env-append SHLIB_LDFLAGS='-Wl,-syslibroot,${sdkrootpath} -arch ppc -arch i386'
-		}
-	}
-}
-
-
-platform darwin 8 i386 {
-	# Supply architecture flags to build MacPorts as fat on an Intel Mac
-	configure.cflags-append -arch ppc -arch i386
-    configure.args-append SHLIB_LDFLAGS='-arch ppc -arch i386'
-}

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.macosforge.org/pipermail/macports-changes/attachments/20070709/78b68dbd/attachment.html


More information about the macports-changes mailing list