File: rules

package info (click to toggle)
lz4 1.10.0-6
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 2,496 kB
  • sloc: ansic: 19,102; makefile: 1,060; python: 812; sh: 486; cpp: 173
file content (33 lines) | stat: -rwxr-xr-x 926 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
#!/usr/bin/make -f
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1

CPPFLAGS:= $(shell dpkg-buildflags --get CPPFLAGS) -fvisibility=hidden -DLZ4F_PUBLISH_STATIC_FUNCTIONS -DLZ4IO_MULTITHREAD
CFLAGS:= $(shell dpkg-buildflags --get CFLAGS) $(CPPFLAGS)
CXXFLAGS:= $(shell dpkg-buildflags --get CXXFLAGS) $(CPPFLAGS)
LDFLAGS:= $(shell dpkg-buildflags --get LDFLAGS) -pthread
DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
PREFIX:= /usr

ifeq ($(origin CC),default)
CC := $(DEB_HOST_GNU_TYPE)-gcc
endif

export CFLAGS
export CPPFLAGS
export LDFLAGS
export PREFIX

disable_test=0
ifneq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
disable_test=1
endif

%:
	dh $@ --buildsystem=cmake

override_dh_auto_configure:
	dh_auto_configure --sourcedirectory=build/cmake -- \
		-DBUILD_STATIC_LIBS=ON \
		-DCMAKE_BUILD_TYPE=RelWithDebInfo