diff options
author | 2020-06-24 10:40:14 -0700 | |
---|---|---|
committer | 2020-06-24 21:46:24 +0100 | |
commit | 1b3cea081588bd5e3491b66f65035c5772733eff (patch) | |
tree | 408bb9b54ab5080b4596fa39ec591e328fee59ce | |
parent | README: add 'Releasing' section (diff) | |
download | gcc-config-1b3cea081588bd5e3491b66f65035c5772733eff.tar.gz gcc-config-1b3cea081588bd5e3491b66f65035c5772733eff.tar.bz2 gcc-config-1b3cea081588bd5e3491b66f65035c5772733eff.zip |
gcc-config: make USE_CC_WRAPPERS=yes to install cc/f77 links
Add USE_CC_WRAPPERS option to control installation of cc/f77 symlinks.
This will let packages other than GCC to install 'cc'.
Signed-off-by: Manoj Gupta <manojgupta@google.com>
Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
-rw-r--r-- | Makefile | 3 | ||||
-rwxr-xr-x | gcc-config | 9 |
2 files changed, 10 insertions, 2 deletions
@@ -5,6 +5,8 @@ # and keep only # ${CTARGET}-gcc USE_NATIVE_LINKS ?= yes +# Install cc/f77 symlinks to gcc/g77. +USE_CC_WRAPPERS ?= yes # Prepend toolchain prefix to 'gcc' in c89/c99 wrapeprs. # Should usually be '${CHOST}-'. @@ -41,6 +43,7 @@ clean: -e 's:@GENTOO_LIBDIR@:$(SUBLIBDIR):g' \ -e 's:@PV@:$(PV):g' \ -e 's:@USE_NATIVE_LINKS@:$(USE_NATIVE_LINKS):g' \ + -e 's:@USE_CC_WRAPPERS@:$(USE_CC_WRAPPERS):g' \ $< > $@ chmod a+rx $@ @@ -289,8 +289,10 @@ update_wrappers() { local all_wrappers=( ${new_wrappers[@]/#/${CTARGET}-} ) if ! is_cross_compiler ; then all_wrappers+=( "${new_wrappers[@]}" ) - # There are a few fun extra progs which we have to handle #412319 - all_wrappers+=( cc:gcc f77:g77 ) + if [[ ${USE_CC_WRAPPERS} == "yes" ]]; then + # There are a few fun extra progs which we have to handle #412319 + all_wrappers+=( cc:gcc f77:g77 ) + fi fi # Then install wrappers for anything new to this profile. @@ -995,6 +997,7 @@ CC_COMP= ENV_D="${EROOT}etc/env.d" GCC_ENV_D="${ENV_D}/gcc" USE_NATIVE_LINKS="@USE_NATIVE_LINKS@" +USE_CC_WRAPPERS="@USE_CC_WRAPPERS@" for x in "$@" ; do case "${x}" in @@ -1050,6 +1053,8 @@ for x in "$@" ; do ;; --enable-native-links) USE_NATIVE_LINKS="yes" ;; --disable-native-links) USE_NATIVE_LINKS="no" ;; + --enable-cc-wrappers) USE_CC_WRAPPERS="yes" ;; + --disable-cc-wrappers) USE_CC_WRAPPERS="no" ;; -*) die "Invalid switch! Run ${argv0} without parameters for help." ;; |