From: John Wright Date: Mon, 17 May 2010 06:12:21 +0000 (-0600) Subject: Ensure pristine source after the "clean" target X-Git-Tag: 0.97.7-3~2 X-Git-Url: http://git.johnwright.org/?p=fmit.git;a=commitdiff_plain;h=0a7ac8ff1b912358f95a98f0bccc5c484dec351b Ensure pristine source after the "clean" target A file gets regenerated via "lupdate", so we now keep a copy of that file so we can restore the original version in the clean rule. --- diff --git a/debian/rules b/debian/rules index d0b7def..c7ce458 100755 --- a/debian/rules +++ b/debian/rules @@ -12,3 +12,14 @@ endif override_dh_auto_configure: dh_auto_configure -- --with-Qt-dir=/usr/share/qt3 $(DEB_CONFIGURE_ALSA) + +override_dh_auto_build: + # This file gets regenerated. Make sure we can end up with the + # original copy of it in place after the clean target. + [ -f tr/fmit_fr.ts.orig ] || cp tr/fmit_fr.ts tr/fmit_fr.ts.orig + dh_auto_build + +override_dh_auto_clean: + dh_auto_clean + # Restore the original version of the regenerated .ts file + [ -f tr/fmit_fr.ts.orig ] && mv tr/fmit_fr.ts{.orig,} || true