diff options
author | Maciej W. Rozycki <macro@wdc.com> | 2020-01-24 11:24:25 +0000 |
---|---|---|
committer | Maciej W. Rozycki <macro@wdc.com> | 2020-01-24 11:24:25 +0000 |
commit | e8e66971cdc6d1390d47a227899e2e340ff44d66 (patch) | |
tree | 553c62c0b065ea104cf6378f46a4ef31b2d5f84d /libgcc | |
parent | e3fe0070c189e214d51cfc314591b6ffa526fb2f (diff) | |
download | gcc-e8e66971cdc6d1390d47a227899e2e340ff44d66.zip gcc-e8e66971cdc6d1390d47a227899e2e340ff44d66.tar.gz gcc-e8e66971cdc6d1390d47a227899e2e340ff44d66.tar.bz2 |
Add `--with-toolexeclibdir=' configuration option
Provide means, in the form of a `--with-toolexeclibdir=' configuration
option, to override the default installation directory for target
libraries, otherwise known as $toolexeclibdir. This is so that it is
possible to get newly-built libraries, particularly the shared ones,
installed in a common place, so that they can be readily used by the
target system as their host libraries, possibly over NFS, without a need
to manually copy them over from the currently hardcoded location they
would otherwise be installed in.
In the presence of the `--enable-version-specific-runtime-libs' option
and for configurations building native GCC the option is ignored.
config/
* toolexeclibdir.m4: New file.
gcc/
* doc/install.texi (Cross-Compiler-Specific Options): Document
`--with-toolexeclibdir' option.
libada/
* Makefile.in (configure_deps): Add `toolexeclibdir.m4'.
* configure.ac: Handle `--with-toolexeclibdir='.
* configure: Regenerate.
libatomic/
* configure.ac: Handle `--with-toolexeclibdir='.
* Makefile.in: Regenerate.
* aclocal.m4: Regenerate.
* configure: Regenerate.
* testsuite/Makefile.in: Regenerate.
libffi/
* configure.ac: Handle `--with-toolexeclibdir='.
* Makefile.in: Regenerate.
* aclocal.m4: Regenerate.
* configure: Regenerate.
* include/Makefile.in: Regenerate.
* man/Makefile.in: Regenerate.
* testsuite/Makefile.in: Regenerate.
libgcc/
* Makefile.in (configure_deps): Add `toolexeclibdir.m4'.
* configure.ac: Handle `--with-toolexeclibdir='.
* configure: Regenerate.
libgfortran/
* configure.ac: Handle `--with-toolexeclibdir='.
* Makefile.in: Regenerate.
* aclocal.m4: Regenerate.
* configure: Regenerate.
libgomp/
* configure.ac: Handle `--with-toolexeclibdir='.
* Makefile.in: Regenerate.
* aclocal.m4: Regenerate.
* configure: Regenerate.
* testsuite/Makefile.in: Regenerate.
libhsail-rt/
* configure.ac: Handle `--with-toolexeclibdir='.
* Makefile.in: Regenerate.
* aclocal.m4: Regenerate.
* configure: Regenerate.
libitm/
* configure.ac: Handle `--with-toolexeclibdir='.
* Makefile.in: Regenerate.
* aclocal.m4: Regenerate.
* configure: Regenerate.
* testsuite/Makefile.in: Regenerate.
libobjc/
* Makefile.in (aclocal_deps): Add `toolexeclibdir.m4'.
* aclocal.m4: Include `toolexeclibdir.m4'.
* configure.ac: Handle `--with-toolexeclibdir='.
* configure: Regenerate.
liboffloadmic/
* plugin/configure.ac: Handle `--with-toolexeclibdir='.
* plugin/Makefile.in: Regenerate.
* plugin/aclocal.m4: Regenerate.
* plugin/configure: Regenerate.
* configure.ac: Handle `--with-toolexeclibdir='.
* Makefile.in: Regenerate.
* aclocal.m4: Regenerate.
* configure: Regenerate.
libphobos/
* m4/druntime.m4: Handle `--with-toolexeclibdir='.
* m4/Makefile.in: Regenerate.
* libdruntime/Makefile.in: Regenerate.
* src/Makefile.in: Regenerate.
* testsuite/Makefile.in: Regenerate.
* Makefile.in: Regenerate.
* aclocal.m4: Regenerate.
* configure: Regenerate.
libquadmath/
* configure.ac: Handle `--with-toolexeclibdir='.
* Makefile.in: Regenerate.
* aclocal.m4: Regenerate.
* configure: Regenerate.
libsanitizer/
* configure.ac: Handle `--with-toolexeclibdir='.
* Makefile.in: Regenerate.
* aclocal.m4: Regenerate.
* configure: Regenerate.
* asan/Makefile.in: Regenerate.
* interception/Makefile.in: Regenerate.
* libbacktrace/Makefile.in: Regenerate.
* lsan/Makefile.in: Regenerate.
* sanitizer_common/Makefile.in: Regenerate.
* tsan/Makefile.in: Regenerate.
* ubsan/Makefile.in: Regenerate.
libssp/
* configure.ac: Handle `--with-toolexeclibdir='.
* Makefile.in: Regenerate.
* aclocal.m4: Regenerate.
* configure: Regenerate.
libstdc++-v3/
* acinclude.m4: Handle `--with-toolexeclibdir='.
* Makefile.in: Regenerate.
* aclocal.m4: Regenerate.
* configure: Regenerate.
* doc/Makefile.in: Regenerate.
* include/Makefile.in: Regenerate.
* libsupc++/Makefile.in: Regenerate.
* po/Makefile.in: Regenerate.
* python/Makefile.in: Regenerate.
* src/Makefile.in: Regenerate.
* src/c++11/Makefile.in: Regenerate.
* src/c++17/Makefile.in: Regenerate.
* src/c++98/Makefile.in: Regenerate.
* src/filesystem/Makefile.in: Regenerate.
* testsuite/Makefile.in: Regenerate.
libvtv/
* configure.ac: Handle `--with-toolexeclibdir='.
* Makefile.in: Regenerate.
* aclocal.m4: Regenerate.
* configure: Regenerate.
* testsuite/Makefile.in: Regenerate.
zlib/
* configure.ac: Handle `--with-toolexeclibdir='.
* Makefile.in: Regenerate.
* aclocal.m4: Regenerate.
* configure: Regenerate.
Diffstat (limited to 'libgcc')
-rw-r--r-- | libgcc/ChangeLog | 6 | ||||
-rw-r--r-- | libgcc/Makefile.in | 1 | ||||
-rwxr-xr-x | libgcc/configure | 38 | ||||
-rw-r--r-- | libgcc/configure.ac | 25 |
4 files changed, 64 insertions, 6 deletions
diff --git a/libgcc/ChangeLog b/libgcc/ChangeLog index bea77b2..0920265 100644 --- a/libgcc/ChangeLog +++ b/libgcc/ChangeLog @@ -1,3 +1,9 @@ +2020-01-24 Maciej W. Rozycki <macro@wdc.com> + + * Makefile.in (configure_deps): Add `toolexeclibdir.m4'. + * configure.ac: Handle `--with-toolexeclibdir='. + * configure: Regenerate. + 2020-01-23 Dragan Mladjenovic <dmladjenovic@wavecomp.com> * config/mips/gnustack.h: Check for TARGET_LIBC_GNUSTACK also. diff --git a/libgcc/Makefile.in b/libgcc/Makefile.in index 43bad01..851e765 100644 --- a/libgcc/Makefile.in +++ b/libgcc/Makefile.in @@ -165,6 +165,7 @@ AUTOCONF = autoconf configure_deps = \ $(srcdir)/../config/enable.m4 \ $(srcdir)/../config/tls.m4 \ + $(srcdir)/../config/toolexeclibdir.m4 \ $(srcdir)/../config/acx.m4 \ $(srcdir)/../config/no-executables.m4 \ $(srcdir)/../config/lib-ld.m4 \ diff --git a/libgcc/configure b/libgcc/configure index 97cbad3..ab8d471 100755 --- a/libgcc/configure +++ b/libgcc/configure @@ -705,6 +705,7 @@ enable_gcov enable_vtable_verify with_aix_soname enable_version_specific_runtime_libs +with_toolexeclibdir with_slibdir enable_maintainer_mode with_build_libsubdir @@ -1369,6 +1370,9 @@ Optional Packages: --with-aix-soname=aix|svr4|both shared library versioning (aka "SONAME") variant to provide on AIX + --with-toolexeclibdir=DIR + install libraries built with a cross compiler within + DIR --with-slibdir=DIR shared libraries in DIR LIBDIR --with-build-libsubdir=DIR Directory where to find libraries for build system --with-system-libunwind use installed libunwind @@ -2464,6 +2468,22 @@ fi $as_echo "$version_specific_libs" >&6; } +# Check whether --with-toolexeclibdir was given. +if test "${with_toolexeclibdir+set}" = set; then : + withval=$with_toolexeclibdir; case ${with_toolexeclibdir} in + /) + ;; + */) + with_toolexeclibdir=`echo $with_toolexeclibdir | sed 's,/$,,'` + ;; +esac +else + with_toolexeclibdir=no +fi + + + + # Check whether --with-slibdir was given. if test "${with_slibdir+set}" = set; then : withval=$with_slibdir; slibdir="$with_slibdir" @@ -2471,7 +2491,14 @@ else if test "${version_specific_libs}" = yes; then slibdir='$(libsubdir)' elif test -n "$with_cross_host" && test x"$with_cross_host" != x"no"; then - slibdir='$(exec_prefix)/$(host_noncanonical)/lib' + case ${with_toolexeclibdir} in + no) + slibdir='$(exec_prefix)/$(host_noncanonical)/lib' + ;; + *) + slibdir=${with_toolexeclibdir} + ;; + esac else slibdir='$(libdir)' fi @@ -2701,7 +2728,14 @@ case ${version_specific_libs} in test x"$with_cross_host" != x"no"; then # Install a library built with a cross compiler in tooldir, not libdir. toolexecdir='$(exec_prefix)/$(target_noncanonical)' - toolexeclibdir='$(toolexecdir)/lib' + case ${with_toolexeclibdir} in + no) + toolexeclibdir='$(toolexecdir)/lib' + ;; + *) + toolexeclibdir=${with_toolexeclibdir} + ;; + esac else toolexecdir='$(libdir)/gcc-lib/$(target_noncanonical)' toolexeclibdir='$(libdir)' diff --git a/libgcc/configure.ac b/libgcc/configure.ac index 2d22f05..85979da9 100644 --- a/libgcc/configure.ac +++ b/libgcc/configure.ac @@ -2,6 +2,7 @@ dnl Process this file with autoconf to produce a configure script. sinclude(../config/enable.m4) sinclude(../config/tls.m4) +sinclude(../config/toolexeclibdir.m4) sinclude(../config/acx.m4) sinclude(../config/no-executables.m4) sinclude(../config/lib-ld.m4) @@ -113,16 +114,25 @@ AC_ARG_ENABLE(version-specific-runtime-libs, [version_specific_libs=no]) AC_MSG_RESULT($version_specific_libs) +GCC_WITH_TOOLEXECLIBDIR + AC_ARG_WITH(slibdir, [ --with-slibdir=DIR shared libraries in DIR [LIBDIR]], slibdir="$with_slibdir", -if test "${version_specific_libs}" = yes; then +[if test "${version_specific_libs}" = yes; then slibdir='$(libsubdir)' elif test -n "$with_cross_host" && test x"$with_cross_host" != x"no"; then - slibdir='$(exec_prefix)/$(host_noncanonical)/lib' + case ${with_toolexeclibdir} in + no) + slibdir='$(exec_prefix)/$(host_noncanonical)/lib' + ;; + *) + slibdir=${with_toolexeclibdir} + ;; + esac else slibdir='$(libdir)' -fi) +fi]) AC_SUBST(slibdir) # Command-line options. @@ -168,7 +178,14 @@ case ${version_specific_libs} in test x"$with_cross_host" != x"no"; then # Install a library built with a cross compiler in tooldir, not libdir. toolexecdir='$(exec_prefix)/$(target_noncanonical)' - toolexeclibdir='$(toolexecdir)/lib' + case ${with_toolexeclibdir} in + no) + toolexeclibdir='$(toolexecdir)/lib' + ;; + *) + toolexeclibdir=${with_toolexeclibdir} + ;; + esac else toolexecdir='$(libdir)/gcc-lib/$(target_noncanonical)' toolexeclibdir='$(libdir)' |