Skip site navigation (1)Skip section navigation (2)
Date:      Tue,  2 Jan 2007 12:56:13 -0500 (EST)
From:      Jason DiCioccio <jd@ods.org>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   ports/107437: Port lang/gdc favors libc_r to libpthread
Message-ID:  <20070102175613.131B86D637@update.ods.org>
Resent-Message-ID: <200701021820.l02IKCxu046050@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         107437
>Category:       ports
>Synopsis:       Port lang/gdc favors libc_r to libpthread
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Tue Jan 02 18:20:11 GMT 2007
>Closed-Date:
>Last-Modified:
>Originator:     Jason DiCioccio
>Release:        FreeBSD 6.1-RELEASE-p10 i386
>Organization:
>Environment:
System: FreeBSD update.ods.org 6.1-RELEASE-p10 FreeBSD 6.1-RELEASE-p10 #3: Sun Oct 1 21:24:32 EDT 2006 geniusj@update.ods.org:/usr/obj/usr/src/sys/UPDATE i386


	
>Description:
When compiling threaded D code with gdc, gdc will automatically link in libc_r
instead of libpthread.  This is due to a check in autoconf that seems to be
targeted at FreeBSD 4.x
	
>How-To-Repeat:
Compile D code with gdc that uses threads.
ldd <resulting binary>
	
>Fix:

diff -ruN gdc.bak/files/patch-gcc::d::phobos::configure gdc/files/patch-gcc::d::phobos::configure
--- gdc.bak/files/patch-gcc::d::phobos::configure	Wed Dec 31 19:00:00 1969
+++ gdc/files/patch-gcc::d::phobos::configure	Tue Jan  2 12:37:28 2007
@@ -0,0 +1,11 @@
+--- gcc.orig/d/phobos/configure       Tue Jan  2 10:12:52 2007
++++ gcc/d/phobos/configure    Tue Jan  2 10:12:24 2007
+@@ -5912,7 +5912,7 @@
+     echo "$as_me:$LINENO: checking for thread library linker argument" >&5
+ echo $ECHO_N "checking for thread library linker argument... $ECHO_C" >&6
+     d_thread_lib=error
+-    for thrd_lib in "" -lc_r -lpthread -ldce; do
++    for thrd_lib in "" -lpthread -ldce -lc_r; do
+ 	d_savelibs=$LIBS
+ 	LIBS="$LIBS $thrd_lib"
+ 
	



!DSPAM:2756,459a9cbd4853422919100!


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20070102175613.131B86D637>