From: Ben Pfaff Date: Mon, 12 Oct 2009 04:31:18 +0000 (-0700) Subject: Don't delete .po files from source directory in "make clean". X-Git-Tag: lenny-x64-build41^0 X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fremotes%2Forigin%2Fmakefiles;p=pspp-builds.git Don't delete .po files from source directory in "make clean". Running "make clean" when the source directory is configured as a build directory shouldn't delete the .po files, but the rule as written did so. This fixes the problem. --- diff --git a/po/automake.mk b/po/automake.mk index e7b13096..0b18ef80 100644 --- a/po/automake.mk +++ b/po/automake.mk @@ -52,5 +52,13 @@ uninstall-hook: EXTRA_DIST += $(POFILES) $(POTFILE) -CLEANFILES += $(POFILES) $(GMOFILES) $(POTFILE) - +CLEANFILES += $(GMOFILES) $(POTFILE) + +# Clean $(POFILES) from build directory but not if that's the same as +# the source directory. +po_CLEAN: + @if test "$(srcdir)" != .; then \ + echo rm -f $(POFILES); \ + rm -f $(POFILES); \ + fi +CLEAN_LOCAL += po_CLEAN