Revision: 144390 https://trac.macports.org/changeset/144390 Author: jeremyhu@macports.org Date: 2016-01-06 23:33:19 -0800 (Wed, 06 Jan 2016) Log Message: ----------- Xaw3d: Additional fixes for libXt symbol-fu Modified Paths: -------------- trunk/dports/x11/Xaw3d/Portfile Added Paths: ----------- trunk/dports/x11/Xaw3d/files/0001-darwin-Remove-incorrect-export-of-vendorShellClassRe.patch Removed Paths: ------------- trunk/dports/x11/Xaw3d/files/0001-darwin-Fixup-vendorShellWidgetClass.patch Modified: trunk/dports/x11/Xaw3d/Portfile =================================================================== --- trunk/dports/x11/Xaw3d/Portfile 2016-01-07 07:12:40 UTC (rev 144389) +++ trunk/dports/x11/Xaw3d/Portfile 2016-01-07 07:33:19 UTC (rev 144390) @@ -4,7 +4,7 @@ name Xaw3d version 1.6.2 -revision 1 +revision 2 categories x11 devel license X11 maintainers jeremyhu openmaintainer @@ -31,7 +31,7 @@ patch.pre_args -p1 patchfiles \ - 0001-darwin-Fixup-vendorShellWidgetClass.patch \ + 0001-darwin-Remove-incorrect-export-of-vendorShellClassRe.patch \ 0001-Xaw3d-1.6.1-3Dlabel.patch.patch \ 0002-Xaw3d-1.6.1-fontset.patch.patch \ 0003-Xaw3d-1.6.1-hsbar.patch.patch Deleted: trunk/dports/x11/Xaw3d/files/0001-darwin-Fixup-vendorShellWidgetClass.patch =================================================================== --- trunk/dports/x11/Xaw3d/files/0001-darwin-Fixup-vendorShellWidgetClass.patch 2016-01-07 07:12:40 UTC (rev 144389) +++ trunk/dports/x11/Xaw3d/files/0001-darwin-Fixup-vendorShellWidgetClass.patch 2016-01-07 07:33:19 UTC (rev 144390) @@ -1,49 +0,0 @@ -From 8f1e4d58649ff043b83dae8c37feae0c536dae9c Mon Sep 17 00:00:00 2001 -From: Jeremy Huddleston Sequoia <jeremyhu@apple.com> -Date: Wed, 6 Jan 2016 22:33:12 -0800 -Subject: [PATCH] darwin: Fixup vendorShellWidgetClass - -Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com> ---- - src/Vendor.c | 13 +++++++++++-- - 1 file changed, 11 insertions(+), 2 deletions(-) - -diff --git a/src/Vendor.c b/src/Vendor.c -index 8899cd1..a18b9f3 100644 ---- a/src/Vendor.c -+++ b/src/Vendor.c -@@ -110,12 +110,21 @@ static void XawVendorShellClassPartInit(WidgetClass); - void XawVendorShellExtResize(Widget); - #endif - --#if defined(__UNIXOS2__) || defined(__CYGWIN__) || defined(__MINGW32__) -+#if defined(__UNIXOS2__) || defined(__CYGWIN__) || defined(__MINGW32__) || defined(__APPLE__) - /* to fix the EditRes problem because of wrong linker semantics */ - extern WidgetClass vendorShellWidgetClass; /* from Xt/Vendor.c */ - extern VendorShellClassRec _XawVendorShellClassRec; - void _XawFixupVendorShell(void); - -+#if defined(__APPLE__) -+__attribute__((constructor)) -+static void __VendorShellHack(void) -+{ -+ vendorShellWidgetClass = (WidgetClass)(&_XawVendorShellClassRec); -+ _XawFixupVendorShell(); -+} -+#endif -+ - #if defined(__UNIXOS2__) - unsigned long _DLL_InitTerm(unsigned long mod,unsigned long flag) - { -@@ -475,7 +484,7 @@ XawVendorShellClassPartInit(WidgetClass class) - } - #endif - --#if defined(__osf__) || defined(__UNIXOS2__) || defined(__CYGWIN__) || defined(__MINGW32__) -+#if defined(__osf__) || defined(__UNIXOS2__) || defined(__CYGWIN__) || defined(__MINGW32__) || defined(__APPLE__) - /* stupid OSF/1 shared libraries have the wrong semantics */ - /* symbols do not get resolved external to the shared library */ - void --- -2.6.4 - Added: trunk/dports/x11/Xaw3d/files/0001-darwin-Remove-incorrect-export-of-vendorShellClassRe.patch =================================================================== --- trunk/dports/x11/Xaw3d/files/0001-darwin-Remove-incorrect-export-of-vendorShellClassRe.patch (rev 0) +++ trunk/dports/x11/Xaw3d/files/0001-darwin-Remove-incorrect-export-of-vendorShellClassRe.patch 2016-01-07 07:33:19 UTC (rev 144390) @@ -0,0 +1,62 @@ +From 8f4fcae39f232a5457e63ce8e3892806113da809 Mon Sep 17 00:00:00 2001 +From: Jeremy Huddleston Sequoia <jeremyhu@apple.com> +Date: Wed, 6 Jan 2016 22:33:12 -0800 +Subject: [PATCH] darwin: Remove incorrect export of vendorShellClassRec and + vendorShellWidgetClass + +Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com> +--- + src/Vendor.c | 16 +++++++++++++--- + 1 file changed, 13 insertions(+), 3 deletions(-) + +diff --git a/src/Vendor.c b/src/Vendor.c +index 8899cd1..6b34b31 100644 +--- a/src/Vendor.c ++++ b/src/Vendor.c +@@ -110,12 +110,21 @@ static void XawVendorShellClassPartInit(WidgetClass); + void XawVendorShellExtResize(Widget); + #endif + +-#if defined(__UNIXOS2__) || defined(__CYGWIN__) || defined(__MINGW32__) ++#if defined(__UNIXOS2__) || defined(__CYGWIN__) || defined(__MINGW32__) || defined(__APPLE__) + /* to fix the EditRes problem because of wrong linker semantics */ + extern WidgetClass vendorShellWidgetClass; /* from Xt/Vendor.c */ + extern VendorShellClassRec _XawVendorShellClassRec; + void _XawFixupVendorShell(void); + ++#if defined(__APPLE__) ++__attribute__((constructor)) ++static void __VendorShellHack(void) ++{ ++ vendorShellWidgetClass = (WidgetClass)(&_XawVendorShellClassRec); ++ _XawFixupVendorShell(); ++} ++#endif ++ + #if defined(__UNIXOS2__) + unsigned long _DLL_InitTerm(unsigned long mod,unsigned long flag) + { +@@ -229,9 +238,10 @@ externaldef(vendorshellclassrec) VendorShellClassRec vendorShellClassRec = { + } + }; + ++#if !defined(__APPLE__) + externaldef(vendorshellwidgetclass) WidgetClass vendorShellWidgetClass = + (WidgetClass) (&vendorShellClassRec); +- ++#endif + + #ifdef XAW_INTERNATIONALIZATION + /*************************************************************************** +@@ -475,7 +485,7 @@ XawVendorShellClassPartInit(WidgetClass class) + } + #endif + +-#if defined(__osf__) || defined(__UNIXOS2__) || defined(__CYGWIN__) || defined(__MINGW32__) ++#if defined(__osf__) || defined(__UNIXOS2__) || defined(__CYGWIN__) || defined(__MINGW32__) || defined(__APPLE__) + /* stupid OSF/1 shared libraries have the wrong semantics */ + /* symbols do not get resolved external to the shared library */ + void +-- +2.6.4 +