1
0
Fork 0
mirror of https://github.com/alacritty/alacritty.git synced 2024-11-18 13:55:23 -05:00
alacritty/.copr/Makefile

15 lines
478 B
Makefile
Raw Permalink Normal View History

2019-06-09 12:30:42 -04:00
version := $(shell rpmspec -q --srpm --qf "%{version}\n" extra/linux/redhat/alacritty.spec)
commands = git
srpm: $(commands)
$(eval top := $(shell mktemp -d))
mkdir -p "$(top)/SOURCES"
git archive HEAD --output "$(top)/SOURCES/alacritty-$(version).tar" --prefix "alacritty-$(version)/"
rpmbuild -bs "$(spec)" --define "_topdir $(top)" --define "_srcrpmdir $(outdir)"
rm -rf "$(top)"
$(commands):
command -v $@ &> /dev/null || dnf -y install $@
.PHONY: srpm $(commands)