[61500] trunk/dports/lang/hugs98

mww at macports.org mww at macports.org
Sun Dec 13 04:09:24 PST 2009


Revision: 61500
          http://trac.macports.org/changeset/61500
Author:   mww at macports.org
Date:     2009-12-13 04:09:19 -0800 (Sun, 13 Dec 2009)
Log Message:
-----------
fix the 'Undefined symbols: "_environ"' error in 10.6 (still does not build though!) (--> http://trac.macports.org/ticket/20950)

Modified Paths:
--------------
    trunk/dports/lang/hugs98/Portfile

Added Paths:
-----------
    trunk/dports/lang/hugs98/files/
    trunk/dports/lang/hugs98/files/patch-packages-base-include-HsBase.h.diff

Modified: trunk/dports/lang/hugs98/Portfile
===================================================================
--- trunk/dports/lang/hugs98/Portfile	2009-12-13 10:54:25 UTC (rev 61499)
+++ trunk/dports/lang/hugs98/Portfile	2009-12-13 12:09:19 UTC (rev 61500)
@@ -22,6 +22,11 @@
 
 depends_lib	port:readline
 
+platform darwin 10 {
+    # This fixes the 'Undefined symbols: "_environ"' error
+    patchfiles-append patch-packages-base-include-HsBase.h.diff
+}
+
 livecheck.type	regex
 livecheck.url	${master_sites}
 livecheck.regex	hugs98-\(plus-\[A-Za-z\]+200\[6-9\]\)\.tar.gz

Added: trunk/dports/lang/hugs98/files/patch-packages-base-include-HsBase.h.diff
===================================================================
--- trunk/dports/lang/hugs98/files/patch-packages-base-include-HsBase.h.diff	                        (rev 0)
+++ trunk/dports/lang/hugs98/files/patch-packages-base-include-HsBase.h.diff	2009-12-13 12:09:19 UTC (rev 61500)
@@ -0,0 +1,17 @@
+--- packages/base/include/HsBase.h	2006-09-21 00:28:37.000000000 +0200
++++ packages/base/include/HsBase.h	2009-12-13 12:52:32.000000000 +0100
+@@ -764,7 +764,13 @@
+ 
+ /* ToDo: write a feature test that doesn't assume 'environ' to
+  *    be in scope at link-time. */
+-extern char** environ;
++#ifdef __APPLE__
++#include <crt_externs.h>
++#define environ (*_NSGetEnviron())
++#else
++ extern char **environ;
++#endif
++
+ INLINE char **__hscore_environ() { return environ; }
+ 
+ /* lossless conversions between pointers and integral types */
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20091213/e3990eae/attachment.html>


More information about the macports-changes mailing list