diff --git a/gnucash-tip-of-the-day.patch b/gnucash-tip-of-the-day.patch new file mode 100644 index 0000000..5525050 --- /dev/null +++ b/gnucash-tip-of-the-day.patch @@ -0,0 +1,14 @@ +Index: doc/Makefile.am +=================================================================== +--- doc/Makefile.am (revision 22245) ++++ doc/Makefile.am (revision 22246) +@@ -49,7 +49,7 @@ + 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 --git a/gnucash.changes b/gnucash.changes index da9f708..475fd9d 100644 --- a/gnucash.changes +++ b/gnucash.changes @@ -1,3 +1,17 @@ +------------------------------------------------------------------- +Sat Jul 21 10:24:05 UTC 2012 - dimstar@opensuse.org + +- Add gnucash-tip-of-the-day.patch: Fix "Tip of the day" parsing + when building with gcc 4.7: 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. Pre gcc-4.7 + there will be two newlines between tips, but this has no impact + on the tip displaying code. + ------------------------------------------------------------------- Fri Feb 24 09:37:45 UTC 2012 - vuntz@opensuse.org diff --git a/gnucash.spec b/gnucash.spec index 155dec6..c337651 100644 --- a/gnucash.spec +++ b/gnucash.spec @@ -27,6 +27,8 @@ Source: http://downloads.sourceforge.net/project/gnucash/gnucash%20%28st Source1: %{name}-rpmlintrc # PATCH-FIX-UPSTREAM gnucash-fix-python-install.patch bgo#668196 vuntz@opensuse.org -- Fix installation of python bindings Patch0: gnucash-fix-python-install.patch +# PATCH-FIX-UPSTREAM gnucash-tip-of-the-day.patch bnc#771603 dimstar@opensuse.org -- Fix tip-of-the-day with gcc-4.7, svn commit r22246 +Patch1: gnucash-tip-of-the-day.patch # PATCH-MISSING-TAG -- See http://wiki.opensuse.org/Packaging/Patches Patch3: gnucash-cpan-warning.patch BuildRequires: automake @@ -129,6 +131,7 @@ balanced books. %prep %setup -q %patch0 -p1 +%patch1 # This patch must be applied: %patch3