When making the text file tips-of-the-day, GnuCash expects 'gcc -E' to
preserve at least one of the whitespace lines between entries. However, this
relies on behavior of 'gcc -E' that isn't actually part of the spec, and is
a historical accident. And it changed in gcc-4.7, such that all the
whitespace is removed.

Work around this by explicitly adding a newline in the sed expression.

Bill
diff -up gnucash-2.4.10/doc/Makefile.am.foo gnucash-2.4.10/doc/Makefile.am
--- gnucash-2.4.10/doc/Makefile.am.foo  2012-06-21 15:49:01.849038350 -0400
+++ gnucash-2.4.10/doc/Makefile.am      2012-06-21 15:49:08.285038512 -0400
@@ -52,7 +52,7 @@ gnucash.1: gnucash.1.in Makefile
 tip_of_the_day.list: tip_of_the_day.list.in Makefile
        ${CC} -E -P -x c -D'N_(x)=x' -o $@.tmp $<
        cat -s $@.tmp | ${SED} -e 's/^ *"//' \
-                              -e 's/" *$$//' \
+                              -e 's/" *$$/\n/' \
                               -e 's/"* *[|] */|/' \
                            -e 
's:@-GNUCASH_LATEST_STABLE_SERIES-@:${GNUCASH_LATEST_STABLE_SERIES}:g' > $@
        rm -f $@.tmp
diff -up gnucash-2.4.10/doc/Makefile.in.foo gnucash-2.4.10/doc/Makefile.in
--- gnucash-2.4.10/doc/Makefile.in.foo  2012-06-21 14:50:58.000000000 -0400
+++ gnucash-2.4.10/doc/Makefile.in      2012-06-21 15:28:54.743004680 -0400
@@ -882,7 +882,7 @@ gnucash.1: gnucash.1.in Makefile
 tip_of_the_day.list: tip_of_the_day.list.in Makefile
        ${CC} -E -P -x c -D'N_(x)=x' -o $@.tmp $<
        cat -s $@.tmp | ${SED} -e 's/^ *"//' \
-                              -e 's/" *$$//' \
+                              -e 's/" *$$/\n/' \
                               -e 's/"* *[|] */|/' \
                            -e 
's:@-GNUCASH_LATEST_STABLE_SERIES-@:${GNUCASH_LATEST_STABLE_SERIES}:g' > $@
        rm -f $@.tmp
_______________________________________________
gnucash-devel mailing list
gnucash-devel@gnucash.org
https://lists.gnucash.org/mailman/listinfo/gnucash-devel

Reply via email to