File: rules

package info (click to toggle)
d2x-rebirth 0.58.1-1.3
  • links: PTS, VCS
  • area: non-free
  • in suites: bookworm, bullseye, sid
  • size: 6,540 kB
  • sloc: ansic: 111,473; asm: 1,228; ada: 364; objc: 243; python: 121; makefile: 26
file content (50 lines) | stat: -rwxr-xr-x 1,574 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
#!/usr/bin/make -f

# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1

%:
	dh $@ --parallel

override_dh_clean:
	scons --clean
	dh_clean .sconsign.dblite debian/*.xpm

override_dh_auto_build:
	dh_auto_build
	## build menu icon
	convert d2x-rebirth.xpm -resize 32x32 debian/d2x-rebirth32.xpm
	CFLAGS="$(CFLAGS) $(CPPFLAGS)" LDFLAGS="$(LDFLAGS)" \
        scons prefix=/usr verbosebuild=1 --debug=presub

#DATA_DIR = $(SHARE_DIR)/games/$(PKG)
#DEBIAN_TMP = debian/tmp
#TMP_DATA_DIR = $(DEBIAN_TMP)/$(DATA_DIR)
	#install -d $(TMP_DATA_DIR)/missions $(TMP_DATA_DIR)/demos $(TMP_DATA_DIR)/screenshots $(TMP_DATA_DIR)/Music
	#unzip d1xr-hires.zip -d $(TMP_DATA_DIR)

#override_dh_clean:
#	dh_clean debian/*.xpm CMakeCache.txt cmake_install.cmake Makefile

override_dh_auto_configure:
	dh_auto_configure --builddirectory=$(CURDIR)

override_dh_auto_install:
	#scons install install_path=$(CURDIR)/tmp
	dh_auto_install --destdir=$(CURDIR)/tmp

override_dh_installchangelogs:
	dh_installchangelogs CHANGELOG.txt

## http://wiki.debian.org/onlyjob/get-orig-source
PKD   = $(abspath $(dir $(MAKEFILE_LIST)))
PKG   = $(word 2,$(shell dpkg-parsechangelog -l$(PKD)/changelog | grep ^Source))
VER  ?= $(shell dpkg-parsechangelog -l$(PKD)/changelog | perl -ne 'print $$1 if m{Version:\s*([\d\.]+)}')
DTYPE =
.PHONY: get-orig-source
get-orig-source: $(PKG)_$(VER)$(DTYPE).orig.tar.xz
	@

$(PKG)_$(VER)$(DTYPE).orig.tar.xz:
	@echo "# Downloading..."
	uscan --noconf --verbose --rename --destdir=$(CURDIR) --check-dirname-level=0 --force-download --download-version $(VER) $(PKD)