X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/49b0a3aad965b07c9c39ea5038420b15e156324f..941b78cc1da712afca54adb29bb6c04d6ba9b295:/aclocal.m4 diff --git a/aclocal.m4 b/aclocal.m4 index 0828cf2a63..b92b74aa73 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -1299,7 +1299,7 @@ while test \${#} -gt 0; do exit 1 ;; - *.o | *.a) + *.o | *.a | *.dylib) # collect object files objects="\${objects} \${1}" ;; @@ -1464,6 +1464,16 @@ AC_DEFUN(AC_BAKEFILE_DEPS, if test "x$GCC" = "xyes"; then DEPSMODE=gcc DEPS_TRACKING=1 + case "${host}" in + powerpc-*-darwin* ) + dnl -cpp-precomp (the default) conflicts with -MMD option + dnl used by bk-deps (see also http://developer.apple.com/documentation/Darwin/Conceptual/PortingUnix/compiling/chapter_4_section_3.html) + DEPSFLAG_GCC="-no-cpp-precomp -MMD" + ;; + * ) + DEPSFLAG_GCC="-MMD" + ;; + esac AC_MSG_RESULT([gcc]) else AC_MSG_RESULT([none]) @@ -1480,11 +1490,12 @@ AC_DEFUN(AC_BAKEFILE_DEPS, DEPSMODE=$DEPSMODE DEPSDIR=.deps +DEPSFLAG_GCC="$DEPSFLAG_GCC" mkdir -p \$DEPSDIR if test \$DEPSMODE = gcc ; then - \${*} -MMD + \${*} \${DEPSFLAG_GCC} status=\${?} if test \${status} != 0 ; then exit \${status} @@ -1506,8 +1517,16 @@ if test \$DEPSMODE = gcc ; then done depfile=\`basename \$srcfile | sed -e 's/\..*$/.d/g'\` depobjname=\`echo \$depfile |sed -e 's/\.d/.o/g'\` - sed -e "s,\$depobjname:,\$objfile:,g" \$depfile >\${DEPSDIR}/\${objfile}.d - rm -f \$depfile + if test -f \$depfile ; then + sed -e "s,\$depobjname:,\$objfile:,g" \$depfile >\${DEPSDIR}/\${objfile}.d + rm -f \$depfile + else + depfile=\`basename \$objfile | sed -e 's/\..*$/.d/g'\` + if test -f \$depfile ; then + sed -e "/^\$objfile/! s,\$depobjname:,\$objfile:,g" \$depfile >\${DEPSDIR}/\${objfile}.d + rm -f \$depfile + fi + fi exit 0 else \${*} @@ -1552,6 +1571,13 @@ AC_DEFUN(AC_BAKEFILE_CHECK_BASIC_STUFF, ;; esac AC_SUBST(INSTALL_DIR) + + LDFLAGS_GUI= + case ${host} in + *-*-cygwin* | *-*-mingw32* ) + LDFLAGS_GUI="-Wl,--subsystem,windows -mwindows" + esac + AC_SUBST(LDFLAGS_GUI) ])