File: rules

package info (click to toggle)
softhsm2 2.2.0-3
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 6,348 kB
  • ctags: 5,366
  • sloc: cpp: 57,326; sh: 11,467; ansic: 1,891; python: 890; makefile: 608
file content (53 lines) | stat: -rwxr-xr-x 1,513 bytes parent folder | download | duplicates (2)
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
49
50
51
52
53
#!/usr/bin/make -f
# See debhelper(7) (uncomment to enable)
# output every command that modifies files on the build system.
#DH_VERBOSE = 1

# see EXAMPLES in dpkg-buildflags(1) and read /usr/share/dpkg/*
DPKG_EXPORT_BUILDFLAGS = 1
include /usr/share/dpkg/default.mk

# see FEATURE AREAS in dpkg-buildflags(1)
export DEB_BUILD_MAINT_OPTIONS = hardening=+all

# see ENVIRONMENT in dpkg-buildflags(1)
# package maintainers to append CFLAGS
export DEB_CFLAGS_MAINT_APPEND  = -Wall -pedantic
# package maintainers to append LDFLAGS
export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed

SKIP_64BIT_ON_CPU="aarch64 alpha ia64 mips64 mips64el"

export DPKG_GENSYMBOLS_CHECK_LEVEL=4

ifeq ($(DEB_HOST_ARCH_BITS),64)
  # -m64 is not recognized on most architectures
  ifeq (,$(findstring $(DEB_HOST_GNU_CPU),$(SKIP_64BIT_ON_CPU)))
    CONFIGURE_FLAGS = --enable-64bit
  endif
endif

%:
	dh $@ --with autoreconf

override_dh_auto_configure:
	dh_auto_configure -- \
	  --sysconfdir=/etc/softhsm \
	  --localstatedir=/var \
	  --libdir=/usr/lib \
	  --with-crypto-backend=openssl \
	  --with-migrate \
	  --with-pic \
	  --disable-gost \
	  $(CONFIGURE_FLAGS)

override_dh_installchangelogs:
	dh_installchangelogs NEWS

override_dh_install:
	install -m 0755 -d $(CURDIR)/debian/tmp/usr/include/softhsm/
	install -m 0644 $(CURDIR)/src/lib/cryptoki_compat/pkcs11.h $(CURDIR)/debian/tmp/usr/include/softhsm/
	dh_install -X.la -X.sample --fail-missing

override_dh_strip:
	dh_strip -O--dbgsym-migration='softhsm2-dbg (<< 2.2.0-2~)'