diff options
| author | thorpej <thorpej@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-09-15 18:14:18 +0000 |
|---|---|---|
| committer | thorpej <thorpej@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-09-15 18:14:18 +0000 |
| commit | 5ccae5bfd969aaddcc0e4e4c4e640cfc1c8f0417 (patch) | |
| tree | 41fb57985cf24878b6cf2a1308e14942670a7e2b | |
| parent | 09f85456e8d3f359289f077bd8cb2c936009612a (diff) | |
| download | ppe42-gcc-5ccae5bfd969aaddcc0e4e4c4e640cfc1c8f0417.tar.gz ppe42-gcc-5ccae5bfd969aaddcc0e4e4c4e640cfc1c8f0417.zip | |
* config/netbsd.h (LIB_SPEC): Include the appropriate pthread
library if -pthread is specified.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@57164 138bc75d-0d04-0410-961f-82ee72b054a4
| -rw-r--r-- | gcc/ChangeLog | 5 | ||||
| -rw-r--r-- | gcc/config/netbsd.h | 19 |
2 files changed, 19 insertions, 5 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 016f5ca0cf4..9055d877827 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,10 @@ 2002-09-15 Jason Thorpe <thorpej@wasabisystems.com> + * config/netbsd.h (LIB_SPEC): Include the appropriate pthread + library if -pthread is specified. + +2002-09-15 Jason Thorpe <thorpej@wasabisystems.com> + * config.gcc (*-*-netbsd*): Set thread_file to 'posix' for --enable-threads=yes and --enable-threads=posix. diff --git a/gcc/config/netbsd.h b/gcc/config/netbsd.h index 38eb7491d84..b57d412e53b 100644 --- a/gcc/config/netbsd.h +++ b/gcc/config/netbsd.h @@ -77,14 +77,23 @@ Boston, MA 02111-1307, USA. */ #endif /* NETBSD_NATIVE */ -/* Provide a LIB_SPEC appropriate for NetBSD. Just select the appropriate - libc, depending on whether we're doing profiling; if `-posix' is specified, - link against the appropriate libposix first. Don't include libc when - linking a shared library. */ +/* Provide a LIB_SPEC appropriate for NetBSD. Here we: + + 1. Select the appropriate set of libs, depending on whether we're + profiling. + + 2. Include the pthread library if -pthread is specified. + + 3. Include the posix library if -posix is specified. */ #undef LIB_SPEC #define LIB_SPEC \ - "%{posix: \ + "%{pthread: \ + %{!p: \ + %{!pg:-lpthread}} \ + %{p:-lpthread_p} \ + %{pg:-lpthread_p}} \ + %{posix: \ %{!p: \ %{!pg:-lposix}} \ %{p:-lposix_p} \ |

