]> git.puffer.fish Git - matthieu/frr.git/commitdiff
build: clean up BUILT_SOURCES
authorDavid Lamparter <equinox@opensourcerouting.org>
Fri, 4 Aug 2017 08:36:34 +0000 (10:36 +0200)
committerDavid Lamparter <equinox@opensourcerouting.org>
Fri, 4 Aug 2017 09:13:55 +0000 (11:13 +0200)
BUILT_SOURCES doesn't do what the name suggests.  What it actually means
is "these files should be built first when doing a 'make' without
explicit target" (or "make all").

It's pretty much almost always wrong to use BUILT_SOURCES, the only
correct use is when a file is needed by an unspecified / large set of
files.

Also remove version.h and route_types.h from dist tarball while we're at
it.  configure will create them anyway.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
Makefile.am
doc/Makefile.am
fpm/subdir.am
lib/subdir.am
qpb/subdir.am
tests/Makefile.am

index bd421c9dde6bab950a90aff70fd40c43d4ca5991..72689c28f7657adc2e649251f04973361121b588 100644 (file)
@@ -22,6 +22,7 @@ noinst_LIBRARIES =
 lib_LTLIBRARIES =
 module_LTLIBRARIES =
 pkginclude_HEADERS =
+nodist_pkginclude_HEADERS =
 dist_examples_DATA =
 
 include lib/subdir.am
index b2bdf91cd422f35f809b0cb85c7a66ca7351940f..47e87c7b9c645d1db9cfec09affb35a686810934 100644 (file)
@@ -45,18 +45,20 @@ figures_txt = $(figures_names_parts:%=fig%.txt)
 # provided by automake. If you are an automake wizard, please feel free to
 # compact it somehow.
 
-# Built from defines.texi.in
-BUILT_SOURCES = defines.texi
-
 info_TEXINFOS = frr.texi
 
 # Have to manually specify the frr.pdf rule in order to allow
 # us to have a generic automatic .pdf rule to build the figure sources
 # because it cant just work from the png's directly it seems - contrary
 # to the documentation...
-frr.pdf: $(info_TEXINFOS) $(figures_pdf) $(frr_TEXINFOS)
+frr.pdf: $(info_TEXINFOS) $(figures_pdf) $(frr_TEXINFOS) defines.texi
        $(TEXI2PDF) -o "$@" $< || true
 
+# don't ask me why the info file is in srcdir
+$(srcdir)/frr.info: defines.texi
+frr.dvi: defines.texi
+frr.html: defines.texi
+
 frr_TEXINFOS = appendix.texi basic.texi bgpd.texi isisd.texi filter.texi \
        vnc.texi \
        babeld.texi \
@@ -65,7 +67,7 @@ frr_TEXINFOS = appendix.texi basic.texi bgpd.texi isisd.texi filter.texi \
        eigrpd.texi \
        ospf6d.texi ospfd.texi \
        overview.texi protocol.texi ripd.texi ripngd.texi routemap.texi \
-       snmp.texi vtysh.texi routeserver.texi defines.texi $(figures_png) \
+       snmp.texi vtysh.texi routeserver.texi $(figures_png) \
        snmptrap.texi ospf_fundamentals.texi isisd.texi $(figures_txt)
 
 .png.eps:
index f81a84222cd80f61aeb8f46323be3f8771881708..795535596b6fd0a6ec5f4c06a6808059bc73f724 100644 (file)
@@ -13,7 +13,6 @@ fpm_libfrrfpm_pb_la_SOURCES = \
 
 if HAVE_PROTOBUF
 nodist_fpm_libfrrfpm_pb_la_SOURCES = fpm/fpm.pb-c.c
-BUILT_SOURCES += fpm/fpm.pb-c.c
 CLEANFILES += \
        fpm/fpm.pb-c.c \
        fpm/fpm.pb-c.h \
index 86fe09ca649a2edc326832178e1b889b35d1716c..682ae45cb443d815675cf927f4fcf0ad6b6ae87b 100644 (file)
@@ -124,7 +124,6 @@ pkginclude_HEADERS += \
        lib/privs.h \
        lib/ptm_lib.h \
        lib/qobj.h \
-       lib/route_types.h \
        lib/routemap.h \
        lib/sbuf.h \
        lib/sha256.h \
@@ -141,7 +140,6 @@ pkginclude_HEADERS += \
        lib/termtable.h \
        lib/thread.h \
        lib/vector.h \
-       lib/version.h \
        lib/vlan.h \
        lib/vrf.h \
        lib/vrf_int.h \
@@ -154,6 +152,11 @@ pkginclude_HEADERS += \
        lib/zebra.h \
        # end
 
+nodist_pkginclude_HEADERS += \
+       lib/route_types.h \
+       lib/version.h \
+       # end
+
 noinst_HEADERS += \
        lib/clippy.h \
        lib/log_int.h \
@@ -216,6 +219,7 @@ lib_clippy_SOURCES = \
 #
 EXTRA_DIST += \
        lib/command_lex.h \
+       lib/command_parse.h \
        lib/gitversion.pl \
        lib/queue.h \
        lib/route_types.pl \
@@ -223,8 +227,6 @@ EXTRA_DIST += \
        # end
 
 BUILT_SOURCES += \
-       lib/command_lex.h \
-       lib/command_parse.h \
        lib/gitversion.h \
        lib/route_types.h \
        # end
index 71e501b9c29a0491f99a233e32a65f37deeda2ec..3c006fd221b5fddc1eef351a6dd9263af492fe3b 100644 (file)
@@ -16,7 +16,6 @@ qpb_libfrr_pb_la_SOURCES = \
 if HAVE_PROTOBUF
 qpb_libfrr_pb_la_SOURCES += qpb/qpb_allocator.c
 nodist_qpb_libfrr_pb_la_SOURCES = qpb/qpb.pb-c.c
-BUILT_SOURCES += qpb/qpb.pb-c.c
 CLEANFILES += \
        qpb/qpb.pb-c.c \
        qpb/qpb.pb-c.h \
index 0c31c0441ad96a9a31626b567b7811d397312251..59ea3c4c6998a0b0bcf2008dd124ee208ef45a18 100644 (file)
@@ -85,9 +85,7 @@ lib/cli/test_commands_defun.c: ../vtysh/vtysh_cmd.c
 
 isisd/test_fuzz_isis_tlv_tests.h: $(top_srcdir)/tests/isisd/test_fuzz_isis_tlv_tests.h.gz
        gzip -d < $(top_srcdir)/tests/isisd/test_fuzz_isis_tlv_tests.h.gz > "$@"
-
-BUILT_SOURCES = \
-       lib/cli/test_commands_defun.c \
+isisd/isisd_test_fuzz_isis_tlv-test_fuzz_isis_tlv.$(OBJEXT): \
        isisd/test_fuzz_isis_tlv_tests.h
 
 noinst_HEADERS = \