misc/91883: www/apache20 doesn't compile on 5.4.1

Balázs Nagy js at iksz.hu
Mon Jan 16 13:10:03 PST 2006


>Number:         91883
>Category:       misc
>Synopsis:       www/apache20 doesn't compile on 5.4.1
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Jan 16 21:10:02 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator:     Balázs Nagy
>Release:        5.4-RELEASE-p9
>Organization:
>Environment:
FreeBSD tcb.aranyoroszlan.hu 5.4-RELEASE-p9 FreeBSD 5.4-RELEASE-p9 #0: Sun Jan 15 22:13:08 CET 2006     root at tcb.aranyoroszlan.hu:/opt/devel/obj/opt/devel/src/sys/SAMU  i386
>Description:
The following patch (ports/www/apache20/Makefile:1.232) breaks the compatibility with 5.4

-WITH_PTHREAD_LIBS?=	${PTHREAD_LIBS:S/-l//:S/-//}
-WITH_PTHREAD_CFLAGS?=	${PTHREAD_CFLAGS}
..
+.if defined(WITH_THREADS)
+CONFIGURE_ARGS+=	--enable-threads
+.   if ${OSVERSION} > 500023
+CONFIGURE_ENV+=		apr_cv_pthreads_lib=-l${WITH_PTHREAD_LIBS} \
+			apr_cv_pthreads_cflags=${WITH_PTHREAD_CFLAGS}
+.     if ${ARCH} == i386
+CONFIGURE_ARGS+=	--enable-nonportable-atomics
+.     endif
+.  else
+CFLAGS+=		-DFREEBSD_THREAD_HACK
+.   endif
+.endif

It used to define WITH_PTHREAD_LIBS and WITH_PTHREAD_CFLAGS, but they don't accessible anymore.  Moreover, it breaks configure because of the bare '-l'.

>How-To-Repeat:
              
>Fix:
AFAIK ports/Mk/bsd.ports.mk knows better how to use threading libraries.  I suggest to use

.if defined(WITH_THREADS)
CONFIGURE_ARGS+=        --enable-threads
CONFIGURE_ENV+= apr_cv_pthreads_lib=${PTHREAD_LIBS} \
        apr_cv_pthreads_cflags=${PTHREAD_CFLAGS}
..

because PTHREAD_LIBS and PTHREAD_CFLAGS are always defined.
>Release-Note:
>Audit-Trail:
>Unformatted:


More information about the freebsd-bugs mailing list