Date: Mon, 2 Sep 2002 21:34:12 -0400 (EDT) From: Alan Eldridge <ports@geeksrus.net> To: FreeBSD-gnats-submit@FreeBSD.org Subject: ports/42351: Mk/bsd.port.mk: clean up auto* mess Message-ID: <200209030134.g831YCqr083102@wwweasel.geeksrus.net>
next in thread | raw e-mail | index | archive | help
>Number: 42351 >Category: ports >Synopsis: Mk/bsd.port.mk: clean up auto* mess >Confidential: no >Severity: serious >Priority: high >Responsible: freebsd-ports >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon Sep 02 18:40:01 PDT 2002 >Closed-Date: >Last-Modified: >Originator: Alan Eldridge >Release: FreeBSD 4.6-STABLE i386 >Organization: Geeksrus.NET >Environment: System: FreeBSD wwweasel.geeksrus.net 4.6-STABLE FreeBSD 4.6-STABLE #0: Sat Aug 31 23:40:18 EDT 2002 root@wwweasel.geeksrus.net:/usr/obj/usr/src/sys/WWWEASEL i386 >Description: The current handling of autoconf and automake versions is clumsy at best, and does not allow specifying use of current autoconf. >How-To-Repeat: >Fix: This patch supercedes the one I have circulated via mail. As usual, there were still a few bugs lurking in that one. ==8<====8<====8<====8<====8<====8<====8<====8<====8<====8<== Index: bsd.port.mk =================================================================== RCS file: /home/ncvs/ports/Mk/bsd.port.mk,v retrieving revision 1.422 diff -u -3 -r1.422 bsd.port.mk --- bsd.port.mk 19 Aug 2002 17:12:59 -0000 1.422 +++ bsd.port.mk 3 Sep 2002 00:20:18 -0000 @@ -873,36 +876,73 @@ BUILD_DEPENDS+= gmake:${PORTSDIR}/devel/gmake CONFIGURE_ENV+= MAKE=${GMAKE} .endif -.if defined(USE_AUTOMAKE) || defined(USE_AUTOMAKE_VER) -USE_AUTOMAKE?= yes -USE_AUTOMAKE_VER?= 14 -USE_AUTOCONF= yes -.endif -.if defined(USE_AUTOMAKE_VER) -.if ${USE_AUTOMAKE_VER} == 15 -BUILD_DEPENDS+= automake:${PORTSDIR}/devel/automake +# Proof of concept for autotools versioning using PATH +# AlanE <ports@geeksrus.net> -ACLOCAL?= aclocal -AUTOMAKE?= automake -ACLOCAL_DIR?= ${LOCALBASE}/share/aclocal -AUTOMAKE_DIR?= ${LOCALBASE}/share/automake -.else -BUILD_DEPENDS+= automake14:${PORTSDIR}/devel/automake14 +.if defined(USE_AUTOMAKE) || defined(USE_AUTOMAKE_VER) +USE_AUTOMAKE?= yes +USE_AUTOMAKE_VER?= 14 +.if ${USE_AUTOMAKE_VER} == 14 AUTOMAKE_ARGS+= -i -USE_AUTOCONF_VER?= 213 +ACLOCAL_DIR= ${LOCALBASE}/share/automake14/aclocal +AUTOMAKE_DIR= ${LOCALBASE}/share/automake14/automake +_AUTOMAKE_PATH= ${LOCALBASE}/libexec/automake14 +BUILD_DEPENDS+= automake14:${PORTSDIR}/devel/automake14 +USE_AUTOCONF_VER= 213 +.else +AUTOMAKE_DIR= ${LOCALBASE}/share/automake +BUILD_DEPENDS+= automake:${PORTSDIR}/devel/automake +USE_AUTOCONF_VER= current .endif .endif + .if defined(USE_AUTOCONF) || defined(USE_AUTOCONF_VER) -USE_AUTOCONF?= yes +USE_AUTOCONF?= yes USE_AUTOCONF_VER?= 213 +.if ${USE_AUTOCONF_VER} == 213 +_AUTOCONF_PATH= ${LOCALBASE}/libexec/autoconf213 +AUTOCONF_DIR= ${LOCALBASE}/share/autoconf213 +BUILD_DEPENDS+= autoconf213:${PORTSDIR}/devel/autoconf213 +.else +AUTOCONF_DIR= ${LOCALBASE}/share/autoconf +BUILD_DEPENDS+= autoconf:${PORTSDIR}/devel/autoconf +.endif +.endif + +.if defined(USE_AUTOMAKE_VER) +ACLOCAL= aclocal +AUTOMAKE= automake GNU_CONFIGURE= yes .endif .if defined(USE_AUTOCONF_VER) -BUILD_DEPENDS+= autoconf213:${PORTSDIR}/devel/autoconf213 +AUTOCONF= autoconf +AUTOHEADER= autoheader +AUTORECONF= autoreconf +AUTOSCAN= autoscan +AUTOUPDATE= autoupdate +AUTOIFNAMES= ifnames +GNU_CONFIGURE= yes +.endif + +.if defined(_AUTOCONF_PATH) && defined(_AUTOMAKE_PATH) +_AUTOTOOLS_PATH= ${_AUTOMAKE_PATH}:${_AUTOCONF_PATH} +.elif defined(_AUTOCONF_PATH) +_AUTOTOOLS_PATH= ${_AUTOCONF_PATH} .endif + +.if defined(_AUTOTOOLS_PATH) +MAKE_ENV+= PATH=${_AUTOTOOLS_PATH}:${PATH} +CONFIGURE_ENV+= PATH=${_AUTOTOOLS_PATH}:${PATH} +SCRIPTS_ENV+= PATH=${_AUTOTOOLS_PATH}:${PATH} +AUTOCONF_ENV+= PATH=${_AUTOTOOLS_PATH}:${PATH} +AUTOMAKE_ENV+= PATH=${_AUTOTOOLS_PATH}:${PATH} +.endif + +# END test autotools code + .if defined(USE_LIBTOOL) GNU_CONFIGURE= yes BUILD_DEPENDS+= libtool:${PORTSDIR}/devel/libtool ==8<====8<====8<====8<====8<====8<====8<====8<====8<====8<== The result of this patch, as it's kind of hard to tell from the patch itself, is this section of code: The preamble and trailing comments would, of course, be deleted before committing. ==8<====8<====8<====8<====8<====8<====8<====8<====8<====8<== # Proof of concept for autotools versioning using PATH # AlanE <ports@geeksrus.net> .if defined(USE_AUTOMAKE) || defined(USE_AUTOMAKE_VER) USE_AUTOMAKE?= yes USE_AUTOMAKE_VER?= 14 .if ${USE_AUTOMAKE_VER} == 14 AUTOMAKE_ARGS+= -i ACLOCAL_DIR= ${LOCALBASE}/share/automake14/aclocal AUTOMAKE_DIR= ${LOCALBASE}/share/automake14/automake _AUTOMAKE_PATH= ${LOCALBASE}/libexec/automake14 BUILD_DEPENDS+= automake14:${PORTSDIR}/devel/automake14 USE_AUTOCONF_VER= 213 .else AUTOMAKE_DIR= ${LOCALBASE}/share/automake BUILD_DEPENDS+= automake:${PORTSDIR}/devel/automake USE_AUTOCONF_VER= current .endif .endif .if defined(USE_AUTOCONF) || defined(USE_AUTOCONF_VER) USE_AUTOCONF?= yes USE_AUTOCONF_VER?= 213 .if ${USE_AUTOCONF_VER} == 213 _AUTOCONF_PATH= ${LOCALBASE}/libexec/autoconf213 AUTOCONF_DIR= ${LOCALBASE}/share/autoconf213 BUILD_DEPENDS+= autoconf213:${PORTSDIR}/devel/autoconf213 .else AUTOCONF_DIR= ${LOCALBASE}/share/autoconf BUILD_DEPENDS+= autoconf:${PORTSDIR}/devel/autoconf .endif .endif .if defined(USE_AUTOMAKE_VER) ACLOCAL= aclocal AUTOMAKE= automake GNU_CONFIGURE= yes .endif .if defined(USE_AUTOCONF_VER) AUTOCONF= autoconf AUTOHEADER= autoheader AUTORECONF= autoreconf AUTOSCAN= autoscan AUTOUPDATE= autoupdate AUTOIFNAMES= ifnames GNU_CONFIGURE= yes .endif .if defined(_AUTOCONF_PATH) && defined(_AUTOMAKE_PATH) _AUTOTOOLS_PATH= ${_AUTOMAKE_PATH}:${_AUTOCONF_PATH} .elif defined(_AUTOCONF_PATH) _AUTOTOOLS_PATH= ${_AUTOCONF_PATH} .endif .if defined(_AUTOTOOLS_PATH) MAKE_ENV+= PATH=${_AUTOTOOLS_PATH}:${PATH} CONFIGURE_ENV+= PATH=${_AUTOTOOLS_PATH}:${PATH} SCRIPTS_ENV+= PATH=${_AUTOTOOLS_PATH}:${PATH} AUTOCONF_ENV+= PATH=${_AUTOTOOLS_PATH}:${PATH} AUTOMAKE_ENV+= PATH=${_AUTOTOOLS_PATH}:${PATH} .endif # END test autotools code ==8<====8<====8<====8<====8<====8<====8<====8<====8<====8<== >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200209030134.g831YCqr083102>