This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
[patch] Cleanup: set LC_ALL=C before invoking sed on non-ASCII data
- From: Paul Pluzhnikov <ppluzhnikov at google dot com>
- To: libc-alpha at sourceware dot org
- Cc: ppluzhnikov at google dot com, ronis at google dot com
- Date: Fri, 08 Mar 2013 18:02:00 -0800
- Subject: [patch] Cleanup: set LC_ALL=C before invoking sed on non-ASCII data
Greetings,
On Ubuntu Precise, with LANG=en_US.UTF-8, this sed in posix/
sed -f PTESTS2C.sed < PTESTS > ptestcases.h
produces a "corrupt" file ptestcases.h file (line 233), causing subsequent
"make check" to fail.
Thanks,
--
2013-03-08 Paul Pluzhnikov <ppluzhnikov@google.com>
* posix/Makefile: Set LC_ALL=C before sed.
diff --git a/posix/Makefile b/posix/Makefile
index 658c47e..a728630 100644
--- a/posix/Makefile
+++ b/posix/Makefile
@@ -210,11 +210,11 @@ bug-glob1-ARGS = "$(objpfx)"
tst-execvp3-ARGS = --test-dir=$(objpfx)
testcases.h: TESTS TESTS2C.sed
- sed -f TESTS2C.sed < $< > $@T
+ LC_ALL=C sed -f TESTS2C.sed < $< > $@T
mv -f $@T $@
ptestcases.h: PTESTS PTESTS2C.sed
- sed -f PTESTS2C.sed < $< > $@T
+ LC_ALL=C sed -f PTESTS2C.sed < $< > $@T
mv -f $@T $@
# Run a test on the header files we use.