From 94e59bc59f508fe2130d1153ac92625a5b0e4e4d Mon Sep 17 00:00:00 2001 From: Mathieu Arnold Date: Fri, 7 Mar 2014 18:48:03 +0000 Subject: [PATCH] Update the autotools bits. Draft by: tijl Sponsored by: Absolight --- .../porters-handbook/special/chapter.xml | 104 ++++++------------ 1 file changed, 34 insertions(+), 70 deletions(-) diff --git a/en_US.ISO8859-1/books/porters-handbook/special/chapter.xml b/en_US.ISO8859-1/books/porters-handbook/special/chapter.xml index 61843ce892..c7e993fab3 100644 --- a/en_US.ISO8859-1/books/porters-handbook/special/chapter.xml +++ b/en_US.ISO8859-1/books/porters-handbook/special/chapter.xml @@ -649,67 +649,45 @@ CMAKE_SOURCE_PATH= ${WRKSRC}/subproject Within the Ports Collection, an individual port can make use of these tools via a simple construct: - USE_AUTOTOOLS= tool:version[:operation] ... + USE_AUTOTOOLS= tool[:env] ... At the time of writing, tool - can be one of libtool, - libltdl, autoconf, - autoheader, automake - or aclocal. + can be one of autoconf, + autoheader, automake, + aclocal, libtool + (deprecated), libtoolize, + libltdl. It can also be one the older + legacy of autoconf213, + autoheader213, + automake14, + aclocal14. - version specifies the - particular tool revision to be used (see - devel/{automake,autoconf,libtool}[0-9]+ - for valid versions). - - operation is an optional - extension to modify how the tool is used. + env is used to specify that the + environmental variables are needed. It also adds a build + dependency on the tool. The relevant tool is + not ran as part of the + run-autotools target. Multiple tools can be specified at once, either by including them all on a single line, or using the += Makefile construct. - - Finally, there is the special tool, called - autotools, which is a convenience - function to bring in all available versions of the autotools - to allow for cross-development work. This can also be - accomplished by installing the - devel/autotools port. <command>libtool</command> - Shared libraries using the GNU building framework - usually use libtool to adjust the - compilation and installation of shared libraries to match - the specifics of the underlying operating system. The usual - practice is to use copy of libtool - bundled with the application. In case you need to use - external libtool, you can use the version - provided by The Ports Collection: + The use of USE_AUTOTOOLS=libtool is + deprecated. Now all ports that ship with their own copy of + libtool (search for a file named ltmain.sh) need to have + USES=libtool. Also, if a port has + USE_AUTOTOOLS=libtoolize it probably also + needs USES=libtool. - USE_AUTOTOOLS= libtool:version[:env] + Some ports do not ship with their own copy of libtool and + expect libtool to be provided by the build system. In that + case simply add: - With no additional operations, - libtool:version - tells the building framework to patch the configure script - with the system-installed copy of - libtool. The - GNU_CONFIGURE is implied. Further, a - number of make and shell variables will be assigned for - onward use by the port. See - bsd.autotools.mk for details. - - With the :env operation, only the - environment will be set up. - - Finally, LIBTOOLFLAGS and - LIBTOOLFILES can be optionally set to - override the most likely arguments to, and files patched by, - libtool. Most ports are unlikely to need - this. See bsd.autotools.mk for further - details. + BUILD_DEPENDS= libtool:${PORTSDIR}/devel/libtool. @@ -722,7 +700,7 @@ CMAKE_SOURCE_PATH= ${WRKSRC}/subproject libtool itself, so a separate construct is provided. - USE_AUTOTOOLS= libltdl:version + USE_AUTOTOOLS= libltdl Currently, all this does is to bring in a LIB_DEPENDS on the appropriate @@ -745,27 +723,22 @@ CMAKE_SOURCE_PATH= ${WRKSRC}/subproject autoheader create template headers for use by the configure script. - USE_AUTOTOOLS= autoconf:version[:env] + USE_AUTOTOOLS= autoconf[:env] and - USE_AUTOTOOLS= autoheader:version + USE_AUTOTOOLS= autoheader which also implies the use of - autoconf:version. - - Similarly to libtool, the inclusion - of the optional :env operation simply - sets up the environment for further use. Without it, - patching and reconfiguration of the port is carried - out. + autoconf. The additional optional variables AUTOCONF_ARGS and AUTOHEADER_ARGS can be overridden by the port Makefile if specifically - requested. As with the libtool - equivalents, most ports are unlikely to need this. + requested. Most ports are unlikely to need this. See + bsd.autotools.mk for further + details. @@ -792,20 +765,11 @@ CMAKE_SOURCE_PATH= ${WRKSRC}/subproject previous section. aclocal implies the use of automake, thus we have: - USE_AUTOTOOLS= automake:version[:env] + USE_AUTOTOOLS= automake[:env] and - USE_AUTOTOOLS= aclocal:version - - which also implies the use of - automake:version. - - Similarly to libtool and - autoconf, the inclusion of the optional - :env operation simply sets up the - environment for further use. Without it, reconfiguration of - the port is carried out. + USE_AUTOTOOLS= aclocal As with autoconf and autoheader, both