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