[88540] trunk/base

jberry at macports.org jberry at macports.org
Tue Jan 3 18:32:12 PST 2012


Revision: 88540
          http://trac.macports.org/changeset/88540
Author:   jberry at macports.org
Date:     2012-01-03 18:32:11 -0800 (Tue, 03 Jan 2012)
Log Message:
-----------
Add autoconfig detection of xcodebuild and xcrun, so that we can
call xcrun from portconfigure in a subsequent patch.

Modified Paths:
--------------
    trunk/base/configure
    trunk/base/configure.ac
    trunk/base/src/port1.0/port_autoconf.tcl.in

Modified: trunk/base/configure
===================================================================
--- trunk/base/configure	2012-01-04 02:28:02 UTC (rev 88539)
+++ trunk/base/configure	2012-01-04 02:32:11 UTC (rev 88540)
@@ -691,6 +691,7 @@
 GNUPATCH
 GNUMAKE
 GNUTAR
+XCRUN
 XCODEBUILD
 LAUNCHCTL
 HAVE_LAUNCHD
@@ -5329,6 +5330,46 @@
 fi
 
 
+# Extract the first word of "xcrun", so it can be a program name with args.
+set dummy xcrun; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if ${ac_cv_path_XCRUN+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  case $XCRUN in
+  [\\/]* | ?:[\\/]*)
+  ac_cv_path_XCRUN="$XCRUN" # 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_XCRUN="$as_dir/$ac_word$ac_exec_ext"
+    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+  done
+IFS=$as_save_IFS
+
+  ;;
+esac
+fi
+XCRUN=$ac_cv_path_XCRUN
+if test -n "$XCRUN"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XCRUN" >&5
+$as_echo "$XCRUN" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
 for ac_prog in gnutar gtar
 do
   # Extract the first word of "$ac_prog", so it can be a program name with args.

Modified: trunk/base/configure.ac
===================================================================
--- trunk/base/configure.ac	2012-01-04 02:28:02 UTC (rev 88539)
+++ trunk/base/configure.ac	2012-01-04 02:32:11 UTC (rev 88540)
@@ -115,6 +115,7 @@
 AC_CHECK_PROG(HAVE_LAUNCHD, [launchd], [yes], [])
 AC_PATH_PROG(LAUNCHCTL, [launchctl], [])
 AC_PATH_PROG(XCODEBUILD, [xcodebuild], [])
+AC_PATH_PROG(XCRUN, [xcrun], [])
 AC_PATH_PROGS(GNUTAR, [gnutar gtar], [], [$PATH:/usr/local/bin])
 AC_PATH_PROGS(GNUMAKE, [gnumake gmake], [], [$PATH:/usr/local/bin])
 AC_PATH_PROGS(GNUPATCH, [gnupatch gpatch], [], [$PATH:/usr/local/bin])

Modified: trunk/base/src/port1.0/port_autoconf.tcl.in
===================================================================
--- trunk/base/src/port1.0/port_autoconf.tcl.in	2012-01-04 02:28:02 UTC (rev 88539)
+++ trunk/base/src/port1.0/port_autoconf.tcl.in	2012-01-04 02:32:11 UTC (rev 88540)
@@ -62,6 +62,9 @@
 	variable mtree_path "@MTREE@"
 	variable pax_path "@PAX@"
 	variable xar_path "@XAR@"
+	variable xcode_select_path "@XCODE_SELECT@"
+	variable xcodebuild_path "@XCODEBUILD@"
+	variable xcrun_path "@XCRUN@"
 	variable sed_command "@SED@"
 	variable sed_ext_flag "@SED_EXT@"
 	variable tar_command "@TAR_CMD@"
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20120103/78a25a97/attachment-0001.html>


More information about the macports-changes mailing list