fedora-settings/dist/Makefile
2024-10-30 17:14:08 +01:00

16 lines
510 B
Makefile

.PHONY: clean build all
SOURCE_DIR := $(realpath $(dir $(abspath $(lastword $(MAKEFILE_LIST))))/..)
RESULT_DIR ?= ./result
all: fedora-settings.tar.gz build
fedora-settings.tar.gz: $(shell find $(SOURCE_DIR) -type f)
tar -cpzf $@ --exclude=dist --exclude=.git -C $(SOURCE_DIR)/.. $(notdir $(SOURCE_DIR))
build:
mock --resultdir $(RESULT_DIR) --buildsrpm --spec ./fedora-settings.spec --sources ./fedora-settings.tar.gz
mock --resultdir $(RESULT_DIR) $(RESULT_DIR)/*.fc??.src.rpm
clean:
git clean -fxd