diff options
author | Igor Pashev <pashev.igor@gmail.com> | 2022-10-27 09:24:57 +0200 |
---|---|---|
committer | Igor Pashev <pashev.igor@gmail.com> | 2022-10-27 09:29:56 +0200 |
commit | abc0ff40d820ed712325a9b9df1875be5d7e1f9a (patch) | |
tree | 9653043daa2f2ca80e31aa81aa4655ec2e0e5de2 /debian/rules | |
download | chicago95-debian-abc0ff40d820ed712325a9b9df1875be5d7e1f9a.tar.gz |
Diffstat (limited to 'debian/rules')
-rwxr-xr-x | debian/rules | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/debian/rules b/debian/rules new file mode 100755 index 0000000..aa773ff --- /dev/null +++ b/debian/rules @@ -0,0 +1,35 @@ +#!/usr/bin/make -f + +override_dh_auto_install: + make \ + install_cursors \ + install_doc \ + install_fonts \ + install_gtk_theme \ + install_icons \ + install_login_sound \ + install_sounds \ + DESTDIR=$(CURDIR)/debian/tmp + rm -rfv $(CURDIR)/debian/tmp/usr/share/icons/*/src + rm -rfv $(CURDIR)/debian/tmp/usr/share/icons/*/build + rm -fv $(CURDIR)/debian/tmp/usr/share/themes/Chicago95/index.theme + rm -fv $(CURDIR)/debian/tmp/usr/share/themes/Chicago95/gtk-3.2* + +%: + dh $@ + +PACKAGE := chicago95 +GIT_REPO := https://github.com/grassmunk/Chicago95.git +DEBIAN_PATH := $(abspath $(dir $(firstword $(MAKEFILE_LIST)))) +SRC_VERSION := $(shell dpkg-parsechangelog -l$(DEBIAN_PATH)/changelog | awk '/^Version:/ {sub(/-[^-]*/, "", $$2); print $$2}') +GIT_REVISION := $(shell echo $(SRC_VERSION) | sed -r 's,.+git\.(\w+).*,\1,') +TARBALL := $(PACKAGE)_$(SRC_VERSION).orig.tar.xz +.PHONY: get-orig-source +get-orig-source: + rm -rf get-orig-source $(TARBALL) && mkdir get-orig-source + git clone $(GIT_REPO) get-orig-source/$(PACKAGE)-$(SRC_VERSION) + git -C get-orig-source/$(PACKAGE)-$(SRC_VERSION) checkout $(GIT_REVISION) + find get-orig-source/$(PACKAGE)-$(SRC_VERSION) -name '.*' -print0 | xargs -0 --no-run-if-empty rm -rfv + tar cJf $(TARBALL) -C get-orig-source $(PACKAGE)-$(SRC_VERSION) + rm -rf get-orig-source + @echo " "$(TARBALL)" created; move it to the right destination to build the package" |