3 # FRRouting Configuration options
4 ######################################
6 # WANT_xxxx --> Set to 1 for enable, 0 for disable
7 # The following are the defaults. They can be overridden by setting a
8 # env variable to a different value
14 WANT_CUMULUS_MODE ?
= 0
20 # If multipath is enabled (WANT_MULTIPATH=1), then set number of multipaths here
21 # Please be aware that 0 is NOT disabled, but treated as unlimited
25 # Set the following to the value required (or leave alone for the default below)
26 # WANT_FRR_USER is used for the username and groupname of the FRR user account
29 WANT_FRR_VTY_GROUP ?
= frrvty
31 # Don't build PDF docs by default
35 ####################################
38 export DEB_BUILD_MAINT_OPTIONS
= hardening
=+all
41 ifeq ($(WANT_SNMP
), 1)
42 USE_SNMP
=--enable-snmp
43 $(warning
"DEBIAN: SNMP enabled, sorry for your inconvenience")
45 USE_SNMP
=--disable-snmp
46 $(warning
"DEBIAN: SNMP disabled, see README.Debian")
52 USE_LDP
=--disable-ldpd
58 USE_PIM
=--disable-pimd
61 ifeq ($(WANT_OSPFAPI
), 1)
62 USE_OSPFAPI
=--enable-ospfapi
=yes
64 USE_OSPFAPI
=--enable-ospfapi
=no
67 ifeq ($(WANT_BGP_VNC
), 1)
68 USE_BGP_VNC
=--enable-bgp-vnc
=yes
70 USE_BGP_VNC
=--enable-bgp-vnc
=no
73 USE_FRR_USER
=--enable-user
=$(WANT_FRR_USER
)
74 USE_FRR_GROUP
=--enable-group
=$(WANT_FRR_USER
)
75 USE_FRR_VTY_GROUP
=--enable-vty-group
=$(WANT_FRR_VTY_GROUP
)
77 ifeq ($(WANT_MULTIPATH
), 1)
78 USE_MULTIPATH
=--enable-multipath
=$(MULTIPATH
)
80 USE_MULTIPATH
=--disable-multipath
83 ifeq ($(WANT_CUMULUS_MODE
), 1)
84 USE_CUMULUS
=--enable-cumulus
=yes
86 USE_CUMULUS
=--enable-cumulus
=no
89 ifneq (,$(filter parallel
=%,$(DEB_BUILD_OPTIONS
)))
90 DEBIAN_JOBS
:= $(subst parallel
=,,$(filter parallel
=%,$(DEB_BUILD_OPTIONS
)))
94 MAKEFLAGS
+= -j
$(DEBIAN_JOBS
)
98 dh
$@
--with
=autoreconf
--parallel
--dbg-package
=frr-dbg
--list-missing
100 override_dh_auto_configure
:
101 # Frr needs /proc to check some BSD vs Linux specific stuff.
102 # Else it fails with an obscure error message pointing out that
103 # IPCTL_FORWARDING is an undefined symbol which is not very helpful.
104 @if
! [ -d
/proc
/1 ]; then \
105 echo
"./configure needs a mounted /proc"; \
109 if
! [ -e config.status
]; then \
110 dh_auto_configure
-- \
111 --enable-exampledir
=/usr
/share
/doc
/frr
/examples
/ \
112 --localstatedir
=/var
/run
/frr \
113 --sbindir
=/usr
/lib
/frr \
114 --sysconfdir
=/etc
/frr \
120 $(USE_FRR_USER
) $(USE_FRR_GROUP
) \
121 $(USE_FRR_VTY_GROUP
) \
122 --enable-configfile-mask
=0640 \
123 --enable-logfile-mask
=0640 \
125 --enable-systemd
=no \
130 --enable-dependency-tracking \
132 $(shell dpkg-buildflags
--export=configure
); \
135 override_dh_auto_build
:
136 ifeq ($(GENERATE_PDF
), 1)
137 dh_auto_build
-- -C doc pdf
139 rm -vf doc
/user
/_build
/texinfo
/frr.
info
140 dh_auto_build
-- -C doc
info
142 override_dh_auto_test
:
144 override_dh_auto_install
:
147 # installed in frr-pythontools
148 rm debian
/tmp
/usr
/lib
/frr
/frr-reload.py
150 # cleaning up the info dir
151 rm -f debian
/tmp
/usr
/share
/info/dir*
153 # install config files
154 mkdir
-p debian
/tmp
/etc
/frr
/
155 perl
-pi
-e
's#^!log file #!log file /var/log/frr/#' debian
/tmp
/usr
/share
/doc
/frr
/examples
/*sample
*
157 # leftover from previously shipping SMUX client OID MIB
158 mkdir
-p debian
/tmp
/usr
/share
/snmp
/mibs
161 sed
-i
"/dependency_libs/ s/'.*'/''/" debian
/tmp
/usr
/lib
/*.la
162 sed
-i
"/dependency_libs/ s/'.*'/''/" debian
/tmp
/usr
/lib
/frr
/modules
/*.la