File: rules

package info (click to toggle)
ltt-control 2.9.3-1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 9,992 kB
  • ctags: 8,466
  • sloc: ansic: 74,351; sh: 15,191; makefile: 1,807; python: 742; yacc: 548; lex: 138; perl: 99; java: 77
file content (40 lines) | stat: -rwxr-xr-x 1,170 bytes parent folder | download
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
#!/usr/bin/make -f

DEB_BUILD_ARCH ?= $(shell dpkg-architecture -qDEB_BUILD_ARCH)

# A bug in gcc causes build failure with -fPIE on armel
ifneq ($(DEB_BUILD_ARCH), armel)
    export DEB_BUILD_MAINT_OPTIONS := hardening=+all
endif

PY3V := $(shell py3versions -vr)

%:
	dh $@ --with autoreconf,bash-completion,python3

override_dh_auto_build:
	dh_auto_build -- V=1

override_dh_auto_test:

override_dh_auto_install:
	dh_auto_install
	for pv in $(PY3V); do \
	  PYTHON=python$${pv} PYTHON_CONFIG=python$${pv}-config \
	    dh_auto_configure -- --enable-python-bindings; \
	  cd extras/bindings/swig/python; \
	  make clean; \
	  make install DESTDIR="$(CURDIR)/debian/tmp"; \
	  mv "$(CURDIR)/debian/tmp/usr/lib/python$${pv}/site-packages" \
	     "$(CURDIR)/debian/tmp/usr/lib/python$${pv}/dist-packages"; \
	  find "$(CURDIR)/debian/tmp/usr/lib/python$${pv}" -type l -delete; \
	  mv "$(CURDIR)/debian/tmp/usr/lib/python$${pv}/dist-packages/_lttng.so.0.0.0" \
	     "$(CURDIR)/debian/tmp/usr/lib/python$${pv}/dist-packages/_lttng.so"; \
	  cd $(CURDIR); \
	done

override_dh_installinit:
	dh_installinit --name=lttng-sessiond

override_dh_makeshlibs:
	dh_makeshlibs -V