Debian Codegraph @

debian/rules

raw
1 #!/usr/bin/make -f
2 # debian/rules for invesalius
3 # Andreas Tille <[email protected]>
4 # GPL
5
6 export DEB_BUILD_MAINT_OPTIONS = hardening=+bindnow
7 export PYBUILD_NAME=invesalius
8 export HOME=$(shell mktemp --directory /tmp/home.XXXXXX)
9
10 %:
11 dh $@ --buildsystem=pybuild
12
13 override_dh_auto_build:
14 python3 setup.py build_ext --inplace
15
16 execute_after_dh_auto_clean:
17 rm -f invesalius_cy/*.so
18
19 override_dh_compress:
20 dh_compress --exclude=LICENSE.pt.txt --exclude=.inv3
21
22 create-launcher:
23 echo '#!/bin/sh' > invesalius3
24 echo 'export INV_SAMPLE_DIR="/usr/share/doc/invesalius-examples/examples/"' >> invesalius3
25 echo 'export GDK_BACKEND=x11' >> invesalius3
26 echo 'export PYTHONPATH=$$PYTHONPATH:"/usr/lib/invesalius"' >> invesalius3
27 echo 'export INVESALIUS_LIBRARY_PATH="/usr/share/invesalius/"' >> invesalius3
28 echo 'export NUMPY_EXPERIMENTAL_DTYPE_API=1' >> invesalius3
29 echo 'cd $$INVESALIUS_LIBRARY_PATH' >> invesalius3
30 echo 'python3 app.py $$@' >> invesalius3
31
32 override_dh_install: create-launcher
33 dh_install
34 # Converting a shipped .ico file into an installed .png icon
35 mkdir -p debian/invesalius/usr/share/icons/hicolor/64x64/apps/
36 convert icons/invesalius_64x64.ico -resize 64x64\! debian/invesalius/usr/share/icons/hicolor/64x64/apps/invesalius.png
37
38 override_dh_installchangelogs:
39 dh_installchangelogs changelog.md
40
41 override_dh_auto_install: ;