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
15 WANT_CUMULUS_MODE ?
= 0
18 WANT_CUMULUS_NODE ?
= 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
32 ####################################
35 export DEB_BUILD_MAINT_OPTIONS
= hardening
=+all
38 ifeq ($(WANT_SNMP
), 1)
39 USE_SNMP
=--enable-snmp
40 $(warning
"DEBIAN: SNMP enabled, sorry for your inconvenience")
42 USE_SNMP
=--disable-snmp
43 $(warning
"DEBIAN: SNMP disabled, see README.Debian")
49 USE_LDP
=--disable-ldpd
55 USE_PIM
=--disable-pimd
58 ifeq ($(WANT_OSPFAPI
), 1)
59 USE_OSPFAPI
=--enable-ospfapi
=yes
61 USE_OSPFAPI
=--enable-ospfapi
=no
64 ifeq ($(WANT_TCP_ZEBRA
),1)
65 USE_TCP_ZEBRA
=--enable-tcp-zebra
67 USE_TCP_ZEBRA
=--disable-tcp-zebra
70 ifeq ($(WANT_BGP_VNC
), 1)
71 USE_BGP_VNC
=--enable-bgp-vnc
=yes
73 USE_BGP_VNC
=--enable-bgp-vnc
=no
76 USE_FRR_USER
=--enable-user
=$(WANT_FRR_USER
)
77 USE_FRR_GROUP
=--enable-group
=$(WANT_FRR_USER
)
78 USE_FRR_VTY_GROUP
=--enable-vty-group
=$(WANT_FRR_VTY_GROUP
)
80 ifeq ($(WANT_MULTIPATH
), 1)
81 USE_MULTIPATH
=--enable-multipath
=$(MULTIPATH
)
83 USE_MULTIPATH
=--disable-multipath
86 ifeq ($(WANT_CUMULUS_NODE
), 1)
87 USE_CUMULUS
=--enable-cumulus
=yes
89 USE_CUMULUS
=--enable-cumulus
=no
92 ifneq (,$(filter parallel
=%,$(DEB_BUILD_OPTIONS
)))
93 DEBIAN_JOBS
:= $(subst parallel
=,,$(filter parallel
=%,$(DEB_BUILD_OPTIONS
)))
97 MAKEFLAGS
+= -j
$(DEBIAN_JOBS
)
101 dh
$@
--with
=autoreconf
--parallel
--dbg-package
=frr-dbg
--list-missing
103 override_dh_auto_configure
:
104 # Frr needs /proc to check some BSD vs Linux specific stuff.
105 # Else it fails with an obscure error message pointing out that
106 # IPCTL_FORWARDING is an undefined symbol which is not very helpful.
107 @if
! [ -d
/proc
/1 ]; then \
108 echo
"./configure needs a mounted /proc"; \
112 if
! [ -e config.status
]; then \
113 dh_auto_configure
-- \
114 --enable-exampledir
=/usr
/share
/doc
/frr
/examples
/ \
115 --localstatedir
=/var
/run
/frr \
116 --sbindir
=/usr
/lib
/frr \
117 --sysconfdir
=/etc
/frr \
124 $(USE_FRR_USER
) $(USE_FRR_GROUP
) \
125 $(USE_FRR_VTY_GROUP
) \
126 --enable-configfile-mask
=0640 \
127 --enable-logfile-mask
=0640 \
129 --enable-systemd
=no \
133 --enable-dependency-tracking \
135 $(shell dpkg-buildflags
--export=configure
); \
138 override_dh_auto_build
:
141 dh_auto_build
-- -C doc draft-zebra-00.txt
144 # doc/ is a bit crazy
145 ifeq ($(GENERATE_PDF
), 1)
146 dh_auto_build
-- -C doc frr.pdf || true
# pdfetex fails with exit code 1 but still produces a good looking .pdf
149 dh_auto_build
-- -C doc frr.
info
150 rm -vf doc
/frr.
info.html
*
152 override_dh_auto_test
:
154 override_dh_auto_install
:
157 # installed in frr-pythontools
158 rm debian
/tmp
/usr
/lib
/frr
/frr-reload.py
160 # cleaning up the info dir
161 rm -f debian
/tmp
/usr
/share
/info/dir*
163 # install config files
164 mkdir
-p debian
/tmp
/etc
/frr
/
165 perl
-pi
-e
's#^!log file #!log file /var/log/frr/#' debian
/tmp
/usr
/share
/doc
/frr
/examples
/*sample
*
167 # installing the Frr specific SNMP MIB
168 ifeq ($(WANT_SNMP
), 1)
169 install -D
-m
644 .
/zebra
/GNOME-PRODUCT-ZEBRA-MIB debian
/tmp
/usr
/share
/snmp
/mibs
/GNOME-PRODUCT-ZEBRA-MIB
171 mkdir
-p debian
/tmp
/usr
/share
/snmp
/mibs
175 sed
-i
"/dependency_libs/ s/'.*'/''/" debian
/tmp
/usr
/lib
/*.la
176 sed
-i
"/dependency_libs/ s/'.*'/''/" debian
/tmp
/usr
/lib
/frr
/modules
/*.la