aboutsummaryrefslogtreecommitdiff
path: root/devel
diff options
context:
space:
mode:
authorMartin Wilke <miwi@FreeBSD.org>2007-01-29 09:20:36 +0000
committerMartin Wilke <miwi@FreeBSD.org>2007-01-29 09:20:36 +0000
commit96963603bb33a1a75e1f58c0283667b648f29909 (patch)
tree1ec56ea85b81682f40927b7da6e1d47b1037b5d0 /devel
parent58dd600615034070f44ccc104d62bdea5f350a16 (diff)
This library provides weak aliases for pthread functions not provided in libc
or otherwise available by default. Libraries like libxcb rely on pthread stubs to use pthreads optionally, becoming thread-safe when linked to libpthread, while avoiding any performance hit when running single-threaded. libpthread-stubs supports this behavior even on platforms which do not supply all the necessary pthread stubs. On platforms which already supply all the necessary pthread stubs, this package ships only the pkg-config file pthread-stubs.pc, to allow libraries to unconditionally express a dependency on pthread-stubs and still obtain correct behavior. WWW: http://xcb.freedesktop.org/ PR: ports/108491 Submitted by: wahjava
Notes
Notes: svn path=/head/; revision=183606
Diffstat (limited to 'devel')
-rw-r--r--devel/Makefile1
-rw-r--r--devel/libpthread-stubs/Makefile24
-rw-r--r--devel/libpthread-stubs/distinfo3
-rw-r--r--devel/libpthread-stubs/files/patch-configure11
-rw-r--r--devel/libpthread-stubs/pkg-descr11
-rw-r--r--devel/libpthread-stubs/pkg-plist5
6 files changed, 55 insertions, 0 deletions
diff --git a/devel/Makefile b/devel/Makefile
index 7915c7cefb33..cb5a4fac2bf6 100644
--- a/devel/Makefile
+++ b/devel/Makefile
@@ -584,6 +584,7 @@
SUBDIR += libpeak
SUBDIR += libphish
SUBDIR += libpperl
+ SUBDIR += libpthread-stubs
SUBDIR += libredblack
SUBDIR += libs11n
SUBDIR += libshbuf
diff --git a/devel/libpthread-stubs/Makefile b/devel/libpthread-stubs/Makefile
new file mode 100644
index 000000000000..31b6e26258c6
--- /dev/null
+++ b/devel/libpthread-stubs/Makefile
@@ -0,0 +1,24 @@
+# New ports collection makefile for: libpthread-stubs
+# Date created: 24 January 2007
+# Whom: wahjava
+#
+# $FreeBSD$
+#
+
+PORTNAME= libpthread-stubs
+PORTVERSION= 0.1
+CATEGORIES= devel
+MASTER_SITES= http://xcb.freedesktop.org/dist/
+
+MAINTAINER= wahjava@gmail.com
+COMMENT= This library provides weak aliases for pthread functions
+
+USE_GMAKE= yes
+USE_BZIP2= yes
+USE_GNOME= gnomehack pkgconfig
+USE_LDCONFIG= yes
+
+GNU_CONFIGURE= yes
+CONFIGURE_TARGET= --build=${ARCH}-portbld-freebsd${OSREL}
+
+.include <bsd.port.mk>
diff --git a/devel/libpthread-stubs/distinfo b/devel/libpthread-stubs/distinfo
new file mode 100644
index 000000000000..499ac2def0a0
--- /dev/null
+++ b/devel/libpthread-stubs/distinfo
@@ -0,0 +1,3 @@
+MD5 (libpthread-stubs-0.1.tar.bz2) = 774eabaf33440d534efe108ef9130a7d
+SHA256 (libpthread-stubs-0.1.tar.bz2) = 004dae11e11598584939d66d26a5ab9b48d08a00ca2d00ae8d38ee3ac7a15d65
+SIZE (libpthread-stubs-0.1.tar.bz2) = 194060
diff --git a/devel/libpthread-stubs/files/patch-configure b/devel/libpthread-stubs/files/patch-configure
new file mode 100644
index 000000000000..d5e9ca9c4a03
--- /dev/null
+++ b/devel/libpthread-stubs/files/patch-configure
@@ -0,0 +1,11 @@
+--- configure.orig Wed Jan 24 17:10:44 2007
++++ configure Wed Jan 24 17:11:08 2007
+@@ -20705,7 +20705,7 @@
+ _ACEOF
+
+ else
+- PKG_CONFIG_LIBS='-L${libdir} -pthread-stubs'
++ PKG_CONFIG_LIBS='-L${libdir} -lpthread-stubs'
+ fi
+ done
+
diff --git a/devel/libpthread-stubs/pkg-descr b/devel/libpthread-stubs/pkg-descr
new file mode 100644
index 000000000000..5669418fead7
--- /dev/null
+++ b/devel/libpthread-stubs/pkg-descr
@@ -0,0 +1,11 @@
+This library provides weak aliases for pthread functions not provided in libc
+or otherwise available by default. Libraries like libxcb rely on pthread
+stubs to use pthreads optionally, becoming thread-safe when linked to
+libpthread, while avoiding any performance hit when running single-threaded.
+libpthread-stubs supports this behavior even on platforms which do not supply
+all the necessary pthread stubs. On platforms which already supply all the
+necessary pthread stubs, this package ships only the pkg-config file
+pthread-stubs.pc, to allow libraries to unconditionally express a dependency
+on pthread-stubs and still obtain correct behavior.
+
+WWW: http://xcb.freedesktop.org/
diff --git a/devel/libpthread-stubs/pkg-plist b/devel/libpthread-stubs/pkg-plist
new file mode 100644
index 000000000000..4738179c9603
--- /dev/null
+++ b/devel/libpthread-stubs/pkg-plist
@@ -0,0 +1,5 @@
+lib/libpthread-stubs.a
+lib/libpthread-stubs.la
+lib/libpthread-stubs.so
+lib/libpthread-stubs.so.0
+libdata/pkgconfig/pthread-stubs.pc