ports/58498: kdelibs links against -pthread on -CURRENT, ignoring PTHREADS_LIBS

Jonathan Fosburgh jonathan at fosburgh.org
Fri Oct 24 21:10:15 UTC 2003


>Number:         58498
>Category:       ports
>Synopsis:       kdelibs links against -pthread on -CURRENT, ignoring PTHREADS_LIBS
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Oct 24 14:10:12 PDT 2003
>Closed-Date:
>Last-Modified:
>Originator:     Jonathan Fosburgh
>Release:        FreeBSD 5.1-CURRENT i386
>Organization:
>Environment:
System: FreeBSD jef-nt.mdacc.tmc.edu 5.1-CURRENT FreeBSD 5.1-CURRENT #22: Wed Oct 22 11:35:45 CDT 2003 syjef at jef-nt.mdacc.tmc.edu:/usr/obj/usr/src/sys/vmbsd i386


>Description:
	PTHREAD_LIBS has been set to -lkse in my environment.  The configure script for kdelibs (actually, for all kde packages, as far as I can tell) set a variable called USE_THREADS to -pthread.  From this, several other variables are set, with the result that -pthread is used as a linker option.  This forces the app to link against libc_r, regardless of what PTHREAD_LIBS is set to.  Actually, it seems to cause a link against PTHREAD_LIBS and -libc_r, which can cause problems...
>How-To-Repeat:
	PTHREAD_LIBS=-lkse cd /usr/ports/x11/kdelibs && make
>Fix:

	Apply the following patch, which sets USE_THREADS to $PTHREAD_LIBS:

# This is a shell archive.  Save it in a file, remove anything before
# this line, and then unpack it by entering "sh file".  Note, it may
# create directories; files and directories will be owned by you and
# have default permissions.
#
# This archive contains:
#
#       patch-configure
#
echo x - patch-configure
sed 's/^X//' >patch-configure << 'END-of-patch-configure'
X--- configure.orig     Fri Oct 24 09:07:24 2003
X+++ configure  Fri Oct 24 08:55:20 2003
X@@ -25047,7 +25047,7 @@
X  echo "$as_me:$LINENO: result: yes" >&5
X echo "${ECHO_T}yes" >&6
X  :
X- USE_THREADS="-pthread"
X+ USE_THREADS="$PTHREAD_LIBS"
X else
X  echo "$as_me:$LINENO: result: no" >&5
X echo "${ECHO_T}no" >&6
X@@ -25131,7 +25131,7 @@
X  echo "$as_me:$LINENO: result: yes" >&5
X echo "${ECHO_T}yes" >&6
X  :
X- USE_THREADS="-pthread"
X+ USE_THREADS="$PTHREAD_LIBS"
X else
X  echo "$as_me:$LINENO: result: no" >&5
X echo "${ECHO_T}no" >&6
END-of-patch-configure
exit



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



More information about the freebsd-ports-bugs mailing list