Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2023-10-15 12:29:13 +0300
committerMike Frysinger <vapier@gentoo.org>2023-11-28 20:50:44 +0300
commitdab15f6740ff73e8b17b7ddddcbb678895a916a2 (patch)
tree784f6fc0a1d953754f56dfcfa79d4e2aca5d9009 /newlib/configure
parent65831f88d6c4cd943969b5ee531bc6162c7b0f60 (diff)
newlib: filter out versions from newlib.h to simplify autoreconf
We've been manually editing newlib.hin after generating it with autoheader to drop the version defines that we keep in the separate _newlib_version.h header. This is confusing for people, and is an easy source of mistakes/errors. Since we're already running sed on newlib.h during configure to filter out defines we don't want to expose, add the version macros there too. This way we don't have to manually edit newlib.hin. This simplifies the autoreconf step in exchange for a slightly more complicated configure+sed step, but seems worth the trade-off.
Diffstat (limited to 'newlib/configure')
-rwxr-xr-xnewlib/configure2
1 files changed, 1 insertions, 1 deletions
diff --git a/newlib/configure b/newlib/configure
index 0585e0ee8..b21d9bf45 100755
--- a/newlib/configure
+++ b/newlib/configure
@@ -9269,7 +9269,7 @@ $as_echo "$as_me: executing $ac_file commands" >&6;}
case $ac_file$ac_mode in
- "newlib.h":H) sed -i.tmp -e '/^#define [^_]/d' -e '/^\/\* #undef [^_]/d' newlib.h && rm -f newlib.h.tmp ;;
+ "newlib.h":H) sed -i.tmp -E -e '/^#define [^_]/d' -e '/^\/\* #undef [^_]/d' -e '/_NEWLIB_VERSION|__NEWLIB_(MINOR|PATCHLEVEL)__|__NEWLIB__/d' newlib.h && rm -f newlib.h.tmp ;;
"default-1":C)
# Only add multilib support code if we just rebuilt the top-level
# Makefile.