From owner-freebsd-ports-bugs@FreeBSD.ORG Tue Sep 9 18:40:18 2003 Return-Path: Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 55D9216A4C0 for ; Tue, 9 Sep 2003 18:40:18 -0700 (PDT) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id C836C43FE3 for ; Tue, 9 Sep 2003 18:40:15 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.12.9/8.12.9) with ESMTP id h8A1eEUp014623 for ; Tue, 9 Sep 2003 18:40:14 -0700 (PDT) (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.12.9/8.12.9/Submit) id h8A1eEds014622; Tue, 9 Sep 2003 18:40:14 -0700 (PDT) Resent-Date: Tue, 9 Sep 2003 18:40:14 -0700 (PDT) Resent-Message-Id: <200309100140.h8A1eEds014622@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Palle Girgensohn Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E21FB16A4C0 for ; Tue, 9 Sep 2003 18:35:46 -0700 (PDT) Received: from amsfep16-int.chello.nl (amsfep16-int.chello.nl [213.46.243.26]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9C20543FCB for ; Tue, 9 Sep 2003 18:35:44 -0700 (PDT) (envelope-from girgen@smtp.chello.se) Received: from palle.girgensohn.se ([213.89.138.245]) by amsfep16-int.chello.nlESMTP <20030910013543.SMLO24754.amsfep16-int.chello.nl@palle.girgensohn.se>; Wed, 10 Sep 2003 03:35:43 +0200 Received: from palle.girgensohn.se (localhost [127.0.0.1]) by palle.girgensohn.se (8.12.9/8.12.9) with ESMTP id h8A1ZhNr058399; Wed, 10 Sep 2003 03:35:43 +0200 (CEST) (envelope-from girgen@palle.girgensohn.se) Received: (from girgen@localhost) by palle.girgensohn.se (8.12.9/8.12.9/Submit) id h8A1ZgTO058398; Wed, 10 Sep 2003 03:35:42 +0200 (CEST) (envelope-from girgen) Message-Id: <200309100135.h8A1ZgTO058398@palle.girgensohn.se> Date: Wed, 10 Sep 2003 03:35:42 +0200 (CEST) From: Palle Girgensohn To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 cc: dominic.marks@btinternet.com Subject: ports/56663: apache2 always sets REENTRANT & THREAD_SAFE X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: Palle Girgensohn List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Sep 2003 01:40:18 -0000 >Number: 56663 >Category: ports >Synopsis: apache2 always sets REENTRANT & THREAD_SAFE >Confidential: no >Severity: critical >Priority: medium >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Tue Sep 09 18:40:14 PDT 2003 >Closed-Date: >Last-Modified: >Originator: Palle Girgensohn >Release: FreeBSD 4.8-STABLE i386 >Organization: PING PONG >Environment: System: FreeBSD palle.girgensohn.se 4.7-RC FreeBSD 4.7-RC #0: Sun Sep 29 17:21:22 CEST 2002 root@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: >Release-Note: >Audit-Trail: >Unformatted: