Skip to content

Commit

Permalink
Add --with-xcodecfg configure flag
Browse files Browse the repository at this point in the history
  • Loading branch information
b4winckler committed Sep 29, 2009
1 parent b262a38 commit b05db8d
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 4 deletions.
21 changes: 19 additions & 2 deletions src/configure
Original file line number Diff line number Diff line change
Expand Up @@ -1387,6 +1387,7 @@ Optional Packages:
--with-gnome Specify prefix for GNOME files
--with-motif-lib=STRING Library for Motif
--with-tlib=library terminal library to be used
--with-xcodecfg=CFG Debug, Release (default: Release)
--with-archs=ARCHS space separated list of archs (i386 x86_64 ppc ...)
Some influential environment variables:
Expand Down Expand Up @@ -16482,6 +16483,21 @@ if test "x$MACARCH" = "xboth"; then
fi
if test "x$MACOSX" = "xyes"; then
{ echo "$as_me:$LINENO: checking --with-xcodecfg argument" >&5
echo $ECHO_N "checking --with-xcodecfg argument... $ECHO_C" >&6; }
# Check whether --with-xcodecfg was given.
if test "${with_xcodecfg+set}" = set; then
withval=$with_xcodecfg; XCODEFLAGS="$XCODEFLAGS -configuration $withval"
{ echo "$as_me:$LINENO: result: $withval" >&5
echo "${ECHO_T}$withval" >&6; }
else
{ echo "$as_me:$LINENO: result: using default" >&5
echo "${ECHO_T}using default" >&6; }
fi
{ echo "$as_me:$LINENO: checking --with-archs argument" >&5
echo $ECHO_N "checking --with-archs argument... $ECHO_C" >&6; }
Expand Down Expand Up @@ -16538,8 +16554,7 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
$as_test_x conftest$ac_exeext; then
{ echo "$as_me:$LINENO: result: yes" >&5
echo "${ECHO_T}yes" >&6; }
XCODEFLAGS="ARCHS=\"$ARCHS\" ONLY_ACTIVE_ARCH=\"NO\""
XCODEFLAGS="$XCODEFLAGS ARCHS=\"$ARCHS\" ONLY_ACTIVE_ARCH=\"NO\""
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
Expand All @@ -16558,6 +16573,8 @@ rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
CFLAGS="$CFLAGS -m32"
LDFLAGS="$LDFLAGS -m32"
fi
fi
Expand Down
13 changes: 11 additions & 2 deletions src/configure.in
Original file line number Diff line number Diff line change
Expand Up @@ -3252,6 +3252,14 @@ if test "x$MACARCH" = "xboth"; then
fi

if test "x$MACOSX" = "xyes"; then
AC_MSG_CHECKING(--with-xcodecfg argument)
AC_ARG_WITH(xcodecfg,
[ --with-xcodecfg=CFG Debug, Release (default: Release)],
[ XCODEFLAGS="$XCODEFLAGS -configuration $withval"
AC_MSG_RESULT($withval) ],
[ AC_MSG_RESULT(using default) ])


AC_MSG_CHECKING(--with-archs argument)
AC_ARG_WITH(archs,
[ --with-archs=ARCHS space separated list of archs (i386 x86_64 ppc ...)],
Expand All @@ -3267,8 +3275,7 @@ if test "x$MACOSX" = "xyes"; then
LDFLAGS="$LDFLAGS $archflags"
AC_TRY_LINK([ ], [ ],
[ AC_MSG_RESULT([yes])
XCODEFLAGS="ARCHS=\"$ARCHS\" ONLY_ACTIVE_ARCH=\"NO\""
AC_SUBST(XCODEFLAGS) ],
XCODEFLAGS="$XCODEFLAGS ARCHS=\"$ARCHS\" ONLY_ACTIVE_ARCH=\"NO\"" ],
[ AC_MSG_RESULT([no, will build for native arch only])
ARCHS=""
CFLAGS="$save_cflags"
Expand All @@ -3281,6 +3288,8 @@ if test "x$MACOSX" = "xyes"; then
CFLAGS="$CFLAGS -m32"
LDFLAGS="$LDFLAGS -m32"
fi

AC_SUBST(XCODEFLAGS)
fi


Expand Down

0 comments on commit b05db8d

Please sign in to comment.