This is the mail archive of the
newlib@sourceware.org
mailing list for the newlib project.
[PATCH][libgloss] Use POSIX regex character classes instead of perl regex classes
- From: Tamar Christina <Tamar dot Christina at arm dot com>
- To: "newlib at sourceware dot org" <newlib at sourceware dot org>
- Cc: nd <nd at arm dot com>
- Date: Thu, 6 Jul 2017 12:21:56 +0000
- Subject: [PATCH][libgloss] Use POSIX regex character classes instead of perl regex classes
- Authentication-results: sourceware.org; auth=none
- Authentication-results: arm.com; dkim=none (message not signed) header.d=none;arm.com; dmarc=none action=none header.from=arm.com;
- Nodisclaimer: True
- Spamdiagnosticmetadata: NSPM
- Spamdiagnosticoutput: 1:99
Hi All,
This fixed the build on systems using BSD sed instead of GNU sed where the semihosting
build would fall over because the sed expression wouldn't match.
The previous patch used perl style character classes for space \s while the new one
uses the POSIX style [:space:] instead.
OK for master?
PS. I don't have commit rights so if OK can someone commit for me?
Thanks,
Tamar
From 20e021656e96e28c9bdd81b7dac423961f340c75 Mon Sep 17 00:00:00 2001
From: Tamar Christina <tamar.christina@arm.com>
Date: Thu, 6 Jul 2017 10:33:31 +0100
Subject: [PATCH] Replace the perl character classes with POSIX ones to fix the
build when sed is a BSD sed instead of GNU.
Signed-off-by: Tamar Christina <tamar.christina@arm.com>
---
libgloss/multi-build.in | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/libgloss/multi-build.in b/libgloss/multi-build.in
index 0bd12cfd9..e2fd0807a 100644
--- a/libgloss/multi-build.in
+++ b/libgloss/multi-build.in
@@ -20,10 +20,10 @@ multi-do:
cp config.status $${destpre}; \
cd $${destpre}; \
$(SHELL) config.status; \
- sed -e "s:^MULTIDIRS\s*+=.*$$:MULTIDIRS = :" \
- -e "s:^MULTILIBNAME\s*=.*$$:MULTILIBNAME = MULTIDIR_$${dir}_NAME:" \
- -e "s:^MULTI_FLAGS_FOR_TARGET\s*=.*$$:MULTI_FLAGS_FOR_TARGET = MULTIDIR_$${dir}_FLAGS:" \
- -e "s:^objdir\s*=.*$$:objdir = ..:" \
+ sed -e "s:^MULTIDIRS[[:space:]]*+=.*$$:MULTIDIRS = :" \
+ -e "s:^MULTILIBNAME[[:space:]]*=.*$$:MULTILIBNAME = MULTIDIR_$${dir}_NAME:" \
+ -e "s:^MULTI_FLAGS_FOR_TARGET[[:space:]]*=.*$$:MULTI_FLAGS_FOR_TARGET = MULTIDIR_$${dir}_FLAGS:" \
+ -e "s:^objdir[[:space:]]*=.*$$:objdir = ..:" \
Makefile > Makefile.tem; \
rm -f Makefile; \
mv Makefile.tem Makefile; \
--
2.13.0