From Martin Mathieson:
[obnox/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 #
27 # This is a hideous hack.
28 #
29 # Automake needs to know into which sections to install various man
30 # pages; if the names in "man_MANS" have suffixes, it can infer the
31 # sections from the name (e.g., "hello.1" goes in section 1), but if
32 # they don't have suffixes, it can't tell what sections to put them, and
33 # it just gives up and doesn't create any rules to install them (and it
34 # gives up silently, so you have no clue what's wrong).
35 #
36 # Therefore, we can't just set "man_MANS" to a list of variables to be
37 # filled in by the configure script, as those variables don't have man
38 # page section numbers.
39 #
40 # It turns out (although this is not documented anywhere I could find
41 # in the automake Info file) that if you define, instead, variables with
42 # names like "man{section}_MANS", automake will infer that the names in
43 # those variables are the names of man pages to be installed in section
44 # "{section}".
45 #
46 # So, as all our man pages go in section 1, we define "man1_MANS" to
47 # contain all the man page.
48 #
49 # *However*, if "man_MANS" isn't defined at all, automake concludes that
50 # there are no man pages, the fact that, say, "man1_MANS" is defined
51 # nonwithstanding!  (I suspect this is the result of a mistaken attempt
52 # to get people to fix their automake files not to use "MANS"; if "MANS"
53 # is defined, it prints a warning and sets the exit status, but doesn't
54 # exit, and then it just gives up if "man_MANS" isn't defined,
55 # presumably on the theory that the only reason it wouldn't be defined
56 # is because the automake file uses the obsolete "MANS" variable instead
57 # of the shiny new "man_MANS" variable.)
58 #
59 # So we also define "man_MANS", but don't define it as anything;
60 # automake will arrange that the Makefile define it as the union of all
61 # the "man{section}_MANS" variables.
62 #
63 bin_PROGRAMS = @wireshark_bin@ @capinfos_bin@ @editcap_bin@ @mergecap_bin@ @tshark_bin@ @dftest_bin@ @randpkt_bin@ @text2pcap_bin@ @dumpcap_bin@
64 bin_SCRIPTS = @idl2wrs_bin@
65 man1_MANS = @wireshark_man@ @capinfos_man@ @editcap_man@ @mergecap_man@ @tshark_man@ @text2pcap_man@ @dumpcap_man@ @idl2wrs_man@
66 man4_MANS = @wiresharkfilter_man@
67 man_MANS =
68
69 EXTRA_PROGRAMS = wireshark tshark capinfos editcap mergecap dftest \
70         randpkt text2pcap dumpcap
71 EXTRA_SCRIPTS = idl2wrs
72
73 idl2wrs: tools/idl2wrs.sh Makefile
74         cp $(srcdir)/tools/idl2wrs.sh idl2wrs
75         chmod +x idl2wrs
76
77 #
78 # Wireshark configuration files are put in $(pkgdatadir).
79 #
80 pkgdata_DATA = AUTHORS-SHORT manuf wireshark.html tshark.html \
81         wireshark-filter.html capinfos.html editcap.html \
82         idl2wrs.html mergecap.html text2pcap.html dumpcap.html \
83         cfilters colorfilters dfilters
84
85 #
86 # Install the Diameter DTD and XML files in the "diameter" subdirectory
87 # of that directory.
88 #
89 diameterdir = $(pkgdatadir)/diameter
90 diameter_DATA = \
91         diameter/chargecontrol.xml \
92         diameter/dictionary.dtd \
93         diameter/dictionary.xml \
94         diameter/imscxdx.xml \
95         diameter/mobileipv4.xml \
96         diameter/nasreq.xml \
97         diameter/sunping.xml \
98         diameter/TGPPSh.xml
99
100 #
101 # Install the DTDs directory files in the "dtds" subdirectory
102 # of that directory
103 #
104 dtdsdir = $(pkgdatadir)/dtds
105 dtds_DATA = \
106         dtds/dc.dtd \
107         dtds/itunes.dtd \
108         dtds/pocsettings.dtd \
109         dtds/presence.dtd \
110         dtds/reginfo.dtd \
111         dtds/rss.dtd \
112         dtds/smil.dtd \
113         dtds/xcap-caps.dtd \
114         dtds/watcherinfo.dtd
115 #
116 # Install the RADIUS directory files in the "radius" subdirectory
117 # of that directory.
118 #
119 radiusdir = $(pkgdatadir)/radius
120 radius_DATA = \
121         radius/dictionary  \
122         radius/dictionary.3com  \
123         radius/dictionary.3gpp  \
124         radius/dictionary.3gpp2  \
125         radius/dictionary.acc  \
126         radius/dictionary.alcatel  \
127         radius/dictionary.alteon  \
128         radius/dictionary.altiga  \
129         radius/dictionary.aptis  \
130         radius/dictionary.ascend  \
131         radius/dictionary.bay  \
132         radius/dictionary.bintec  \
133         radius/dictionary.bristol  \
134         radius/dictionary.cablelabs  \
135         radius/dictionary.cabletron  \
136         radius/dictionary.cisco  \
137         radius/dictionary.cisco.bbsm  \
138         radius/dictionary.cisco.vpn3000  \
139         radius/dictionary.cisco.vpn5000  \
140         radius/dictionary.colubris  \
141         radius/dictionary.columbia_university  \
142         radius/dictionary.compat  \
143         radius/dictionary.cosine  \
144         radius/dictionary.ericsson  \
145         radius/dictionary.erx  \
146         radius/dictionary.extreme  \
147         radius/dictionary.foundry  \
148         radius/dictionary.freeradius  \
149         radius/dictionary.gandalf  \
150         radius/dictionary.garderos  \
151         radius/dictionary.gemtek  \
152         radius/dictionary.itk  \
153         radius/dictionary.juniper  \
154         radius/dictionary.karlnet  \
155         radius/dictionary.livingston  \
156         radius/dictionary.localweb  \
157         radius/dictionary.merit  \
158         radius/dictionary.microsoft  \
159         radius/dictionary.mikrotik  \
160         radius/dictionary.navini  \
161         radius/dictionary.netscreen  \
162         radius/dictionary.nokia  \
163         radius/dictionary.nomadix  \
164         radius/dictionary.propel  \
165         radius/dictionary.quintum  \
166         radius/dictionary.redback  \
167         radius/dictionary.redcreek  \
168         radius/dictionary.shasta  \
169         radius/dictionary.shiva  \
170         radius/dictionary.sonicwall  \
171         radius/dictionary.springtide  \
172         radius/dictionary.t_systems_nova  \
173         radius/dictionary.telebit  \
174         radius/dictionary.trapeze  \
175         radius/dictionary.tunnel  \
176         radius/dictionary.unisphere  \
177         radius/dictionary.unix  \
178         radius/dictionary.usr  \
179         radius/dictionary.valemount  \
180         radius/dictionary.versanet  \
181         radius/dictionary.wispr  \
182         radius/dictionary.xedia
183
184 PLATFORM_SRC = capture-pcap-util-unix.c
185
186 include Makefile.common
187
188 if HAVE_PLUGINS
189
190 if HAVE_LIBLUA
191 lua_lib = plugins/lua/lua.la
192 else            # HAVE_LIBLUA
193 lua_lib =
194 endif           # HAVE_LIBLUA
195
196 plugin_libs = \
197         plugins/acn/acn.la \
198         plugins/agentx/agentx.la \
199         plugins/artnet/artnet.la \
200         plugins/asn1/asn1.la \
201         plugins/ciscosm/ciscosm.la \
202         plugins/docsis/docsis.la \
203         plugins/enttec/enttec.la \
204         plugins/giop/cosnaming.la \
205         plugins/giop/coseventcomm.la \
206         plugins/gryphon/gryphon.la \
207         plugins/irda/irda.la \
208         $(lua_lib) \
209         plugins/lwres/lwres.la \
210         plugins/mate/mate.la \
211         plugins/megaco/megaco.la \
212         plugins/mgcp/mgcp.la \
213         plugins/opsi/opsi.la \
214         plugins/pcli/pcli.la \
215         plugins/profinet/profinet.la \
216         plugins/rdm/rdm.la \
217         plugins/rlm/rlm.la \
218         plugins/rtnet/rtnet.la \
219         plugins/rudp/rudp.la \
220         plugins/sbus/sbus.la \
221         plugins/stats_tree/stats_tree.la \
222         plugins/v5ua/v5ua.la
223
224 if ENABLE_STATIC
225 plugin_ldadd = $(plugin_libs)
226
227 else            # ENABLE_STATIC
228
229 if HAVE_LIBLUA
230 lua_ldadd = "-dlopen" plugins/lua/lua.la
231 else            # HAVE_LIBLUA
232 lua_ldadd =
233 endif           # HAVE_LIBLUA
234
235 plugin_ldadd = \
236         "-dlopen" self  \
237         "-dlopen" plugins/acn/acn.la \
238         "-dlopen" plugins/agentx/agentx.la \
239         "-dlopen" plugins/artnet/artnet.la \
240         "-dlopen" plugins/asn1/asn1.la \
241         "-dlopen" plugins/ciscosm/ciscosm.la \
242         "-dlopen" plugins/docsis/docsis.la \
243         "-dlopen" plugins/enttec/enttec.la \
244         "-dlopen" plugins/giop/cosnaming.la \
245         "-dlopen" plugins/giop/coseventcomm.la \
246         "-dlopen" plugins/gryphon/gryphon.la \
247         "-dlopen" plugins/h223/h223.la \
248         "-dlopen" plugins/irda/irda.la \
249         $(lua_ldadd) \
250         "-dlopen" plugins/lwres/lwres.la \
251         "-dlopen" plugins/mate/mate.la \
252         "-dlopen" plugins/megaco/megaco.la \
253         "-dlopen" plugins/mgcp/mgcp.la \
254         "-dlopen" plugins/opsi/opsi.la \
255         "-dlopen" plugins/pcli/pcli.la \
256         "-dlopen" plugins/profinet/profinet.la \
257         "-dlopen" plugins/rdm/rdm.la \
258         "-dlopen" plugins/rlm/rlm.la \
259         "-dlopen" plugins/rtnet/rtnet.la \
260         "-dlopen" plugins/rudp/rudp.la \
261         "-dlopen" plugins/sbus/sbus.la \
262         "-dlopen" plugins/stats_tree/stats_tree.la \
263         "-dlopen" plugins/v5ua/v5ua.la
264
265 endif           # ENABLE_STATIC
266
267 else            # HAVE_PLUGINS
268 plugin_libs =
269
270 plugin_ldadd =
271 endif           # HAVE_PLUGINS
272
273 # Optional objects that I know how to build. These will be
274 # linked into the wireshark executable.
275 # They will also be linked into the tshark executable; if this
276 # list ever grows to include something that can't be linked with
277 # tshark, or if tshark needs something that wireshark doesn't,
278 # we should probably split this into stuff needed both
279 # by wireshark and tshark and stuff needed only by one or the
280 # other.
281 wireshark_optional_objects = @GETOPT_O@ @SNPRINTF_O@ @STRERROR_O@ \
282         @STRCASECMP_O@ @STRNCASECMP_O@ @MKSTEMP_O@ @STRPTIME_O@
283
284 # Additional libs that I know how to build. These will be
285 # linked into the wireshark executable.
286 wireshark_additional_libs = \
287         gtk/libui.a             \
288         wiretap/libwiretap.la   \
289         epan/libwireshark.la
290
291 # This is the automake dependency variable for the executable
292 wireshark_DEPENDENCIES = \
293         $(wireshark_optional_objects)   \
294         $(wireshark_additional_libs)    \
295         $(plugin_libs)
296
297 # This automake variable adds to the link-line for the executable.
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
305 if ENABLE_STATIC
306 wireshark_LDFLAGS = -Wl,-static -all-static
307 else
308 wireshark_LDFLAGS = -export-dynamic
309 endif
310
311 wireshark_LDADD = \
312         $(wireshark_optional_objects)   \
313         $(wireshark_additional_libs)    \
314         @SNMP_LIBS@ @SSL_LIBS@          \
315         $(plugin_ldadd)                 \
316         @PCRE_LIBS@                     \
317         @PCAP_LIBS@ @GTK_LIBS@ @ADNS_LIBS@ @KRB5_LIBS@ @FRAMEWORKS@ \
318         @LIBICONV@                      \
319         @LIBGCRYPT_LIBS@                \
320         @LIBGNUTLS_LIBS@
321
322 # Additional libs that I know how to build. These will be
323 # linked into the tshark executable.
324 tshark_additional_libs =                \
325         wiretap/libwiretap.la           \
326         epan/libwireshark.la
327
328 # This is the automake dependency variable for the executable
329 tshark_DEPENDENCIES = \
330         $(wireshark_optional_objects)   \
331         $(tshark_additional_libs)       \
332         $(plugin_libs)
333
334 # This automake variable adds to the link-line for the executable
335 tshark_LDADD = \
336         $(wireshark_optional_objects)   \
337         $(tshark_additional_libs)       \
338         @SNMP_LIBS@ @SSL_LIBS@          \
339         $(plugin_ldadd)                 \
340         @PCRE_LIBS@                     \
341         @GLIB_LIBS@ -lm                 \
342         @PCAP_LIBS@ @SOCKET_LIBS@ @NSL_LIBS@ @ADNS_LIBS@ @KRB5_LIBS@ \
343         @LIBICONV@                      \
344         @LIBGCRYPT_LIBS@                \
345         @LIBGNUTLS_LIBS@
346
347 if ENABLE_STATIC
348 tshark_LDFLAGS = -Wl,-static -all-static
349 else
350 tshark_LDFLAGS = -export-dynamic
351 endif
352
353 # Optional objects that I know how to build, and that are needed by
354 # text2pcap.
355 text2pcap_optional_objects = @STRERROR_O@ @STRPTIME_O@
356
357 text2pcap_DEPENDENCIES = text2pcap.h
358
359 # This automake variable adds to the link-line for the executable
360 text2pcap_LDADD = $(text2pcap_optional_objects) \
361         @GLIB_LIBS@ -lm
362
363 mergecap_DEPENDENCIES = wiretap/libwiretap.la
364
365 # This is the automake dependency variable for the executable
366 capinfos_DEPENDENCIES = wiretap/libwiretap.la
367 editcap_DEPENDENCIES = wiretap/libwiretap.la
368
369 # This automake variable adds to the link-line for the executable
370 capinfos_LDADD = wiretap/libwiretap.la @GLIB_LIBS@
371 editcap_LDADD = wiretap/libwiretap.la @GLIB_LIBS@
372 mergecap_LDADD = wiretap/libwiretap.la @GLIB_LIBS@
373
374 # Common headers
375 AM_CPPFLAGS = -I$(top_srcdir) -I$(top_srcdir)/wiretap
376
377 #
378 # Build the version string
379 #
380 # FORCE is the portable version of .PHONY
381 FORCE:
382
383 svnversion.h: FORCE
384         $(PERL) $(srcdir)/make-version.pl $(srcdir)
385
386 #
387 # Build the short version of the authors file for the about dialog
388 #
389 AUTHORS-SHORT: AUTHORS make-authors-short.pl
390         $(PERL) $(srcdir)/perlnoutf.pl $(srcdir)/make-authors-short.pl < $(srcdir)/AUTHORS > AUTHORS-SHORT
391
392 #
393 # Build the short version of the authors file with formatting codes for the
394 # man page
395 #
396 AUTHORS-SHORT-FORMAT: AUTHORS-SHORT make-authors-format.pl
397         $(PERL) $(srcdir)/perlnoutf.pl $(srcdir)/make-authors-format.pl < AUTHORS-SHORT > AUTHORS-SHORT-FORMAT
398
399 #
400 # Build shell scripts by doing variable substitution.
401 # Taken from autoconf 2.13.
402 #
403 editsh = sed -e 's,@''SHELL''@,$(SHELL),g'
404
405 SUFFIXES = .sh
406 .sh:
407         rm -f $@ $@.tmp
408         $(editsh) $< > $@.tmp && chmod +x $@.tmp && mv $@.tmp $@
409
410 #
411 # Build "tshark-tap-register.c", which contains a function
412 # "register_all_tap_listeners()"
413 # that calls the register routines for all tshark tap listeners.
414 #
415 # We do this by grepping through sources.
416 #
417 # Formatting conventions:  The name of the tap_listener_register_*
418 # routines must start in column zero, or must be preceded only by
419 # "void " starting in column zero, and must not be inside #if.
420 #
421 # The first argument is the directory in which the source files live.
422 # All subsequent arguments are the files to scan.
423 #
424 tshark-tap-register.c: $(TSHARK_TAP_SRC) $(srcdir)/make-tapreg-dotc
425         @echo Making tshark-tap-register.c
426         @$(srcdir)/make-tapreg-dotc tshark-tap-register.c $(srcdir) $(TSHARK_TAP_SRC)
427
428 ps.c: print.ps rdps
429         ./rdps $(srcdir)/print.ps ps.c
430
431 rdps: rdps.c
432         $(CC) $(CFLAGS) -o rdps $(srcdir)/rdps.c
433
434 randpkt_additional_libs = wiretap/libwiretap.la
435
436 randpkt_DEPENDENCIES = \
437         $(randpkt_additional_libs)
438
439 randpkt_LDADD = \
440         $(randpkt_additional_libs) \
441         @GLIB_LIBS@ -lm                 \
442         @PCAP_LIBS@ @SOCKET_LIBS@ @NSL_LIBS@ @ADNS_LIBS@
443
444 dftest_additional_libs =                \
445         wiretap/libwiretap.la           \
446         epan/libwireshark.la
447
448 dftest_DEPENDENCIES = \
449         $(wireshark_optional_objects)   \
450         $(dftest_additional_libs)       \
451         $(plugin_libs)
452
453 # This automake variable adds to the link-line for the executable
454 dftest_LDADD = \
455         $(wireshark_optional_objects)   \
456         $(dftest_additional_libs)       \
457         @SNMP_LIBS@ @SSL_LIBS@          \
458         $(plugin_ldadd)                 \
459         @PCRE_LIBS@                     \
460         @GLIB_LIBS@ -lm                 \
461         @PCAP_LIBS@ @SOCKET_LIBS@ @NSL_LIBS@ @ADNS_LIBS@ @KRB5_LIBS@ \
462         @LIBICONV@                      \
463         @LIBGCRYPT_LIBS@                \
464         @LIBGNUTLS_LIBS@
465
466 dftest_LDFLAGS = -export-dynamic
467
468 dumpcap_additional_libs = \
469         wiretap/libwiretap.la
470
471 dumpcap_DEPENDENCIES = \
472         $(dumpcap_additional_libs)
473
474 dumpcap_LDADD = \
475         $(dumpcap_additional_libs)      \
476         @GLIB_LIBS@                     \
477         @PCAP_LIBS@ @SOCKET_LIBS@ @NSL_LIBS@
478
479 #
480 # XXX - "svnversion.h" is distributed in the release tarball; should
481 # we be deleting it with "make clean", or should we only do that with
482 # "make maintainer-clean"?
483 #
484 CLEANFILES =            \
485         svnversion.h    \
486         @rdps_bin@      \
487         idl2wrs         \
488         *~              \
489         vgcore.pid*
490
491 #
492 # XXX - "ps.c" is distributed in the source tarballs; why is it in the
493 # list of files removed by "make distclean"?  (It's deliberately
494 # included in that list.)
495 #
496 DISTCLEANFILES = \
497         AUTHORS-SHORT           \
498         AUTHORS-SHORT-FORMAT    \
499         ps.c
500
501 MAINTAINERCLEANFILES =          \
502         $(GENERATED_FILES)      \
503         Makefile.in             \
504         aclocal.m4              \
505         config.h.in             \
506         configure               \
507         depcomp                 \
508         install-sh              \
509         ltmain.sh               \
510         missing
511
512 EXTRA_DIST = \
513         FAQ                     \
514         INSTALL.configure       \
515         Makefile.common         \
516         Makefile.nmake          \
517         README.aix              \
518         README.bsd              \
519         README.hpux             \
520         README.irix             \
521         README.linux            \
522         README.macos            \
523         README.tru64            \
524         README.vmware           \
525         README.win32            \
526         aclocal-fallback/glib-2.0.m4 \
527         aclocal-fallback/glib.m4 \
528         aclocal-fallback/gtk-2.0.m4 \
529         aclocal-fallback/gtk.m4 \
530         aclocal-fallback/iconv.m4 \
531         aclocal-flags           \
532         autogen.sh              \
533         capinfos.c              \
534         capture-wpcap.c         \
535         capture-wpcap.h         \
536         capture_wpcap_packet.c  \
537         capture_wpcap_packet.h  \
538         cfilters                \
539         colorfilters            \
540         config.h.win32          \
541         config.nmake            \
542         debian/README.debian    \
543         debian/changelog        \
544         debian/control          \
545         debian/copyright        \
546         debian/dirs             \
547         debian/docs             \
548         debian/menu             \
549         debian/postinst         \
550         debian/prerm            \
551         debian/rules            \
552         dfilters                \
553         doc/Makefile.am         \
554         doc/Makefile.nmake      \
555         doc/README.capture      \
556         doc/README.design       \
557         doc/README.developer    \
558         doc/README.idl2wrs      \
559         doc/README.malloc       \
560         doc/README.plugins      \
561         doc/README.regression   \
562         doc/README.stats_tree   \
563         doc/README.tapping      \
564         doc/README.xml-output   \
565         doc/capinfos.pod                \
566         doc/dfilter2pod.pl      \
567         doc/editcap.pod         \
568         doc/wireshark-filter.pod.template \
569         doc/wireshark.pod       \
570         doc/idl2wrs.pod         \
571         doc/mergecap.pod        \
572         doc/randpkt.txt         \
573         doc/tshark.pod  \
574         doc/text2pcap.pod       \
575         doc/dumpcap.pod \
576         docbook/Makefile.auto.am        \
577         doxygen.cfg.in          \
578         dumpcap.c       \
579         editcap.c               \
580         epan/libwireshark.def   \
581         wireshark.desktop       \
582         image/capinfos.rc.in    \
583         image/clist_ascend.xpm  \
584         image/clist_descend.xpm \
585         image/dn_arrow.xpm      \
586         image/dumpcap.rc.in     \
587         image/editcap.rc.in     \
588         image/hi16-app-wireshark.png    \
589         image/hi32-app-wireshark.png    \
590         image/hi48-app-wireshark.png    \
591         image/icon_layout_1.xpm \
592         image/icon_layout_2.xpm \
593         image/icon_layout_3.xpm \
594         image/icon_layout_4.xpm \
595         image/icon_layout_5.xpm \
596         image/icon_layout_6.xpm \
597         image/libwireshark.rc.in        \
598         image/lo16-app-wireshark.png    \
599         image/lo32-app-wireshark.png    \
600         image/lo48-app-wireshark.png    \
601         image/Makefile.nmake    \
602         image/mergecap.rc.in    \
603         image/nsis-checked.bmp  \
604         image/nsis-unchecked.bmp        \
605         image/README.image      \
606         image/stock_dialog_error_48.xpm \
607         image/stock_dialog_info_48.xpm  \
608         image/stock_dialog_question_48.xpm      \
609         image/stock_dialog_stop_48.xpm  \
610         image/stock_dialog_warning_48.xpm       \
611         image/text2pcap.rc.in   \
612         image/toolbar/autoscroll_24.xpm \
613         image/toolbar/capture_filter_24.xpm     \
614         image/toolbar/capture_interfaces_24.xpm \
615         image/toolbar/capture_options_24.xpm    \
616         image/toolbar/capture_restart_24.xpm    \
617         image/toolbar/capture_start_24.xpm      \
618         image/toolbar/capture_stop_24.xpm       \
619         image/toolbar/checkbox_16.xpm   \
620         image/toolbar/colorize_24.xpm   \
621         image/toolbar/conversations_16.xpm      \
622         image/toolbar/decode_as_16.xpm  \
623         image/toolbar/display_filter_24.xpm     \
624         image/toolbar/endpoints_16.xpm  \
625         image/toolbar/file_set_list_16.xpm      \
626         image/toolbar/file_set_next_16.xpm      \
627         image/toolbar/file_set_previous_16.xpm  \
628         image/toolbar/graphs_16.xpm     \
629         image/toolbar/internet_24.xpm   \
630         image/toolbar/resize_columns_24.xpm     \
631         image/toolbar/stock_add_24.xpm  \
632         image/toolbar/stock_bottom_24.xpm       \
633         image/toolbar/stock_clear_24.xpm        \
634         image/toolbar/stock_close_24.xpm        \
635         image/toolbar/stock_colorselector_24.xpm        \
636         image/toolbar/stock_help_24.xpm \
637         image/toolbar/stock_jump_to_24.xpm      \
638         image/toolbar/stock_left_arrow_24.xpm   \
639         image/toolbar/stock_ok_20.xpm   \
640         image/toolbar/stock_open_24.xpm \
641         image/toolbar/stock_preferences_24.xpm  \
642         image/toolbar/stock_print_24.xpm        \
643         image/toolbar/stock_properties_24.xpm   \
644         image/toolbar/stock_refresh_24.xpm      \
645         image/toolbar/stock_right_arrow_24.xpm  \
646         image/toolbar/stock_save_24.xpm \
647         image/toolbar/stock_save_as_24.xpm      \
648         image/toolbar/stock_search_24.xpm       \
649         image/toolbar/stock_stop_24.xpm \
650         image/toolbar/stock_top_24.xpm  \
651         image/toolbar/stock_zoom_1_24.xpm       \
652         image/toolbar/stock_zoom_in_24.xpm      \
653         image/toolbar/stock_zoom_out_24.xpm     \
654         image/toolbar/telephony_16.xpm  \
655         image/toolbar/time_24.xpm       \
656         image/toolbar/web_support_24.xpm        \
657         image/toolbar/wiki_24.xpm       \
658         image/tshark.rc.in      \
659         image/up_arrow.xpm      \
660         image/win32-file-dlg.rc \
661         image/wireshark.exe.manifest.in \
662         image/wireshark.ico     \
663         image/wireshark.rc.in   \
664         image/wiretap.rc.in     \
665         image/wsicon.svg        \
666         image/wsicon16.png      \
667         image/wsicon16.xpm      \
668         image/wsicon200.png     \
669         image/wsicon32.png      \
670         image/wsicon32.xpm      \
671         image/wsicon48.png      \
672         image/wsicon48.xpm      \
673         image/wsicon64.png      \
674         image/wsicon64.xpm      \
675         image/wsiconcap.svg     \
676         image/wsiconcap16.xpm   \
677         image/wsiconcap200.png  \
678         image/wsiconcap32.xpm   \
679         image/wsiconcap48.xpm   \
680         image/wslogo.eps        \
681         image/wslogo.svg        \
682         image/wssplash.xpm      \
683         make-authors-format.pl  \
684         make-authors-short.pl   \
685         make-manuf              \
686         make-tapreg-dotc        \
687         make-version.pl         \
688         manuf                   \
689         manuf.tmpl              \
690         mergecap.c              \
691         perlnoutf.pl            \
692         print.ps                \
693         $(diameter_DATA)        \
694         $(dtds_DATA)            \
695         $(radius_DATA)          \
696         randpkt.c               \
697         rdps.c                  \
698         text2pcap-scanner.l     \
699         text2pcap.c             \
700         text2pcap.h             \
701         wka.tmpl
702
703 if SETUID_INSTALL
704 install-exec-hook:
705         -chmod +s $(DESTDIR)$(bindir)/dumpcap
706         -chmod +s $(DESTDIR)$(bindir)/tshark
707 else
708 install-exec-hook:
709 endif
710
711 DIST_SUBDIRS = asn1 doc epan gtk help packaging plugins tools wiretap
712
713 if HAVE_PLUGINS
714 SUBDIRS = tools wiretap doc epan plugins packaging help @wireshark_SUBDIRS@
715 else
716 SUBDIRS = tools wiretap doc epan packaging help @wireshark_SUBDIRS@
717 endif
718
719 wireshark.1: doc/wireshark.pod AUTHORS-SHORT-FORMAT
720         (cd doc ; \
721         $(MAKE) ../wireshark.1 )
722
723 tshark.1: doc/tshark.pod
724         (cd doc ; \
725         $(MAKE) ../tshark.1 )
726
727 wireshark-filter.4: tshark doc/wireshark-filter.pod.template
728         (cd doc ; \
729         $(MAKE) ../wireshark-filter.4 )
730
731 capinfos.1: doc/capinfos.pod
732         (cd doc ; \
733         $(MAKE) ../capinfos.1 )
734
735 editcap.1: doc/editcap.pod
736         (cd doc ; \
737         $(MAKE) ../editcap.1 )
738
739 idl2wrs.1: doc/idl2wrs.pod
740         (cd doc ; \
741         $(MAKE) ../idl2wrs.1 )
742
743 mergecap.1: doc/mergecap.pod
744         (cd doc ; \
745         $(MAKE) ../mergecap.1 )
746
747 text2pcap.1: doc/text2pcap.pod
748         (cd doc ; \
749         $(MAKE) ../text2pcap.1 )
750
751 dumpcap.1: doc/dumpcap.pod
752         (cd doc ; \
753         $(MAKE) ../dumpcap.1 )
754
755 wireshark.html: doc/wireshark.pod AUTHORS-SHORT-FORMAT
756         (cd doc ; \
757         $(MAKE) ../wireshark.html )
758
759 tshark.html: doc/tshark.pod
760         (cd doc ; \
761         $(MAKE) ../tshark.html )
762
763 wireshark-filter.html: tshark doc/wireshark-filter.pod.template
764         (cd doc ; \
765         $(MAKE) ../wireshark-filter.html )
766
767 capinfos.html: doc/capinfos.pod
768         (cd doc ; \
769         $(MAKE) ../capinfos.html )
770
771 editcap.html: doc/editcap.pod
772         (cd doc ; \
773         $(MAKE) ../editcap.html )
774
775 idl2wrs.html: doc/idl2wrs.pod
776         (cd doc ; \
777         $(MAKE) ../idl2wrs.html )
778
779 mergecap.html: doc/mergecap.pod
780         (cd doc ; \
781         $(MAKE) ../mergecap.html )
782
783 text2pcap.html: doc/text2pcap.pod
784         (cd doc ; \
785         $(MAKE) ../text2pcap.html )
786
787 dumpcap.html: doc/dumpcap.pod
788         (cd doc ; \
789         $(MAKE) ../dumpcap.html )
790
791 libtool: $(LIBTOOL_DEPS)
792         $(SHELL) ./config.status --recheck
793
794 # We load top_stagedir with an explicit path so that libtool doesn't freak.
795 top_stagedir=`cd $(top_srcdir) && pwd`/packaging/svr4.stage
796 stagedir=$(top_stagedir)/$(PACKAGE).stage
797 host_cpu=@host_cpu@
798 host_os=@host_os@
799
800 svr4-package: $(bin_SCRIPTS) $(lib_LTLIBRARIES)
801         @if test x$(HAVE_SVR4_PACKAGING) = xyes ; then \
802                 rm -rf $(stagedir) ; \
803                 $(MAKE) DESTDIR=$(stagedir) install; \
804                 $(srcdir)/packaging/svr4/mkpkg \
805                         $(PACKAGE) \
806                         $(PACKAGE)-$(VERSION)-$(host_os)-$(host_cpu)-local \
807                         $(prefix) \
808                         $(top_stagedir) ; \
809         else \
810                 echo "Error: SVR4 packaging tools not found." ; \
811                 echo "Package build abandoned." ; \
812         fi
813
814 solaris-package: svr4-package
815
816 rpm_topdir=`cd $(top_srcdir) && pwd`/packaging/rpm
817 rpm-package: dist
818         if test x$(HAVE_RPM) = xyes ; then \
819                 cd $(rpm_topdir) ; \
820                 mkdir -p BUILD RPMS SOURCES ; \
821                 cd SOURCES ; \
822                 ln -s ../../../$(distdir).tar.gz ; \
823                 ln -s ../../../wireshark.desktop ; \
824                 ln -s ../../../image/wsicon64.png wireshark.png ; \
825                 cd .. ; \
826                 rpmbuild --define "_topdir `cd . && pwd`" -bb SPECS/wireshark.spec && \
827                         echo "Package successfully built in `pwd`/RPMS." ; \
828         else \
829                 echo "Error: RPM executable and/or source directory not found." ; \
830         fi
831 srpm-package: dist
832         if test x$(HAVE_RPM) = xyes ; then \
833                 cd $(rpm_topdir) ; \
834                 mkdir -p BUILD SRPMS SOURCES ; \
835                 cd SOURCES ; \
836                 ln -s ../../../$(distdir).tar.gz ; \
837                 ln -s ../../../wireshark.desktop ; \
838                 ln -s ../../../image/elogo3d64x64.png wireshark.png ; \
839                 cd .. ; \
840                 rpmbuild --define "_topdir `cd . && pwd`" -bs SPECS/wireshark.spec && \
841                         echo "Package successfully built in `pwd`/SRPMS." ; \
842         else \
843                 echo "Error: RPM executable and/or source directory not found." ; \
844         fi
845
846 debian-package: debian/rules
847         dpkg-buildpackage -rfakeroot -us -uc
848
849 clean-local:
850         rm -rf $(top_stagedir)
851