aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoão Valverde <joao.valverde@tecnico.ulisboa.pt>2017-10-18 11:54:15 +0100
committerJoão Valverde <j@v6e.pt>2017-10-18 12:55:23 +0000
commit2575a2e9a8928025a28d6873094c22c867ad5ab5 (patch)
tree4339f59c39cebbf20ec5831d1a71a039f53cfb6d
parentdfa893b1cfd8491a3563ad2c29a0dfaf44d960cf (diff)
autotools: Sort out how we handle register.c
register.c is a built source. It should not be included in the distribution and should be removed with the distclean target. Remove XXX comment suggesting adding the cache to the distribution; let's not do that. Change-Id: I20f9467a93e2b5ad3ee56a5fa83381095b1d28c6 Reviewed-on: https://code.wireshark.org/review/23971 Petri-Dish: João Valverde <j@v6e.pt> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: João Valverde <j@v6e.pt>
-rw-r--r--epan/dissectors/Makefile.am49
1 files changed, 14 insertions, 35 deletions
diff --git a/epan/dissectors/Makefile.am b/epan/dissectors/Makefile.am
index 110fce9ad8..4b503353e5 100644
--- a/epan/dissectors/Makefile.am
+++ b/epan/dissectors/Makefile.am
@@ -27,22 +27,20 @@ AM_CPPFLAGS = $(INCLUDEDIRS) -I$(top_srcdir)/epan $(WS_CPPFLAGS) \
include Custom.common
# "BUILT_SOURCES" are built before any "make all" or "make check" targets.
-BUILT_C_FILES = \
+BUILT_SOURCES = \
register.c
-BUILT_SOURCES = $(BUILT_C_FILES) $(BUILT_HEADER_FILES)
-
# Header files generated from source files.
-GENERATED_HEADER_FILES = \
- $(BUILT_HEADER_FILES)
+NO_DIST_GENERATED_HEADER_FILES =
# C source files generated from source files.
-GENERATED_C_FILES = \
- $(BUILT_C_FILES) \
- packet-ncp2222.c
+NO_DIST_GENERATED_C_FILES = \
+ register.c
# All the generated files.
-GENERATED_FILES = $(GENERATED_HEADER_FILES) $(GENERATED_C_FILES)
+NO_DIST_GENERATED_FILES = \
+ $(NO_DIST_GENERATED_HEADER_FILES) \
+ $(NO_DIST_GENERATED_C_FILES)
#
# PIDL-generated DCE RPC dissectors without warnings.
@@ -1847,7 +1845,6 @@ DISSECTOR_INCLUDES = \
packet-ziop.h \
read_keytab_file.h \
snort-config.h \
- $(GENERATED_HEADER_FILES) \
$(CUSTOM_HEADER_FILES)
# Dissector helpers. They're included in the source files in this
@@ -1857,8 +1854,7 @@ DISSECTOR_SUPPORT_SRC = \
errno.c \
packet-dcerpc-nt.c \
snort-config.c \
- usb.c \
- register.c
+ usb.c
ALL_DISSECTORS_SRC = \
$(DISSECTOR_SRC) \
@@ -1887,6 +1883,9 @@ libdissectors_la_SOURCES = \
$(PIDL_DISSECTOR_SRC) \
$(DISSECTOR_SUPPORT_SRC)
+nodist_libdissectors_la_SOURCES = \
+ $(NO_DIST_GENERATED_C_FILES)
+
subpkgincludedir = $(pkgincludedir)/epan/dissectors
subpkginclude_HEADERS = \
@@ -1953,26 +1952,7 @@ register.c: $(plugin_src) $(ALL_DISSECTORS_SRC) Custom.common \
@echo Making register.c ; \
$(PYTHON) $(top_srcdir)/tools/make-dissector-reg.py $(srcdir) \
dissectors $(ALL_DISSECTORS_SRC) ;
-#
-# Currently register.c can be included in the distribution because
-# we always build all protocol dissectors. We used to have to check
-# whether or not to build the snmp dissector. If we again need to
-# variably build something, making register.c non-portable, uncomment
-# the dist-hook line below.
-#
-# Oh, yuk. We don't want to include "register.c" in the distribution, as
-# its contents depend on the configuration, and therefore we want it
-# to be built when the first "make" is done; however, Automake insists
-# on putting *all* source into the distribution.
-#
-# We work around this by having a "dist-hook" rule that deletes
-# "register.c", so that "dist" won't pick it up.
-#
-#dist-hook:
-# @rm -f $(distdir)/register.c
-# XXX - We may want to add register-cache.pkl to the distribution at
-# some point. It should be portable across architectures.
CLEANFILES = \
libdissectors.a \
libdissectors.la \
@@ -1980,14 +1960,13 @@ CLEANFILES = \
libdirtydissectors.la \
register.c-tmp \
register-cache.pkl \
- $(GENERATED_HEADER_FILES) \
*~
DISTCLEANFILES = \
- register.c
+ $(NO_DIST_GENERATED_FILES)
-MAINTAINERCLEANFILES = \
- $(GENERATED_FILES)
+MAINTAINERCLEANFILES = \
+ packet-ncp2222.c
checkapi:
$(PERL) $(top_srcdir)/tools/checkAPIs.pl -g abort -g termoutput -build \