File: rules

package info (click to toggle)
libgit2 1.9.2%2Bds-3
  • links: PTS, VCS
  • area: main
  • in suites: experimental
  • size: 60,864 kB
  • sloc: ansic: 203,740; javascript: 2,458; sh: 1,767; python: 384; perl: 99; php: 65; makefile: 52
file content (73 lines) | stat: -rwxr-xr-x 2,662 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
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
65
66
67
68
69
70
71
72
73
#!/usr/bin/make -f
# -*- makefile -*-

# This rules file has multiple streams:
# - build-debian-static: static library, SHA-1 hashes only
# - build-debian-shared: shared library, SHA-1 hashes only
# - build-debian-static-experimental: static library, SHA-256 support
# - build-debian-shared-experimental: shared library, SHA-256 support

# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1

export DEB_BUILD_MAINT_OPTIONS = hardening=+all

BUILD_TESTS = $(if $(filter nocheck,$(DEB_BUILD_OPTIONS)),OFF,ON)
COMMON_CMAKE_FLAGS = \
	-DBUILD_CLI=OFF \
	-DBUILD_TESTS=$(BUILD_TESTS) \
	-DCERT_LOCATION=/etc/ssl/certs/ca-certificates.crt \
	-DDISABLE_ONLINE_TESTS=ON \
	-DENABLE_REPRODUCIBLE_BUILDS=ON \
	-DREGEX_BACKEND=pcre2 \
	-DUSE_GSSAPI=ON \
	-DUSE_HTTPS=mbedTLS \
	-DUSE_HTTP_PARSER=http-parser \
	-DUSE_NTLMCLIENT=OFF \
	-DUSE_SSH=ON

# The stat() in the Git fs layer has some issues
export GITTEST_FLAKY_STAT = true

%:
	dh $@ --buildsystem=cmake

override_dh_auto_configure:
	dh_auto_configure --builddirectory=build-debian-static-experimental -- \
		-DBUILD_SHARED_LIBS=OFF \
		-DEXPERIMENTAL_SHA256=ON \
		$(COMMON_CMAKE_FLAGS)
	dh_auto_configure --builddirectory=build-debian-static -- \
		-DBUILD_SHARED_LIBS=OFF \
		-DEXPERIMENTAL_SHA256=OFF \
		$(COMMON_CMAKE_FLAGS)
	dh_auto_configure --builddirectory=build-debian-shared-experimental -- \
		-DBUILD_SHARED_LIBS=ON \
		-DEXPERIMENTAL_SHA256=ON \
		$(COMMON_CMAKE_FLAGS)
	dh_auto_configure --builddirectory=build-debian-shared -- \
		-DBUILD_SHARED_LIBS=ON \
		-DEXPERIMENTAL_SHA256=OFF \
		$(COMMON_CMAKE_FLAGS)

override_dh_auto_build:
	dh_auto_build --builddirectory=build-debian-static-experimental
	dh_auto_build --builddirectory=build-debian-static
	dh_auto_build --builddirectory=build-debian-shared-experimental
	dh_auto_build --builddirectory=build-debian-shared

override_dh_auto_install:
	dh_auto_install --builddirectory=build-debian-static-experimental --destdir=debian/tmp-experimental
	dh_auto_install --builddirectory=build-debian-static --destdir=debian/tmp
	dh_auto_install --builddirectory=build-debian-shared-experimental --destdir=debian/tmp-experimental
	dh_auto_install --builddirectory=build-debian-shared --destdir=debian/tmp

override_dh_auto_test:
	dh_auto_test --builddirectory=build-debian-static-experimental
	dh_auto_test --builddirectory=build-debian-static
	dh_auto_test --builddirectory=build-debian-shared-experimental
	dh_auto_test --builddirectory=build-debian-shared

override_dh_install:
	dh_install -plibgit2-dev -plibgit2-1.9 --sourcedir=debian/tmp
	dh_install -plibgit2-experimental-dev -plibgit2-experimental1.9 --sourcedir=debian/tmp-experimental