On Thu, Feb 27, 2020 at 11:22 AM Manoj Gupta <[email protected]> wrote:
> gcc-config installs cc/f77 by default. This may be undesired on > systems that want to set their own versions of cc/f77. > > Add option "-n"/"--no-default-vars" to not install the cc/f77 > wrappers. > > Signed-off-by: Manoj Gupta <[email protected]> > --- > gcc-config | 6 +++++- > 1 file changed, 5 insertions(+), 1 deletion(-) > > diff --git a/gcc-config b/gcc-config > index f03a46a..6f306db 100755 > --- a/gcc-config > +++ b/gcc-config > @@ -262,7 +262,7 @@ update_wrappers() { > # For all toolchains, we want to create the fully qualified > # `tuple-foo`. Only native ones do we want the simple `foo`. > local all_wrappers=( ${new_wrappers[@]/#/${CTARGET}-} ) > - if ! is_cross_compiler ; then > + if ! is_cross_compiler && [[ "${DEFAULT_PROGS}" == "yes" ]]; then > all_wrappers+=( "${new_wrappers[@]}" ) > # There are a few fun extra progs which we have to handle > #412319 > all_wrappers+=( cc:gcc f77:g77 ) > @@ -951,6 +951,7 @@ FORCE="no" > CC_COMP= > ENV_D="${EROOT}etc/env.d" > GCC_ENV_D="${ENV_D}/gcc" > +DEFAULT_PROGS="yes" > > for x in "$@" ; do > case "${x}" in > @@ -972,6 +973,9 @@ for x in "$@" ; do > -l|--list-profiles) > set_doit list_profiles > ;; > + -n|--no-default-vars) > + DEFAULT_PROGS="no" > + ;; > -S|--split-profile) > if [[ ( $1 != "-S" && $1 != "--split-profile" ) || > $# -eq 1 ]] ; then > usage 1 > -- > > Not sure of the correct mailing list for patches to gcc-config so also adding toolchain@gentoo .
