File: rules

package info (click to toggle)
intel-ipsec-mb 2.0.1-3
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 17,404 kB
  • sloc: ansic: 104,071; asm: 64,976; pascal: 18,149; javascript: 5,637; python: 1,464; makefile: 799
file content (57 lines) | stat: -rwxr-xr-x 1,647 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
54
55
56
57
#!/usr/bin/make -f

include /usr/share/dpkg/architecture.mk

DESTDIR=$$(pwd)/debian/tmp
LIBDIR=/usr/lib/$(DEB_HOST_MULTIARCH)
HDRDIR=/usr/include
MANDIR=/usr/share/man/man7
DOCDIR=/usr/share/doc

VERSION_MAJOR=$(shell grep -e "IMB_VERSION_STR" lib/intel-ipsec-mb.h | cut -d'"' -f2 | cut -d'.' -f1)
VERSION_MINOR=$(shell grep -e "IMB_VERSION_STR" lib/intel-ipsec-mb.h | cut -d'"' -f2 | cut -d'.' -f2)
VERSION_PATCH=$(shell grep -e "IMB_VERSION_STR" lib/intel-ipsec-mb.h | cut -d'"' -f2 | cut -d'.' -f3)

MAN1 = libipsec-mb.7
MAN2 = libipsec-mb-dev.7

export DEB_BUILD_MAINT_OPTIONS = hardening=+all
DPKG_EXPORT_BUILDFLAGS = 1
include /usr/share/dpkg/buildflags.mk

override_dh_auto_configure:

override_dh_auto_build:
	dh_auto_configure -- -DBUILD_SHARED_LIBS=OFF
	find . -type f -name "*.o" -print -exec rm {} \;
	$(shell dpkg-buildflags --export=sh); dh_auto_build --
	find $$(pwd) -name "libIPSec_MB.*" -exec ls -al {} \;

	#dh_auto_install

	dh_auto_configure -- -DBUILD_SHARED_LIBS=ON
	find . -type f -name "*.o" -print -exec rm {} \;
	$(shell dpkg-buildflags --export=sh); dh_auto_build --
	find $$(pwd) -name "libIPSec_MB.*" -exec ls -al {} \;

	find $$(pwd) -name "libIPSec_MB.so*" -exec ls -al {} \;
	find $$(pwd) -name "libIPSec_MB.a" -exec ls -al {} \;
	#dh_auto_install

override_dh_auto_install:
	#find $$(pwd) -name "libIPSec_MB.so*" -exec ls -al {} \;
	#find $$(pwd) -name "libIPSec_MB.a" -exec ls -al {} \;
	dh_auto_configure -- -DBUILD_SHARED_LIBS=OFF
	dh_auto_install
	dh_auto_configure -- -DBUILD_SHARED_LIBS=ON
	dh_auto_install

#
# Disable elf debug optimization step
#
override_dh_dwz:

%:
	dh $@
	dh_makeshlibs
	dh_shlibdeps