Incorporate plugin dissector into build in collection.
[metze/wireshark/wip.git] / Makefile.am
1 # Makefile.am
2 # Automake file for Wireshark
3 #
4 # $Id$
5 #
6 # Wireshark - Network traffic analyzer
7 # By Gerald Combs <gerald@wireshark.org>
8 # Copyright 1998 Gerald Combs
9 #
10 # This program is free software; you can redistribute it and/or
11 # modify it under the terms of the GNU General Public License
12 # as published by the Free Software Foundation; either version 2
13 # of the License, or (at your option) any later version.
14 #
15 # This program is distributed in the hope that it will be useful,
16 # but WITHOUT ANY WARRANTY; without even the implied warranty of
17 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18 # GNU General Public License for more details.
19 #
20 # You should have received a copy of the GNU General Public License
21 # along with this program; if not, write to the Free Software
22 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
23
24 ACLOCAL_AMFLAGS = `./aclocal-flags`
25
26 INCLUDES= @LUA_INCLUDES@
27
28 if HAVE_WARNINGS_AS_ERRORS
29 AM_CLEAN_CFLAGS = -Werror
30 endif
31
32 #
33 # This is a hideous hack.
34 #
35 # Automake needs to know into which sections to install various man
36 # pages; if the names in "man_MANS" have suffixes, it can infer the
37 # sections from the name (e.g., "hello.1" goes in section 1), but if
38 # they don't have suffixes, it can't tell what sections to put them, and
39 # it just gives up and doesn't create any rules to install them (and it
40 # gives up silently, so you have no clue what's wrong).
41 #
42 # Therefore, we can't just set "man_MANS" to a list of variables to be
43 # filled in by the configure script, as those variables don't have man
44 # page section numbers.
45 #
46 # It turns out (although this is not documented anywhere I could find
47 # in the automake Info file) that if you define, instead, variables with
48 # names like "man{section}_MANS", automake will infer that the names in
49 # those variables are the names of man pages to be installed in section
50 # "{section}".
51 #
52 # So, as all our man pages go in section 1, we define "man1_MANS" to
53 # contain all the man page.
54 #
55 # *However*, if "man_MANS" isn't defined at all, automake concludes that
56 # there are no man pages, the fact that, say, "man1_MANS" is defined
57 # nonwithstanding!  (I suspect this is the result of a mistaken attempt
58 # to get people to fix their automake files not to use "MANS"; if "MANS"
59 # is defined, it prints a warning and sets the exit status, but doesn't
60 # exit, and then it just gives up if "man_MANS" isn't defined,
61 # presumably on the theory that the only reason it wouldn't be defined
62 # is because the automake file uses the obsolete "MANS" variable instead
63 # of the shiny new "man_MANS" variable.)
64 #
65 # So we also define "man_MANS", but don't define it as anything;
66 # automake will arrange that the Makefile define it as the union of all
67 # the "man{section}_MANS" variables.
68 #
69 bin_PROGRAMS = \
70         @wireshark_bin@ \
71         @tshark_bin@    \
72         @text2pcap_bin@ \
73         @mergecap_bin@  \
74         @capinfos_bin@  \
75         @editcap_bin@   \
76         @randpkt_bin@   \
77         @dftest_bin@    \
78         @dumpcap_bin@   \
79         @rawshark_bin@
80 bin_SCRIPTS = @idl2wrs_bin@
81
82 man1_MANS = \
83         @wireshark_man@ \
84         @tshark_man@    \
85         @text2pcap_man@ \
86         @mergecap_man@  \
87         @capinfos_man@  \
88         @editcap_man@   \
89         @dumpcap_man@   \
90         @idl2wrs_man@   \
91         @rawshark_man@
92 man4_MANS = @wiresharkfilter_man@
93 man_MANS =
94
95 EXTRA_PROGRAMS = wireshark tshark capinfos editcap mergecap dftest \
96         randpkt text2pcap dumpcap rawshark
97 EXTRA_SCRIPTS = idl2wrs
98
99 idl2wrs: tools/idl2wrs.sh Makefile
100         cp tools/idl2wrs.sh idl2wrs
101         chmod +x idl2wrs
102
103 #
104 # Wireshark configuration files are put in $(pkgdatadir).
105 #
106 pkgdata_DATA = AUTHORS-SHORT COPYING manuf services wireshark.html \
107         tshark.html wireshark-filter.html capinfos.html editcap.html \
108         idl2wrs.html mergecap.html text2pcap.html dumpcap.html \
109         rawshark.html ws.css cfilters colorfilters dfilters smi_modules ipmap.html
110
111 #
112 # Install the Diameter DTD and XML files in the "diameter" subdirectory
113 # of that directory.
114 #
115 diameterdir = $(pkgdatadir)/diameter
116 diameter_DATA = \
117         diameter/chargecontrol.xml \
118         diameter/dictionary.dtd \
119         diameter/dictionary.xml \
120         diameter/Ericsson.xml \
121         diameter/etsie2e4.xml \
122         diameter/gqpolicy.xml \
123         diameter/imscxdx.xml \
124         diameter/mobileipv4.xml \
125         diameter/nasreq.xml \
126         diameter/sip.xml \
127         diameter/sunping.xml \
128         diameter/TGPPGmb.xml \
129         diameter/TGPPRx.xml \
130         diameter/TGPPSh.xml
131
132 #
133 # Install the DTDs directory files in the "dtds" subdirectory
134 # of that directory
135 #
136 dtdsdir = $(pkgdatadir)/dtds
137 dtds_DATA = \
138         dtds/dc.dtd \
139         dtds/itunes.dtd \
140         dtds/mscml.dtd \
141         dtds/pocsettings.dtd \
142         dtds/presence.dtd \
143         dtds/reginfo.dtd \
144         dtds/rlmi.dtd \
145         dtds/rss.dtd \
146         dtds/smil.dtd \
147         dtds/xcap-caps.dtd \
148         dtds/xcap-error.dtd \
149         dtds/watcherinfo.dtd
150
151 #
152 # Install the RADIUS directory files in the "radius" subdirectory
153 # of that directory.
154 #
155 radiusdir = $(pkgdatadir)/radius
156 radius_DATA = \
157         radius/dictionary  \
158         radius/dictionary.3com  \
159         radius/dictionary.3gpp  \
160         radius/dictionary.3gpp2  \
161         radius/dictionary.acc  \
162         radius/dictionary.alcatel  \
163         radius/dictionary.alteon  \
164         radius/dictionary.altiga  \
165         radius/dictionary.aptis  \
166         radius/dictionary.ascend  \
167         radius/dictionary.aruba  \
168         radius/dictionary.bay  \
169         radius/dictionary.bintec  \
170         radius/dictionary.bristol  \
171         radius/dictionary.cablelabs  \
172         radius/dictionary.cabletron  \
173         radius/dictionary.cisco  \
174         radius/dictionary.cisco.bbsm  \
175         radius/dictionary.cisco.vpn3000  \
176         radius/dictionary.cisco.vpn5000  \
177         radius/dictionary.colubris  \
178         radius/dictionary.columbia_university  \
179         radius/dictionary.compat  \
180         radius/dictionary.cosine  \
181         radius/dictionary.ericsson  \
182         radius/dictionary.erx  \
183         radius/dictionary.extreme  \
184         radius/dictionary.foundry  \
185         radius/dictionary.freeradius  \
186         radius/dictionary.gandalf  \
187         radius/dictionary.garderos  \
188         radius/dictionary.gemtek  \
189         radius/dictionary.itk  \
190         radius/dictionary.juniper  \
191         radius/dictionary.karlnet  \
192         radius/dictionary.livingston  \
193         radius/dictionary.localweb  \
194         radius/dictionary.merit  \
195         radius/dictionary.microsoft  \
196         radius/dictionary.mikrotik  \
197         radius/dictionary.navini  \
198         radius/dictionary.netscreen  \
199         radius/dictionary.nokia  \
200         radius/dictionary.nomadix  \
201         radius/dictionary.propel  \
202         radius/dictionary.quintum  \
203         radius/dictionary.redback  \
204         radius/dictionary.redcreek  \
205         radius/dictionary.shasta  \
206         radius/dictionary.shiva  \
207         radius/dictionary.sonicwall  \
208         radius/dictionary.springtide  \
209         radius/dictionary.t_systems_nova  \
210         radius/dictionary.telebit  \
211         radius/dictionary.trapeze  \
212         radius/dictionary.tunnel  \
213         radius/dictionary.unisphere  \
214         radius/dictionary.unix  \
215         radius/dictionary.usr  \
216         radius/dictionary.valemount  \
217         radius/dictionary.versanet  \
218         radius/dictionary.wispr  \
219         radius/dictionary.xedia
220
221 #
222 # Install the tpncp directory files in the "tpncp" subdirectory
223 # of that directory
224 #
225 tpncpdir = $(pkgdatadir)/tpncp
226 tpncp_DATA = \
227         tpncp/tpncp.dat
228
229
230 #
231 # Install the wimaxasncp directory files in the "wimaxasncp" subdirectory
232 # of that directory
233 #
234 wimaxasncpdir = $(pkgdatadir)/wimaxasncp
235 wimaxasncp_DATA = \
236         wimaxasncp/dictionary.xml \
237         wimaxasncp/dictionary.dtd
238
239 PLATFORM_SRC = capture-pcap-util-unix.c
240
241 if HAVE_PLUGINS
242 -include plugins/Custom.make
243 plugin_ldadd = $(_CUSTOM_plugin_ldadd_) \
244         -dlopen plugins/agentx/agentx.la \
245         -dlopen plugins/artnet/artnet.la \
246         -dlopen plugins/asn1/asn1.la \
247         -dlopen plugins/ciscosm/ciscosm.la \
248         -dlopen plugins/docsis/docsis.la \
249         -dlopen plugins/enttec/enttec.la \
250         -dlopen plugins/ethercat/ethercat.la \
251         -dlopen plugins/giop/cosnaming.la \
252         -dlopen plugins/giop/coseventcomm.la \
253         -dlopen plugins/gryphon/gryphon.la \
254         -dlopen plugins/infiniband/infiniband.la \
255         -dlopen plugins/irda/irda.la \
256         -dlopen plugins/lwres/lwres.la \
257         -dlopen plugins/m2m/m2m.la \
258         -dlopen plugins/mate/mate.la \
259         -dlopen plugins/opcua/opcua.la \
260         -dlopen plugins/profinet/profinet.la \
261         -dlopen plugins/sercosiii/sercosiii.la \
262         -dlopen plugins/stats_tree/stats_tree.la \
263         -dlopen plugins/unistim/unistim.la \
264         -dlopen plugins/wimax/wimax.la
265
266 WTAP_PLUGIN_SOURCES = \
267        epan/plugins.c \
268        epan/report_err.c \
269        epan/filesystem.c
270
271 else            # HAVE_PLUGINS
272
273 plugin_ldadd =
274 WTAP_PLUGIN_SOURCES =
275
276 endif           # HAVE_PLUGINS
277
278 include Makefile.common
279
280 # Optional objects that I know how to build. These will be
281 # linked into the wireshark executable.
282 # They will also be linked into the tshark executable; if this
283 # list ever grows to include something that can't be linked with
284 # tshark, or if tshark needs something that wireshark doesn't,
285 # we should probably split this into stuff needed both
286 # by wireshark and tshark and stuff needed only by one or the
287 # other.
288 wireshark_optional_objects = @GETOPT_O@ @STRERROR_O@ \
289         @STRCASECMP_O@ @STRNCASECMP_O@ @MKSTEMP_O@ @STRPTIME_O@
290
291 if ENABLE_STATIC
292 wireshark_LDFLAGS = -Wl,-static -all-static
293 else
294 wireshark_LDFLAGS = -export-dynamic
295 endif
296
297 # Libraries and plugin flags with which to link wireshark.
298 #
299 # Note that Wireshark doesn't have to be linked with @GLIB_LIBS@, as
300 # they are included in @GTK_LIBS@, and doesn't have to be linked with
301 # @SOCKET_LIBS@ or @NSL_LIBS@, as those should also be included in
302 # @GTK_LIBS@ (as those are also needed for X applications, and GTK+
303 # applications are X applications).
304 wireshark_LDADD = \
305         $(wireshark_optional_objects)   \
306         gtk/libui.a                     \
307         codecs/libcodec.a               \
308         wiretap/libwiretap.la           \
309         epan/libwireshark.la            \
310         wsutil/libwsutil.la             \
311         @INET_PTON_LO@                  \
312         @INET_NTOP_LO@                  \
313         @SSL_LIBS@                      \
314         $(plugin_ldadd)                 \
315         @PCRE_LIBS@                     \
316         @PCAP_LIBS@                     \
317         @GTK_LIBS@                      \
318         @C_ARES_LIBS@                   \
319         @ADNS_LIBS@                     \
320         @KRB5_LIBS@                     \
321         @FRAMEWORKS@                    \
322         @LIBGCRYPT_LIBS@                \
323         @LIBGNUTLS_LIBS@                \
324         @LIBSMI_LDFLAGS@                \
325         @PORTAUDIO_LIBS@
326 wireshark_CFLAGS = $(AM_CLEAN_CFLAGS)
327
328 if ENABLE_STATIC
329 tshark_LDFLAGS = -Wl,-static -all-static
330 else
331 tshark_LDFLAGS = -export-dynamic
332 endif
333
334 # Libraries and plugin flags with which to link tshark.
335 tshark_LDADD = \
336         $(wireshark_optional_objects)   \
337         wiretap/libwiretap.la           \
338         epan/libwireshark.la            \
339         wsutil/libwsutil.la             \
340         @INET_PTON_LO@                  \
341         @INET_NTOP_LO@                  \
342         @SSL_LIBS@                      \
343         $(plugin_ldadd)                 \
344         @PCRE_LIBS@                     \
345         @GLIB_LIBS@ -lm                 \
346         @PCAP_LIBS@                     \
347         @SOCKET_LIBS@                   \
348         @NSL_LIBS@                      \
349         @C_ARES_LIBS@                   \
350         @ADNS_LIBS@                     \
351         @KRB5_LIBS@                     \
352         @FRAMEWORKS@                    \
353         @LIBGCRYPT_LIBS@                \
354         @LIBGNUTLS_LIBS@                \
355         @LIBSMI_LDFLAGS@
356 tshark_CFLAGS = $(AM_CLEAN_CFLAGS)
357
358 if ENABLE_STATIC
359 rawshark_LDFLAGS = -Wl,-static -all-static
360 else
361 rawshark_LDFLAGS = -export-dynamic
362 endif
363
364 # Libraries and plugin flags with which to link tshark.
365 rawshark_LDADD = \
366         $(wireshark_optional_objects)   \
367         wiretap/libwiretap.la           \
368         epan/libwireshark.la            \
369         wsutil/libwsutil.la             \
370         @INET_PTON_LO@                  \
371         @INET_NTOP_LO@                  \
372         @SSL_LIBS@                      \
373         $(plugin_ldadd)                 \
374         @PCRE_LIBS@                     \
375         @GLIB_LIBS@ -lm                 \
376         @PCAP_LIBS@                     \
377         @SOCKET_LIBS@                   \
378         @NSL_LIBS@                      \
379         @C_ARES_LIBS@                   \
380         @ADNS_LIBS@                     \
381         @KRB5_LIBS@                     \
382         @FRAMEWORKS@                    \
383         @LIBGCRYPT_LIBS@                \
384         @LIBGNUTLS_LIBS@                \
385         @LIBSMI_LDFLAGS@
386 rawshark_CFLAGS = $(AM_CLEAN_CFLAGS)
387
388 # Optional objects that I know how to build, and that are needed by
389 # text2pcap.
390 text2pcap_optional_objects = @STRERROR_O@ @STRPTIME_O@
391
392 # Libraries with which to link text2pcap.
393 text2pcap_LDADD = \
394         $(text2pcap_optional_objects)   \
395         wiretap/libwiretap.la           \
396         wsutil/libwsutil.la             \
397         @GLIB_LIBS@ -lm
398 # Don't turn on -Werror for text2pcap: its source includes text2pcap-scanner.c
399 # which is generated (and therefore not always clean).
400 # We could generate text2pcap.o as a library with -Werror but for now it
401 # doesn't seem worth the effort.
402 #text2pcap_CFLAGS = $(AM_CLEAN_CFLAGS)
403
404 # Libraries with which to link mergecap.
405 mergecap_LDADD = \
406         wiretap/libwiretap.la           \
407         wsutil/libwsutil.la             \
408         @GLIB_LIBS@
409 mergecap_CFLAGS = $(AM_CLEAN_CFLAGS)
410
411 # Libraries with which to link capinfos.
412 capinfos_LDADD = \
413         wiretap/libwiretap.la           \
414         wsutil/libwsutil.la             \
415         @GLIB_LIBS@
416 capinfos_CFLAGS = $(AM_CLEAN_CFLAGS)
417
418 # Libraries with which to link editcap.
419 editcap_LDADD = \
420         wiretap/libwiretap.la           \
421         wsutil/libwsutil.la             \
422         @GLIB_LIBS@
423 editcap_CFLAGS = $(AM_CLEAN_CFLAGS)
424
425 # Libraries with which to link randpkt.
426 randpkt_LDADD = \
427         wiretap/libwiretap.la           \
428         wsutil/libwsutil.la             \
429         @GLIB_LIBS@ -lm                 \
430         @PCAP_LIBS@                     \
431         @SOCKET_LIBS@                   \
432         @NSL_LIBS@                      \
433         @C_ARES_LIBS@                   \
434         @ADNS_LIBS@
435 randpkt_CFLAGS = $(AM_CLEAN_CFLAGS)
436
437 # Libraries and plugin flags with which to link dftest.
438 dftest_LDADD = \
439         $(wireshark_optional_objects)   \
440         wiretap/libwiretap.la           \
441         wsutil/libwsutil.la             \
442         epan/libwireshark.la            \
443         @SSL_LIBS@                      \
444         $(plugin_ldadd)                 \
445         @PCRE_LIBS@                     \
446         @GLIB_LIBS@ -lm                 \
447         @PCAP_LIBS@                     \
448         @SOCKET_LIBS@                   \
449         @NSL_LIBS@                      \
450         @C_ARES_LIBS@                   \
451         @ADNS_LIBS@                     \
452         @KRB5_LIBS@                     \
453         @LIBGCRYPT_LIBS@                \
454         @LIBGNUTLS_LIBS@                \
455         @LIBSMI_LDFLAGS@
456 dftest_CFLAGS = $(AM_CLEAN_CFLAGS)
457
458 # Libraries with which to link dumpcap.
459 dumpcap_LDADD = \
460         wiretap/libwiretap.la           \
461         wsutil/libwsutil.la             \
462         @INET_NTOP_LO@                  \
463         @GLIB_LIBS@                     \
464         @PCAP_LIBS@                     \
465         @SOCKET_LIBS@                   \
466         @NSL_LIBS@                      \
467         @FRAMEWORKS@                    \
468         @LIBGCRYPT_LIBS@                \
469         @LIBGNUTLS_LIBS@                \
470         @LIBCAP_LIBS@
471 dumpcap_CFLAGS = $(AM_CLEAN_CFLAGS)
472
473 # Common headers
474 AM_CPPFLAGS = -I$(top_srcdir) -I$(top_srcdir)/wiretap \
475         $(LIBGNUTLS_CFLAGS) $(LIBGCRYPT_CFLAGS) $(LIBSMI_CFLAGS)
476
477 #
478 # Build the version string
479 #
480 # FORCE is the portable version of .PHONY
481 FORCE:
482
483 svnversion.h: FORCE
484         LANG=C $(PERL) $(srcdir)/make-version.pl $(srcdir)
485
486 #
487 # Build the short version of the authors file for the about dialog
488 #
489 AUTHORS-SHORT: AUTHORS make-authors-short.pl
490         $(PERL) $(srcdir)/perlnoutf.pl $(srcdir)/make-authors-short.pl < $(srcdir)/AUTHORS > AUTHORS-SHORT
491
492 #
493 # Build the short version of the authors file with formatting codes for the
494 # man page
495 #
496 AUTHORS-SHORT-FORMAT: AUTHORS-SHORT make-authors-format.pl
497         $(PERL) $(srcdir)/perlnoutf.pl $(srcdir)/make-authors-format.pl < AUTHORS-SHORT > AUTHORS-SHORT-FORMAT
498
499 #
500 # Build shell scripts by doing variable substitution.
501 # Taken from autoconf 2.13.
502 #
503 editsh = sed -e 's,@''SHELL''@,$(SHELL),g'
504
505 SUFFIXES = .sh
506 .sh:
507         rm -f $@ $@.tmp
508         $(editsh) $< > $@.tmp && chmod +x $@.tmp && mv $@.tmp $@
509
510 #
511 # Build "tshark-tap-register.c", which contains a function
512 # "register_all_tap_listeners()"
513 # that calls the register routines for all tshark tap listeners.
514 #
515 # We do this by grepping through sources.
516 #
517 # Formatting conventions:  The name of the tap_listener_register_*
518 # routines must start in column zero, or must be preceded only by
519 # "void " starting in column zero, and must not be inside #if.
520 #
521 # The first argument is the directory in which the source files live.
522 # All subsequent arguments are the files to scan.
523 #
524 tshark-tap-register.c: $(TSHARK_TAP_SRC) $(srcdir)/make-tapreg-dotc
525         @echo Making tshark-tap-register.c
526         @$(srcdir)/make-tapreg-dotc tshark-tap-register.c $(srcdir) $(TSHARK_TAP_SRC)
527
528 ps.c: print.ps rdps
529         ./rdps $(srcdir)/print.ps ps.c
530
531 rdps: rdps.c
532         $(CC) $(CFLAGS) -o rdps $(srcdir)/rdps.c
533
534 #
535 # XXX - "svnversion.h" is distributed in the release tarball; should
536 # we be deleting it with "make clean", or should we only do that with
537 # "make maintainer-clean"?
538 #
539 CLEANFILES =            \
540         svnversion.h    \
541         @rdps_bin@      \
542         idl2wrs         \
543         *~              \
544         vgcore.*
545
546 #
547 # XXX - "ps.c" is distributed in the source tarballs; why is it in the
548 # list of files removed by "make distclean"?  (It's deliberately
549 # included in that list.)
550 #
551 DISTCLEANFILES = \
552         AUTHORS-SHORT           \
553         AUTHORS-SHORT-FORMAT    \
554         ps.c                    \
555         ws.css
556
557 MAINTAINERCLEANFILES =          \
558         $(GENERATED_FILES)      \
559         Makefile.in             \
560         aclocal.m4              \
561         config.h.in             \
562         configure               \
563         depcomp                 \
564         install-sh              \
565         ltmain.sh               \
566         missing
567
568 EXTRA_DIST = \
569         INSTALL.configure       \
570         Makefile.am.inc         \
571         Makefile.common         \
572         Makefile.nmake          \
573         Makefile.nmake.inc      \
574         README.aix              \
575         README.bsd              \
576         README.hpux             \
577         README.irix             \
578         README.linux            \
579         README.macos            \
580         README.tru64            \
581         README.vmware           \
582         README.win32            \
583         aclocal-fallback/glib-2.0.m4 \
584         aclocal-fallback/gtk-2.0.m4 \
585         aclocal-flags           \
586         adns_dll.dep            \
587         adns_dll.rc             \
588         autogen.sh              \
589         capinfos.c              \
590         capture-wpcap.c         \
591         capture-wpcap.h         \
592         capture_wpcap_packet.c  \
593         capture_wpcap_packet.h  \
594         cfilters                \
595         colorfilters            \
596         config.h.win32          \
597         config.nmake            \
598         debian/changelog        \
599         debian/compat           \
600         debian/control          \
601         debian/copyright        \
602         debian/dirs             \
603         debian/headers-check.c  \
604         debian/patches/00list   \
605         debian/patches/03_preferences.dpatch \
606         debian/postinst         \
607         debian/pycompat         \
608         debian/pyversions       \
609         debian/rules            \
610         debian/tshark.files     \
611         debian/tshark.manpages  \
612         debian/watch            \
613         debian/wireshark-common.files \
614         debian/wireshark-common.manpages \
615         debian/wireshark-common.shlibs \
616         debian/wireshark-dev.docs \
617         debian/wireshark-dev.files \
618         debian/wireshark-dev.header-files \
619         debian/wireshark-dev.manpages \
620         debian/wireshark-dev.prerm \
621         debian/wireshark-root.desktop \
622         debian/wireshark.desktop \
623         debian/wireshark.files \
624         debian/wireshark.manpages \
625         debian/wireshark.menu   \
626         dfilters                \
627         docbook/Makefile.auto.am        \
628         docbook/ws.css          \
629         doxygen.cfg.in          \
630         dumpcap.c       \
631         editcap.c               \
632         wireshark.desktop       \
633         idl/cosnaming.idl       \
634         idl/tango.idl   \
635         idl/parlay/am.idl       \
636         idl/parlay/cccs.idl     \
637         idl/parlay/cm.idl       \
638         idl/parlay/common_cc_data.idl   \
639         idl/parlay/cs.idl       \
640         idl/parlay/dsc.idl      \
641         idl/parlay/fw_data.idl  \
642         idl/parlay/fw_if.idl    \
643         idl/parlay/fw_if_access.idl     \
644         idl/parlay/fw_if_app.idl        \
645         idl/parlay/fw_if_entop.idl      \
646         idl/parlay/fw_if_service.idl    \
647         idl/parlay/gcc_data.idl \
648         idl/parlay/gcc_interfaces.idl   \
649         idl/parlay/gms.idl      \
650         idl/parlay/mm.idl       \
651         idl/parlay/mmccs.idl    \
652         idl/parlay/mmm.idl      \
653         idl/parlay/mpcc_data.idl        \
654         idl/parlay/mpcc_interfaces.idl  \
655         idl/parlay/osa.idl      \
656         idl/parlay/pam_data.idl \
657         idl/parlay/pam_interfaces.idl   \
658         idl/parlay/Parlay.idl   \
659         idl/parlay/policy_data.idl      \
660         idl/parlay/policy_interfaces.idl        \
661         idl/parlay/README.parlay        \
662         idl/parlay/termcap.idl  \
663         idl/parlay/ui_data.idl  \
664         idl/parlay/ui_interfaces.idl    \
665         image/capinfos.rc.in    \
666         image/clist_ascend.xpm  \
667         image/clist_descend.xpm \
668         image/dn_arrow.xpm      \
669         image/dumpcap.rc.in     \
670         image/editcap.rc.in     \
671         image/expert_chat.xpm   \
672         image/expert_error.xpm  \
673         image/expert_none.xpm   \
674         image/expert_note.xpm   \
675         image/expert_warn.xpm   \
676         image/file_dlg_win32.rc \
677         image/hi16-app-wireshark.png    \
678         image/hi32-app-wireshark.png    \
679         image/hi48-app-wireshark.png    \
680         image/icon_layout_1.xpm \
681         image/icon_layout_2.xpm \
682         image/icon_layout_3.xpm \
683         image/icon_layout_4.xpm \
684         image/icon_layout_5.xpm \
685         image/icon_layout_6.xpm \
686         image/libwireshark.rc.in        \
687         image/libwsutil.rc.in   \
688         image/lo16-app-wireshark.png    \
689         image/lo32-app-wireshark.png    \
690         image/lo48-app-wireshark.png    \
691         image/Makefile.nmake    \
692         image/mergecap.rc.in    \
693         image/nsis-checked.bmp  \
694         image/nsis-unchecked.bmp        \
695         image/rawshark.rc.in    \
696         image/README.image      \
697         image/stock_dialog_error_48.xpm \
698         image/stock_dialog_info_48.xpm  \
699         image/stock_dialog_question_48.xpm      \
700         image/stock_dialog_stop_48.xpm  \
701         image/stock_dialog_warning_48.xpm       \
702         image/text2pcap.rc.in   \
703         image/toolbar/autoscroll_24.xpm \
704         image/toolbar/capture_airpcap_16.xpm \
705         image/toolbar/capture_capture_16.xpm \
706         image/toolbar/capture_details_16.xpm \
707         image/toolbar/capture_details_24.xpm \
708         image/toolbar/capture_ethernet_16.xpm  \
709         image/toolbar/capture_filter_24.xpm     \
710         image/toolbar/capture_interfaces_24.xpm \
711         image/toolbar/capture_options_24.xpm    \
712         image/toolbar/capture_prepare_16.xpm \
713         image/toolbar/capture_restart_24.xpm    \
714         image/toolbar/capture_start_24.xpm      \
715         image/toolbar/capture_stop_24.xpm       \
716         image/toolbar/checkbox_16.xpm   \
717         image/toolbar/colorize_24.xpm   \
718         image/toolbar/conversations_16.xpm      \
719         image/toolbar/decode_as_16.xpm  \
720         image/toolbar/display_filter_24.xpm     \
721         image/toolbar/endpoints_16.xpm  \
722         image/toolbar/expert_info_16.xpm        \
723         image/toolbar/file_set_list_16.xpm      \
724         image/toolbar/file_set_next_16.xpm      \
725         image/toolbar/file_set_previous_16.xpm  \
726         image/toolbar/flow_graph_16.xpm \
727         image/toolbar/graphs_16.xpm     \
728         image/toolbar/icon_color_0.xpm  \
729         image/toolbar/icon_color_1.xpm  \
730         image/toolbar/icon_color_2.xpm  \
731         image/toolbar/icon_color_3.xpm  \
732         image/toolbar/icon_color_4.xpm  \
733         image/toolbar/icon_color_5.xpm  \
734         image/toolbar/icon_color_6.xpm  \
735         image/toolbar/icon_color_7.xpm  \
736         image/toolbar/icon_color_8.xpm  \
737         image/toolbar/icon_color_9.xpm  \
738         image/toolbar/internet_24.xpm   \
739         image/toolbar/modem_16.png      \
740         image/toolbar/modem_16.xpm      \
741         image/toolbar/network_bluetooth_16.png  \
742         image/toolbar/network_bluetooth_16.xpm  \
743         image/toolbar/network_virtual_16.xpm    \
744         image/toolbar/network_wired_16.png      \
745         image/toolbar/network_wired_16.xpm      \
746         image/toolbar/network_wireless_16.png   \
747         image/toolbar/network_wireless_16.xpm   \
748         image/toolbar/resize_columns_24.xpm     \
749         image/toolbar/telephony_16.xpm  \
750         image/toolbar/time_24.xpm       \
751         image/toolbar/web_support_24.xpm        \
752         image/toolbar/wep_closed_24.xpm \
753         image/toolbar/wiki_24.xpm       \
754         image/tshark.rc.in      \
755         image/up_arrow.xpm      \
756         image/wiresharkdoc.ico  \
757         image/wireshark.exe.manifest.in \
758         image/wireshark.ico     \
759         image/wiresharkinst.ico \
760         image/wireshark.rc.in   \
761         image/wiretap.rc.in     \
762         image/wsicon16.png      \
763         image/wsicon16.xpm      \
764         image/wsicon256.png     \
765         image/wsicon32.png      \
766         image/wsicon32.xpm      \
767         image/wsicon48.png      \
768         image/wsicon48.xpm      \
769         image/wsicon64.png      \
770         image/wsicon64.xpm      \
771         image/wsiconcap16.xpm   \
772         image/wsiconcap256.png  \
773         image/wsiconcap32.xpm   \
774         image/wsiconcap48.xpm   \
775         image/wsiconcap.svg     \
776         image/wsicondoc256.png  \
777         image/wsicondoc.svg     \
778         image/wsiconinst256.png \
779         image/wsiconinst.svg    \
780         image/wsicon.svg        \
781         image/wslogo.eps        \
782         image/wslogo.svg        \
783         image/wssplash.xpm      \
784         image/wssplash-dev.xpm  \
785         ipmap.html      \
786         make-authors-format.pl  \
787         make-authors-short.pl   \
788         make-manuf              \
789         make-tapreg-dotc        \
790         make-version.pl         \
791         manuf                   \
792         manuf.tmpl              \
793         mergecap.c              \
794         perlnoutf.pl            \
795         print.ps                \
796         $(diameter_DATA)        \
797         $(dtds_DATA)            \
798         $(radius_DATA)          \
799         $(tpncp_DATA)           \
800         $(wimaxasncp_DATA)      \
801         randpkt.c               \
802         rdps.c                  \
803         smi_modules             \
804         text2pcap-scanner.l     \
805         text2pcap.c             \
806         text2pcap.h             \
807         services                \
808         wka.tmpl
809
810 if SETUID_INSTALL
811 install-exec-hook:
812         -chmod +s $(DESTDIR)$(bindir)/dumpcap
813 else
814 install-exec-hook:
815 endif
816
817 DIST_SUBDIRS = asn1 codecs doc epan gtk help packaging plugins tools wiretap wsutil
818
819 if HAVE_PLUGINS
820 SUBDIRS = tools wsutil wiretap doc epan plugins packaging help @wireshark_SUBDIRS@
821 else
822 SUBDIRS = tools wsutil wiretap doc epan packaging help @wireshark_SUBDIRS@
823 endif
824
825 help/faq.txt: $(srcdir)/help/faq.py
826         (cd help ; \
827         $(MAKE) faq.txt ;)
828
829 wireshark.1: doc/wireshark.pod AUTHORS-SHORT-FORMAT
830         (cd doc ; \
831         $(MAKE) ../wireshark.1 )
832
833 tshark.1: doc/tshark.pod
834         (cd doc ; \
835         $(MAKE) ../tshark.1 )
836
837 wireshark-filter.4: tshark doc/wireshark-filter.pod.template
838         (cd doc ; \
839         $(MAKE) ../wireshark-filter.4 )
840
841 capinfos.1: doc/capinfos.pod
842         (cd doc ; \
843         $(MAKE) ../capinfos.1 )
844
845 editcap.1: doc/editcap.pod
846         (cd doc ; \
847         $(MAKE) ../editcap.1 )
848
849 idl2wrs.1: doc/idl2wrs.pod
850         (cd doc ; \
851         $(MAKE) ../idl2wrs.1 )
852
853 mergecap.1: doc/mergecap.pod
854         (cd doc ; \
855         $(MAKE) ../mergecap.1 )
856
857 text2pcap.1: doc/text2pcap.pod
858         (cd doc ; \
859         $(MAKE) ../text2pcap.1 )
860
861 dumpcap.1: doc/dumpcap.pod
862         (cd doc ; \
863         $(MAKE) ../dumpcap.1 )
864
865 rawshark.1: doc/rawshark.pod
866         (cd doc ; \
867         $(MAKE) ../rawshark.1 )
868
869 ws.css: $(srcdir)/docbook/ws.css
870         cp $(srcdir)/docbook/ws.css .
871
872 wireshark.html: doc/wireshark.pod AUTHORS-SHORT-FORMAT ws.css
873         (cd doc ; \
874         $(MAKE) ../wireshark.html )
875
876 tshark.html: doc/tshark.pod ws.css
877         (cd doc ; \
878         $(MAKE) ../tshark.html )
879
880 wireshark-filter.html: tshark doc/wireshark-filter.pod.template ws.css
881         (cd doc ; \
882         $(MAKE) ../wireshark-filter.html )
883
884 capinfos.html: doc/capinfos.pod ws.css
885         (cd doc ; \
886         $(MAKE) ../capinfos.html )
887
888 editcap.html: doc/editcap.pod ws.css
889         (cd doc ; \
890         $(MAKE) ../editcap.html )
891
892 idl2wrs.html: doc/idl2wrs.pod ws.css
893         (cd doc ; \
894         $(MAKE) ../idl2wrs.html )
895
896 mergecap.html: doc/mergecap.pod ws.css
897         (cd doc ; \
898         $(MAKE) ../mergecap.html )
899
900 text2pcap.html: doc/text2pcap.pod ws.css
901         (cd doc ; \
902         $(MAKE) ../text2pcap.html )
903
904 dumpcap.html: doc/dumpcap.pod ws.css
905         (cd doc ; \
906         $(MAKE) ../dumpcap.html )
907
908 rawshark.html: doc/rawshark.pod ws.css
909         (cd doc ; \
910         $(MAKE) ../rawshark.html )
911
912 libtool: $(LIBTOOL_DEPS)
913         $(SHELL) ./config.status --recheck
914
915 # Used by svr4-package and osx-package
916 # We load top_stagedir with an explicit path so that libtool doesn't freak.
917 top_stagedir=`cd $(top_srcdir) && pwd`/packaging/staging
918 stagedir=$(top_stagedir)/$(PACKAGE).inst
919
920 host_cpu=@host_cpu@
921 host_os=@host_os@
922
923 svr4-package: $(PROGRAMS) $(SCRIPTS) $(MANS) $(DATA)
924         @if test x$(HAVE_SVR4_PACKAGING) = xyes ; then \
925                 rm -rf $(stagedir) ; \
926                 $(MAKE) DESTDIR=$(stagedir) install; \
927                 $(srcdir)/packaging/svr4/mkpkg \
928                         $(PACKAGE) \
929                         $(PACKAGE)-$(VERSION)-$(host_os)-$(host_cpu)-local \
930                         $(prefix) \
931                         $(top_stagedir) ; \
932         else \
933                 echo "Error: SVR4 packaging tools not found." ; \
934                 echo "Package build abandoned." ; \
935         fi
936
937 solaris-package: svr4-package
938
939 rpm_topdir=`cd $(top_builddir) && pwd`/packaging/rpm
940 rpm-package: dist
941         if test x$(HAVE_RPM) = xyes ; then \
942                 cd $(rpm_topdir) ; \
943                 mkdir -p BUILD RPMS SOURCES ; \
944                 cd SOURCES ; \
945                 ln -s ../../../$(distdir).tar.gz ; \
946                 ln -s ../../../wireshark.desktop ; \
947                 ln -s ../../../image/wsicon64.png wireshark.png ; \
948                 cd .. ; \
949                 rpmbuild --define "_topdir `cd . && pwd`" -bb SPECS/wireshark.spec && \
950                         echo "Package successfully built in `pwd`/RPMS." ; \
951         else \
952                 echo "Error: RPM executable and/or source directory not found." ; \
953         fi
954 srpm-package: dist
955         if test x$(HAVE_RPM) = xyes ; then \
956                 cd $(rpm_topdir) ; \
957                 mkdir -p BUILD SRPMS SOURCES ; \
958                 cd SOURCES ; \
959                 ln -s ../../../$(distdir).tar.gz ; \
960                 ln -s ../../../wireshark.desktop ; \
961                 ln -s ../../../image/wsicon64.png wireshark.png ; \
962                 cd .. ; \
963                 rpmbuild --define "_topdir `cd . && pwd`" -bs SPECS/wireshark.spec && \
964                         echo "Package successfully built in `pwd`/SRPMS." ; \
965         else \
966                 echo "Error: RPM executable and/or source directory not found." ; \
967         fi
968
969 debian-package: debian/rules
970         @if test x$(HAVE_DPKG_BUILDPACKAGE) = xyes ; then \
971                 dpkg-buildpackage -rfakeroot -us -uc ; \
972         else \
973                 echo "Error: Debian packaging tools not found." ; \
974                 echo "Package build abandoned." ; \
975         fi
976
977 # XXX - This assumes we're building from the source directory.
978 osx-app: $(PROGRAMS) $(SCRIPTS) $(MANS) $(DATA) packaging/macosx/Info.plist
979         @if test x$(HAVE_OSX_PACKAGING) = xyes ; then \
980                 rm -rf $(stagedir) ; \
981                 $(MAKE) DESTDIR=$(stagedir) install; \
982                 cd $(srcdir)/packaging/macosx ;  \
983                 ./osx-app.sh -bp ../staging/$(PACKAGE).inst$(bindir) ; \
984         else \
985                 echo "Error: OS X packaging tools not found." ; \
986                 echo "Package build abandoned." ; \
987         fi
988
989 osx-package: osx-app
990         @if test x$(HAVE_OSX_PACKAGING) = xyes ; then \
991                 cd $(srcdir)/packaging/macosx ;  \
992                 ./osx-dmg.sh ; \
993         fi
994
995 clean-local:
996         rm -rf $(top_stagedir)
997
998 checkapi_local:
999         $(PERL) tools/checkAPIs.pl \
1000         $(TSHARK_TAP_SRC)
1001 #       $(wireshark_SOURCES)
1002 #       $(EXTRA_wireshark_SOURCES)
1003
1004 checkapi: checkapi_local
1005         cd wiretap && $(MAKE) checkapi
1006         cd ../codecs && $(MAKE) checkapi
1007 ##      cd ../gtk && $(MAKE) checkapi
1008 ##      cd ../epan && $(MAKE) checkapi
1009 ##      cd ../epan/crypt && $(MAKE) checkapi
1010         cd ../dfilter && $(MAKE) checkapi
1011 ##      cd ../ftypes && $(MAKE) checkapi
1012 ##      cd ../wslua && $(MAKE) checkapi
1013         cd ../dissectors && $(MAKE) checkapi
1014         cd ../../plugins && $(MAKE) checkapi
1015         cd ../wsutil && $(MAKE) checkapi