mirror of
https://git.FreeBSD.org/ports.git
synced 2024-11-23 00:43:28 +00:00
Cleanups and fixes
- remove useless options (and fix thread stuff) [1] - move print-closest-mirror to bsd.apache.mk - move threads configure options out of Makefile.modules - Fix stupid logic to disable v4mapped address [2] - and more... Submitted/spotted by: many, Hirohisa Yamaguchi <umq@ueo.co.jp> [1] ume[2] PR: ports/91813 [1]
This commit is contained in:
parent
236bc34aee
commit
c5d4c969c8
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=153583
@ -337,6 +337,17 @@ AP_EXTRAS+= -L ${AP_LIB}
|
||||
.endif
|
||||
|
||||
.if defined(AP_PORT_IS_SERVER)
|
||||
.if !target(print-closest-mirrors)
|
||||
print-closest-mirrors:
|
||||
@${ECHO_MSG} -n "Fetching list of nearest mirror: " >&2
|
||||
@MIRRORS=`${FETCH_CMD} -T 30 -qo - http://www.apache.org/dyn/closer.cgi/httpd/ 2> /dev/null\
|
||||
| ${GREP} /httpd/ | ${SED} 's/.*href="\(.*\)"><str.*/\1/g' | \
|
||||
${HEAD} -7 | ${TAIL} -6` ; \
|
||||
${ECHO_MSG} done >&2; if [ "x$$MIRRORS" != "x" ]; then \
|
||||
${ECHO_MSG} -n "MASTER_SITE_APACHE_HTTPD?= ";\
|
||||
${ECHO_MSG} $$MIRRORS; else \
|
||||
${ECHO_MSG} "No mirrors found!">&2 ; fi
|
||||
.endif
|
||||
|
||||
.if !target(show-categories)
|
||||
show-categories:
|
||||
|
@ -57,6 +57,7 @@ USE_AUTOTOOLS= autoconf:259 libtool:15
|
||||
USE_PERL5= yes
|
||||
USE_RC_SUBR= yes
|
||||
USE_REINPLACE= yes
|
||||
USE_APACHE= common20
|
||||
LIBTOOLFILES= configure
|
||||
INSTALLS_SHLIB= yes
|
||||
LDCONFIG_DIRS= ${PREFIX}/lib/apache2
|
||||
@ -89,7 +90,7 @@ WITH_HTTP_PORT?= 80
|
||||
CONFIGURE_ARGS+= --disable-ipv6
|
||||
.else
|
||||
CATEGORIES+= ipv6
|
||||
. if defined(WITH_IPV6_V6ONLY) && defined(WITHOUT_V4MAPPED)
|
||||
. if defined(WITH_IPV6_V6ONLY) || defined(WITHOUT_V4MAPPED)
|
||||
CONFIGURE_ARGS+= --disable-v4-mapped
|
||||
. else
|
||||
CONFIGURE_ARGS+= --enable-v4-mapped
|
||||
@ -139,46 +140,32 @@ CONFIGURE_ARGS+= --with-ldap \
|
||||
--with-ldap-include="${LOCALBASE}/include"
|
||||
.endif
|
||||
|
||||
.include "${APACHEDIR}/Makefile.doc"
|
||||
.include "${APACHEDIR}/Makefile.modules"
|
||||
.include <bsd.port.pre.mk>
|
||||
|
||||
.if exists(${LOCALBASE}/lib/libapr-0.so) || defined(WITH_APR_FROM_PORTS)
|
||||
IGNORE= : apr from ports (WITH_APR_FROM_PORTS) is no longer supported
|
||||
.endif
|
||||
|
||||
WITH_PTHREAD_LIBS?= ${PTHREAD_LIBS:S/-l//:S/-//}
|
||||
WITH_PTHREAD_CFLAGS?= ${PTHREAD_CFLAGS}
|
||||
|
||||
.include "${APACHEDIR}/Makefile.doc"
|
||||
.include "${APACHEDIR}/Makefile.modules"
|
||||
WANT_APACHE= common2
|
||||
.include "${APACHEDIR}/Makefile.modules.3rd"
|
||||
.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
|
||||
|
||||
CONFIGURE_ARGS+= --with-mpm=${WITH_MPM:L} ${CONFIGURE_TARGET}
|
||||
|
||||
show-options:
|
||||
@${SED} -ne 's/^##//p' ${APACHEDIR}/Makefile.doc
|
||||
|
||||
show-categories:
|
||||
.for category in ${ALL_MODULES_CATEGORIES}
|
||||
@${ECHO_MSG} "${category} contains these modules:"
|
||||
@${ECHO_MSG} " ${${category}_MODULES}"
|
||||
.endfor
|
||||
|
||||
show-modules:
|
||||
@for module in ${AVAILABLE_MODULES} ; do \
|
||||
${ECHO_MSG} -n "$${module}: ";\
|
||||
if ${ECHO_CMD} ${APACHE_MODULES} | ${GREP} -wq $${module} 2> /dev/null ; then \
|
||||
${ECHO_CMD} -n "enabled "; \
|
||||
if ${ECHO_CMD} ${WITH_STATIC_MODULES} | ${GREP} -wq $${module} 2> /dev/null ; then \
|
||||
${ECHO_CMD} "(static)" ; \
|
||||
else \
|
||||
${ECHO_CMD} "(shared)" ;\
|
||||
fi;\
|
||||
else\
|
||||
${ECHO_CMD} disabled ;\
|
||||
fi;\
|
||||
done
|
||||
|
||||
pre-everything::
|
||||
@${ECHO_MSG} ""
|
||||
@${ECHO_MSG} " To enable a module category: WITH_<CATEGORY>_MODULES"
|
||||
|
@ -92,19 +92,6 @@ IGNORE= "Unknown DBM"
|
||||
CONFIGURE_ARGS+= --with-dbm=sdbm
|
||||
.endif
|
||||
|
||||
.if defined(WITH_THREADS)
|
||||
CONFIGURE_ARGS+= --enable-threads
|
||||
. if ${WITH_PTHREAD_LIBS} != "c_r" && ${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
|
||||
|
||||
.if !defined(WITHOUT_SSL)
|
||||
WITH_SSL_MODULES= yes
|
||||
CONFIGURE_ARGS+= --with-ssl=${OPENSSLBASE}
|
||||
|
@ -5,7 +5,7 @@
|
||||
|
||||
# PROVIDE: apache2
|
||||
# REQUIRE: NETWORKING SERVERS
|
||||
# BEFORE: DAEMON
|
||||
# BEFORE: LOGIN
|
||||
# KEYWORD: FreeBSD shutdown
|
||||
|
||||
#
|
||||
|
@ -40,6 +40,7 @@ SCRIPTS_ENV+= LIBTOOL=${LIBTOOL} LIBTOOLIZE=${LIBTOOLIZE} \
|
||||
LIBTOOL_M4=${LOCALBASE}/share/aclocal/libtool${LIBTOOL_VERSION}.m4 \
|
||||
AUTOHEADER=${AUTOHEADER}
|
||||
|
||||
USE_APACHE= common21
|
||||
USE_BZIP2= yes
|
||||
USE_ICONV= yes
|
||||
USE_AUTOTOOLS= autoconf:259 libtool:15
|
||||
@ -80,7 +81,7 @@ EXTRA_PATCHES+= ${FILESDIR}/exp-windowsupdate.patch
|
||||
CONFIGURE_ARGS+= --disable-ipv6
|
||||
.else
|
||||
CATEGORIES+= ipv6
|
||||
. if defined(WITH_IPV6_V6ONLY) && defined(WITHOUT_V4MAPPED)
|
||||
. if defined(WITH_IPV6_V6ONLY) || defined(WITHOUT_V4MAPPED)
|
||||
CONFIGURE_ARGS+= --disable-v4-mapped
|
||||
. else
|
||||
CONFIGURE_ARGS+= --enable-v4-mapped
|
||||
@ -126,6 +127,8 @@ CONFIGURE_ARGS+= --with-ldap \
|
||||
--with-ldap-include="${LOCALBASE}/include"
|
||||
.endif
|
||||
|
||||
.include "${APACHEDIR}/Makefile.doc"
|
||||
.include "${APACHEDIR}/Makefile.modules"
|
||||
.include <bsd.port.pre.mk>
|
||||
|
||||
.if defined(WITH_APR_FROM_PORTS)
|
||||
@ -140,40 +143,22 @@ CONFLICTS+= apr-1.*
|
||||
CONFIGURE_ENV+= USE_BUNDLED_APR=YES
|
||||
.endif
|
||||
|
||||
WITH_PTHREAD_LIBS?= ${PTHREAD_LIBS:S/-l//:S/-//}
|
||||
WITH_PTHREAD_CFLAGS?= ${PTHREAD_CFLAGS}
|
||||
|
||||
.include "${APACHEDIR}/Makefile.doc"
|
||||
.include "${APACHEDIR}/Makefile.modules"
|
||||
WANT_APACHE= common21
|
||||
.include "${APACHEDIR}/../apache20/Makefile.modules.3rd"
|
||||
.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
|
||||
. endif
|
||||
.endif
|
||||
|
||||
CONFIGURE_ARGS+= --with-mpm=${WITH_MPM:L} ${CONFIGURE_TARGET}
|
||||
|
||||
show-options:
|
||||
@${SED} -ne 's/^##//p' ${APACHEDIR}/Makefile.doc
|
||||
|
||||
show-categories:
|
||||
.for category in ${ALL_MODULES_CATEGORIES}
|
||||
@${ECHO_MSG} "${category} contains these modules:"
|
||||
@${ECHO_MSG} " ${${category}_MODULES}"
|
||||
.endfor
|
||||
|
||||
show-modules:
|
||||
@for module in ${AVAILABLE_MODULES} ; do \
|
||||
${ECHO_MSG} -n "$${module}: ";\
|
||||
if ${ECHO_CMD} ${APACHE_MODULES} | ${GREP} -wq $${module} 2> /dev/null ; then \
|
||||
${ECHO_CMD} -n "enabled "; \
|
||||
if ${ECHO_CMD} ${WITH_STATIC_MODULES} | ${GREP} -wq $${module} 2> /dev/null ; then \
|
||||
${ECHO_CMD} "(static)" ; \
|
||||
else \
|
||||
${ECHO_CMD} "(shared)" ;\
|
||||
fi;\
|
||||
else\
|
||||
${ECHO_CMD} disabled ;\
|
||||
fi;\
|
||||
done
|
||||
|
||||
pre-everything::
|
||||
@${ECHO_MSG} ""
|
||||
@${ECHO_MSG} " To enable a module category: WITH_<CATEGORY>_MODULES"
|
||||
|
@ -94,19 +94,6 @@ IGNORE= "Unknown DBM"
|
||||
CONFIGURE_ARGS+= --with-dbm=sdbm
|
||||
.endif
|
||||
|
||||
.if defined(WITH_THREADS)
|
||||
CONFIGURE_ARGS+= --enable-threads
|
||||
. if ${WITH_PTHREAD_LIBS} != "c_r" && ${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
|
||||
|
||||
.if !defined(WITHOUT_SSL)
|
||||
WITH_SSL_MODULES= yes
|
||||
CONFIGURE_ARGS+= --with-ssl=${OPENSSLBASE}
|
||||
|
@ -1,11 +1,11 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# $FreeBSD: /tmp/pcvs/ports/www/apache21/files/Attic/apache.sh,v 1.8 2005-01-11 13:45:05 clement Exp $
|
||||
# $FreeBSD: /tmp/pcvs/ports/www/apache21/files/Attic/apache.sh,v 1.9 2006-01-15 18:58:38 clement Exp $
|
||||
#
|
||||
|
||||
# PROVIDE: apache21
|
||||
# REQUIRE: NETWORKING SERVERS
|
||||
# BEFORE: DAEMON
|
||||
# BEFORE: LOGIN
|
||||
# KEYWORD: FreeBSD shutdown
|
||||
|
||||
#
|
||||
|
@ -48,9 +48,11 @@ USE_PERL5= yes
|
||||
USE_RC_SUBR= yes
|
||||
USE_REINPLACE= yes
|
||||
LIBTOOLFILES= configure
|
||||
|
||||
.if !defined(WITH_APR_FROM_PORTS)
|
||||
INSTALLS_SHLIB= yes
|
||||
.endif
|
||||
|
||||
CONFIGURE_ARGS= --prefix=${PREFIX_RELDEST} \
|
||||
--enable-layout=FreeBSD \
|
||||
--with-perl=${PERL5} \
|
||||
@ -81,18 +83,13 @@ EXTRA_PATCHES+= ${FILESDIR}/exp-windowsupdate.patch
|
||||
CONFIGURE_ARGS+= --disable-ipv6
|
||||
.else
|
||||
CATEGORIES+= ipv6
|
||||
. if defined(WITH_IPV6_V6ONLY) && defined(WITHOUT_V4MAPPED)
|
||||
. if defined(WITH_IPV6_V6ONLY) || defined(WITHOUT_V4MAPPED)
|
||||
CONFIGURE_ARGS+= --disable-v4-mapped
|
||||
. else
|
||||
CONFIGURE_ARGS+= --enable-v4-mapped
|
||||
. endif
|
||||
.endif
|
||||
|
||||
#backward compatibility
|
||||
.if defined(WITHOUT_SSL)
|
||||
WITHOUT_SSL_MODULES= YES
|
||||
.endif
|
||||
|
||||
.if !defined(WITHOUT_SSL_MODULES)
|
||||
USE_OPENSSL= yes
|
||||
.endif
|
||||
@ -127,10 +124,9 @@ CONFIGURE_ARGS+= --with-ldap \
|
||||
--with-ldap-include="${LOCALBASE}/include"
|
||||
.endif
|
||||
|
||||
|
||||
.include <bsd.port.pre.mk>
|
||||
.include "${APACHEDIR}/Makefile.doc"
|
||||
.include "${APACHEDIR}/Makefile.modules"
|
||||
.include <bsd.port.pre.mk>
|
||||
|
||||
.if defined(WITH_APR_FROM_PORTS)
|
||||
PLIST_SUB+= APR_PORTS="@comment "
|
||||
@ -144,14 +140,19 @@ CONFLICTS+= apr-1.*
|
||||
CONFIGURE_ENV+= USE_BUNDLED_APR=YES
|
||||
.endif
|
||||
|
||||
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
|
||||
. endif
|
||||
.endif
|
||||
|
||||
CONFIGURE_ARGS+= --with-mpm=${WITH_MPM:L} ${CONFIGURE_TARGET}
|
||||
|
||||
show-options:
|
||||
@${SED} -ne 's/^##//p' ${APACHEDIR}/Makefile.doc
|
||||
|
||||
pre-everything::
|
||||
@${ECHO_MSG} ""
|
||||
@${ECHO_MSG} " To enable a module category: WITH_<CATEGORY>_MODULES"
|
||||
@ -167,6 +168,9 @@ pre-everything::
|
||||
@${ECHO_MSG} " You can check your modules configuration by using make show-modules"
|
||||
@${ECHO_MSG} ""
|
||||
|
||||
show-options:
|
||||
@${SED} -ne 's/^##//p' ${APACHEDIR}/Makefile.doc
|
||||
|
||||
post-extract:
|
||||
@${INSTALL_DATA} ${DISTDIR}/${DIST_SUBDIR}/apr_dbd_mysql.c \
|
||||
${WRKSRC}/srclib/apr-util/dbd
|
||||
@ -175,8 +179,6 @@ post-patch:
|
||||
@${RM} -f ${WRKSRC}/docs/docroot/*.bak
|
||||
@${SED} ${RC_SCRIPTS_SUB:S/$/!g/:S/^/ -e s!%%/:S/=/%%!/} \
|
||||
${FILESDIR}/apache.sh > ${WRKDIR}/apache22.sh
|
||||
@${RM} -f ${WRKSRC}/docs/manual/index.html.ko.euc-kr
|
||||
@${RM} -f ${WRKSRC}/docs/conf/highperformance-std.conf
|
||||
@${REINPLACE_CMD} -e 's," PLATFORM ",FreeBSD,' \
|
||||
${WRKSRC}/server/core.c
|
||||
@${REINPLACE_CMD} -e "s,%%OSVERSION%%,${OSVERSION}," \
|
||||
|
@ -113,19 +113,6 @@ USE_SQLITE= YES
|
||||
CONFIGURE_ARGS+= --with-sqlite3=${LOCALBASE}
|
||||
.endif
|
||||
|
||||
.if defined(WITH_THREADS)
|
||||
CONFIGURE_ARGS+= --enable-threads
|
||||
. if ${WITH_PTHREAD_LIBS} != "c_r" && ${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
|
||||
|
||||
.if !defined(WITHOUT_SSL)
|
||||
WITH_SSL_MODULES= yes
|
||||
CONFIGURE_ARGS+= --with-ssl=${OPENSSLBASE}
|
||||
|
Loading…
Reference in New Issue
Block a user