From owner-freebsd-apache@FreeBSD.ORG Sun Jun 23 18:48:18 2013 Return-Path: Delivered-To: freebsd-apache@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 96D743C4 for ; Sun, 23 Jun 2013 18:48:18 +0000 (UTC) (envelope-from tijl@freebsd.org) Received: from mailrelay007.isp.belgacom.be (mailrelay007.isp.belgacom.be [195.238.6.173]) by mx1.freebsd.org (Postfix) with ESMTP id EFE3A1908 for ; Sun, 23 Jun 2013 18:48:17 +0000 (UTC) X-Belgacom-Dynamic: yes X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AlUGAEdBx1FR8Y5L/2dsb2JhbABbgwkxwAB7F3SCIwEBBVYYCxALGAkWDwkDAgECASceBg0BBwEBiA64Xo9PBwmDWgOQA4Esl1iDEjo Received: from 75.142-241-81.adsl-dyn.isp.belgacom.be (HELO kalimero.tijl.coosemans.org) ([81.241.142.75]) by relay.skynet.be with ESMTP; 23 Jun 2013 20:47:07 +0200 Received: from kalimero.tijl.coosemans.org (kalimero.tijl.coosemans.org [127.0.0.1]) by kalimero.tijl.coosemans.org (8.14.7/8.14.7) with ESMTP id r5NIl5jN081975; Sun, 23 Jun 2013 20:47:06 +0200 (CEST) (envelope-from tijl@FreeBSD.org) Message-ID: <51C742A4.1070709@FreeBSD.org> Date: Sun, 23 Jun 2013 20:47:00 +0200 From: Tijl Coosemans User-Agent: Mozilla/5.0 (X11; FreeBSD i386; rv:17.0) Gecko/20130517 Thunderbird/17.0.6 MIME-Version: 1.0 To: olli hauer Subject: Re: Splitting up and simplifying devel/apr1 References: <51C1AFA7.9080700@FreeBSD.org> <51C58174.20209@gmx.de> In-Reply-To: <51C58174.20209@gmx.de> X-Enigmail-Version: 1.5.1 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="----enig2EIWEEDJSAQMVHUJBNSTJ" Cc: freebsd-apache@freebsd.org X-BeenThere: freebsd-apache@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Support of apache-related ports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 23 Jun 2013 18:48:18 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) ------enig2EIWEEDJSAQMVHUJBNSTJ Content-Type: multipart/mixed; boundary="------------000203020007050305010807" This is a multi-part message in MIME format. --------------000203020007050305010807 Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: quoted-printable On 2013-06-22 12:50, olli hauer wrote: >> In the discussion on src-committers about svnlite it was mentioned tha= t >> devel/subversion is too heavy to build, pulling in perl, python and >> all the autotools. I've been going over its dependencies and it turns >> out these are all pulled in by devel/apr1, so I've been looking into >> simplifying that port. >> >> It seems the port can easily be split up into two simple ports, one fo= r >> the APR library and one for the APR Utility library. There's no need >> for autotools, libtool, python, etc. >> >> I've attached a patch that creates devel/apr and devel/apr-util. >> Please take a look at them and let me know what you think. >> Another patch can then remove devel/apr1 and update all ports that >> depend on it, but before I spend more time on this, do you agree this >=20 > On upstream apr and apr-util are already merged but until now are > delivered separate. >=20 > In the past they had also sometimes update to apr2 snapshots where > they delivered everything in one dist file. >=20 > In case there is no planning on upstream to merge the two distfiles > into one like the apr2 snapshots then I think we could spend some > time and separate the ports. >=20 > I will ask on the dev@apr.apache mailing list if there is a road map > (I cannot find one on the apr public sites). I've seen the mails on the apr mailing list. Since apr2 includes apr-util= it's probably easier to keep apr1 and apr-util in one port too. Then there's no need to update and rebuild dependent ports either. I've attached a new patch for devel/apr1. It contains the following chang= es: - Move include down. - Remove USE_AUTOTOOLS and USE_PYTHON_BUILD. - Use pathfix to patch pkgconfig paths. (replaces a post-patch command) - Add CFLAGS, CPPFLAGS and LDFLAGS to CONFIGURE_ENV. They are set for some options. - Append include dirs to CPPFLAGS instead of CFLAGS. - Remove files/patch-apr_hints.m4. Instead replace any evaluation of $os_version with ${OSVERSION} directly in configure script. - Remove patching of gen-build.py because we don't run it anymore. - Remove patching of "void main" to "int main". According to the commit l= og it was added for Clang, but Clang no longer seems to complain about it.= - Patch -lpthread directly in the configure script. - Remove the run-autotools target. Running of configure has been moved to= the do-configure target. - Replace "cd ; " with "(cd && )" as recommended by the make manpage in current. - Add ${_MAKE_JOBS} in do-build. - Rename the test target to regression-test because that's what pointyhat= runs. - Remove debug_autoconf target because we don't run autotools anymore. --------------000203020007050305010807 Content-Type: text/plain; charset=ISO-8859-15; name="apr1.patch" Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename="apr1.patch" Index: devel/apr1/Makefile =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- devel/apr1/Makefile (revision 321639) +++ devel/apr1/Makefile (working copy) @@ -29,18 +29,15 @@ NDBM_DESC=3D NDBM support SSL_DESC=3D OpenSSL crypto driver NSS_DESC=3D NSS crypto driver =20 -.include - APR_VERSION=3D 1.4.6 APU_VERSION=3D 1.4.1 =20 -USES=3D iconv -USE_AUTOTOOLS=3D automake autoconf libtool:env -USE_PYTHON_BUILD=3D -2.7 -USE_LDCONFIG=3D yes -GNU_CONFIGURE=3D yes +USES=3D iconv pathfix +USE_LDCONFIG=3D yes +GNU_CONFIGURE=3D yes =20 -CONFIGURE_ENV=3D CC=3D"${CC}" +CONFIGURE_ENV=3D CC=3D"${CC}" CFLAGS=3D"${CFLAGS}" CPPFLAGS=3D"${CPPFLAG= S}" \ + LDFLAGS=3D"${LDFLAGS}" =20 NO_WRKSUBDIR=3D yes APR_WRKDIR=3D ${WRKDIR}/apr-${APR_VERSION} @@ -55,6 +52,8 @@ APU_CONF_ARGS=3D --with-apr=3D${APR_WRKDIR}=20 --with-expat=3D${LOCALBASE} \ --with-iconv=3D${LOCALBASE} =20 +.include + ########## APR Options .if ${PORT_OPTIONS:MTHREADS} APR_CONF_ARGS+=3D --enable-threads @@ -131,7 +130,7 @@ PLIST_SUB+=3D MYSQL=3D"" USE_MYSQL=3D YES APU_CONF_ARGS+=3D --with-mysql=3D${LOCALBASE} CONFIGURE_ENV+=3D LIBS=3D"${LIBS}" -CFLAGS+=3D -I${LOCALBASE}/include -I${LOCALBASE}/include/mysql -DHAVE_MY= SQL_H +CPPFLAGS+=3D -I${LOCALBASE}/include -I${LOCALBASE}/include/mysql -DHAVE_= MYSQL_H LDFLAGS+=3D -L${LOCALBASE}/lib/mysql .else PLIST_SUB+=3D MYSQL=3D"@comment " @@ -168,7 +167,7 @@ APU_CONF_ARGS+=3D --with-crypto APU_EXTRAS=3D yes USE_OPENSSL=3D yes PLIST_SUB+=3D SSL=3D"" -CFLAGS+=3D -I${OPENSSLINC} +CPPFLAGS+=3D -I${OPENSSLINC} LDFLAGS+=3D -L${OPENSSLLIB} APU_CONF_ARGS+=3D --with-openssl=3D${OPENSSLBASE} .else @@ -182,7 +181,7 @@ APU_CONF_ARGS+=3D --without-openssl APU_EXTRAS=3D yes PLIST_SUB+=3D NSS=3D"" LIB_DEPENDS+=3D nss3:${PORTSDIR}/security/nss -CFLAGS+=3D -I${LOCALBASE}/include/nss +CPPFLAGS+=3D -I${LOCALBASE}/include/nss LDFLAGS+=3D -L${LOCALBASE}/lib/nss APU_CONF_ARGS+=3D --with-nss=3D${LOCALBASE} .else @@ -195,66 +194,31 @@ PLIST_SUB+=3D APU_EXTRAS=3D"" PLIST_SUB+=3D APU_EXTRAS=3D"@comment " .endif =20 -post-patch: .SILENT - ${REINPLACE_CMD} -e 's/OSVERSION/${OSVERSION}/g' \ - ${APR_WRKDIR}/build/apr_hints.m4 - ${FIND} ${APR_WRKDIR} ${APU_WRKDIR} -name "Makefile.in*" | ${XARGS} ${R= EINPLACE_CMD} -e \ - 's|[(]libdir[)]/pkgconfig|(prefix)/libdata/pkgconfig|g' - ${REINPLACE_CMD} -e '1 s/python/${PYTHON_VERSION}/' \ - ${APR_WRKDIR}/build/gen-build.py - ${REINPLACE_CMD} -e 's/void main/int main/' ${APR_WRKDIR}/build/apr_net= work.m4 +post-patch: + @${REINPLACE_CMD} -e 's/$$os_version/${OSVERSION}/g' \ + ${APR_WRKDIR}/configure # Fix pthread: Please do not remove, else apr-1-config returns wrong val= ues - ${REINPLACE_CMD} -e 's/-lpthread/-pthread/g' \ - ${APR_WRKDIR}/build/apr_threads.m4 ${APR_WRKDIR}/build/apr_hints.m4 \ - ${APU_WRKDIR}/build/apu-conf.m4 - -run-autotools:: - cd ${APR_WRKDIR} ; \ - ${SETENV} ${CONFIGURE_ENV} ${SH} ./buildconf - cd ${APU_WRKDIR} ; \ - ${RM} -fr xml/expat - cd ${APU_WRKDIR} ; \ - ${SETENV} ${CONFIGURE_ENV} ${SH} ./buildconf \ - --with-apr=3D${APR_WRKDIR} - ${REINPLACE_CMD} -e 's/ gsed//g' \ - ${APR_WRKDIR}/build/libtool.m4 \ + @${REINPLACE_CMD} -e 's/-lpthread/${PTHREAD_LIBS}/g' \ ${APR_WRKDIR}/configure - cd ${APR_WRKDIR}; \ - ${SETENV} ${CONFIGURE_ENV} ${SH} \ - ./configure ${CONFIGURE_ARGS} ${APR_CONF_ARGS} - cd ${APU_WRKDIR}; \ - ${SETENV} ${CONFIGURE_ENV} CFLAGS=3D"${CFLAGS}" ${SH} \ - ./configure ${CONFIGURE_ARGS} ${APU_CONF_ARGS} =20 do-configure: - ${DO_NADA} + @(cd ${APR_WRKDIR} && \ + ${SETENV} ${CONFIGURE_ENV} \ + ./configure ${CONFIGURE_ARGS} ${APR_CONF_ARGS}) + @(cd ${APU_WRKDIR} && \ + ${SETENV} ${CONFIGURE_ENV} \ + ./configure ${CONFIGURE_ARGS} ${APU_CONF_ARGS}) =20 do-build: - cd ${APR_WRKDIR}; ${SETENV} ${MAKE_ENV} ${MAKE} - cd ${APU_WRKDIR}; ${SETENV} ${MAKE_ENV} ${MAKE} + @(cd ${APR_WRKDIR} && ${SETENV} ${MAKE_ENV} ${MAKE} ${_MAKE_JOBS}) + @(cd ${APU_WRKDIR} && ${SETENV} ${MAKE_ENV} ${MAKE} ${_MAKE_JOBS}) =20 do-install: - cd ${APR_WRKDIR}; ${SETENV} ${MAKE_ENV} ${MAKE} ${INSTALL_TARGET} - cd ${APU_WRKDIR}; ${SETENV} ${MAKE_ENV} ${MAKE} ${INSTALL_TARGET} + @(cd ${APR_WRKDIR} && ${SETENV} ${MAKE_ENV} ${MAKE} ${INSTALL_TARGET}) + @(cd ${APU_WRKDIR} && ${SETENV} ${MAKE_ENV} ${MAKE} ${INSTALL_TARGET}) =20 -test: build - -@(cd ${APR_WRKDIR}; ${MAKE} test) - -@(cd ${APU_WRKDIR}; ${MAKE} test) - -#regression-test: test - -debug_autoconf: - @${ECHO} "LIBTOOL: ${LIBTOOL_VERSION}" - @${ECHO} "AUTOCONF: dev ${dev_acver} cur ${cur_acver} use ${use_acver}"= - @${ECHO} "AUTOMAKE: dev ${dev_amver} cur ${cur_amver} use ${use_amver}"= - @${ECHO} "AUTOCONF_DIR: ${AUTOCONF_DIR}" - @${ECHO} "BUILD_DEPENDS: ${BUILD_DEPENDS}" - @${ECHO} "ACLOCAL_DIR: ${ACLOCAL_DIR}" - @${ECHO} "LIBTOOLFILES: ${LIBTOOLFILES}" - @${ECHO} "LIBTOOL_SHAREDIR: ${LIBTOOL_SHAREDIR}" - @${ECHO} "LIBTOOL_LIBEXECDIR: ${LIBTOOL_LIBEXECDIR}" - @${ECHO} "LIBTOOL_M4: ${LIBTOOL_M4}" - @${ECHO} "${SETENV} ${CONFIGURE_ENV} ${SH} ./configure ${CONFIGURE_ARGS= } ${APR_CONF_ARGS}" - @${ECHO} "${SETENV} ${CONFIGURE_ENV} CFLAGS=3D"${CFLAGS}" ${SH} ./confi= gure ${CONFIGURE_ARGS} ${APR_UTIL_CONF_ARGS}" +regression-test: build + @(cd ${APR_WRKDIR} && ${SETENV} ${MAKE_ENV} ${MAKE} test) + @(cd ${APU_WRKDIR} && ${SETENV} ${MAKE_ENV} ${MAKE} test) =20 .include Index: devel/apr1/files/patch-apr_hints.m4 =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- devel/apr1/files/patch-apr_hints.m4 (revision 321639) +++ devel/apr1/files/patch-apr_hints.m4 (working copy) @@ -1,15 +0,0 @@ ---- apr-1.4.6/build/apr_hints.m4.orig Wed Oct 27 11:12:28 2004 -+++ apr-1.4.6/build/apr_hints.m4 Wed Oct 27 11:25:32 2004 -@@ -159,11 +159,7 @@ - ;; - *-freebsd*) - APR_SETIFNULL(apr_lock_method, [USE_FLOCK_SERIALIZE]) -- if test -x /sbin/sysctl; then -- os_version=3D`/sbin/sysctl -n kern.osreldate` -- else -- os_version=3D000000 -- fi -+ os_version=3D"OSVERSION" - # 502102 is when libc_r switched to libpthread (aka libkse). - if test $os_version -ge "502102"; then - apr_cv_pthreads_cflags=3D"none" --------------000203020007050305010807-- ------enig2EIWEEDJSAQMVHUJBNSTJ Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.20 (FreeBSD) iF4EAREIAAYFAlHHQqkACgkQfoCS2CCgtisiRwEAhahA2B8koPpCPw+Idekq+u+f YUHQAl0ggxOqyQR8OD0A/j/FVQ48pGSrHOtRyxwtEZRLNGiKY7P7bYxcSTvey9rK =dMLu -----END PGP SIGNATURE----- ------enig2EIWEEDJSAQMVHUJBNSTJ--