aboutsummaryrefslogtreecommitdiffstats
path: root/x11/xorg-libraries
diff options
context:
space:
mode:
authoranholt <anholt@FreeBSD.org>2004-12-31 17:02:27 +0800
committeranholt <anholt@FreeBSD.org>2004-12-31 17:02:27 +0800
commit9e18f9fee0213797d5972c9e94fa7b8502d34582 (patch)
treed7c00e0aedcb3df4c09f9fd89da9b457448f7983 /x11/xorg-libraries
parentac91c0eccf2b314a08ea5b028a36073aa3ee6be4 (diff)
downloadfreebsd-ports-gnome-9e18f9fee0213797d5972c9e94fa7b8502d34582.tar.gz
freebsd-ports-gnome-9e18f9fee0213797d5972c9e94fa7b8502d34582.tar.zst
freebsd-ports-gnome-9e18f9fee0213797d5972c9e94fa7b8502d34582.zip
Re-add libXThrStub for FreeBSD that requires thread stubs. Between 6.7 and 6.8
I had moved libXThrStub into libX11, because it seemed unnecessary. However, because libc_r symbols are also weak, the weak stubs in libX11 would interfere, however they don't if they are in a library linked by libX11. The most common manifestation of the problem was: GThread-ERROR **: file gthread-posix.c: line 137 (g_thread_impl_init): error 'Invalid argument' during 'pthread_getschedparam (pthread_self(), &policy, &sched)' in glib apps. PR: ports/75477 Submitted by: KIMURA Yasuhiro, yasu at utahime dot org Testing by: marcus
Diffstat (limited to 'x11/xorg-libraries')
-rw-r--r--x11/xorg-libraries/Makefile9
-rw-r--r--x11/xorg-libraries/files/XThrStub-Imakefile35
-rw-r--r--x11/xorg-libraries/files/patch-GL-GL-Imakefile20
-rw-r--r--x11/xorg-libraries/files/patch-X11-Imakefile12
-rw-r--r--x11/xorg-libraries/files/patch-lib-Imakefile22
-rw-r--r--x11/xorg-libraries/pkg-plist2
6 files changed, 100 insertions, 0 deletions
diff --git a/x11/xorg-libraries/Makefile b/x11/xorg-libraries/Makefile
index 70a214ea89a2..138e45a9bc1d 100644
--- a/x11/xorg-libraries/Makefile
+++ b/x11/xorg-libraries/Makefile
@@ -7,6 +7,7 @@
PORTNAME= xorg-libraries
PORTVERSION= 6.8.1
+PORTREVISION= 1
CATEGORIES= x11
MASTER_SITES= ${MASTER_SITE_XORG}
MASTER_SITE_SUBDIR= X11R6.8.1/tars
@@ -38,6 +39,8 @@ INSTALLS_SHLIB= yes
post-patch:
${CP} ${FILESDIR}/nls-Compose-microsoft-cp1251 ${WRKSRC}/nls/Compose/microsoft-cp1251
+ ${MKDIR} ${WRKSRC}/lib/XThrStub
+ ${CP} ${FILESDIR}/XThrStub-Imakefile ${WRKSRC}/lib/XThrStub/Imakefile
post-install:
${MKDIR} ${PREFIX}/libdata/pkgconfig
@@ -58,4 +61,10 @@ PLIST_SUB+= OSMESA:="@comment "
PLIST_SUB+= OSMESA:=""
.endif
+.if ${OSVERSION} >= 500043
+PLIST_SUB+= XTHRSTUB:="@comment "
+.else
+PLIST_SUB+= XTHRSTUB:=""
+.endif
+
.include <bsd.port.post.mk>
diff --git a/x11/xorg-libraries/files/XThrStub-Imakefile b/x11/xorg-libraries/files/XThrStub-Imakefile
new file mode 100644
index 000000000000..83e850325c9a
--- /dev/null
+++ b/x11/xorg-libraries/files/XThrStub-Imakefile
@@ -0,0 +1,35 @@
+#define DoNormalLib NormalLibXThrStub
+#define DoSharedLib SharedLibXThrStub
+#define DoExtraLib SharedLibXThrStub
+#define DoDebugLib DebugLibXThrStub
+#define DoProfileLib ProfileLibXThrStub
+#define LibName XThrStub
+#define SoRev SOXTHRSTUBREV
+#define LibHeaders NO
+
+#include <Threads.tmpl>
+
+#ifdef SharedXThrStubReqs
+REQUIREDLIBS = SharedXThrStubReqs
+#endif
+
+#if NeedUIThrStubs
+STUBSRCS = UIThrStubs.c
+STUBOBJS = UIThrStubs.o
+#endif
+
+#if Malloc0ReturnsNull
+ALLOC_DEFINES = -DMALLOC_0_RETURNS_NULL
+#endif
+
+ DEFINES = $(ALLOC_DEFINES)
+ INCLUDES =
+ SRCS = $(STUBSRCS)
+ OBJS = $(STUBOBJS)
+ LINTLIBS = $(LINTXLIB)
+
+#include <Library.tmpl>
+
+DependTarget()
+
+LinkSourceFile(UIThrStubs.c,$(XTOP)/lib/X11)
diff --git a/x11/xorg-libraries/files/patch-GL-GL-Imakefile b/x11/xorg-libraries/files/patch-GL-GL-Imakefile
new file mode 100644
index 000000000000..69f1eb2c40d7
--- /dev/null
+++ b/x11/xorg-libraries/files/patch-GL-GL-Imakefile
@@ -0,0 +1,20 @@
+Index: lib/GL/GL/Imakefile
+===================================================================
+RCS file: /cvs/xorg/xc/lib/GL/GL/Imakefile,v
+retrieving revision 1.5
+diff -u -r1.5 Imakefile
+--- lib/GL/GL/Imakefile 23 Jul 2004 05:25:39 -0000 1.5
++++ lib/GL/GL/Imakefile 29 Dec 2004 20:51:25 -0000
+@@ -209,8 +209,12 @@
+ POBJS = $(GLXPOBJS) $(DRIPOBJS) $(DRVPOBJS) $(DRMPOBJS)
+
+ #if LocalThreads
++#if NeedUIThrStubs
++ THREADOBJS = $(LDPRELIB) $(XTHRSTUBLIB)
++#else
+ THREADOBJS = $(THREADS_LIBS)
+ #endif
++#endif
+
+ #include <Library.tmpl>
+
diff --git a/x11/xorg-libraries/files/patch-X11-Imakefile b/x11/xorg-libraries/files/patch-X11-Imakefile
new file mode 100644
index 000000000000..f8bba66d39ed
--- /dev/null
+++ b/x11/xorg-libraries/files/patch-X11-Imakefile
@@ -0,0 +1,12 @@
+--- lib/X11/Imakefile.orig Wed Dec 29 13:44:54 2004
++++ lib/X11/Imakefile Wed Dec 29 13:46:19 2004
+@@ -126,8 +126,7 @@
+ K5INCL = Krb5Includes
+ K5DEFS = Krb5Defines
+ #endif
+-#if (defined(FreeBSDArchitecture) && OSRelVersion < 500016) || \
+- defined(OpenBSDArchitecture)
++#if (defined(OpenBSDArchitecture))
+ THRSTUBSRCS = UIThrStubs.c
+ THRSTUBOBJS = UIThrStubs.o
+ #endif
diff --git a/x11/xorg-libraries/files/patch-lib-Imakefile b/x11/xorg-libraries/files/patch-lib-Imakefile
new file mode 100644
index 000000000000..9db3ac355f73
--- /dev/null
+++ b/x11/xorg-libraries/files/patch-lib-Imakefile
@@ -0,0 +1,22 @@
+--- lib/Imakefile.orig Wed Sep 1 18:10:28 2004
++++ lib/Imakefile Wed Dec 29 13:43:31 2004
+@@ -36,6 +36,10 @@
+ XKBUILIBDIR = xkbui
+ #endif
+
++#if BuildThreadStubLibrary && BuildLibraries
++THRSTUBLIBDIR = XThrStub
++#endif
++
+ #if BuildXInputLib
+ XINPUTLIBDIR = Xi
+ #endif
+@@ -223,7 +227,7 @@
+ #endif
+
+
+-LINTSUBDIRS = $(XAULIBDIR) $(XDMCPLIBDIR) $(X11LIBDIR) \
++LINTSUBDIRS = $(XAULIBDIR) $(XDMCPLIBDIR) $(THRSTUBLIBDIR) $(X11LIBDIR) \
+ $(OLDXLIBDIR) $(ICELIBDIR) $(SMLIBDIR) $(XEXTLIBDIR) $(XTLIBDIR) \
+ $(SSLIBDIR) $(XF86MISCLIBDIR) $(XF86VMLIBDIR) $(XF86DGALIBDIR) \
+ $(XF86RUSHLIBDIR) $(XMULIBDIR) $(XMUULIBDIR) $(XPMLIBDIR) \
diff --git a/x11/xorg-libraries/pkg-plist b/x11/xorg-libraries/pkg-plist
index 22b530f0ce65..46c44c9b6ff6 100644
--- a/x11/xorg-libraries/pkg-plist
+++ b/x11/xorg-libraries/pkg-plist
@@ -559,6 +559,8 @@ lib/libXRes.so.1
lib/libXTrap.a
lib/libXTrap.so
lib/libXTrap.so.6
+%%XTHRSTUB:%%lib/libXThrStub.so
+%%XTHRSTUB:%%lib/libXThrStub.so.6
lib/libXau.a
lib/libXau.so
lib/libXau.so.0