File: rules

package info (click to toggle)
flatbuffers 1.12.1~git20200711.33e2d80%2Bdfsg1-0.6
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, sid
  • size: 8,240 kB
  • sloc: cpp: 34,954; python: 5,085; java: 4,080; cs: 4,036; php: 1,455; ansic: 1,323; javascript: 1,074; sh: 733; xml: 727; makefile: 35
file content (38 lines) | stat: -rwxr-xr-x 979 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
#!/usr/bin/make -f

include /usr/share/dpkg/pkg-info.mk

# SOURCE_DATE_EPOCH set by dh
export DEB_CPPFLAGS_MAINT_APPEND = -Wno-error=date-time

export DEB_BUILD_MAINT_OPTIONS = hardening=+all

%:
	dh $@ --with python3

override_dh_auto_configure:
	dh_auto_configure -- -DFLATBUFFERS_BUILD_SHAREDLIB=ON

override_dh_auto_build-arch:
	dh_auto_build --arch

# Python3 build
override_dh_auto_build-indep:
	dh_auto_build --indep
	set -e; cd python && for pv in $(shell py3versions -vr); do \
		VERSION=$(DEB_VERSION) python$$pv setup.py build; \
	done

override_dh_auto_install-arch:
	dh_auto_install --arch

# Python3 install.
override_dh_auto_install-indep:
	dh_auto_install --indep
	set -e; \
	cd python && for pv in $(shell py3versions -vr); do \
		VERSION=$(DEB_VERSION) python$$pv setup.py install \
			--install-layout=deb --no-compile \
			--root=$(CURDIR)/debian/python3-flatbuffers; \
	done
	find $(CURDIR)/debian/python3-flatbuffers -name 'flatbuffers-*-nspkg.pth' -delete