From: Stewart Brodie <sbrodie@espial.com>
To: <libffi-discuss@sourceware.org>
Subject: [PATCH] Add --disable-multi-os-directory configure option
Date: Thu, 20 Jun 2013 12:11:00 -0000 [thread overview]
Message-ID: <gemini.mooxux00epu2o0hb7.sbrodie@espial.com> (raw)
In-Reply-To: <gemini.mo8kb000r1iao05r2.sbrodie@espial.com>
Stewart Brodie <sbrodie@espial.com> wrote:
>
> I've been trying to compile libffi (latest cloned from git earlier today)
> but hitting a problem with overriding where the library is installed.
> [ patch in original e-mail ]
I have since discovered that my patch only works if you build out-of-tree.
autoconf has put something strange in the configure script to detect when
$top_srcdir == $top_builddir and write completely different stuff out to the
Makefile, which doesn't pass the required parameters to the recursive makes
that it runs, as far as I can tell.
So I just added a configuration option instead, which always works.
The --disable-multi-os-directory option stops the configure script
from asking gcc whether it should override the library installation
directory.
---
configure.ac | 16 +++++++++++-----
1 file changed, 11 insertions(+), 5 deletions(-)
diff --git a/configure.ac b/configure.ac
index 0dc0675..cc64876 100644
--- a/configure.ac
+++ b/configure.ac
@@ -535,6 +535,10 @@ AC_ARG_ENABLE(purify-safety,
AC_DEFINE(USING_PURIFY, 1, [Define this if you are using Purify and
want to suppress spurious messages.])
fi)
+AC_ARG_ENABLE(multi-os-directory,
+[ --disable-multi-os-directory
+ disable use of gcc --print-multi-os-directory to
change the library installation directory])
+
# These variables are only ever used when we cross-build to X86_WIN32.
# And we only support this with GCC, so...
if test "x$GCC" = "xyes"; then
@@ -546,11 +550,13 @@ if test "x$GCC" = "xyes"; then
toolexecdir='$(libdir)/gcc-lib/$(target_alias)'
toolexeclibdir='$(libdir)'
fi
- multi_os_directory=`$CC -print-multi-os-directory`
- case $multi_os_directory in
- .) ;; # Avoid trailing /.
- ../*) toolexeclibdir=$toolexeclibdir/$multi_os_directory ;;
- esac
+ if test x"$enable_multi_os_directory" != x"no"; then
+ multi_os_directory=`$CC -print-multi-os-directory`
+ case $multi_os_directory in
+ .) ;; # Avoid trailing /.
+ ../*) toolexeclibdir=$toolexeclibdir/$multi_os_directory ;;
+ esac
+ fi
AC_SUBST(toolexecdir)
else
toolexeclibdir='$(libdir)'
--
1.8.1.4
--
Stewart Brodie
Senior Software Engineer
Team Leader ANT Galio Browser
Espial UK
prev parent reply other threads:[~2013-06-20 12:11 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-06-11 15:57 [PATCH] Missing variable in AM_MAKEFLAGS Stewart Brodie
2013-06-20 12:11 ` Stewart Brodie [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=gemini.mooxux00epu2o0hb7.sbrodie@espial.com \
--to=sbrodie@espial.com \
--cc=libffi-discuss@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).