Change optional tool settings from environment variables to --with-foo=/bin/foo style. Resolves issues with bzip2 and BZIP2. See https://trac.macports.org/ticket/43204. Still needs regen.

git-svn-id: https://svn.macports.org/repository/macports/trunk/base@119421 d073be05-634f-4543-b044-5fe20cf6d1d6
This commit is contained in:
Eric A. Borisch
2014-04-25 05:29:21 +00:00
parent 2c062eb48b
commit db72e648c2
2 changed files with 29 additions and 18 deletions
Vendored
+9
View File
@@ -96,6 +96,15 @@ AC_DEFUN([_MP_EXTRACT_KEY], [dnl
$1=$(AS_ECHO([$2]) | sed -E 's/^--?([[^=]]+)=.*$/\1/')dnl
])
dnl Similar to AC_ARG_VAR, but implemented with --with-pkg=PATH for PKG.
dnl
dnl Parameters: Similar to AC_ARG_VAR ($2 gets some boiler plate around it)
AC_DEFUN([MP_TOOL_PATH], [dnl
AC_ARG_WITH([m4_tolower($1)], [AS_HELP_STRING([--with-m4_tolower($1)=PATH],
[Path to alternate $2 command])], [$1=$withval],dnl
[])dnl
])
dnl Configure a project contained in a .tar.gz, .tgz or .tar.bz2 tarball,
dnl extracting it previously, if necessary. Different from AC_CONFIG_SUBDIRS
dnl (on which this macro is based), you can pass parameters to the
+20 -18
View File
@@ -101,6 +101,26 @@ AC_PROG_LN_S
AC_PROG_MAKE_SET
AC_PROG_OBJC([clang cc gcc])
# Check for user-supplied paths before searching
MP_TOOL_PATH(BSDMAKE, [bsdmake/pmake])
MP_TOOL_PATH(BZIP2, [bzip2])
MP_TOOL_PATH(CVS, [cvs])
MP_TOOL_PATH(GNUMAKE, [gnumake])
MP_TOOL_PATH(GNUTAR, [gnutar])
MP_TOOL_PATH(LZMA, [lzma])
MP_TOOL_PATH(MAKE, [make])
MP_TOOL_PATH(MTREE, [mtree])
MP_TOOL_PATH(OPEN, [open])
MP_TOOL_PATH(OPENSSL, [openssl])
MP_TOOL_PATH(RSYNC, [rsync])
MP_TOOL_PATH(SED, [sed])
MP_TOOL_PATH(SVN, [svn])
MP_TOOL_PATH(SWIG, [swig])
MP_TOOL_PATH(TAR, [tar])
MP_TOOL_PATH(XAR, [xar])
MP_TOOL_PATH(XZ, [xz])
# Search for tool paths. Any set above (via --with-pkg=PATH) will be retained
AC_PATH_PROGS(BSDMAKE, [bsdmake pmake], [])
AC_PATH_PROG(BZIP2, [bzip2], [])
AC_PATH_PROG(BZR, [bzr], [])
@@ -149,24 +169,6 @@ AC_PATH_PROG(ZIP, [zip])
AC_CHECK_PROG(HAVE_LAUNCHD, [launchd], [yes], [], [/sbin])
# Define some precious variables allowing user to override PATH for some programs
AC_ARG_VAR(BSDMAKE, [path to bsdmake/pmake command])
AC_ARG_VAR(BZIP2, [path to bzip2 command])
AC_ARG_VAR(CVS, [path to cvs command])
AC_ARG_VAR(GNUMAKE, [path to gnumake command])
AC_ARG_VAR(GNUTAR, [path to gnutar command])
AC_ARG_VAR(LZMA, [path to lzma command])
AC_ARG_VAR(MAKE, [path to make command])
AC_ARG_VAR(MTREE, [path to mtree command])
AC_ARG_VAR(OPEN, [path to open command])
AC_ARG_VAR(OPENSSL, [path to openssl command])
AC_ARG_VAR(RSYNC, [path to rsync command])
AC_ARG_VAR(SED, [path to sed command])
AC_ARG_VAR(SVN, [path to svn command])
AC_ARG_VAR(SWIG, [path to swig command])
AC_ARG_VAR(TAR, [path to tar command])
AC_ARG_VAR(XAR, [path to xar command])
AC_ARG_VAR(XZ, [path to xz command])
if test "x$MTREE" = "x"; then
AC_MSG_ERROR([mtree not found])