From cd5a03e574dbdf816e7ae68b47fae3375fc0568f Mon Sep 17 00:00:00 2001 From: Rob Crittenden Date: Apr 08 2022 18:26:19 +0000 Subject: Manually build the srpm for the copr CI I'm not sure what changed but copr was building the srpm using the upstream tarball and not the current git checkout so it wasn't actually testing anything. copr now uses the manual make srpm method instead, as documented at https://docs.pagure.org/copr.copr/user_documentation.html#make-srpm Use configure.ac to determine the current version. Signed-off-by: Rob Crittenden --- diff --git a/.copr/Makefile b/.copr/Makefile new file mode 100644 index 0000000..26b2b5b --- /dev/null +++ b/.copr/Makefile @@ -0,0 +1,8 @@ +srpm: + dnf -y install git + $(eval version := $(shell grep AC_INIT configure.ac | cut -d, -f2 | rev | cut -c2- | rev)) + git archive -v --format=tar --prefix=certmonger-${version}/ HEAD | gzip > certmonger-${version}.tar.gz + rpmbuild \ + --define "_sourcedir `pwd`" \ + --define "_srcrpmdir ${outdir}" \ + -bs `pwd`/certmonger.spec