summaryrefslogtreecommitdiff
path: root/.copr
diff options
context:
space:
mode:
authorThomas Schneider <qsx@chaotikum.eu>2024-04-04 17:44:09 +0200
committerThomas Schneider <qsx@chaotikum.eu>2024-04-04 17:44:09 +0200
commit82f4901f86977b1bf4b783c251780eb607b3f3c0 (patch)
tree3448da8e376545b07238f420591012076b3814cd /.copr
parent6a3b76ce918344db8f1b6a52b22cbb38b4b61650 (diff)
.copr/Makefile: Fix _sourcedir and rpmautospec
Diffstat (limited to '.copr')
-rw-r--r--.copr/Makefile11
1 files changed, 8 insertions, 3 deletions
diff --git a/.copr/Makefile b/.copr/Makefile
index 0b2aaf9..7579fcb 100644
--- a/.copr/Makefile
+++ b/.copr/Makefile
@@ -1,13 +1,18 @@
spec ?= $(wildcard *.spec)
+$(shell test -f $(spec))
+ifneq ($(.SHELLSTATUS),0)
+override spec := $(wildcard $(spec)/*.spec)
+endif
ifneq ($(words spec),1)
$(error More than one spec file: $(spec))
endif
outdir ?= $(CURDIR)
-srpm: $(spec) /usr/bin/spectool
+srpm: $(spec) /usr/bin/spectool /usr/bin/rpmautospec
spectool -g $(spec)
- sha512sum -c $(CURDIR)/sources
- rpmbuild -D '_sourcedir $(CURDIR)' -D "_srcrpmdir $(outdir)" -bs $(spec)
+ sha512sum -c sources
+ rpmautospec process-distgit $(spec) $(spec)
+ rpmbuild -D "_srcrpmdir $(outdir)" -D "_sourcedir $(CURDIR)" -bs $(spec)
.PHONY: srpm