summaryrefslogtreecommitdiffstats
path: root/build
diff options
context:
space:
mode:
authorPatrick McDermott <patrick.mcdermott@libiquity.com>2019-05-18 18:50:46 (EDT)
committer Patrick McDermott <patrick.mcdermott@libiquity.com>2019-05-18 18:50:46 (EDT)
commit04c176a7a0db49f1977d27a72f956440cbcefe44 (patch)
treecab42ba33651c59178b9e374101a578e1793a56f /build
parent44d204a405dd439a6d8e1ecc239faf8445dcbe55 (diff)
build: Set prefixes in target machine config header
Diffstat (limited to 'build')
-rwxr-xr-xbuild6
1 files changed, 6 insertions, 0 deletions
diff --git a/build b/build
index e8a282e..16d199c 100755
--- a/build
+++ b/build
@@ -113,6 +113,12 @@ build-gcc-config:
mv "$(tm)/$(tm_file)" "$(tm)/$(tm_file).orig"
sed "s|^\(#define $(tm_interp_macro)\) \".*\"$$|\1 \"$(elf_interp)\"|" \
"$(tm)/$(tm_file).orig" >"$(tm)/$(tm_file)"
+ printf '\n#undef %s\n#define %s "%s"\n' STANDARD_EXEC_PREFIX \
+ STANDARD_EXEC_PREFIX "$(exec_prefix)" >>"$(tm)/$(tm_file)"
+ printf '\n#undef %s\n#define %s "%s"\n' STANDARD_LIBEXEC_PREFIX \
+ STANDARD_LIBEXEC_PREFIX "$(startfile_prefix)" >>"$(tm)/$(tm_file)"
+ printf '#define %s ""\n' STANDARD_STARTFILE_PREFIX_1 \
+ STANDARD_STARTFILE_PREFIX_2 >>"$(tm)/$(tm_file)"
[ -e "$(tm)/$(tmake_file).orig" ] || \
mv "$(tm)/$(tmake_file)" "$(tm)/$(tmake_file).orig"
sed "$(tmake_script)" "$(tm)/$(tmake_file).orig" >"$(tm)/$(tmake_file)"