diff options
author | Mark Mitchell <mark@codesourcery.com> | 2005-04-27 20:35:54 +0000 |
---|---|---|
committer | Mark Mitchell <mmitchel@gcc.gnu.org> | 2005-04-27 20:35:54 +0000 |
commit | 380e5ca402e4dc6441a903de5ff88593f92f71d7 (patch) | |
tree | e35f58f5c5ef495d2de849689e0398b292c98c9c /gcc/configure | |
parent | c7a5c6238107a92afe645481a7ad770289b274ca (diff) | |
download | gcc-380e5ca402e4dc6441a903de5ff88593f92f71d7.zip gcc-380e5ca402e4dc6441a903de5ff88593f92f71d7.tar.gz gcc-380e5ca402e4dc6441a903de5ff88593f92f71d7.tar.bz2 |
configure.ac: Check for ld --sysroot support.
* configure.ac: Check for ld --sysroot support.
* gcc.c: Document %R specifier for specs.
(SYSROOT_SPEC): New macro.
(sysroot_spec): New variable.
(static_specs): Add sysroot_spec.
(main): Pass the sysroot spec to the linker if appropriate.
* configure: Regenerated.
* config.in: Likewise.
From-SVN: r98880
Diffstat (limited to 'gcc/configure')
-rwxr-xr-x | gcc/configure | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/gcc/configure b/gcc/configure index 98639db..bf9966f 100755 --- a/gcc/configure +++ b/gcc/configure @@ -15050,6 +15050,32 @@ _ACEOF ;; esac +echo "$as_me:$LINENO: checking linker --sysroot support" >&5 +echo $ECHO_N "checking linker --sysroot support... $ECHO_C" >&6 +if test "${gcc_cv_ld_sysroot+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + gcc_cv_ld_sysroot=no + if test $in_tree_ld = yes ; then + if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 16 -o "$gcc_cv_gld_major_version" -gt 2 ; then + gcc_cv_ld_sysroot = yes + fi + elif test x$gcc_cv_ld != x; then + if $gcc_cv_ld --help 2>/dev/null | grep sysroot > /dev/null; then + gcc_cv_ld_sysroot=yes + fi + fi +fi +echo "$as_me:$LINENO: result: $gcc_cv_ld_sysroot" >&5 +echo "${ECHO_T}$gcc_cv_ld_sysroot" >&6 +if test x"$gcc_cv_ld_sysroot" = xyes; then + +cat >>confdefs.h <<\_ACEOF +#define HAVE_LD_SYSROOT 1 +_ACEOF + +fi + if test x$with_sysroot = x && test x$host = x$target \ && test "$prefix" != "/usr" && test "x$prefix" != "x$local_prefix" ; then |