Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 10 Jun 2002 08:40:04 -0700 (PDT)
From:      Maxim Sobolev <sobomax@FreeBSD.org>
To:        freebsd-ports@FreeBSD.org
Subject:   Re: ports/39107: _REENTRANT not defined in PTHREAD_CFLAGS
Message-ID:  <200206101540.g5AFe4D63508@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR ports/39107; it has been noted by GNATS.

From: Maxim Sobolev <sobomax@FreeBSD.org>
To: Sandro Tolaini <sandro@focuseek.com>
Cc: FreeBSD-gnats-submit@FreeBSD.org
Subject: Re: ports/39107: _REENTRANT not defined in PTHREAD_CFLAGS
Date: Mon, 10 Jun 2002 18:38:44 +0300

 Sandro Tolaini wrote:
 > 
 > >Number:         39107
 > >Category:       ports
 > >Synopsis:       _REENTRANT not defined in PTHREAD_CFLAGS
 > >Confidential:   no
 > >Severity:       serious
 > >Priority:       high
 > >Responsible:    freebsd-ports
 > >State:          open
 > >Quarter:
 > >Keywords:
 > >Date-Required:
 > >Class:          sw-bug
 > >Submitter-Id:   current-users
 > >Arrival-Date:   Mon Jun 10 08:00:12 PDT 2002
 > >Closed-Date:
 > >Last-Modified:
 > >Originator:     Sandro Tolaini
 > >Release:        FreeBSD 4.6-PRERELEASE i386
 > >Organization:
 > >Environment:
 > System: FreeBSD gundam.psitrust.com 4.6-PRERELEASE FreeBSD 4.6-PRERELEASE #0: Thu May 9 11:19:04 CEST 2002 root@gundam.psitrust.com:/usr/obj/usr/src/sys/INTELLISTATION i386
 > 
 > 
 > >Description:
 > bsd.ports.mk defines a PTHREAD_CFLAGS variable with -D_THREAD_SAFE value.
 > Unfortunately, some software (notably, STLpoort) requires -D_REENTRANT to be
 > defined, too. Even math.h include file requires this.
 > 
 > On many platforms, gcc autagically defines -D_REENTRANT when -pthread flag is
 > given, but this is not the case with stock gcc found on FreeBSD (and with
 > gcc295 and gcc31 ports).
 > 
 > STLport build relies on _REENTRANT to determine if the default allocators
 > should use locking. Lack of _REENTRANT produces a non thread safe string class,
 > for example.
 > 
 > >How-To-Repeat:
 > 
 > >Fix:
 > 
 > Add -D_REENTRANT to PTHREAD_CFLAGS.
 
 The diagnosis is incorrect - all base system headers that require
 _REENTRANT are broken and should be fixed to use _THREAD_SAFE instead.
 
 -Maxim

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-ports" in the body of the message




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