libtool-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Unify line endings in localization test


From: Peter Rosin
Subject: Re: Unify line endings in localization test
Date: Mon, 19 Jan 2009 21:52:50 +0100
User-agent: Thunderbird 2.0.0.19 (Windows/20081209)

Hi Ralf,

Den 2009-01-19 21:35 skrev Ralf Wildenhues:
Ok to push? Or should I just push it to the pr-msvc-support branch
for now?

I think we shouldn't be constantly rebasing pr-msvc-support.  I think
instead when we can't decide soonish whether to merge it into master or
to redo it (because it would need largish redoing), then you should just
merge from master into the branch in order to keep it up to date.

I had no plan to rebase anything, what I was suggesting was to maybe
push it to the branch now (if it wasn't clear that it was safe for
master), then when someone said "ok", I could cherry-pick it into
master.

(But the last four patches on the branch are not very pretty, dates
are all messed up, no Changelog entries, crappy commit msgs etc etc.
Those should be merged with care.)

2009-01-17  Peter Rosin  <address@hidden>

        Unify line endings in localization test.
        * tests/localization.at: Process both the expected output and
        the libtool output in the same manner in order to eliminate
        line ending differences. Fixes the test on MSYS/MSVC.

This looks a bit hackish.  We already have a handful of places which we
fixed up in order to avoid line ending issues.  This one looks hackish
enough to deserve being wrapped in a macro (in testsuite.at, below
LT_AT_HOST_DATA?), so that future instances of this issue can easily be
handled likewise.

Ok, I'll have a look writing some output unification macro.

--- a/tests/localization.at
+++ b/tests/localization.at
@@ -43,7 +43,7 @@ AT_CHECK([$CC $CPPFLAGS $CFLAGS -c b.c || exit 77], [], 
[stdout], [stderr])
# Find out about expected output.
 AT_CHECK([$CC $CPPFLAGS $CFLAGS -c a.c || exit 1], [1], [stdout], [stderr])
-mv -f stdout expected-stdout
+grep -v thisisprobablynotmatching stdout > expected-stdout
 mv -f stderr expected-stderr

Why only stdout and not stderr?

Because it's the grep that warps stdout of the libtool run. By also
running grep on the expected output the two files get the exact same
treatment. But since stderr isn't piped through grep, they compare
ok w/o unifying.

 AT_CHECK([$LIBTOOL --mode=compile --tag=CC $CC $CPPFLAGS $CFLAGS -c a.c || 
exit 1],
         [1], [stdout], [stderr])





reply via email to

[Prev in Thread] Current Thread [Next in Thread]