rpm-ostree/packaging/Makefile.dist-packaging

27 lines
680 B
Makefile
Raw Permalink Normal View History

2014-01-16 05:05:54 +04:00
# -*- mode: Makefile -*-
GITREV = $$(git describe --always --tags)
GITREV_FOR_PKG = $(shell echo "$(GITREV)" | sed -e 's,-,\.,g' -e 's,^v,,')
2014-01-16 02:41:21 +04:00
srcdir=$(shell dirname `pwd`)
PACKAGE=rpm-ostree
2014-01-16 02:41:21 +04:00
2014-01-16 05:05:54 +04:00
PKG_VER = $(PACKAGE)-$(GITREV_FOR_PKG)
PKG_CLIENT_VER = $(PACKAGE)-client-$(GITREV_FOR_PKG)
2014-01-16 05:05:54 +04:00
2014-01-16 02:41:21 +04:00
dist-snapshot:
./make-git-snapshot.sh "$(srcdir)" "$(PKG_VER)" "$(GITREV)"
rm -f $(PKG_VER).tar.xz
xz -T0 $(PKG_VER).tar
2014-01-16 02:41:21 +04:00
srpm: dist-snapshot
sed -e "s,^Version:.*,Version: $(GITREV_FOR_PKG)," $(PACKAGE).spec.in > $(PACKAGE).spec; \
./rpmbuild-cwd -bs $(PACKAGE).spec
2014-01-16 02:41:21 +04:00
rpm: srpm
./rpmbuild-cwd --rebuild $(PKG_VER)*.src.rpm
yumrepo: rpm
repomanage -o . | xargs -r rm
2016-03-10 17:22:39 +03:00
createrepo_c .