ostree/.copr/Makefile
Luca BRUNO 4bc79ada27
copr: only use libostree tags
This adds a tag filter to the logic which emits version labels for
COPR build, so that it avoids mistakenly picking up tags belonging
to the Rust bindings.
2022-11-11 14:05:56 +00:00

11 lines
689 B
Makefile

srpm:
dnf install -y git
# similar to https://github.com/actions/checkout/issues/760, but for COPR
git config --global --add safe.directory '*'
ci/make-git-snapshot.sh
curl -LO https://src.fedoraproject.org/rpms/ostree/raw/rawhide/f/ostree.spec
sed -ie "s,^Version:.*,Version: $$(git describe --always --tags --match 'v2???.*' | sed -e 's,-,\.,g' -e 's,^v,,')," ostree.spec
sed -ie 's/^Patch/# Patch/g' ostree.spec # we don't want any downstream patches
rpmbuild -bs --define "_sourcedir ${PWD}" --define "_specdir ${PWD}" --define "_builddir ${PWD}" --define "_srcrpmdir ${PWD}" --define "_rpmdir ${PWD}" --define "_buildrootdir ${PWD}/.build" ostree.spec
mv *.src.rpm $$outdir