aboutsummaryrefslogtreecommitdiffstats
path: root/main/gcc/gcc-spec-env.patch
diff options
context:
space:
mode:
Diffstat (limited to 'main/gcc/gcc-spec-env.patch')
-rw-r--r--main/gcc/gcc-spec-env.patch7
1 files changed, 4 insertions, 3 deletions
diff --git a/main/gcc/gcc-spec-env.patch b/main/gcc/gcc-spec-env.patch
index 9d5e666a54..57e7567e54 100644
--- a/main/gcc/gcc-spec-env.patch
+++ b/main/gcc/gcc-spec-env.patch
@@ -1,8 +1,9 @@
Add support for external spec file via the GCC_SPECS env var. This
allows us to easily control pie/ssp defaults with gcc-config profiles.
- Original patch by Rob Holland. Extended to support multiple
- entries separated by ':' by Kevin F. Quinn
+ Original patch by Rob Holland
+ Extended to support multiple entries separated by ':' by Kevin F. Quinn
+ Modified to use getenv instead of poisoned GET_ENVIRONMENT by Ryan Hill
--- gcc-4/gcc/gcc.c
+++ gcc-4/gcc/gcc.c
@@ -15,7 +16,7 @@
+ * each spec listed, the string is overwritten at token boundaries
+ * (':') with '\0', an effect of strtok_r().
+ */
-+ GET_ENVIRONMENT (specs_file, "GCC_SPECS");
++ specs_file = getenv ("GCC_SPECS");
+ if (specs_file && (strlen(specs_file) > 0))
+ {
+ char *spec, *saveptr;