ports/56663: apache2 always sets REENTRANT & THREAD_SAFE

Ceri Davies ceri at FreeBSD.org
Thu Sep 18 21:10:03 UTC 2003


The following reply was made to PR ports/56663; it has been noted by GNATS.

From: Ceri Davies <ceri at FreeBSD.org>
To: FreeBSD Gnats Submit <freebsd-gnats-submit at FreeBSD.org>
Cc:  
Subject: Re: ports/56663: apache2 always sets REENTRANT & THREAD_SAFE
Date: Thu, 18 Sep 2003 22:02:52 +0100

 Adding to audit trail, from misfiled PR ports/56681:
 
 Date: Wed, 10 Sep 2003 17:57:44 +0000
 From: Dominic Marks <dom at wirespeed.org.uk>
 Message-Id: <200309101757.45031.dom at wirespeed.org.uk>
 References: <200309100135.h8A1ZgTO058398 at palle.girgensohn.se>
 
  On Wednesday 10 September 2003 1:35 am, Palle Girgensohn wrote:
  > >Submitter-Id:	current-users
  > >Originator:	Palle Girgensohn <girgen at pingpong.net>
  > >Organization:	PING PONG
  > >Confidential:	no
  > >Synopsis:	apache2 always sets REENTRANT & THREAD_SAFE
  > >Severity:	critical
  > >Priority:	medium
  > >Category:	ports
  > >Class:		sw-bug
  > >Release:	FreeBSD 4.8-STABLE i386
  > >Environment:
  >
  > System: FreeBSD palle.girgensohn.se 4.7-RC FreeBSD 4.7-RC #0: Sun
  > Sep 29 17:21:22 CEST 2002    
  > root at palle.girgensohn.se:/usr/local/obj/usr/src/sys/STORDATAN  i386
  >
  > >Description:
  >
  > After installing apache2 on freebsd4.8, MPM=prefork (i.e. default),
  > $ apxs -q EXTRA_CPPFLAGS
  > -D_REENTRANT -D_THREAD_SAFE
  > $ ldd /usr/local/sbin/httpd
  > ...
  >         libc.so.4 => /usr/lib/libc.so.4 (0x4824c000)
  >
  > and strings /usr/local/sbin/httpd | grep pthread
  > gives nothing.
  >
  > I don't get it; why _REENTRANT and _THREAD_SAFE if there are no
  > threads, and httpd is linked with libc, not libc_r? Seems like a
  > bug to me? The gcc manpage says to use thread_safe only when
  > linking with ptreads, here we don't...
  >
  > This breaks mod_jk that I'm porting right now... apache fails to
  > run with the built mod_jk:
  >
  > Cannot load /usr/local/libexec/apache2/mod_jk.so into server:
  > /usr/local/libexec/apache2/mod_jk.so: Undefined symbol
  > "pthread_mutex_unlock"
  >
  > Hence, this sometimes breaks module building, if the module trusts
  > apxs to give correct CFLAGS & CPPFLAGS.
  >
  > >How-To-Repeat:
  >
  > build apache2 without any extra options, (on freebsd 4.8)
  >
  > $ apxs -q EXTRA_CPPFLAGS
  > -D_REENTRANT -D_THREAD_SAFE
  >
  > although httpd is linked with lib_c.so
  >
  > >Fix:
  
  Thanks for the bug report. I will try and produce a fix soon.
  
  -- 
  Dominic <dom at wirespeed.org.uk>
  
 



More information about the freebsd-ports-bugs mailing list