-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrules
executable file
·48 lines (39 loc) · 1.74 KB
/
rules
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
#!/usr/bin/make -f
CFLAGS+=$(CPPFLAGS)
DEB_BUILD_ARCH_CPU := $(shell dpkg-architecture -qDEB_BUILD_ARCH_CPU 2>/dev/null)
ifeq ($(DEB_BUILD_ARCH_CPU), arm)
DISABLE_GUI := --disable-gui
else ifeq ($(DEB_BUILD_ARCH_CPU), armhf)
DISABLE_GUI := --disable-gui
else ifeq ($(DEB_BUILD_ARCH_CPU), armel)
DISABLE_GUI := --disable-gui
else
DISABLE_GUI :=
endif
%:
dh $@ --with python2 --with autoreconf
override_dh_auto_configure:
dh_auto_configure -- $(DISABLE_GUI) --enable-openmp --prefix=/usr --enable-python $(shell dpkg-buildflags --export=configure)
VERSION := $(shell grep '^AC_INIT' configure.ac | \
sed 's/AC_INIT(saga, \([0-9|\.]*\)\,.*)/\1/g')
UPSTREAM_URL ?=$(shell uscan --dehs | sed -n 's/.*<upstream-url>\(.*\)<\/upstream-url>.*/\1/p')
UPSTREAM_VERSION ?=$(shell uscan --dehs | sed -n 's/.*<upstream-version>\(.*\)<\/upstream-version>.*/\1/p')
debian/% :: debian/%.in
sed -e 's/@VERSION@/$(VERSION)/' $< >$@
override_dh_python2:
dh_python2 --no-guessing-versions
override_dh_clean:
dh_clean
rm -f src/saga_core/saga_api/saga_api.py
override_dh_makeshlibs:
dh_makeshlibs -Xpython-saga
get-orig-source:
uscan --verbose --force-download --repack --compression xz
#sources up to version 2.1.2 were created using these commands:
#wget $(UPSTREAM_URL)
#gunzip *.tar.gz
#tar --delete -f saga_$(UPSTREAM_VERSION).tar saga-$(UPSTREAM_VERSION)/src/modules/grid/grid_gridding/nn/triangle.c
#tar --delete -f saga_$(UPSTREAM_VERSION).tar saga-$(UPSTREAM_VERSION)/src/modules/grid/grid_gridding/nn/triangle.h
#tar --delete -f saga_$(UPSTREAM_VERSION).tar saga-$(UPSTREAM_VERSION)/src/modules/simulation/sim_fire_spreading
#gzip -9n saga_$(UPSTREAM_VERSION).tar
#mv saga_$(UPSTREAM_VERSION).tar.gz ../saga_$(UPSTREAM_VERSION)+dfsg.orig.tar.gz