bin/lto-dump which may be helpful if you employ link-time optimization (LTO). Forward port r499061 | gerald | 2019-04-15 from lang/gcc8 and gcc8-devel [1]: GCC has two runtime libraries: The static library libgcc.a (-lgcc) and the shared library libgcc_s.so (-lgcc_s). Both implement many of the same functions but they also each have their unique functions. When GCC links programs and libraries there are three possibilities: 1. gcc -static-libgcc or gcc -static: -lgcc => Just use libgcc.a. 2. gcc -shared-libgcc: -lgcc_s -lgcc => Link with libgcc_s first, so libgcc.a is only used for its unique functions. 3. gcc: -lgcc -Wl,--as-needed -lgcc_s -Wl,--no-as-needed => Link with libgcc.a first so libgcc_s is only used for its unique functions (_Unwind_* functions). Approach 3 is the default for gcc and it's also what clang and clang++ use; approach 2 is the default for gfortran, g++ and probably other front ends. This patch makes 3 the default for gfortran. It significantly reduces the use of libgcc_s. The _Unwind_* functions are also available in the old base system libgcc_s which means this reduces the need for -rpath /usr/local/lib/gccN in ports that depend on libraries built with gfortran. Consider a dependency tree like this: prog -> libA -> libgcc_s (old base system libgcc_s is fine) -> libB -> libgcc_s (libB built with gfortran, needs new libgcc_s) Here prog needs to be linked with -rpath /usr/local/lib/gccN even if it's a normal C program compiled with clang. Without -rpath it will fail to start because it loads old libgcc_s first as a dependency of libA and then it fails to load libB. With this patch libB works with old base system libgcc_s or may not need libgcc_s at all, so prog does not need to be linked with -rpath. PR: 208120 [1] Submitted by: tijl [1]
34 lines
1.1 KiB
Text
34 lines
1.1 KiB
Text
bin/%%GNU_HOST%%-c++%%SUFFIX%%
|
|
bin/%%GNU_HOST%%-g++%%SUFFIX%%
|
|
bin/%%GNU_HOST%%-gcc%%SUFFIX%%
|
|
bin/%%GNU_HOST%%-gcc-%%GCC_VERSION%%
|
|
bin/%%GNU_HOST%%-gcc-ar%%SUFFIX%%
|
|
bin/%%GNU_HOST%%-gcc-nm%%SUFFIX%%
|
|
bin/%%GNU_HOST%%-gcc-ranlib%%SUFFIX%%
|
|
bin/%%GNU_HOST%%-gfortran%%SUFFIX%%
|
|
bin/c++%%SUFFIX%%
|
|
bin/cpp%%SUFFIX%%
|
|
bin/g++%%SUFFIX%%
|
|
bin/gcc%%SUFFIX%%
|
|
bin/gcc-ar%%SUFFIX%%
|
|
bin/gcc-nm%%SUFFIX%%
|
|
bin/gcc-ranlib%%SUFFIX%%
|
|
bin/gcov%%SUFFIX%%
|
|
bin/gcov-dump%%SUFFIX%%
|
|
bin/gcov-tool%%SUFFIX%%
|
|
bin/gfortran%%SUFFIX%%
|
|
bin/lto-dump%%SUFFIX%%
|
|
man/man1/cpp%%SUFFIX%%.1.gz
|
|
man/man1/g++%%SUFFIX%%.1.gz
|
|
man/man1/gcc%%SUFFIX%%.1.gz
|
|
man/man1/gcov%%SUFFIX%%.1.gz
|
|
man/man1/gcov-dump%%SUFFIX%%.1.gz
|
|
man/man1/gcov-tool%%SUFFIX%%.1.gz
|
|
man/man1/gfortran%%SUFFIX%%.1.gz
|
|
share/gcc-%%GCC_VERSION%%/python/libstdcxx/__init__.py
|
|
share/gcc-%%GCC_VERSION%%/python/libstdcxx/v6/__init__.py
|
|
share/gcc-%%GCC_VERSION%%/python/libstdcxx/v6/printers.py
|
|
share/gcc-%%GCC_VERSION%%/python/libstdcxx/v6/xmethods.py
|
|
@postexec if type ccache-update-links >/dev/null 2>&1; then ccache-update-links -v; fi
|
|
@postunexec if type ccache-update-links >/dev/null 2>&1; then ccache-update-links -v; fi
|
|
@comment Insert PLIST.lib here
|