Date: Wed, 18 Nov 1998 09:14:09 -0800 (PST) From: fanf@demon.net To: freebsd-gnats-submit@FreeBSD.ORG Subject: gnu/8746: gcc man page misleading Message-ID: <199811181714.JAA02466@hub.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 8746 >Category: gnu >Synopsis: gcc man page misleading >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: doc-bug >Submitter-Id: current-users >Arrival-Date: Wed Nov 18 09:20:00 PST 1998 >Last-Modified: >Originator: Tony Finch >Organization: Demon Internet >Release: 3.0-BETA and -RELEASE >Environment: FreeBSD prometheus.noc.demon.net 3.0-RELEASE FreeBSD 3.0-RELEASE #0: Mon Nov 9 14:35:56 GMT 1998 root@prometheus.noc.demon.net:/usr/src/sys/compile/PROMETHEUS i386 >Description: The gcc manpage says that programs linked with -pthread or -kthread should be compiled with -D_THREADSAFE, but this symbol does not occur anywhere else in /usr/src and its absence doesn't seem to cause problems. Other OSs use _REENTRANT for the same purpose (but FreeBSD doesn't seem to use that very much either). >How-To-Repeat: man gcc and look for the bit that says -pthread Link a user-threaded process against libc_r instead of libc. Objects linked into user-threaded process- es should be compiled with -D_THREADSAFE. -kthread Link a kernel-threaded process against libpthread in addition to libc. Objects linked into kernel- threaded processes should be compiled with -D_THREADSAFE. >Fix: This changes the _THREADSAFE to _REENTRANT; I'm not sure whether this is the right fix because these two paragraphs are both a bit misleading (especially the second one). --- gcc.1.orig Wed Nov 18 17:03:14 1998 +++ gcc.1 Wed Nov 18 17:11:51 1998 @@ -525,12 +525,12 @@ .TP .BI "\-pthread" Link a user-threaded process against libc_r instead of libc. Objects linked -into user-threaded processes should be compiled with -D_THREADSAFE. +into user-threaded processes should be compiled with -D_REENTRANT. .TP .BI "\-kthread" Link a kernel-threaded process against libpthread in addition to libc. Objects linked into kernel-threaded processes should be compiled with --D_THREADSAFE. +-D_REENTRANT. .SH OVERALL OPTIONS .TP .BI "\-x " "language" >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199811181714.JAA02466>