File: rules

package info (click to toggle)
freeradius 3.0.17+dfsg-1.1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, sid
  • size: 20,080 kB
  • sloc: ansic: 110,697; sh: 5,096; perl: 2,653; sql: 1,352; python: 1,267; makefile: 429; xml: 62; tcl: 35; sed: 23; ruby: 22
file content (88 lines) | stat: -rwxr-xr-x 2,912 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
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
#!/usr/bin/make -f
# -*- makefile -*-

export DH_VERBOSE=1
export DEB_BUILD_MAINT_OPTIONS = hardening=+all

ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
       NUMJOBS = $(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
       MAKEFLAGS += -j$(NUMJOBS)
endif

override_dh_auto_clean:
	[ ! -f Make.inc ] || dh_auto_clean

override_dh_auto_build:
	# dh_auto_install does both, compilation and installation.

override_dh_auto_install:
	VERBOSE=1 $(MAKE) install R=debian/tmp PACKAGE='debian'

override_dh_auto_test:
	# TODO: enable testing

override_dh_install:
	mv debian/tmp/usr/sbin/radiusd debian/tmp/usr/sbin/freeradius
	mv debian/tmp/usr/share/man/man8/radiusd.8 debian/tmp/usr/share/man/man8/freeradius.8
	# Not installed as we do not install the dhcpclient binary as per
	# https://github.com/FreeRADIUS/freeradius-server/issues/1734#issuecomment-247848277
	rm debian/tmp/usr/share/man/man1/dhcpclient.1
	# Remove all libtool .la files, as per
	# https://wiki.debian.org/ReleaseGoals/LAFileRemoval
	find debian/tmp/usr/lib/freeradius -name "*.la" -delete
	# Remove all plugin .a files (unnecessary), keep libfreeradius .a files
	# for end-users who want to statically link against libfreeradius.
	find debian/tmp/usr/lib/freeradius -name "*.a" -and \! -name "libfreeradius-*.a" -delete
	# We create the {mods,sites}-enabled links in freeradius-config.postinst
	# so that they are not re-created when users upgrade to a newer version.
	rm debian/tmp/etc/freeradius/3.0/mods-enabled/*
	rm debian/tmp/etc/freeradius/3.0/sites-enabled/*
	dh_install

override_dh_missing:
	# Use --fail-missing so that new files e.g. in usr/lib/freeradius/rlm_*
	# can be detected and added to debian/freeradius.install. We cannot use
	# globbing because some files are split into more specific packages,
	# e.g. freeradius-mysql.
	dh_missing --fail-missing

override_dh_installpam:
	dh_installpam --name=radiusd

override_dh_installinit:
	dh_installinit --noscripts

override_dh_compress:
	dh_compress -Xexamples

override_dh_installdocs:
	dh_installdocs -Xdebian/tmp/usr/share/doc/freeradius/ChangeLog

override_dh_strip:
	dh_strip --dbgsym-migration='freeradius-dbg (<< 3.0.11-1~)'

override_dh_gencontrol:
	dh_gencontrol -- $(SUBSTVARS)

override_dh_auto_configure:
	dh_auto_configure -- $(confflags) \
		--config-cache \
		--disable-developer \
		--disable-openssl-version-check \
		--exec-prefix=/usr \
		--libdir=/usr/lib/freeradius \
		--datadir=/usr/share \
		--with-raddbdir=/etc/freeradius/3.0 \
		--with-logdir=/var/log/freeradius \
		--with-large-files \
		--with-udpfromto \
		--without-rlm_eap_tnc \
		--with-rlm_sql_postgresql_lib_dir=`pg_config --libdir` \
		--with-rlm_sql_postgresql_include_dir=`pg_config --includedir` \
		--with-iodbc-include-dir='/usr/include/iodbc' \
		--without-rlm_eap_ikev2 \
		--without-rlm_sql_oracle \
		--without-rlm_sql_unixodbc

%:
	dh $@ --with autoreconf