2022-06-13 07:22:45 +00:00
|
|
|
# See https://docs.pagure.org/copr.copr/user_documentation.html#make-srpm
|
|
|
|
# See for the --setopt option in the enabling of copr repo see:
|
|
|
|
# https://pagure.io/copr/copr/issue/184
|
2023-05-19 12:08:56 +00:00
|
|
|
|
|
|
|
COPR_USERNAME=$(shell rpm --eval %copr_username)
|
|
|
|
COPR_PROJECT=$(shell rpm --eval %copr_projectname)
|
|
|
|
|
2022-06-13 07:22:45 +00:00
|
|
|
.PHONY: srpm
|
|
|
|
srpm:
|
2022-09-06 12:53:04 +00:00
|
|
|
dnf install -y dnf-plugins-core fedora-packager
|
2023-05-19 12:08:56 +00:00
|
|
|
dnf copr enable -y --setopt=reposdir=/tmp/yum.repos.d $(COPR_USERNAME)/$(COPR_PROJECT)
|
2022-06-13 07:22:45 +00:00
|
|
|
dnf install -y --setopt=reposdir=/tmp/yum.repos.d llvm-snapshot-builder
|
2022-06-13 15:46:11 +00:00
|
|
|
rpmbuild \
|
|
|
|
--define "_srcrpmdir $(outdir)" \
|
|
|
|
--define "_sourcedir $(shell pwd)" \
|
|
|
|
--define "_disable_source_fetch 0" \
|
|
|
|
-bs $(spec)
|