[24398] trunk/base

source_changes at macosforge.org source_changes at macosforge.org
Mon Apr 23 18:55:13 PDT 2007


Revision: 24398
          http://trac.macosforge.org/projects/macports/changeset/24398
Author:   jmpp at macports.org
Date:     2007-04-23 18:55:13 -0700 (Mon, 23 Apr 2007)

Log Message:
-----------

Bring back autoconf detection of the mtree(8) binary in the same fashion as we do for tar, rsync and others, per jberry's suggestion.
This differs from what he had before for mtree(8), however, as we don't provide our own copy of the sources any longer in case the binary
can't be found.

Modified Paths:
--------------
    trunk/base/Mk/dports.autoconf.mk.in
    trunk/base/configure
    trunk/base/configure.ac
    trunk/base/doc/Makefile
    trunk/base/src/port/Makefile

Modified: trunk/base/Mk/dports.autoconf.mk.in
===================================================================
--- trunk/base/Mk/dports.autoconf.mk.in	2007-04-24 01:44:30 UTC (rev 24397)
+++ trunk/base/Mk/dports.autoconf.mk.in	2007-04-24 01:55:13 UTC (rev 24398)
@@ -25,6 +25,7 @@
 LIBS			= @LIBS@
 MD5_LIBS		= @MD5_LIBS@
 INSTALL			= @INSTALL@
+MTREE			= @MTREE@
 LN_S			= @LN_S@
 XCODEBUILD		= @XCODEBUILD@
 

Modified: trunk/base/configure
===================================================================
--- trunk/base/configure	2007-04-24 01:44:30 UTC (rev 24397)
+++ trunk/base/configure	2007-04-24 01:55:13 UTC (rev 24398)
@@ -677,6 +677,7 @@
 INSTALL_DATA
 SET_MAKE
 LN_S
+MTREE
 CVS
 RSYNC
 HAVE_LAUNCHD
@@ -751,6 +752,7 @@
 LDFLAGS
 LIBS
 CPPFLAGS
+MTREE
 CVS
 RSYNC
 TAR
@@ -1366,6 +1368,7 @@
   LIBS        libraries to pass to the linker, e.g. -l<library>
   CPPFLAGS    C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
               you have headers in a nonstandard directory <include dir>
+  MTREE       path to mtree command
   CVS         path to cvs command
   RSYNC       path to rsync command
   TAR         path to tar command
@@ -3033,6 +3036,46 @@
 echo "${ECHO_T}no, using $LN_S" >&6; }
 fi
 
+# Extract the first word of "mtree", so it can be a program name with args.
+set dummy mtree; ac_word=$2
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+if test "${ac_cv_path_MTREE+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  case $MTREE in
+  [\\/]* | ?:[\\/]*)
+  ac_cv_path_MTREE="$MTREE" # Let the user override the test with a path.
+  ;;
+  *)
+  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+  for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_path_MTREE="$as_dir/$ac_word$ac_exec_ext"
+    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+done
+IFS=$as_save_IFS
+
+  ;;
+esac
+fi
+MTREE=$ac_cv_path_MTREE
+if test -n "$MTREE"; then
+  { echo "$as_me:$LINENO: result: $MTREE" >&5
+echo "${ECHO_T}$MTREE" >&6; }
+else
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
+fi
+
+
 # Extract the first word of "cvs", so it can be a program name with args.
 set dummy cvs; ac_word=$2
 { echo "$as_me:$LINENO: checking for $ac_word" >&5
@@ -3320,6 +3363,7 @@
 
 
 
+
 	# Extract the first word of "tar", so it can be a program name with args.
 set dummy tar; ac_word=$2
 { echo "$as_me:$LINENO: checking for $ac_word" >&5
@@ -10176,6 +10220,7 @@
 INSTALL_DATA!$INSTALL_DATA$ac_delim
 SET_MAKE!$SET_MAKE$ac_delim
 LN_S!$LN_S$ac_delim
+MTREE!$MTREE$ac_delim
 CVS!$CVS$ac_delim
 RSYNC!$RSYNC$ac_delim
 HAVE_LAUNCHD!$HAVE_LAUNCHD$ac_delim
@@ -10211,7 +10256,6 @@
 X_EXTRA_LIBS!$X_EXTRA_LIBS$ac_delim
 TCL_VERSION!$TCL_VERSION$ac_delim
 TCL_BIN_DIR!$TCL_BIN_DIR$ac_delim
-TCL_SRC_DIR!$TCL_SRC_DIR$ac_delim
 _ACEOF
 
   if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then
@@ -10253,6 +10297,7 @@
 ac_delim='%!_!# '
 for ac_last_try in false false false false false :; do
   cat >conf$$subs.sed <<_ACEOF
+TCL_SRC_DIR!$TCL_SRC_DIR$ac_delim
 TCL_LIB_FILE!$TCL_LIB_FILE$ac_delim
 TCL_LIB_FLAG!$TCL_LIB_FLAG$ac_delim
 TCL_LIB_SPEC!$TCL_LIB_SPEC$ac_delim
@@ -10284,7 +10329,7 @@
 LTLIBOBJS!$LTLIBOBJS$ac_delim
 _ACEOF
 
-  if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 29; then
+  if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 30; then
     break
   elif $ac_last_try; then
     { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5

Modified: trunk/base/configure.ac
===================================================================
--- trunk/base/configure.ac	2007-04-24 01:44:30 UTC (rev 24397)
+++ trunk/base/configure.ac	2007-04-24 01:55:13 UTC (rev 24398)
@@ -13,6 +13,7 @@
 AC_PROG_INSTALL
 AC_PROG_MAKE_SET
 AC_PROG_LN_S
+AC_PATH_PROG(MTREE, [mtree], [])
 AC_PATH_PROG(CVS, [cvs], [])
 AC_PATH_PROG(RSYNC, [rsync], [])
 AC_CHECK_PROG(HAVE_LAUNCHD, [launchd], [yes], [])
@@ -22,6 +23,7 @@
 AC_PATH_PROG(XAR, [xar], [])
 
 # Define some precious variables allowing user to override PATH for some programs
+AC_ARG_VAR(MTREE, [path to mtree command])
 AC_ARG_VAR(CVS, [path to cvs command])
 AC_ARG_VAR(RSYNC, [path to rsync command])
 AC_ARG_VAR(TAR, [path to tar command])

Modified: trunk/base/doc/Makefile
===================================================================
--- trunk/base/doc/Makefile	2007-04-24 01:44:30 UTC (rev 24397)
+++ trunk/base/doc/Makefile	2007-04-24 01:55:13 UTC (rev 24398)
@@ -20,7 +20,7 @@
 	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${INSTALLDIR}
 	$(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${DESTDIR}${portconfigdir}
 
-	cat prefix.mtree | mtree -U -e -p ${INSTALLDIR} > /dev/null
+	cat prefix.mtree | $(MTREE) -U -e -p ${INSTALLDIR} > /dev/null
 	if test -L "${INSTALLDIR}/man" ; then \
 		rm -f "${INSTALLDIR}/man"; \
 	fi

Modified: trunk/base/src/port/Makefile
===================================================================
--- trunk/base/src/port/Makefile	2007-04-24 01:44:30 UTC (rev 24397)
+++ trunk/base/src/port/Makefile	2007-04-24 01:55:13 UTC (rev 24398)
@@ -21,7 +21,7 @@
 	${edit} port.tcl > $@
 
 mkdirs:
-	cat ../../doc/prefix.mtree | mtree -U -d -e -p ${INSTALLDIR} > /dev/null
+	cat ../../doc/prefix.mtree | $(MTREE) -U -d -e -p ${INSTALLDIR} > /dev/null
 
 clean:
 	rm -f ${SCRIPTS}

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.macosforge.org/pipermail/macports-changes/attachments/20070423/69aee265/attachment.html


More information about the macports-changes mailing list