]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
backport: freebsd-spec.h: Use KSE pthread lib for -pthread.
authorDavid O'Brien <obrien@FreeBSD.org>
Tue, 21 Dec 2004 18:00:24 +0000 (18:00 +0000)
committerDavid O'Brien <obrien@gcc.gnu.org>
Tue, 21 Dec 2004 18:00:24 +0000 (18:00 +0000)
2004-12-21  David O'Brien  <obrien@FreeBSD.org>
Backport from mainline:
* config/freebsd-spec.h:  Use KSE pthread lib for -pthread.

From-SVN: r92465

gcc/ChangeLog
gcc/config/freebsd-spec.h

index b9967d64e9b496a715854275533c07b0e68fbf7c..41f0f675897cf3b28a95b79c3e806f21cf1d8c72 100644 (file)
@@ -1,3 +1,8 @@
+2004-12-21  David O'Brien  <obrien@FreeBSD.org>
+
+       Backport from mainline:
+       * config/freebsd-spec.h:  Use KSE pthread lib for -pthread.
+
 2004-12-19  Richard Henderson  <rth@redhat.com>
 
        * config/i386/i386.c (ix86_hard_regno_mode_ok): Always accept all SSE,
index e4459ba6aa6ce95d5ba676828dad7976ca47346f..7329a1f610761910b203c49d946e03e51cfe1c94 100644 (file)
@@ -107,12 +107,12 @@ Boston, MA 02111-1307, USA.  */
    500016, select the appropriate libc, depending on whether we're
    doing profiling or need threads support.  At __FreeBSD_version
    500016 and later, when threads support is requested include both
-   -lc and -lc_r instead of only -lc_r.  To make matters interesting,
-   we can't actually use __FreeBSD_version provided by <osreldate.h>
-   directly since it breaks cross-compiling.  As a final twist, make
-   it a hard error if -pthread is provided on the command line and gcc
-   was configured with --disable-threads (this will help avoid bug
-   reports from users complaining about threading when they
+   -lc and the threading lib instead of only -lc_r.  To make matters
+   interesting, we can't actually use __FreeBSD_version provided by
+   <osreldate.h> directly since it breaks cross-compiling.  As a final
+   twist, make it a hard error if -pthread is provided on the command
+   line and gcc was configured with --disable-threads (this will help
+   avoid bug reports from users complaining about threading when they
    misconfigured the gcc bootstrap but are later consulting FreeBSD
    manual pages that refer to the mythical -pthread option).  */
 
@@ -132,8 +132,8 @@ is built with the --enable-threads configure-time option.}          \
 #if FBSD_MAJOR >= 5
 #define FBSD_LIB_SPEC "                                                        \
   %{!shared:                                                           \
-    %{!pg: %{pthread:-lc_r} -lc}                                       \
-    %{pg:  %{pthread:-lc_r_p} -lc_p}                                   \
+    %{!pg: %{pthread:-lpthread} -lc}                                   \
+    %{pg:  %{pthread:-lpthread_p} -lc_p}                               \
   }"
 #else
 #define FBSD_LIB_SPEC "                                                        \