Reviewed-By: Paulo Vital <pvital(a)linux.vnet.ibm.com>
On Wed, 2016-09-28 at 15:59 -0300, Aline Manera wrote:
make-rpm was failing as below because the dist target (which is
responsible to generate the package tarball) was removed from rpm
generation
Add it back and update po/Makefile.in.in to do not modify files while
generating the package.
/usr/bin/mkdir -p rpm/BUILD rpm/RPMS rpm/SOURCES rpm/SPECS rpm/SRPMS
<danielhb> cp ./wok.spec rpm/SPECS/wok.spec
<danielhb> cp wok-2.2.0.tar.gz rpm/SOURCES
<danielhb> cp: cannot stat ‘wok-2.2.0.tar.gz’: No such file or
directory
---
Makefile.am | 8 ++++----
po/Makefile.in.in | 9 ---------
src/wok/plugins/sample/po/Makefile.in.in | 9 ---------
3 files changed, 4 insertions(+), 22 deletions(-)
diff --git a/Makefile.am b/Makefile.am
index 2b27a6a..8b3f508 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -115,17 +115,17 @@ wok.spec: contrib/wok.spec.fedora
contrib/wok.spec.suse
/bin/false
; \
fi
-rpm: wok.spec
+rpm: dist wok.spec
$(MKDIR_P) rpm/BUILD rpm/RPMS rpm/SOURCES rpm/SPECS
rpm/SRPMS
cp $(top_srcdir)/wok.spec rpm/SPECS/wok.spec
cp $(DIST_ARCHIVES) rpm/SOURCES
rpmbuild -ba --define "_topdir `pwd`/rpm" rpm/SPECS/wok.spec
-fedora-rpm: contrib/wok.spec.fedora
+fedora-rpm: dist contrib/wok.spec.fedora
ln -sf contrib/wok.spec.fedora wok.spec
$(MAKE) rpm
-suse-rpm: contrib/wok.spec.suse
+suse-rpm: dist contrib/wok.spec.suse
ln -sf contrib/wok.spec.suse wok.spec
$(MAKE) rpm
@@ -178,7 +178,7 @@ VERSION:
git describe --abbrev=0 --always > $@; \
fi
-.PHONY: deb install-deb rpm fedora-rpm suse-rpm ChangeLog VERSION
+.PHONY: deb install-deb rpm fedora-rpm suse-rpm VERSION
clean-local:
diff --git a/po/Makefile.in.in b/po/Makefile.in.in
index d01fb31..b7168c7 100644
--- a/po/Makefile.in.in
+++ b/po/Makefile.in.in
@@ -306,7 +306,6 @@ maintainer-clean: distclean
distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir)
dist distdir:
- $(MAKE) update-po
@$(MAKE) dist2
# This is a separate target because 'update-po' must be executed
before.
dist2: stamp-po $(DISTFILES)
@@ -317,14 +316,6 @@ dist2: stamp-po $(DISTFILES)
if test -f $(srcdir)/$(DOMAIN).pot; then \
dists="$$dists $(DOMAIN).pot stamp-po"; \
fi; \
- if test -f $(srcdir)/ChangeLog; then \
- dists="$$dists ChangeLog"; \
- fi; \
- for i in 0 1 2 3 4 5 6 7 8 9; do \
- if test -f $(srcdir)/ChangeLog.$$i; then \
- dists="$$dists ChangeLog.$$i"; \
- fi; \
- done; \
if test -f $(srcdir)/LINGUAS; then dists="$$dists LINGUAS";
fi; \
for file in $$dists; do \
if test -f $$file; then \
diff --git a/src/wok/plugins/sample/po/Makefile.in.in
b/src/wok/plugins/sample/po/Makefile.in.in
index 52ab81c..62e9dae 100644
--- a/src/wok/plugins/sample/po/Makefile.in.in
+++ b/src/wok/plugins/sample/po/Makefile.in.in
@@ -308,7 +308,6 @@ maintainer-clean: distclean
distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir)
dist distdir:
- $(MAKE) update-po
@$(MAKE) dist2
# This is a separate target because 'update-po' must be executed
before.
dist2: stamp-po $(DISTFILES)
@@ -319,14 +318,6 @@ dist2: stamp-po $(DISTFILES)
if test -f $(srcdir)/$(DOMAIN).pot; then \
dists="$$dists $(DOMAIN).pot stamp-po"; \
fi; \
- if test -f $(srcdir)/ChangeLog; then \
- dists="$$dists ChangeLog"; \
- fi; \
- for i in 0 1 2 3 4 5 6 7 8 9; do \
- if test -f $(srcdir)/ChangeLog.$$i; then \
- dists="$$dists ChangeLog.$$i"; \
- fi; \
- done; \
if test -f $(srcdir)/LINGUAS; then dists="$$dists LINGUAS";
fi; \
for file in $$dists; do \
if test -f $$file; then \