aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--devel/glib12/Makefile2
-rw-r--r--devel/glib12/files/patch-ad6
-rw-r--r--devel/glib12/files/patch-ae6
3 files changed, 8 insertions, 6 deletions
diff --git a/devel/glib12/Makefile b/devel/glib12/Makefile
index 03410705b09b..4ff9ca46ee67 100644
--- a/devel/glib12/Makefile
+++ b/devel/glib12/Makefile
@@ -22,6 +22,8 @@ USE_LIBTOOL= yes
INSTALLS_SHLIB= yes
LIBTOOLFLAGS= --disable-ltlibs --release-suffix
CONFIGURE_ARGS= --includedir=${PREFIX}/include/glib12
+CONFIGURE_ENV= PTHREAD_CFLAGS="${PTHREAD_CFLAGS}" \
+ PTHREAD_LIBS="${PTHREAD_LIBS}"
MAN1= glib12-config.1
diff --git a/devel/glib12/files/patch-ad b/devel/glib12/files/patch-ad
index 29585871cb9e..fc31caba3c31 100644
--- a/devel/glib12/files/patch-ad
+++ b/devel/glib12/files/patch-ad
@@ -48,14 +48,14 @@
- # -mthreads flag.
+ *-*-freebsd*)
+ if test x"$G_THREAD_LIBS" = x"-lc_r"; then
-+ G_THREAD_CFLAGS="-D_THREAD_SAFE"
-+ G_THREAD_LIBS="-pthread"
++ G_THREAD_CFLAGS="${PTHREAD_CFLAGS}"
++ G_THREAD_LIBS="${PTHREAD_LIBS}"
+ case $host in
+ *-*-freebsd4*) ;;
+ default) have_poll=no ;;
+ esac
+ else
-+ G_THREAD_CFLAGS="-D_THREAD_SAFE -DLINUXTHREADS"
++ G_THREAD_CFLAGS="${PTHREAD_CFLAGS} -DLINUXTHREADS"
+ fi
;;
esac
diff --git a/devel/glib12/files/patch-ae b/devel/glib12/files/patch-ae
index 49aa09418338..2d7028b6563b 100644
--- a/devel/glib12/files/patch-ae
+++ b/devel/glib12/files/patch-ae
@@ -48,14 +48,14 @@
- # -mthreads flag.
+ *-*-freebsd*)
+ if test x"$G_THREAD_LIBS" = x"-lc_r"; then
-+ G_THREAD_CFLAGS="-D_THREAD_SAFE"
-+ G_THREAD_LIBS="-pthread"
++ G_THREAD_CFLAGS="${PTHREAD_CFLAGS}"
++ G_THREAD_LIBS="${PTHREAD_LIBS}"
+ case $host in
+ *-*-freebsd4*) ;;
+ default) have_poll=no ;;
+ esac
+ else
-+ G_THREAD_CFLAGS="-D_THREAD_SAFE -DLINUXTHREADS"
++ G_THREAD_CFLAGS="${PTHREAD_CFLAGS} -DLINUXTHREADS"
+ fi
;;
esac