From c6ee421c7854a2a95661175ba19381a4a073822d Mon Sep 17 00:00:00 2001 From: Brian Barrett Date: Mon, 22 Jan 2007 20:31:04 +0000 Subject: [PATCH] Work around a bug involving dependent libraries when building 64 bit on Mac OS X This commit was SVN r13246. --- autogen.sh | 7 +++++++ config/ltmain_otool.diff | 13 +++++++++++++ 2 files changed, 20 insertions(+) create mode 100644 config/ltmain_otool.diff diff --git a/autogen.sh b/autogen.sh index 3588a88904..bab0cc7eb5 100755 --- a/autogen.sh +++ b/autogen.sh @@ -433,6 +433,13 @@ EOF echo " ==> your libtool doesn't need this! yay!" fi cd ../.. + echo " -- patching 64-bit OS X bug in ltmain.sh" + if test ! -z "`grep otool config/ltmain.sh`" -a \ + -z "`grep otool64 config/ltmain.sh`"; then + patch -N -p0 < config/ltmain_otool.diff + else + echo " ==> your libtool doesn't need this! yay!" + fi echo " -- patching configure for broken -c/-o compiler test" sed -e 's/chmod -w \./#OMPI\/MPI FIX: chmod -w ./' \ configure > configure.new diff --git a/config/ltmain_otool.diff b/config/ltmain_otool.diff new file mode 100644 index 0000000000..8ab8a4193e --- /dev/null +++ b/config/ltmain_otool.diff @@ -0,0 +1,13 @@ +--- config/ltmain.sh.old 2007-01-22 11:34:19.000000000 -0500 ++++ config/ltmain.sh 2007-01-22 11:34:43.000000000 -0500 +@@ -4428,6 +4428,10 @@ + depdepl="$absdir/$objdir/$depdepl" + darwin_install_name=`otool -L $depdepl | $SED -n -e '3q;2,2p' | $SED -e 's/(.*//'` + darwin_install_name=`$ECHO $darwin_install_name` ++ if test -z "$darwin_install_name"; then ++ darwin_install_name=`otool64 -L $depdepl | $SED -n -e '3q;2,2p' | $SED -e 's/(.*//'` ++ darwin_install_name=`$ECHO $darwin_install_name` ++ fi + compiler_flags="$compiler_flags ${wl}-dylib_file ${wl}${darwin_install_name}:${depdepl}" + linker_flags="$linker_flags -dylib_file ${darwin_install_name}:${depdepl}" + path=