4 From: Bram Moolenaar <Bram@moolenaar.net>
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
11 Problem: Mac: Can't build with different Xcode developer tools directory.
12 Solution: make "Developer" directory name configurable. (Rainer Muller)
13 Files: src/configure.in, src/auto/configure
16 *** ../vim-7.2.392/src/configure.in 2010-02-24 14:46:58.000000000 +0100
17 --- src/configure.in 2010-03-10 16:16:48.000000000 +0100
21 MACARCH="$withval"; AC_MSG_RESULT($MACARCH),
22 MACARCH="current"; AC_MSG_RESULT(defaulting to $MACARCH))
24 + AC_MSG_CHECKING(--with-developer-dir argument)
25 + AC_ARG_WITH(developer-dir, [ --with-developer-dir=PATH use PATH as location for Xcode developer tools],
26 + DEVELOPER_DIR="$withval"; AC_MSG_RESULT($DEVELOPER_DIR),
27 + DEVELOPER_DIR=""; AC_MSG_RESULT(not present))
29 + if test "x$DEVELOPER_DIR" = "x"; then
30 + AC_PATH_PROG(XCODE_SELECT, xcode-select)
31 + if test "x$XCODE_SELECT" != "x"; then
32 + AC_MSG_CHECKING(for developer dir using xcode-select)
33 + DEVELOPER_DIR=`$XCODE_SELECT -print-path`
34 + AC_MSG_RESULT([$DEVELOPER_DIR])
36 + DEVELOPER_DIR=/Developer
40 if test "x$MACARCH" = "xboth"; then
41 AC_MSG_CHECKING(for 10.4 universal SDK)
42 dnl There is a terrible inconsistency (but we appear to get away with it):
45 save_cppflags="$CPPFLAGS"
47 save_ldflags="$LDFLAGS"
48 ! CFLAGS="$CFLAGS -isysroot /Developer/SDKs/MacOSX10.4u.sdk -arch i386 -arch ppc"
50 AC_MSG_RESULT(found, will make universal binary),
53 save_cppflags="$CPPFLAGS"
55 save_ldflags="$LDFLAGS"
56 ! CFLAGS="$CFLAGS -isysroot $DEVELOPER_DIR/SDKs/MacOSX10.4u.sdk -arch i386 -arch ppc"
58 AC_MSG_RESULT(found, will make universal binary),
62 dnl TODO: use -arch i386 on Intel machines
63 CPPFLAGS="$CPPFLAGS -DMACOS_X_UNIX -no-cpp-precomp"
64 if test "x$MACARCH" = "xboth"; then
65 ! CPPFLAGS="$CPPFLAGS -I/Developer/SDKs/MacOSX10.4u.sdk/Developer/Headers/FlatCarbon"
67 ! CPPFLAGS="$CPPFLAGS -I/Developer/Headers/FlatCarbon"
70 dnl If Carbon is found, assume we don't want X11
72 dnl TODO: use -arch i386 on Intel machines
73 CPPFLAGS="$CPPFLAGS -DMACOS_X_UNIX -no-cpp-precomp"
74 if test "x$MACARCH" = "xboth"; then
75 ! CPPFLAGS="$CPPFLAGS -I$DEVELOPER_DIR/SDKs/MacOSX10.4u.sdk/Developer/Headers/FlatCarbon"
77 ! CPPFLAGS="$CPPFLAGS -I$DEVELOPER_DIR/Headers/FlatCarbon"
80 dnl If Carbon is found, assume we don't want X11
85 if test "x$MACARCH" = "xboth"; then
86 ! LDFLAGS="$LDFLAGS -isysroot /Developer/SDKs/MacOSX10.4u.sdk -arch i386 -arch ppc"
89 dnl gcc 3.1 changed the meaning of -MM. The only solution appears to be to
93 if test "x$MACARCH" = "xboth"; then
94 ! LDFLAGS="$LDFLAGS -isysroot $DEVELOPER_DIR/SDKs/MacOSX10.4u.sdk -arch i386 -arch ppc"
97 dnl gcc 3.1 changed the meaning of -MM. The only solution appears to be to
98 *** ../vim-7.2.392/src/auto/configure 2010-02-24 14:46:58.000000000 +0100
99 --- src/auto/configure 2010-03-10 16:19:47.000000000 +0100
113 enable_option_checking
123 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
124 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
125 --with-mac-arch=ARCH current, intel, ppc or both
126 + --with-developer-dir=PATH use PATH as location for Xcode developer tools
127 --with-local-dir=PATH search PATH instead of /usr/local for local libraries.
128 --without-local-dir do not search /usr/local for local libraries.
129 --with-vim-name=NAME what to call the Vim executable
135 if test "x$MACARCH" = "xboth"; then
136 { $as_echo "$as_me:$LINENO: checking for 10.4 universal SDK" >&5
137 $as_echo_n "checking for 10.4 universal SDK... " >&6; }
138 save_cppflags="$CPPFLAGS"
139 save_cflags="$CFLAGS"
140 save_ldflags="$LDFLAGS"
141 ! CFLAGS="$CFLAGS -isysroot /Developer/SDKs/MacOSX10.4u.sdk -arch i386 -arch ppc"
142 cat >conftest.$ac_ext <<_ACEOF
149 + { $as_echo "$as_me:$LINENO: checking --with-developer-dir argument" >&5
150 + $as_echo_n "checking --with-developer-dir argument... " >&6; }
152 + # Check whether --with-developer-dir was given.
153 + if test "${with_developer_dir+set}" = set; then
154 + withval=$with_developer_dir; DEVELOPER_DIR="$withval"; { $as_echo "$as_me:$LINENO: result: $DEVELOPER_DIR" >&5
155 + $as_echo "$DEVELOPER_DIR" >&6; }
157 + DEVELOPER_DIR=""; { $as_echo "$as_me:$LINENO: result: not present" >&5
158 + $as_echo "not present" >&6; }
162 + if test "x$DEVELOPER_DIR" = "x"; then
163 + # Extract the first word of "xcode-select", so it can be a program name with args.
164 + set dummy xcode-select; ac_word=$2
165 + { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
166 + $as_echo_n "checking for $ac_word... " >&6; }
167 + if test "${ac_cv_path_XCODE_SELECT+set}" = set; then
168 + $as_echo_n "(cached) " >&6
170 + case $XCODE_SELECT in
172 + ac_cv_path_XCODE_SELECT="$XCODE_SELECT" # Let the user override the test with a path.
175 + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
176 + for as_dir in $PATH
179 + test -z "$as_dir" && as_dir=.
180 + for ac_exec_ext in '' $ac_executable_extensions; do
181 + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
182 + ac_cv_path_XCODE_SELECT="$as_dir/$ac_word$ac_exec_ext"
183 + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
193 + XCODE_SELECT=$ac_cv_path_XCODE_SELECT
194 + if test -n "$XCODE_SELECT"; then
195 + { $as_echo "$as_me:$LINENO: result: $XCODE_SELECT" >&5
196 + $as_echo "$XCODE_SELECT" >&6; }
198 + { $as_echo "$as_me:$LINENO: result: no" >&5
199 + $as_echo "no" >&6; }
203 + if test "x$XCODE_SELECT" != "x"; then
204 + { $as_echo "$as_me:$LINENO: checking for developer dir using xcode-select" >&5
205 + $as_echo_n "checking for developer dir using xcode-select... " >&6; }
206 + DEVELOPER_DIR=`$XCODE_SELECT -print-path`
207 + { $as_echo "$as_me:$LINENO: result: $DEVELOPER_DIR" >&5
208 + $as_echo "$DEVELOPER_DIR" >&6; }
210 + DEVELOPER_DIR=/Developer
214 if test "x$MACARCH" = "xboth"; then
215 { $as_echo "$as_me:$LINENO: checking for 10.4 universal SDK" >&5
216 $as_echo_n "checking for 10.4 universal SDK... " >&6; }
217 save_cppflags="$CPPFLAGS"
218 save_cflags="$CFLAGS"
219 save_ldflags="$LDFLAGS"
220 ! CFLAGS="$CFLAGS -isysroot $DEVELOPER_DIR/SDKs/MacOSX10.4u.sdk -arch i386 -arch ppc"
221 cat >conftest.$ac_ext <<_ACEOF
226 OS_EXTRA_OBJ="objects/os_macosx.o objects/os_mac_conv.o"
227 CPPFLAGS="$CPPFLAGS -DMACOS_X_UNIX -no-cpp-precomp"
228 if test "x$MACARCH" = "xboth"; then
229 ! CPPFLAGS="$CPPFLAGS -I/Developer/SDKs/MacOSX10.4u.sdk/Developer/Headers/FlatCarbon"
231 ! CPPFLAGS="$CPPFLAGS -I/Developer/Headers/FlatCarbon"
234 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
236 OS_EXTRA_OBJ="objects/os_macosx.o objects/os_mac_conv.o"
237 CPPFLAGS="$CPPFLAGS -DMACOS_X_UNIX -no-cpp-precomp"
238 if test "x$MACARCH" = "xboth"; then
239 ! CPPFLAGS="$CPPFLAGS -I$DEVELOPER_DIR/SDKs/MacOSX10.4u.sdk/Developer/Headers/FlatCarbon"
241 ! CPPFLAGS="$CPPFLAGS -I$DEVELOPER_DIR/Headers/FlatCarbon"
244 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
249 if test "x$MACARCH" = "xboth"; then
250 ! LDFLAGS="$LDFLAGS -isysroot /Developer/SDKs/MacOSX10.4u.sdk -arch i386 -arch ppc"
253 DEPEND_CFLAGS_FILTER=
257 if test "x$MACARCH" = "xboth"; then
258 ! LDFLAGS="$LDFLAGS -isysroot $DEVELOPER_DIR/SDKs/MacOSX10.4u.sdk -arch i386 -arch ppc"
261 DEPEND_CFLAGS_FILTER=
262 *** ../vim-7.2.392/src/version.c 2010-03-10 16:11:57.000000000 +0100
263 --- src/version.c 2010-03-10 16:26:00.000000000 +0100
267 { /* Add new patch number below this line */
273 There are 2 kinds of people in my world: those who know Unix, Perl, Vim, GNU,
274 Linux, etc, and those who know COBOL. It gets very difficult for me at
275 parties, not knowing which group to socialise with :-)
278 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
279 /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
280 \\\ download, build and distribute -- http://www.A-A-P.org ///
281 \\\ help me help AIDS victims -- http://ICCF-Holland.org ///