Subject: pkg/21806: pkgsrc/x11/gtk2 doesn't build on FreeBSD + fix
To: None <>
From: None <>
List: netbsd-bugs
Date: 06/05/2003 21:40:57
>Number:         21806
>Category:       pkg
>Synopsis:       pkgsrc/x11/gtk2 doesn't build on FreeBSD + fix
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    pkg-manager
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Thu Jun 05 19:38:00 UTC 2003
>Originator:     Juan RP
>Release:        NetBSD 1.6T
Juan RP
System: NetBSD Nocturno 1.6T NetBSD 1.6T (Nocturno) #8: Thu May 29 15:13:29 CEST 2003 juan@Nocturno:/home/juan/current/obj/sys/arch/i386/compile/Nocturno i386
Architecture: i386
Machine: i386

gtk2 cannot be build, because -pthread is not enough to compile
with threads support, you need add -lc_r. I fixed this add it to
LDFLAGS using an OPSYS variable.


Index: Makefile
RCS file: /cvsroot/pkgsrc/x11/gtk2/Makefile,v
retrieving revision 1.27
diff -b -u -r1.27 Makefile
--- Makefile	2003/06/02 01:15:43	1.27
+++ Makefile	2003/06/05 19:33:08
@@ -49,6 +49,12 @@
 	${INSTALL_DATA_DIR} ${PREFIX}/lib/gtk-2.0/modules
+.include "../../mk/"
+.if ${OPSYS} == "FreeBSD"
+LDFLAGS+= -lc_r
 .include "../../devel/atk/"
 .include "../../devel/gettext-lib/"
 .include "../../devel/glib2/"