summaryrefslogtreecommitdiffstats
path: root/Makefile.am
diff options
context:
space:
mode:
authorMichael E Brown <michael_e_brown@dell.com>2007-10-18 17:50:48 -0500
committerMichael E Brown <michael_e_brown@dell.com>2007-10-18 17:50:48 -0500
commit2a926fef18a521e05b88b739e56ee5a309788724 (patch)
treeff32c23627c1939af93595bcf47fb4ebccfa2692 /Makefile.am
parent1763fc3d166624ff101b198fcd76db5e0d8a94a7 (diff)
downloadmock-2a926fef18a521e05b88b739e56ee5a309788724.tar.gz
mock-2a926fef18a521e05b88b739e56ee5a309788724.tar.xz
mock-2a926fef18a521e05b88b739e56ee5a309788724.zip
fix 'make distcheck'
Diffstat (limited to 'Makefile.am')
-rw-r--r--Makefile.am17
1 files changed, 9 insertions, 8 deletions
diff --git a/Makefile.am b/Makefile.am
index af63458..8b9ab70 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -53,18 +53,19 @@ pkgpython_PYTHON = \
# indent a space to get around automake
ifneq ($(top_builddir),$(top_srcdir))
$(top_builddir)/src/mock.py: $(top_srcdir)/src/mock.py
+ CLEANFILES=$(top_builddir)/src/mock.py
endif
src/mock.py: Makefile
echo Updating $@, current pwd: $$(pwd)
- cp -f $(top_srcdir)/$@ $(top_builddir)/$@.new
- perl -p -i -e 's|^__VERSION__=.*|__VERSION__="$(RELEASE_VERSION)"|' $(top_builddir)/$@.new
- perl -p -i -e 's|^SYSCONFDIR=.*|SYSCONFDIR="$(sysconfdir)"|' $(top_builddir)/$@.new
- perl -p -i -e 's|^PYTHONDIR=.*|PYTHONDIR="$(pythondir)"|' $(top_builddir)/$@.new
- perl -p -i -e 's|^PKGPYTHONDIR=.*|PKGPYTHONDIR="$(pkgpythondir)"|' $(top_builddir)/$@.new
- diff -q $(top_srcdir)/$@ $(top_builddir)/$@.new >/dev/null 2>&1 || mv -f $(top_builddir)/$@.new $(top_builddir)/$@
- rm -f $(top_builddir)/$@.new
- chmod +x $(top_builddir)/$@ || :
+ cp -f $(top_srcdir)/src/mock.py $(top_builddir)/src/mock.py.new
+ perl -p -i -e 's|^__VERSION__=.*|__VERSION__="$(RELEASE_VERSION)"|' $(top_builddir)/src/mock.py.new
+ perl -p -i -e 's|^SYSCONFDIR=.*|SYSCONFDIR="$(sysconfdir)"|' $(top_builddir)/src/mock.py.new
+ perl -p -i -e 's|^PYTHONDIR=.*|PYTHONDIR="$(pythondir)"|' $(top_builddir)/src/mock.py.new
+ perl -p -i -e 's|^PKGPYTHONDIR=.*|PKGPYTHONDIR="$(pkgpythondir)"|' $(top_builddir)/src/mock.py.new
+ diff -q $(top_srcdir)/src/mock.py $(top_builddir)/src/mock.py.new >/dev/null 2>&1 || mv -f $(top_builddir)/src/mock.py.new $(top_builddir)/src/mock.py
+ rm -f $(top_builddir)/src/mock.py.new
+ chmod +x $(top_builddir)/src/mock.py 2>/dev/null || :
rpm: dist
BLD_DIR=$$(mktemp -d /tmp/rpmbuild-$$$$-XXXXXX); \