diff mbox

[gccgo] Force "C" locale in gotest

Message ID mcrd3uifilg.fsf@google.com
State New
Headers show

Commit Message

Ian Lance Taylor July 20, 2010, 12:22 p.m. UTC
This patch forces the use of the "C" locale in gotest, so that egrep
does the right thing.  Committed to gccgo branch.

Ian

Comments

Andreas Schwab July 20, 2010, 12:28 p.m. UTC | #1
Ian Lance Taylor <iant@google.com> writes:

> +# Makes egrep,grep work better in general if we put them
> +# in ordinary C mode instead of what the current language is.
> +unset LANG
> +export LC_ALL=C
> +export LC_CTYPE=C

If you already set LC_ALL there is no need to set any other LC_*, since
LC_ALL overrides them all.

Andreas.
Ian Lance Taylor July 20, 2010, 1:11 p.m. UTC | #2
Andreas Schwab <schwab@redhat.com> writes:

> Ian Lance Taylor <iant@google.com> writes:
>
>> +# Makes egrep,grep work better in general if we put them
>> +# in ordinary C mode instead of what the current language is.
>> +unset LANG
>> +export LC_ALL=C
>> +export LC_CTYPE=C
>
> If you already set LC_ALL there is no need to set any other LC_*, since
> LC_ALL overrides them all.

Yeah.  I was just copying code from another version of gotest.  I should
have mentioned that.

Ian
diff mbox

Patch

diff -r 8f87e072151f libgo/testsuite/gotest
--- a/libgo/testsuite/gotest	Mon Jul 19 01:42:34 2010 -0700
+++ b/libgo/testsuite/gotest	Tue Jul 20 05:21:29 2010 -0700
@@ -8,6 +8,12 @@ 
 # tests.
 # If files are named on the command line, use them instead of test*.go.
 
+# Makes egrep,grep work better in general if we put them
+# in ordinary C mode instead of what the current language is.
+unset LANG
+export LC_ALL=C
+export LC_CTYPE=C
+
 GC=${GC:-gccgo}
 GL=${GL:-${GC-gccgo}}
 GOLIBS=${GOLIBS:=-lgotesting}