Autotools: Build rawshark.
[metze/wireshark/wip.git] / Makefile.am
index af05c5ddb24458c60a6949b389533bab779be436..330e6612344913f83306ea90c1c209de0e7c2773 100644 (file)
@@ -32,31 +32,34 @@ COMMONCPPFLAGS =
 AM_CPPFLAGS = $(INCLUDEDIRS) $(WS_CPPFLAGS) $(COMMONCPPFLAGS)
 
 bin_PROGRAMS = \
-       @wireshark_bin@         \
-       @tshark_bin@            \
-       @tfshark_bin@           \
-       @text2pcap_bin@         \
-       @mergecap_bin@          \
        @capinfos_bin@          \
        @captype_bin@           \
+       @dumpcap_bin@           \
        @editcap_bin@           \
+       @mergecap_bin@          \
+       @mmdbresolve_bin@       \
        @randpkt_bin@           \
-       @dftest_bin@            \
-       @dumpcap_bin@           \
-       @reordercap_bin@        \
        @rawshark_bin@          \
+       @reordercap_bin@        \
        @sharkd_bin@            \
+       @text2pcap_bin@         \
+       @tfshark_bin@           \
+       @tshark_bin@            \
+       @wireshark_bin@
+
+noinst_PROGRAMS = \
+       @dftest_bin@            \
        @fuzzshark_bin@
 
 EXTRA_PROGRAMS = wireshark-gtk wireshark tshark tfshark capinfos captype \
        editcap mergecap dftest randpkt text2pcap dumpcap reordercap \
-       rawshark sharkd fuzzshark
+       mmdbresolve rawshark sharkd fuzzshark
 
 #
 # Wireshark configuration files are put in $(pkgdatadir).
 #
 dist_pkgdata_DATA = COPYING manuf services cfilters colorfilters dfilters \
-       smi_modules ipmap.html pdml2html.xsl enterprises.tsv wka
+       smi_modules pdml2html.xsl enterprises.tsv wka
 
 pkgconfigdir = $(libdir)/pkgconfig
 pkgconfig_DATA = wireshark.pc
@@ -371,16 +374,14 @@ GENERATED_C_FILES =
 # All the generated files.
 GENERATED_FILES = $(GENERATED_C_FILES) $(GENERATED_HEADER_FILES)
 
-EXTCAP_COMMON_SRC = \
-       extcap.c                \
-       extcap_parser.c         \
-       extcap_spawn.c
-
 # sources common for wireshark, tshark, and rawshark
 SHARK_COMMON_SRC = \
        cfile.c                 \
+       file_packet_provider.c  \
        frame_tvbuff.c          \
-       sync_pipe_write.c
+       sync_pipe_write.c       \
+       extcap.c                \
+       extcap_parser.c
 
 # wireshark specifics
 WIRESHARK_COMMON_SRC = \
@@ -389,13 +390,8 @@ WIRESHARK_COMMON_SRC = \
        capture_opts.c          \
        file.c                  \
        fileset.c               \
-       summary.c               \
        version_info.c
 
-if HAVE_EXTCAP
-SHARK_COMMON_SRC += $(EXTCAP_COMMON_SRC)
-endif
-
 EPAN_EXTRA_LIBS = \
        @C_ARES_LIBS@                   \
        @KRB5_LIBS@                     \
@@ -417,7 +413,6 @@ wireshark_common_ldadd = \
        wiretap/libwiretap.la           \
        epan/libwireshark.la            \
        wsutil/libwsutil.la             \
-       $(plugin_ldadd)                 \
        @PCAP_LIBS@                     \
        $(EPAN_EXTRA_LIBS)              \
        @LIBNL_LIBS@
@@ -426,6 +421,10 @@ if HAVE_Qt
 wireshark_SOURCES = $(WIRESHARK_COMMON_SRC) wireshark-qt.cpp
 
 wireshark_CPPFLAGS = $(AM_CPPFLAGS) $(GLIB_CFLAGS) $(Qt_CFLAGS)
+# Define compatibility macros for Qt 4.8
+if HAVE_QT_VERSION_4
+wireshark_CPPFLAGS += -DQ_NULLPTR=NULL
+endif
 
 wireshark_LDFLAGS = $(AM_LDFLAGS) $(Qt_LDFLAGS)
 
@@ -489,7 +488,6 @@ tshark_LDADD = \
        wiretap/libwiretap.la           \
        epan/libwireshark.la            \
        wsutil/libwsutil.la             \
-       $(plugin_ldadd)                 \
        @GLIB_LIBS@                     \
        @PCAP_LIBS@                     \
        ${EPAN_EXTRA_LIBS}
@@ -510,7 +508,6 @@ tfshark_LDADD = \
        wiretap/libwiretap.la           \
        epan/libwireshark.la            \
        wsutil/libwsutil.la             \
-       $(plugin_ldadd)                 \
        @GLIB_LIBS@                     \
        @PCAP_LIBS@                     \
        ${EPAN_EXTRA_LIBS}
@@ -531,11 +528,15 @@ rawshark_LDADD = \
        wiretap/libwiretap.la           \
        epan/libwireshark.la            \
        wsutil/libwsutil.la             \
-       $(plugin_ldadd)                 \
        @GLIB_LIBS@                     \
        @PCAP_LIBS@                     \
        ${EPAN_EXTRA_LIBS}
 
+mmdbresolve_SOURCES = mmdbresolve.c
+mmdbresolve_CPPFLAGS = $(AM_CPPFLAGS)
+mmdbresolve_LDFLAGS = $(AM_LDFLAGS)
+mmdbresolve_LDADD = @MAXMINDDB_LIBS@
+
 sharkd_SOURCES = \
        $(SHARK_COMMON_SRC)     \
        sharkd.c                \
@@ -560,7 +561,6 @@ sharkd_LDADD = \
        wiretap/libwiretap.la           \
        epan/libwireshark.la            \
        wsutil/libwsutil.la             \
-       $(plugin_ldadd)                 \
        @GLIB_LIBS@                     \
        @PCAP_LIBS@                     \
        ${EPAN_EXTRA_LIBS}
@@ -576,11 +576,7 @@ text2pcap_SOURCES = \
 
 text2pcap_CPPFLAGS = $(AM_CPPFLAGS) $(GLIB_CFLAGS)
 
-# Don't turn on -Werror for text2pcap: its source includes text2pcap-scanner.c
-# which is generated (and therefore not always clean).
-# We could generate text2pcap.o as a library with -Werror but for now it
-# doesn't seem worth the effort.
-text2pcap_CFLAGS = $(GENERATED_CFLAGS)
+text2pcap_CFLAGS = $(AM_CFLAGS)
 
 # Libraries with which to link text2pcap.
 text2pcap_LDADD = \
@@ -682,7 +678,6 @@ dftest_LDADD = \
        wiretap/libwiretap.la           \
        wsutil/libwsutil.la             \
        epan/libwireshark.la            \
-       $(plugin_ldadd)                 \
        @GLIB_LIBS@                     \
        @PCAP_LIBS@                     \
        ${EPAN_EXTRA_LIBS}
@@ -725,17 +720,16 @@ pkginclude_HEADERS = \
 
 # this target needed for distribution only
 noinst_HEADERS = \
+       tools/oss-fuzzshark/FuzzerInterface.h \
        capture_info.h          \
        capture_opts.h          \
        capture_stop_conditions.h       \
        conditions.h            \
        extcap.h                \
        extcap_parser.h         \
-       extcap_spawn.h          \
        fileset.h               \
        frame_tvbuff.h          \
        ringbuffer.h            \
-       summary.h               \
        sync_pipe.h             \
        version_info.h
 
@@ -797,7 +791,6 @@ EXTRA_DIST = \
        fix                     \
        idl                     \
        image                   \
-       ipmap.html              \
        m4                      \
        macosx-support-lib-patches      \
        make-version.pl         \
@@ -842,9 +835,7 @@ plugins_subdir = plugins
 endif
 endif
 
-if HAVE_EXTCAP
 extcap_subdir = extcap
-endif
 
 DIST_SUBDIRS = \
        capchild        \
@@ -1009,7 +1000,6 @@ shellcheck:
        $(SHELLCHECK) --external-sources \
          tools/fuzz-test.sh \
          tools/randpkt-test.sh \
-         tools/runa2x.sh \
          tools/test-captures.sh \
          tools/valgrind-wireshark.sh