#!/usr/bin/make -f # -*- makefile -*- # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 PYBUILD_NAME := xia # The absolute path of the rules file. RULES_PATH := $(realpath $(firstword $(MAKEFILE_LIST))) # The working directory is obtained by removing the # "/debian/rules" string at the end of RULES_PATH. WORKING_DIR := $(realpath $(RULES_PATH:/debian/rules=)) %: dh $@ --with python2 # To use setup.py with --root=debian/$(PYBUILD_NAME) instead of # --root=debian/tmp. See "man dh_auto_install" for more details. override_dh_auto_install: dh_auto_install --destdir="$(WORKING_DIR)/debian/$(PYBUILD_NAME)" # Rename the launcher. cd "$(WORKING_DIR)/build" && mv xia.py xia # We take jquery from Debian archive. cd "$(WORKING_DIR)/build" && rm share/vendors/jquery*.js