]> git.puffer.fish Git - matthieu/frr.git/commitdiff
build: non-recursive babeld & eigrpd
authorDavid Lamparter <equinox@opensourcerouting.org>
Fri, 4 Aug 2017 14:49:15 +0000 (16:49 +0200)
committerDavid Lamparter <equinox@opensourcerouting.org>
Fri, 4 Aug 2017 17:09:14 +0000 (19:09 +0200)
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
Makefile.am
babeld/.gitignore
babeld/Makefile [new file with mode: 0644]
babeld/Makefile.am [deleted file]
babeld/subdir.am [new file with mode: 0644]
configure.ac
eigrpd/.gitignore
eigrpd/Makefile [new file with mode: 0644]
eigrpd/Makefile.am [deleted file]
eigrpd/subdir.am [new file with mode: 0644]

index 7d607b2d53b1e69a3a8319f0e67c2126b596621b..494fcd4d5690b03560882d68366a17231a9faa89 100644 (file)
@@ -38,17 +38,19 @@ include ospfclient/subdir.am
 include isisd/subdir.am
 include nhrpd/subdir.am
 include ldpd/subdir.am
+include babeld/subdir.am
+include eigrpd/subdir.am
 
 SUBDIRS = . @LIBRFP@ @RFPTEST@ \
         @BGPD@ \
-         @PIMD@ @EIGRPD@ @BABELD@ \
+         @PIMD@ \
         @WATCHFRR@ @VTYSH@ @DOC@ \
          @SOLARIS@ tests tools
 
 DIST_SUBDIRS = . bgpd \
          watchfrr vtysh doc tests \
-         solaris pimd eigrpd bgpd/rfp-example/librfp \
-         bgpd/rfp-example/rfptest tools babeld \
+         solaris pimd bgpd/rfp-example/librfp \
+         bgpd/rfp-example/rfptest tools \
          # end
 
 if PKGSRC
index 8384763a654cd61009ff57e9e584db226c701e53..fbdb90f67785c7f994afeb2a7b0c726d49eaaab8 100644 (file)
@@ -2,6 +2,7 @@
 !*.c
 !*.h
 !LICENCE
-!Makefile.am
+!Makefile
+!subdir.am
 !babeld.conf.sample
-!.gitignore
\ No newline at end of file
+!.gitignore
diff --git a/babeld/Makefile b/babeld/Makefile
new file mode 100644 (file)
index 0000000..ae125e6
--- /dev/null
@@ -0,0 +1,10 @@
+all: ALWAYS
+       @$(MAKE) -s -C .. babeld/babeld
+%: ALWAYS
+       @$(MAKE) -s -C .. babeld/$@
+
+Makefile:
+       #nothing
+ALWAYS:
+.PHONY: ALWAYS makefiles
+.SUFFIXES:
diff --git a/babeld/Makefile.am b/babeld/Makefile.am
deleted file mode 100644 (file)
index 39f748e..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-## Process this file with automake to produce Makefile.in.
-
-AM_CPPFLAGS = -I.. -I$(top_srcdir) -I$(top_srcdir)/lib -I$(top_builddir)/lib
-DEFS = @DEFS@ -DSYSCONFDIR=\"$(sysconfdir)/\"
-INSTALL_SDATA=@INSTALL@ -m 600
-
-AM_CFLAGS = $(PICFLAGS) $(WERROR)
-AM_LDFLAGS = $(PILDFLAGS)
-
-noinst_LIBRARIES = libbabel.a
-sbin_PROGRAMS = babeld
-
-libbabel_a_SOURCES = \
-       babel_zebra.c net.c kernel.c util.c source.c neighbour.c        \
-       route.c xroute.c message.c resend.c babel_interface.c babeld.c  \
-       babel_filter.c babel_memory.c
-
-noinst_HEADERS = \
-       babel_zebra.h net.h kernel.h util.h source.h neighbour.h        \
-       route.h xroute.h message.h resend.h babel_interface.h babeld.h  \
-       babel_filter.h babel_main.h babel_memory.h
-
-babeld_SOURCES = \
-       babel_main.c $(libbabel_a_SOURCES)
-
-babeld_LDADD = ../lib/libfrr.la @LIBCAP@
-
-examplesdir = $(exampledir)
-dist_examples_DATA = babeld.conf.sample
diff --git a/babeld/subdir.am b/babeld/subdir.am
new file mode 100644 (file)
index 0000000..c44cb27
--- /dev/null
@@ -0,0 +1,47 @@
+#
+# babeld
+#
+
+if BABELD
+noinst_LIBRARIES += babeld/libbabel.a
+sbin_PROGRAMS += babeld/babeld
+dist_examples_DATA += babeld/babeld.conf.sample
+endif
+
+babeld_libbabel_a_SOURCES = \
+       babeld/babel_filter.c \
+       babeld/babel_interface.c \
+       babeld/babel_memory.c \
+       babeld/babel_zebra.c \
+       babeld/babeld.c \
+       babeld/kernel.c \
+       babeld/message.c \
+       babeld/neighbour.c \
+       babeld/net.c \
+       babeld/resend.c \
+       babeld/route.c \
+       babeld/source.c \
+       babeld/util.c \
+       babeld/xroute.c \
+       # end
+
+noinst_HEADERS += \
+       babeld/babel_filter.h \
+       babeld/babel_interface.h \
+       babeld/babel_main.h \
+       babeld/babel_memory.h \
+       babeld/babel_zebra.h \
+       babeld/babeld.h \
+       babeld/kernel.h \
+       babeld/message.h \
+       babeld/neighbour.h \
+       babeld/net.h \
+       babeld/resend.h \
+       babeld/route.h \
+       babeld/source.h \
+       babeld/util.h \
+       babeld/xroute.h \
+       # end
+
+babeld_babeld_SOURCES = babeld/babel_main.c
+babeld_babeld_LDADD = babeld/libbabel.a lib/libfrr.la @LIBCAP@
index 0cae5e58247f19c6b2103ec646d94b500b5734be..a17c7c15ed0108e02a48c4a1bbbfdcb851fe1cd0 100755 (executable)
@@ -1274,12 +1274,7 @@ case "$host_os" in
 esac
 AM_CONDITIONAL(NHRPD, test "x$NHRPD" = "xnhrpd")
 
-if test "${enable_eigrpd}" = "no";then
-  EIGRPD=""
-else
-  EIGRPD="eigrpd"
-fi
-AM_CONDITIONAL(EIGRPD, test "x$EIGRPD" = "xeigrpd")
+AM_CONDITIONAL(EIGRPD, test "${enable_eigrpd}" != "no")
 
 if test "${enable_watchfrr}" = "no";then
   WATCHFRR=""
@@ -1298,15 +1293,8 @@ if test "${enable_ospfapi}" != "no";then
 fi
 
 AM_CONDITIONAL(OSPFCLIENT, test "x$OSPFCLIENT" = "xospfclient")
-
 AM_CONDITIONAL(RIPNGD, test "${enable_ripngd}" != "no")
-
-case "${enable_babeld}" in
-  "no" ) BABELD="";;
-  *    ) BABELD="babeld";;
-esac
-AM_CONDITIONAL(BABELD, test "x$BABELD" = "xbabeld")
-
+AM_CONDITIONAL(BABELD, test "${enable_babeld}" != "no")
 AM_CONDITIONAL(OSPF6D, test "${enable_ospf6d}" != "no")
 AM_CONDITIONAL(ISISD, test "${enable_isisd}" != "no")
 
@@ -1347,9 +1335,7 @@ AC_SUBST(DOC)
 AC_SUBST(RFPTEST)
 AC_SUBST(LIBRFP)
 AC_SUBST(RFPINC)
-AC_SUBST(BABELD)
 AC_SUBST(BGPD)
-AC_SUBST(EIGRPD)
 AC_SUBST(WATCHFRR)
 AC_SUBST(ISISD)
 AC_SUBST(PIMD)
@@ -1804,9 +1790,7 @@ AC_CONFIG_FILES([Makefile
          vtysh/Makefile
          doc/Makefile tests/Makefile
          bgpd/rfp-example/rfptest/Makefile bgpd/rfp-example/librfp/Makefile
-         babeld/Makefile
          pimd/Makefile
-         eigrpd/Makefile
          tools/Makefile
          redhat/frr.spec
          snapcraft/snapcraft.yaml
index cd46e50c6c83ee3cc4d91979f1b1af95aa9b65c0..5b72399e727f7159c2c86428af808e846bf0a37d 100644 (file)
@@ -1,4 +1,4 @@
-Makefile
+!Makefile
 Makefile.in
 *.o
 *.a
diff --git a/eigrpd/Makefile b/eigrpd/Makefile
new file mode 100644 (file)
index 0000000..b6d6076
--- /dev/null
@@ -0,0 +1,10 @@
+all: ALWAYS
+       @$(MAKE) -s -C .. eigrpd/eigrpd
+%: ALWAYS
+       @$(MAKE) -s -C .. eigrpd/$@
+
+Makefile:
+       #nothing
+ALWAYS:
+.PHONY: ALWAYS makefiles
+.SUFFIXES:
diff --git a/eigrpd/Makefile.am b/eigrpd/Makefile.am
deleted file mode 100644 (file)
index 9ee792e..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-## Process this file with automake to produce Makefile.in.
-
-AM_CPPFLAGS = -I.. -I$(top_srcdir) -I$(top_srcdir)/lib -I$(top_builddir)/lib
-DEFS = @DEFS@ -DSYSCONFDIR=\"$(sysconfdir)/\"
-INSTALL_SDATA=@INSTALL@ -m 600
-
-AM_CFLAGS = $(WERROR)
-
-noinst_LIBRARIES = libeigrp.a
-sbin_PROGRAMS = eigrpd
-
-libeigrp_a_SOURCES = \
-       eigrpd.c eigrp_zebra.c \
-       eigrp_interface.c eigrp_neighbor.c \
-       eigrp_dump.c eigrp_vty.c \
-       eigrp_network.c eigrp_packet.c \
-       eigrp_topology.c eigrp_fsm.c \
-       eigrp_hello.c eigrp_update.c \
-       eigrp_query.c eigrp_reply.c \
-       eigrp_snmp.c eigrp_siaquery.c \
-       eigrp_siareply.c eigrp_filter.c \
-       eigrp_memory.c
-
-
-eigrpdheaderdir = $(pkgincludedir)/eigrpd
-
-eigrpdheader_HEADERS = \
-       eigrp_topology.h eigrp_dump.h eigrpd.h
-
-noinst_HEADERS = \
-       eigrp_const.h eigrp_structs.h \
-       eigrp_macros.h eigrp_interface.h \
-       eigrp_neighbor.h eigrp_network.h \
-       eigrp_packet.h eigrp_memory.h \
-       eigrp_zebra.h eigrp_vty.h \
-       eigrp_snmp.h eigrp_filter.h \
-       eigrp_fsm.h
-
-eigrpd_SOURCES = eigrp_main.c $(libeigrp_a_SOURCES)
-
-eigrpd_LDADD = ../lib/libfrr.la @LIBCAP@
-
-EXTRA_DIST = EIGRP-MIB.txt
-
-examplesdir = $(exampledir)
-dist_examples_DATA = eigrpd.conf.sample
diff --git a/eigrpd/subdir.am b/eigrpd/subdir.am
new file mode 100644 (file)
index 0000000..2c6b1e3
--- /dev/null
@@ -0,0 +1,59 @@
+#
+# eigrpd
+#
+
+if EIGRPD
+noinst_LIBRARIES += eigrpd/libeigrp.a
+sbin_PROGRAMS += eigrpd/eigrpd
+dist_examples_DATA += eigrpd/eigrpd.conf.sample
+endif
+
+eigrpd_libeigrp_a_SOURCES = \
+       eigrpd/eigrp_dump.c \
+       eigrpd/eigrp_filter.c \
+       eigrpd/eigrp_fsm.c \
+       eigrpd/eigrp_hello.c \
+       eigrpd/eigrp_interface.c \
+       eigrpd/eigrp_memory.c \
+       eigrpd/eigrp_neighbor.c \
+       eigrpd/eigrp_network.c \
+       eigrpd/eigrp_packet.c \
+       eigrpd/eigrp_query.c \
+       eigrpd/eigrp_reply.c \
+       eigrpd/eigrp_siaquery.c \
+       eigrpd/eigrp_siareply.c \
+       eigrpd/eigrp_snmp.c \
+       eigrpd/eigrp_topology.c \
+       eigrpd/eigrp_update.c \
+       eigrpd/eigrp_vty.c \
+       eigrpd/eigrp_zebra.c \
+       eigrpd/eigrpd.c \
+       # end
+
+eigrpdheaderdir = $(pkgincludedir)/eigrpd
+eigrpdheader_HEADERS = \
+       eigrpd/eigrp_dump.h \
+       eigrpd/eigrp_topology.h \
+       eigrpd/eigrpd.h \
+       # end
+
+noinst_HEADERS += \
+       eigrpd/eigrp_const.h \
+       eigrpd/eigrp_filter.h \
+       eigrpd/eigrp_fsm.h \
+       eigrpd/eigrp_interface.h \
+       eigrpd/eigrp_macros.h \
+       eigrpd/eigrp_memory.h \
+       eigrpd/eigrp_neighbor.h \
+       eigrpd/eigrp_network.h \
+       eigrpd/eigrp_packet.h \
+       eigrpd/eigrp_snmp.h \
+       eigrpd/eigrp_structs.h \
+       eigrpd/eigrp_vty.h \
+       eigrpd/eigrp_zebra.h \
+       # end
+
+eigrpd_eigrpd_SOURCES = eigrpd/eigrp_main.c
+eigrpd_eigrpd_LDADD = eigrpd/libeigrp.a lib/libfrr.la @LIBCAP@
+
+EXTRA_DIST += eigrpd/EIGRP-MIB.txt