4 export DEB_BUILD_HARDENING
=1
9 $(warning
"DEBIAN: SNMP enabled, sorry for your inconvenience")
11 $(warning
"DEBIAN: SNMP disabled, see README.Debian")
14 ifneq (,$(filter parallel
=%,$(DEB_BUILD_OPTIONS
)))
15 DEBIAN_JOBS
:= $(subst parallel
=,,$(filter parallel
=%,$(DEB_BUILD_OPTIONS
)))
19 MAKEFLAGS
+= -j
$(DEBIAN_JOBS
)
23 dh
$@
--with
=autoreconf
--parallel
--dbg-package
=frr-dbg
--list-missing
25 override_dh_auto_configure
:
26 # Frr needs /proc to check some BSD vs Linux specific stuff.
27 # Else it fails with an obscure error message pointing out that
28 # IPCTL_FORWARDING is an undefined symbol which is not very helpful.
29 @if
! [ -d
/proc
/1 ]; then \
30 echo
"./configure needs a mounted /proc"; \
34 if
! [ -e config.status
]; then \
35 dh_auto_configure
-- \
36 --enable-exampledir
=/usr
/share
/doc
/frr
/examples
/ \
37 --localstatedir
=/var
/run
/frr \
38 --sbindir
=/usr
/lib
/frr \
39 --sysconfdir
=/etc
/frr \
41 --enable-ospfapi
=yes \
44 --enable-multipath
=256 \
47 --enable-vty-group
=frrvty \
48 --enable-configfile-mask
=0640 \
49 --enable-logfile-mask
=0640 \
51 --enable-gcc-rdynamic \
55 --enable-cumulus
=yes \
57 --enable-dependency-tracking \
58 --disable-rr-semantics
; \
61 override_dh_auto_build
:
64 dh_auto_build
-- -C doc draft-zebra-00.txt
68 ifeq ($(GENERATE_PDF
), 1)
69 dh_auto_build
-- -C doc frr.pdf || true
# pdfetex fails with exit code 1 but still produces a good looking .pdf
72 dh_auto_build
-- -C doc frr.
info
73 rm -vf doc
/frr.
info.html
*
75 override_dh_auto_test
:
77 override_dh_auto_install
:
80 # cleaning up the info dir
81 rm -f debian
/tmp
/usr
/share
/info/dir*
83 # install config files
84 mkdir
-p debian
/tmp
/etc
/frr
/
85 perl
-pi
-e
's#^!log file #!log file /var/log/frr/#' debian
/tmp
/usr
/share
/doc
/frr
/examples
/*sample
*
87 # installing the Frr specific SNMP MIB
88 install -D
-m
644 .
/zebra
/GNOME-PRODUCT-ZEBRA-MIB debian
/tmp
/usr
/share
/snmp
/mibs
/GNOME-PRODUCT-ZEBRA-MIB
91 sed
-i
"/dependency_libs/ s/'.*'/''/" debian
/tmp
/usr
/lib
/*.la