[127151] trunk/dports/x11/tk

larryv at macports.org larryv at macports.org
Tue Oct 21 18:52:22 PDT 2014


Revision: 127151
          https://trac.macports.org/changeset/127151
Author:   larryv at macports.org
Date:     2014-10-21 18:52:22 -0700 (Tue, 21 Oct 2014)
Log Message:
-----------
tk: Fix Yosemite version checking (#45444)

Patch taken from upstream and should be removed with 8.6.3 update
(http://core.tcl.tk/tk/info/e49c25c711d967071683aa108e39649a832036da).

Modified Paths:
--------------
    trunk/dports/x11/tk/Portfile

Added Paths:
-----------
    trunk/dports/x11/tk/files/fix-yosemite-version-checking.patch

Modified: trunk/dports/x11/tk/Portfile
===================================================================
--- trunk/dports/x11/tk/Portfile	2014-10-22 01:08:59 UTC (rev 127150)
+++ trunk/dports/x11/tk/Portfile	2014-10-22 01:52:22 UTC (rev 127151)
@@ -4,7 +4,7 @@
 
 name            tk
 version         8.6.1
-revision        1
+revision        2
 categories      x11
 license         Tcl/Tk
 maintainers     mww openmaintainer
@@ -51,6 +51,9 @@
                       patch-unix_configure.diff
 }
 
+# Remove when updated to 8.6.3 (#45444).
+patchfiles-append   fix-yosemite-version-checking.patch
+
 post-patch {
     reinplace s|@TCL_SRC_DIR@|${workpath}/tcl${version}/|g ${worksrcpath}/Makefile.in
 }

Added: trunk/dports/x11/tk/files/fix-yosemite-version-checking.patch
===================================================================
--- trunk/dports/x11/tk/files/fix-yosemite-version-checking.patch	                        (rev 0)
+++ trunk/dports/x11/tk/files/fix-yosemite-version-checking.patch	2014-10-22 01:52:22 UTC (rev 127151)
@@ -0,0 +1,27 @@
+Index: macosx/tkMacOSXInit.c
+==================================================================
+--- macosx/tkMacOSXInit.c
++++ macosx/tkMacOSXInit.c
+@@ -234,15 +234,20 @@
+ #endif
+ 
+ 	if (!uname(&name)) {
+ 	    tkMacOSXMacOSXVersion = (strtod(name.release, NULL) + 96) * 10;
+ 	}
+-	if (tkMacOSXMacOSXVersion &&
++       /*Check for new versioning scheme on Yosemite (10.10) and later.*/
++	if (MAC_OS_X_VERSION_MIN_REQUIRED > 100000) {
++		tkMacOSXMacOSXVersion = MAC_OS_X_VERSION_MIN_REQUIRED/100;
++	    }
++	if (tkMacOSXMacOSXVersion && MAC_OS_X_VERSION_MIN_REQUIRED < 100000 &&
+ 		tkMacOSXMacOSXVersion/10 < MAC_OS_X_VERSION_MIN_REQUIRED/10) {
+ 	    Tcl_Panic("Mac OS X 10.%d or later required !",
+ 		    (MAC_OS_X_VERSION_MIN_REQUIRED/10)-100);
+ 	}
++	
+ 
+ #ifdef TK_FRAMEWORK
+ 	/*
+ 	 * When Tk is in a framework, force tcl_findLibrary to look in the
+ 	 * framework scripts directory.
+
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20141021/1f84af8b/attachment.html>


More information about the macports-changes mailing list