forked from wolfSSL/gnutls-wolfssl
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrules
More file actions
executable file
·64 lines (48 loc) · 1.6 KB
/
rules
File metadata and controls
executable file
·64 lines (48 loc) · 1.6 KB
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
58
59
60
61
62
63
64
#!/usr/bin/make -f
GNUTLS_BUILD_DIR := $(CURDIR)/debian/gnutls-build
GNUTLS_INSTALL ?= $(GNUTLS_BUILD_DIR)
PROVIDER_PATH ?= /opt/wolfssl-gnutls-wrapper
export GNUTLS_INSTALL
export PROVIDER_PATH
PROVIDER_PATH_REL := $(patsubst /%,%,$(PROVIDER_PATH))
FIPS_ARG :=
ifneq (,$(filter fips,$(DEB_BUILD_PROFILES)))
FIPS_ARG := fips
endif
ifeq ($(FIPS),1)
FIPS_ARG := fips
endif
ifeq ($(shell [ -f $(CURDIR)/../fips.flag ] && cat $(CURDIR)/../fips.flag),1)
FIPS_ARG := fips
endif
%:
dh $@ --buildsystem=makefile
override_dh_auto_configure:
echo "usr/lib/*" > debian/gnutls-wolfssl.install
echo "usr/bin/*" >> debian/gnutls-wolfssl.install
echo "usr/include/*" >> debian/gnutls-wolfssl.install
echo "usr/share/*" >> debian/gnutls-wolfssl.install
echo "$(PROVIDER_PATH_REL)/*" > debian/wolfssl-gnutls-wrapper.install
override_dh_auto_build:
:
override_dh_auto_install:
mkdir -p $(GNUTLS_BUILD_DIR)
./setup.sh $(FIPS_ARG)
mkdir -p $(CURDIR)/debian/tmp/usr
if [ -d $(GNUTLS_BUILD_DIR)/lib ]; then \
cp -a $(GNUTLS_BUILD_DIR)/lib $(CURDIR)/debian/tmp/usr/; \
fi
if [ -d $(GNUTLS_BUILD_DIR)/bin ]; then \
cp -a $(GNUTLS_BUILD_DIR)/bin $(CURDIR)/debian/tmp/usr/; \
fi
if [ -d $(GNUTLS_BUILD_DIR)/include ]; then \
cp -a $(GNUTLS_BUILD_DIR)/include $(CURDIR)/debian/tmp/usr/; \
fi
if [ -d $(GNUTLS_BUILD_DIR)/share ]; then \
cp -a $(GNUTLS_BUILD_DIR)/share $(CURDIR)/debian/tmp/usr/; \
fi
mkdir -p $(CURDIR)/debian/tmp$(dir $(PROVIDER_PATH))
cp -a $(PROVIDER_PATH) $(CURDIR)/debian/tmp$(PROVIDER_PATH)
override_dh_clean:
dh_clean
rm -f debian/gnutls-wolfssl.install debian/wolfssl-gnutls-wrapper.install