diff options
author | Mike Frysinger <vapier@gentoo.org> | 2012-06-09 23:47:32 -0400 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2012-06-09 23:47:32 -0400 |
commit | 1c8ed2a8669f4375f965c78ed37588b87cf534b1 (patch) | |
tree | b698f8b1f02c953b01db739e25d5431562b1e59c | |
parent | tests: verify removal of wrappers between diff configs (diff) | |
download | gcc-config-1c8ed2a8669f4375f965c78ed37588b87cf534b1.tar.gz gcc-config-1c8ed2a8669f4375f965c78ed37588b87cf534b1.tar.bz2 gcc-config-1c8ed2a8669f4375f965c78ed37588b87cf534b1.zip |
wrapper: remove ROOT from env when looking up bin path
When falling back to running gcc-config to find out the path to the
real binary, make sure to clear out $ROOT. Otherwise gcc-config will
try to look in $ROOT for its config files when really we're trying to
execute programs in /.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
-rw-r--r-- | wrapper.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -213,7 +213,7 @@ static void find_wrapper_target(struct wrapper_data *data) /* Only our wrapper is in PATH, so get the CC path using * gcc-config and execute the real binary in there ... */ - FILE *inpipe = popen(GCC_CONFIG " --get-bin-path", "r"); + FILE *inpipe = popen("ROOT= " GCC_CONFIG " --get-bin-path", "r"); if (inpipe == NULL) wrapper_errp("could not open pipe"); |