From Michael Lum: add the ability to have a preferences file containing
[obnox/wireshark/wip.git] / Makefile.am
1 # Makefile.am
2 # Automake file for Ethereal
3 #
4 # $Id: Makefile.am,v 1.607 2003/08/07 00:41:26 guy Exp $
5 #
6 # Ethereal - Network traffic analyzer
7 # By Gerald Combs <gerald@ethereal.com>
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 = @ethereal_bin@ @editcap_bin@ @mergecap_bin@ @tethereal_bin@ @dftest_bin@ @randpkt_bin@ @text2pcap_bin@
64 bin_SCRIPTS = @idl2eth_bin@
65 man1_MANS = @ethereal_man@ @editcap_man@ @mergecap_man@ @tethereal_man@ @text2pcap_man@ @idl2eth_man@
66 man_MANS =
67
68 EXTRA_PROGRAMS = ethereal tethereal editcap mergecap dftest text2pcap
69 EXTRA_SCRIPTS = idl2eth
70
71 #
72 # Ethereal configuration files are put in $(pkgdatadir).  It currently
73 # contains the "manuf" file and a "diameter" directory.
74 #
75 pkgdata_DATA = manuf
76
77 #
78 # Install the Diameter DTD and XML files in the "diameter" subdirectory
79 # of that directory.
80 #
81 diameterdir = $(pkgdatadir)/diameter
82 diameter_DATA = dictionary.dtd dictionary.xml mobileipv4.xml \
83         nasreq.xml sunping.xml
84
85 DISSECTOR_SRC = \
86         packet-aarp.c  \
87         packet-acap.c  \
88         packet-afp.c   \
89         packet-afs.c   \
90         packet-aim.c   \
91         packet-ajp13.c          \
92         packet-ans.c   \
93         packet-aodv.c  \
94         packet-arcnet.c \
95         packet-arp.c   \
96         packet-asap.c  \
97         packet-ascend.c\
98         packet-asf.c   \
99         packet-atalk.c \
100         packet-atm.c   \
101         packet-auto_rp.c   \
102         packet-bacapp.c   \
103         packet-bacnet.c   \
104         packet-beep.c \
105         packet-bgp.c   \
106         packet-bofl.c  \
107         packet-bootp.c \
108         packet-bootparams.c \
109         packet-bpdu.c  \
110         packet-brdwlk.c \
111         packet-bvlc.c \
112         packet-cdp.c   \
113         packet-cgmp.c  \
114         packet-chdlc.c  \
115         packet-clearcase.c  \
116         packet-clip.c  \
117         packet-clnp.c  \
118         packet-cops.c  \
119         packet-cosine.c  \
120         packet-cpha.c  \
121         packet-cups.c  \
122         packet-data.c  \
123         packet-dccp.c \
124         packet-dcerpc.c  \
125         packet-dcerpc-afs4int.c  \
126         packet-dcerpc-atsvc.c \
127         packet-dcerpc-bossvr.c  \
128         packet-dcerpc-browser.c  \
129         packet-dcerpc-cds_clerkserver.c  \
130         packet-dcerpc-cds_solicit.c  \
131         packet-dcerpc-conv.c  \
132         packet-dcerpc-cprpc_server.c  \
133         packet-dcerpc-dce122.c \
134         packet-dcerpc-dfs.c \
135         packet-dcerpc-dnsserver.c \
136         packet-dcerpc-dtsprovider.c \
137         packet-dcerpc-dtsstime_req.c \
138         packet-dcerpc-epm.c  \
139         packet-dcerpc-fldb.c  \
140         packet-dcerpc-ftserver.c \
141         packet-dcerpc-krb5rpc.c \
142         packet-dcerpc-lsa.c \
143         packet-dcerpc-lsa-ds.c \
144         packet-dcerpc-mapi.c  \
145         packet-dcerpc-messenger.c  \
146         packet-dcerpc-mgmt.c  \
147         packet-dcerpc-ndr.c  \
148         packet-dcerpc-netlogon.c \
149         packet-dcerpc-nspi.c \
150         packet-dcerpc-oxid.c  \
151         packet-dcerpc-reg.c \
152         packet-dcerpc-remact.c  \
153         packet-dcerpc-rep_proc.c  \
154         packet-dcerpc-roverride.c  \
155         packet-dcerpc-rpriv.c  \
156         packet-dcerpc-rs_acct.c  \
157         packet-dcerpc-rs_attr.c  \
158         packet-dcerpc-rs_misc.c  \
159         packet-dcerpc-rs_pgo.c  \
160         packet-dcerpc-rs_repadm.c  \
161         packet-dcerpc-rs_replist.c  \
162         packet-dcerpc-rs_unix.c  \
163         packet-dcerpc-rsec_login.c  \
164         packet-dcerpc-samr.c \
165         packet-dcerpc-secidmap.c \
166         packet-dcerpc-spoolss.c \
167         packet-dcerpc-srvsvc.c \
168         packet-dcerpc-svcctl.c \
169         packet-dcerpc-tapi.c \
170         packet-dcerpc-tkn4int.c \
171         packet-dcerpc-ubikdisk.c \
172         packet-dcerpc-ubikvote.c \
173         packet-dcerpc-update.c \
174         packet-dcerpc-wkssvc.c \
175         packet-ddtp.c  \
176         packet-dec-bpdu.c \
177         packet-dhcpv6.c \
178         packet-diameter.c \
179         packet-distcc.c \
180         packet-dlsw.c  \
181         packet-dns.c   \
182         packet-dsi.c   \
183         packet-dvmrp.c \
184         packet-eap.c \
185         packet-eapol.c \
186         packet-echo.c \
187         packet-edonkey.c \
188         packet-eigrp.c \
189         packet-enc.c    \
190         packet-enip.c   \
191         packet-esis.c  \
192         packet-eth.c   \
193         packet-etherip.c        \
194         packet-ethertype.c   \
195         packet-fc.c \
196         packet-fcct.c \
197         packet-fcdns.c \
198         packet-fcels.c \
199         packet-fcfcs.c \
200         packet-fcfzs.c \
201         packet-fcip.c \
202         packet-fclctl.c \
203         packet-fcp.c \
204         packet-fcswils.c \
205         packet-fddi.c  \
206         packet-fix.c  \
207         packet-fr.c    \
208         packet-frame.c  \
209         packet-ftp.c   \
210         packet-fw1.c   \
211         packet-giop.c  \
212         packet-gmrp.c \
213         packet-gnutella.c \
214         packet-gre.c   \
215         packet-gssapi.c \
216         packet-gtp.c   \
217         packet-gvrp.c  \
218         packet-h1.c    \
219         packet-h225.c  \
220         packet-h245.c  \
221         packet-h261.c  \
222         packet-hclnfsd.c  \
223         packet-hpext.c \
224         packet-hsrp.c  \
225         packet-http.c  \
226         packet-hyperscsi.c \
227         packet-iapp.c  \
228         packet-ib.c  \
229         packet-icap.c  \
230         packet-icmpv6.c\
231         packet-icp.c   \
232         packet-icq.c   \
233         packet-ieee80211.c \
234         packet-ieee8023.c \
235         packet-igmp.c  \
236         packet-igrp.c  \
237         packet-imap.c   \
238         packet-ip.c    \
239         packet-ipfc.c    \
240         packet-ipmi.c  \
241         packet-ipp.c   \
242         packet-ipsec.c \
243         packet-ipsec-udp.c \
244         packet-ipv6.c  \
245         packet-ipx.c   \
246         packet-ipxwan.c \
247         packet-irc.c   \
248         packet-isakmp.c\
249         packet-iscsi.c \
250         packet-isdn.c \
251         packet-isis.c  \
252         packet-isis-clv.c \
253         packet-isis-hello.c \
254         packet-isis-lsp.c \
255         packet-isis-snp.c \
256         packet-isl.c   \
257         packet-isns.c \
258         packet-isup.c  \
259         packet-iua.c   \
260         packet-jabber.c \
261         packet-kadm5.c \
262         packet-kerberos.c \
263         packet-klm.c   \
264         packet-l2tp.c  \
265         packet-lapb.c  \
266         packet-lapbether.c \
267         packet-lapd.c  \
268         packet-laplink.c  \
269         packet-ldap.c  \
270         packet-ldp.c   \
271         packet-llc.c   \
272         packet-lmi.c   \
273         packet-lmp.c   \
274         packet-lpd.c   \
275         packet-m2pa.c  \
276         packet-m2tp.c  \
277         packet-m2ua.c  \
278         packet-m3ua.c  \
279         packet-mbtcp.c \
280         packet-mdshdr.c \
281         packet-mip.c  \
282         packet-mip6.c  \
283         packet-mmse.c  \
284         packet-mount.c \
285         packet-mpeg1.c  \
286         packet-mpls.c \
287         packet-mrdisc.c \
288         packet-msdp.c  \
289         packet-msn-messenger.c \
290         packet-msnip.c \
291         packet-msproxy.c \
292         packet-mtp2.c \
293         packet-mtp3.c \
294         packet-mtp3mg.c \
295         packet-mysql.c \
296         packet-nbipx.c \
297         packet-nbns.c  \
298         packet-ncp.c   \
299         packet-ncp2222.c   \
300         packet-ndmp.c  \
301         packet-ndps.c  \
302         packet-netbios.c \
303         packet-netflow.c \
304         packet-nfs.c   \
305         packet-nfsacl.c \
306         packet-nfsauth.c \
307         packet-nisplus.c \
308         packet-nlm.c   \
309         packet-nlsp.c  \
310         packet-nntp.c  \
311         packet-ntlmssp.c  \
312         packet-ntp.c  \
313         packet-null.c  \
314         packet-osi.c   \
315         packet-osi-options.c \
316         packet-ospf.c  \
317         packet-pcnfsd.c \
318         packet-per.c \
319         packet-pflog.c \
320         packet-pgm.c   \
321         packet-pim.c   \
322         packet-pop.c   \
323         packet-portmap.c   \
324         packet-ppp.c   \
325         packet-pppoe.c \
326         packet-pptp.c  \
327         packet-prism.c \
328         packet-q2931.c \
329         packet-q931.c  \
330         packet-qllc.c  \
331         packet-quake.c \
332         packet-quake2.c \
333         packet-quake3.c \
334         packet-quakeworld.c \
335         packet-radius.c\
336         packet-ranap.c \
337         packet-raw.c   \
338         packet-rip.c   \
339         packet-ripng.c \
340         packet-rlogin.c \
341         packet-rmcp.c  \
342         packet-rmi.c \
343         packet-rmp.c   \
344         packet-rpc.c   \
345         packet-rpl.c   \
346         packet-rquota.c \
347         packet-rsh.c   \
348         packet-rstat.c \
349         packet-rsvp.c  \
350         packet-rsync.c \
351         packet-rtcp.c  \
352         packet-rtp.c   \
353         packet-rtsp.c  \
354         packet-rwall.c \
355         packet-rx.c  \
356         packet-sadmind.c \
357         packet-sap.c   \
358         packet-sccp.c  \
359         packet-sccpmg.c  \
360         packet-scsi.c  \
361         packet-sctp.c  \
362         packet-sdlc.c  \
363         packet-sdp.c   \
364         packet-sflow.c \
365         packet-sip.c   \
366         packet-skinny.c   \
367         packet-slimp3.c   \
368         packet-sll.c   \
369         packet-slowprotocols.c \
370         packet-smb.c   \
371         packet-smb-browse.c \
372         packet-smb-common.c \
373         packet-smb-logon.c \
374         packet-smb-mailslot.c \
375         packet-smb-pipe.c \
376         packet-smb-sidsnooping.c \
377         packet-smpp.c \
378         packet-smtp.c \
379         packet-sna.c   \
380         packet-snaeth.c \
381         packet-snmp.c   \
382         packet-socks.c \
383         packet-spnego.c \
384         packet-spray.c \
385         packet-srvloc.c \
386         packet-sscop.c \
387         packet-ssh.c   \
388         packet-ssl.c   \
389         packet-stat.c   \
390         packet-stat-notify.c \
391         packet-sua.c   \
392         packet-syslog.c \
393         packet-tacacs.c \
394         packet-tcp.c   \
395         packet-tds.c   \
396         packet-telnet.c\
397         packet-tftp.c  \
398         packet-time.c  \
399         packet-tns.c \
400         packet-tpkt.c  \
401         packet-tr.c    \
402         packet-trmac.c \
403         packet-tsp.c \
404         packet-tzsp.c  \
405         packet-ucp.c   \
406         packet-udp.c   \
407         packet-v120.c \
408         packet-vines.c \
409         packet-vj.c   \
410         packet-vlan.c \
411         packet-vrrp.c \
412         packet-vtp.c  \
413         packet-wap.c \
414         packet-wbxml.c \
415         packet-wccp.c \
416         packet-wcp.c \
417         packet-wfleet-hdlc.c \
418         packet-who.c  \
419         packet-wlancap.c \
420         packet-wsp.c \
421         packet-wtls.c \
422         packet-wtp.c \
423         packet-x11.c   \
424         packet-x25.c   \
425         packet-x29.c   \
426         packet-xdmcp.c \
427         packet-xot.c   \
428         packet-xyplex.c   \
429         packet-yhoo.c  \
430         packet-ymsg.c  \
431         packet-ypbind.c \
432         packet-yppasswd.c \
433         packet-ypserv.c \
434         packet-ypxfr.c \
435         packet-zebra.c
436
437 if HAVE_PLUGINS
438 plugin_libs = \
439         plugins/artnet/artnet.la \
440         plugins/docsis/docsis.la \
441         plugins/giop/cosnaming.la \
442         plugins/giop/coseventcomm.la \
443         plugins/gryphon/gryphon.la \
444         plugins/lwres/lwres.la \
445         plugins/megaco/megaco.la \
446         plugins/mgcp/mgcp.la \
447         plugins/pcli/pcli.la \
448         plugins/rtnet/rtnet.la 
449
450 if ENABLE_STATIC
451 plugin_ldadd = \
452         plugins/artnet/packet-artnet-static.o \
453         plugins/docsis/packet-bpkmattr-static.o \
454         plugins/docsis/packet-bpkmreq-static.o \
455         plugins/docsis/packet-bpkmrsp-static.o \
456         plugins/docsis/packet-docsis-static.o \
457         plugins/docsis/packet-dsaack-static.o \
458         plugins/docsis/packet-dsareq-static.o \
459         plugins/docsis/packet-dsarsp-static.o \
460         plugins/docsis/packet-dscack-static.o \
461         plugins/docsis/packet-dscreq-static.o \
462         plugins/docsis/packet-dscrsp-static.o \
463         plugins/docsis/packet-dsdreq-static.o \
464         plugins/docsis/packet-dsdrsp-static.o \
465         plugins/docsis/packet-macmgmt-static.o \
466         plugins/docsis/packet-map-static.o \
467         plugins/docsis/packet-regack-static.o \
468         plugins/docsis/packet-regreq-static.o \
469         plugins/docsis/packet-regrsp-static.o \
470         plugins/docsis/packet-rngreq-static.o \
471         plugins/docsis/packet-rngrsp-static.o \
472         plugins/docsis/packet-tlv-static.o \
473         plugins/docsis/packet-uccreq-static.o \
474         plugins/docsis/packet-uccrsp-static.o \
475         plugins/docsis/packet-ucd-static.o \
476         plugins/giop/packet-cosnaming-static.o \
477         plugins/giop/packet-coseventcomm-static.o \
478         plugins/gryphon/packet-gryphon-static.o \
479         plugins/lwres/packet-lwres-static.o \
480         plugins/megaco/packet-megaco-static.o \
481         plugins/mgcp/packet-mgcp-static.o \
482         plugins/pcli/packet-pcli-static.o \
483         plugins/rtnet/packet-rtnet-static.o 
484
485 plugin_src = \
486         plugins/artnet/packet-artnet.c \
487         plugins/docsis/packet-bpkmattr.c \
488         plugins/docsis/packet-bpkmreq.c \
489         plugins/docsis/packet-bpkmrsp.c \
490         plugins/docsis/packet-docsis.c \
491         plugins/docsis/packet-dsaack.c \
492         plugins/docsis/packet-dsareq.c \
493         plugins/docsis/packet-dsarsp.c \
494         plugins/docsis/packet-dscack.c \
495         plugins/docsis/packet-dscreq.c \
496         plugins/docsis/packet-dscrsp.c \
497         plugins/docsis/packet-dsdreq.c \
498         plugins/docsis/packet-dsdrsp.c \
499         plugins/docsis/packet-macmgmt.c \
500         plugins/docsis/packet-map.c \
501         plugins/docsis/packet-regack.c \
502         plugins/docsis/packet-regreq.c \
503         plugins/docsis/packet-regrsp.c \
504         plugins/docsis/packet-rngreq.c \
505         plugins/docsis/packet-rngrsp.c \
506         plugins/docsis/packet-tlv.c \
507         plugins/docsis/packet-uccreq.c \
508         plugins/docsis/packet-uccrsp.c \
509         plugins/docsis/packet-ucd.c \
510         plugins/giop/packet-cosnaming.c \
511         plugins/giop/packet-coseventcomm.c \
512         plugins/gryphon/packet-gryphon.c \
513         plugins/lwres/packet-lwres.c \
514         plugins/megaco/packet-megaco.c \
515         plugins/mgcp/packet-mgcp.c \
516         plugins/pcli/packet-pcli.c \
517         plugins/rtnet/packet-rtnet.c 
518
519 else            # ENABLE_STATIC
520 plugin_ldadd = \
521         "-dlopen" self  \
522         "-dlopen" plugins/artnet/artnet.la \
523         "-dlopen" plugins/docsis/docsis.la \
524         "-dlopen" plugins/giop/cosnaming.la \
525         "-dlopen" plugins/giop/coseventcomm.la \
526         "-dlopen" plugins/gryphon/gryphon.la \
527         "-dlopen" plugins/lwres/lwres.la \
528         "-dlopen" plugins/megaco/megaco.la \
529         "-dlopen" plugins/mgcp/mgcp.la \
530         "-dlopen" plugins/pcli/pcli.la \
531         "-dlopen" plugins/rtnet/rtnet.la 
532
533 plugin_src =
534
535 endif           # ENABLE_STATIC
536
537 else            # HAVE_PLUGINS
538 plugin_src =
539
540 plugin_libs =
541
542 plugin_ldadd =
543 endif           # HAVE_PLUGINS
544
545 noinst_HEADERS = \
546         packet-afp.h   \
547         packet-afs-defs.h \
548         packet-afs-macros.h \
549         packet-afs-register-info.h \
550         packet-afs.h   \
551         packet-arcnet.h \
552         packet-arp.h   \
553         packet-atalk.h \
554         packet-atm.h   \
555         packet-bgp.h   \
556         packet-bootparams.h \
557         packet-chdlc.h \
558         packet-clearcase.h  \
559         packet-clip.h  \
560         packet-data.h \
561         packet-dccp.h \
562         packet-dcerpc-atsvc.h \
563         packet-dcerpc-browser.h \
564         packet-dcerpc-dce122.h \
565         packet-dcerpc-dfs.h \
566         packet-dcerpc-dnsserver.h \
567         packet-dcerpc-lsa.h \
568         packet-dcerpc-mapi.h \
569         packet-dcerpc-netlogon.h \
570         packet-dcerpc-nt.h \
571         packet-dcerpc-reg.h \
572         packet-dcerpc-samr.h \
573         packet-dcerpc-spoolss.h \
574         packet-dcerpc-srvsvc.h \
575         packet-dcerpc-svcctl.h \
576         packet-dcerpc-tapi.h \
577         packet-dcerpc-wkssvc.h \
578         packet-dcerpc.h \
579         packet-ddtp.h  \
580         packet-diameter-defs.h \
581         packet-dns.h   \
582         packet-dvmrp.h \
583         packet-edonkey.h \
584         packet-esis.h  \
585         packet-eth.h   \
586         packet-fc.h \
587         packet-fcbls.h \
588         packet-fcct.h \
589         packet-fcdns.h \
590         packet-fcels.h \
591         packet-fcfcs.h \
592         packet-fcfzs.h \
593         packet-fclctl.h \
594         packet-fcp.h \
595         packet-fcswils.h \
596         packet-fddi.h  \
597         packet-frame.h  \
598         packet-giop.h  \
599         packet-gnutella.h \
600         packet-gssapi.h \
601         packet-gtp.h    \
602         packet-h245.h    \
603         packet-hclnfsd.h  \
604         packet-hpext.h  \
605         packet-http.h  \
606         packet-ieee80211.h \
607         packet-ieee8023.h \
608         packet-igmp.h  \
609         packet-ip.h    \
610         packet-ipfc.h  \
611         packet-ipsec.h \
612         packet-ipv6.h  \
613         packet-ipx.h   \
614         packet-isis-clv.h \
615         packet-isis-hello.h \
616         packet-isis-lsp.h \
617         packet-isis-snp.h \
618         packet-isis.h  \
619         packet-isl.h   \
620         packet-kerberos.h \
621         packet-klm.h   \
622         packet-ldap.h  \
623         packet-llc.h   \
624         packet-mip6.h  \
625         packet-mount.h \
626         packet-mrdisc.h \
627         packet-msnip.h \
628         packet-mtp3.h  \
629         packet-ncp-int.h \
630         packet-ndps.h    \
631         packet-netbios.h \
632         packet-nfs.h   \
633         packet-nisplus.h \
634         packet-nlm.h   \
635         packet-ntp.h  \
636         packet-null.h  \
637         packet-osi-options.h \
638         packet-osi.h   \
639         packet-pcnfsd.h \
640         packet-per.h   \
641         packet-pflog.h \
642         packet-pim.h   \
643         packet-portmap.h   \
644         packet-ppp.h   \
645         packet-prism.h \
646         packet-q931.h  \
647         packet-raw.h   \
648         packet-ripng.h \
649         packet-rmi.h   \
650         packet-rpc.h   \
651         packet-rquota.h \
652         packet-rsvp.h  \
653         packet-rtcp.h  \
654         packet-rtp.h   \
655         packet-rwall.h  \
656         packet-rx.h  \
657         packet-scsi.h  \
658         packet-sll.h   \
659         packet-smb-browse.h \
660         packet-smb-common.h \
661         packet-smb-logon.h \
662         packet-smb-mailslot.h \
663         packet-smb-pipe.h \
664         packet-smb-sidsnooping.h \
665         packet-sna.h   \
666         packet-snmp.h   \
667         packet-spray.h \
668         packet-stat-notify.h \
669         packet-stat.h   \
670         packet-tcp.h   \
671         packet-tns.h \
672         packet-tpkt.h  \
673         packet-tr.h    \
674         packet-udp.h   \
675         packet-vines.h \
676         packet-vlan.h \
677         packet-wap.h \
678         packet-wccp.h \
679         packet-wlancap.h \
680         packet-wsp.h \
681         packet-wtls.h \
682         packet-wtp.h \
683         packet-x11-keysym.h     \
684         packet-ypbind.h \
685         packet-yppasswd.h \
686         packet-ypserv.h \
687         packet-ypxfr.h
688
689 ETHEREAL_COMMON_SRC = \
690         afn.c          \
691         afn.h          \
692         aftypes.h      \
693         alignment.h    \
694         arcnet_pids.h  \
695         asn1.c         \
696         asn1.h         \
697         bridged_pids.h \
698         capture_stop_conditions.c   \
699         capture_stop_conditions.h   \
700         cfile.c         \
701         cfile.h         \
702         chdlctypes.h   \
703         color.h        \
704         column.c       \
705         column.h       \
706         conditions.c   \
707         conditions.h   \
708         crypt-des.c    \
709         crypt-des.h    \
710         crypt-md4.c    \
711         crypt-md4.h    \
712         crypt-md5.c    \
713         crypt-md5.h    \
714         crypt-rc4.c    \
715         crypt-rc4.h    \
716         disabled_protos.c      \
717         disabled_protos.h      \
718         etypes.h       \
719         file.h         \
720         follow.c       \
721         follow.h       \
722         format-oid.h   \
723         g711.c          \
724         g711.h          \
725         greproto.h     \
726         in_cksum.c     \
727         in_cksum.h     \
728         ip_opts.h      \
729         ipproto.c      \
730         ipproto.h      \
731         llcsaps.h      \
732         nlpid.h        \
733         oui.h          \
734         packet-dcerpc-nt.c \
735         pcap-util.c    \
736         pcap-util.h    \
737         ppptypes.h     \
738         prefs-int.h    \
739         prefs.c        \
740         prefs.h        \
741         print.c        \
742         print.h        \
743         ps.c           \
744         ps.h           \
745         ptvcursor.c     \
746         ptvcursor.h     \
747         reassemble.c   \
748         reassemble.h   \
749         register.h     \
750         ringbuffer.c   \
751         ringbuffer.h   \
752         rpc_defrag.h   \
753         sctpppids.h    \
754         smb.h          \
755         tap.c           \
756         tap.h           \
757         timestats.c     \
758         timestats.h     \
759         util.c         \
760         util.h         \
761         x11-declarations.h \
762         x11-register-info.h \
763         x264_prt_id.h  \
764         xdlc.c         \
765         xdlc.h         \
766         xmlstub.c      \
767         xmlstub.h
768
769 BUILT_SOURCES = \
770         x11-declarations.h \
771         x11-register-info.h
772
773 ethereal_SOURCES = \
774         $(DISSECTOR_SRC) \
775         $(ETHEREAL_COMMON_SRC) \
776         register.c     \
777         capture.c      \
778         capture.h      \
779         file.c         \
780         filters.c      \
781         filters.h      \
782         globals.h      \
783         menu.h         \
784         progress_dlg.h \
785         proto_hier_stats.h      \
786         proto_hier_stats.c      \
787         simple_dialog.h \
788         statusbar.h    \
789         summary.c      \
790         summary.h      \
791         ui_util.h
792
793 EXTRA_ethereal_SOURCES = \
794         snprintf.c      \
795         snprintf.h      \
796         snprintf-imp.h  \
797         strerror.c      \
798         strerror.h      \
799         strcasecmp.c    \
800         strncasecmp.c   \
801         mkstemp.c       \
802         mkstemp.h       \
803         strptime.c      \
804         strptime.h
805
806 # Optional objects that I know how to build. These will be
807 # linked into the ethereal executable.
808 # They will also be linked into the tethereal executable; if this
809 # list ever grows to include something that can't be linked with
810 # tethereal, or if tethereal needs something that ethereal doesn't,
811 # we should probably split this into stuff needed both
812 # by ethereal and tethereal and stuff needed only by one or the
813 # other.
814 ethereal_optional_objects = @SNPRINTF_O@ @STRERROR_O@ \
815         @STRCASECMP_O@ @STRNCASECMP_O@ @MKSTEMP_O@ @STRPTIME_O@
816
817 # Additional libs that I know how to build. These will be
818 # linked into the ethereal executable.
819 ethereal_additional_libs = \
820         wiretap/libwiretap.a    \
821         gtk/libui.a             \
822         epan/libethereal.a      \
823         epan/ftypes/libftypes.a \
824         epan/dfilter/libdfilter.a
825
826 # This is the automake dependency variable for the executable
827 ethereal_DEPENDENCIES = \
828         $(ethereal_optional_objects)    \
829         $(ethereal_additional_libs)     \
830         $(plugin_libs)
831
832 # This automake variable adds to the link-line for the executable.
833 #
834 # Note that Ethereal doesn't have to be linked with @GLIB_LIBS@, as
835 # they are included in @GTK_LIBS@, and doesn't have to be linked with
836 # @SOCKET_LIBS@ or @NSL_LIBS@, as those should also be included in
837 # @GTK_LIBS@ (as those are also needed for X applications, and GTK+
838 # applications are X applications).
839
840 if ENABLE_STATIC
841 ethereal_LDFLAGS = -Wl,-static -all-static
842 else
843 ethereal_LDFLAGS = -export-dynamic
844 endif
845
846 ethereal_LDADD = \
847         $(ethereal_optional_objects)    \
848         $(ethereal_additional_libs)     \
849         @SNMP_LIBS@ @SSL_LIBS@          \
850         $(plugin_ldadd)                 \
851         @PCAP_LIBS@ @GTK_LIBS@ @ADNS_LIBS@
852
853 TETHEREAL_TAP_SRC = \
854         tap-dcerpcstat.c        \
855         tap-iostat.c            \
856         tap-iousers.c           \
857         tap-mgcpstat.c          \
858         tap-protocolinfo.c      \
859         tap-protohierstat.c     \
860         tap-rpcstat.c           \
861         tap-rpcprogs.c          \
862         tap-smbsids.c           \
863         tap-smbstat.c
864
865 tethereal_SOURCES = \
866         $(DISSECTOR_SRC) \
867         $(ETHEREAL_COMMON_SRC) \
868         $(TETHEREAL_TAP_SRC) \
869         tethereal-tap-register.c \
870         register.c     \
871         tethereal.c
872
873 # Additional libs that I know how to build. These will be
874 # linked into the tethereal executable.
875 tethereal_additional_libs =             \
876         wiretap/libwiretap.a            \
877         epan/libethereal.a              \
878         epan/ftypes/libftypes.a         \
879         epan/dfilter/libdfilter.a
880
881 # This is the automake dependency variable for the executable
882 tethereal_DEPENDENCIES = \
883         $(ethereal_optional_objects)    \
884         $(tethereal_additional_libs)    \
885         $(plugin_libs)
886
887 # This automake variable adds to the link-line for the executable
888 tethereal_LDADD = \
889         $(ethereal_optional_objects)    \
890         $(tethereal_additional_libs)    \
891         @SNMP_LIBS@ @SSL_LIBS@          \
892         $(plugin_ldadd)                 \
893         @GLIB_LIBS@ -lm                 \
894         @PCAP_LIBS@ @SOCKET_LIBS@ @NSL_LIBS@ @ADNS_LIBS@
895
896 if ENABLE_STATIC
897 tethereal_LDFLAGS = -Wl,-static -all-static
898 else
899 tethereal_LDFLAGS = -export-dynamic
900 endif
901
902 # Optional objects that I know how to build, and that are needed by
903 # text2pcap.
904 text2pcap_optional_objects = @STRERROR_O@ @STRPTIME_O@
905
906 text2pcap_SOURCES = text2pcap.c text2pcap-scanner.l
907 text2pcap_DEPENDENCIES = text2pcap.h
908
909 # This automake variable adds to the link-line for the executable
910 text2pcap_LDADD = $(text2pcap_optional_objects) \
911         @GLIB_LIBS@ -lm
912
913 mergecap_SOURCES = mergecap.c
914 mergecap_DEPENDENCIES = wiretap/libwiretap.a
915
916 editcap_SOURCES = editcap.c
917
918 # This is the automake dependency variable for the executable
919 editcap_DEPENDENCIES = wiretap/libwiretap.a
920
921 # This automake variable adds to the link-line for the executable
922 editcap_LDADD = wiretap/libwiretap.a @GLIB_LIBS@
923 mergecap_LDADD = wiretap/libwiretap.a @GLIB_LIBS@
924
925 #
926 # Build various header files for the X11 dissector.
927 #
928 x11-declarations.h x11-register-info.h: x11-fields process-x11-fields.pl
929         $(PERL) $(srcdir)/process-x11-fields.pl <$(srcdir)/x11-fields
930
931 #
932 # Build shell scripts by doing variable substitution.
933 # Taken from autoconf 2.13.
934 #
935 editsh = sed -e 's,@''SHELL''@,$(SHELL),g'
936
937 SUFFIXES = .sh
938 .sh:
939         rm -f $@ $@.tmp
940         $(editsh) $< > $@.tmp && chmod +x $@.tmp && mv $@.tmp $@
941
942 #
943 # Build "register.c", which contains a function "register_all_protocols()"
944 # that calls the register routines for all protocols.
945 #
946 # We do this by grepping through sources.  If that turns out to be too slow,
947 # maybe we could just require every .o file to have an register routine
948 # of a given name (packet-aarp.o -> proto_register_aarp, etc.).
949 #
950 # Formatting conventions:  The name of the proto_register_* routines must
951 # start in column zero, or must be preceded only by "void " starting in
952 # column zero, and must not be inside #if.
953 #
954 # We assume that all dissector routines are in "packet-XXX.c" files.
955 #
956 # For some unknown reason, having a big "for" loop in the Makefile
957 # to scan all the "packet-XXX.c" files doesn't work with some "make"s;
958 # they seem to pass only the first few names in the list to the shell,
959 # for some reason.
960 #
961 # Therefore, we have a script to generate the "register.c" file.
962 #
963 # The first argument is the name of the file to write.
964 # The second argument is the directory in which the source files live.
965 # All subsequent arguments are the files to scan.
966 #
967 register.c: $(plugin_src) $(DISSECTOR_SRC) $(srcdir)/make-reg-dotc
968         @if test -n $(PYTHON); then \
969                 echo Making register.c with python ; \
970                 $(PYTHON) $(srcdir)/make-reg-dotc.py $(srcdir) $(DISSECTOR_SRC) ; \
971         else \
972                 echo Making register.c with shell script ; \
973                 $(srcdir)/make-reg-dotc register.c $(srcdir) \
974                         $(plugin_src) $(DISSECTOR_SRC) ; \
975         fi
976
977 #
978 # Build "tethereal-tap-register.c", which contains a function 
979 # "register_all_tap_listeners()"
980 # that calls the register routines for all tehtereal tap listeners.
981 #
982 # We do this by grepping through sources.
983 #
984 # Formatting conventions:  The name of the tap_listener_register_* 
985 # routines must start in column zero, or must be preceded only by 
986 # "void " starting in column zero, and must not be inside #if.
987 #
988 # The first argument is the directory in which the source files live.
989 # All subsequent arguments are the files to scan.
990 #
991 tethereal-tap-register.c: $(TETHEREAL_TAP_SRC) $(srcdir)/make-tapreg-dotc
992         @echo Making tethereal-tap-register.c
993         @$(srcdir)/make-tapreg-dotc tethereal-tap-register.c $(srcdir) $(TETHEREAL_TAP_SRC)
994
995 ps.c: print.ps rdps
996         ./rdps $(srcdir)/print.ps ps.c
997
998 rdps: rdps.c
999         $(CC) $(CFLAGS) -o rdps $(srcdir)/rdps.c
1000
1001 randpkt.o: randpkt.c
1002         $(CC) -DHAVE_CONFIG_H -I. `glib-config --cflags` -c $(srcdir)/randpkt.c
1003
1004 randpkt: randpkt.o wiretap/libwiretap.a
1005         $(LINK) -o randpkt randpkt.o wiretap/libwiretap.a `glib-config --libs` -lz
1006
1007
1008 dftest_SOURCES = \
1009         $(DISSECTOR_SRC) \
1010         $(ETHEREAL_COMMON_SRC) \
1011         register.c     \
1012         dftest.c
1013
1014 dftest_additional_libs =                \
1015         wiretap/libwiretap.a            \
1016         epan/libethereal.a              \
1017         epan/ftypes/libftypes.a         \
1018         epan/dfilter/libdfilter.a
1019
1020 dftest_DEPENDENCIES = \
1021         $(ethereal_optional_objects)    \
1022         $(dftest_additional_libs)       \
1023         $(plugin_libs)
1024
1025 # This automake variable adds to the link-line for the executable
1026 dftest_LDADD = \
1027         $(ethereal_optional_objects)    \
1028         $(dftest_additional_libs)       \
1029         @SNMP_LIBS@ @SSL_LIBS@          \
1030         $(plugin_ldadd)                 \
1031         @GLIB_LIBS@ -lm \
1032         @PCAP_LIBS@ @SOCKET_LIBS@ @NSL_LIBS@ @ADNS_LIBS@
1033
1034 dftest_LDFLAGS = -export-dynamic
1035
1036 CLEANFILES =    \
1037         idl2eth
1038
1039 DISTCLEANFILES =        \
1040         aclocal-missing/*.m4 \
1041         ps.c            \
1042         rdps            \
1043         *~
1044
1045 MAINTAINERCLEANFILES =          \
1046         register.c              \
1047         ps.c
1048
1049 EXTRA_DIST = \
1050         Ethereal.desktop        \
1051         FAQ                     \
1052         FAQ.include             \
1053         INSTALL.configure       \
1054         Makefile.nmake          \
1055         README.aix              \
1056         README.bsd              \
1057         README.hpux             \
1058         README.irix             \
1059         README.linux            \
1060         README.tru64            \
1061         README.vmware           \
1062         README.win32            \
1063         TODO                    \
1064         aclocal-fallback/glib-2.0.m4 \
1065         aclocal-fallback/glib.m4 \
1066         aclocal-fallback/gtk-2.0.m4 \
1067         aclocal-fallback/gtk.m4 \
1068         aclocal-flags           \
1069         aclocal-missing/dummy   \
1070         autogen.sh              \
1071         capture-wpcap.c         \
1072         capture-wpcap.h         \
1073         cleanbld.bat            \
1074         config.h.win32          \
1075         config.nmake            \
1076         debian/README.debian    \
1077         debian/changelog        \
1078         debian/control          \
1079         debian/copyright        \
1080         debian/dirs             \
1081         debian/docs             \
1082         debian/menu             \
1083         debian/postinst         \
1084         debian/prerm            \
1085         debian/rules            \
1086         dictionary.dtd          \
1087         dictionary.xml          \
1088         doc/Makefile.am         \
1089         doc/Makefile.nmake      \
1090         doc/README.design       \
1091         doc/README.developer    \
1092         doc/README.idl2eth      \
1093         doc/README.plugins      \
1094         doc/README.regression   \
1095         doc/README.tapping      \
1096         doc/README.tvbuff       \
1097         doc/dfilter2pod.pl      \
1098         doc/editcap.pod         \
1099         doc/ethereal.pod.template \
1100         doc/idl2eth.pod         \
1101         doc/mergecap.pod        \
1102         doc/randpkt.txt         \
1103         doc/tethereal.pod.template \
1104         doc/text2pcap.pod       \
1105         editcap.c               \
1106         ethereal_be.py          \
1107         ethereal_gen.py         \
1108         getopt.c                \
1109         getopt.h                \
1110         idl2eth.sh              \
1111         image/Makefile.nmake    \
1112         image/README.image      \
1113         image/clist_ascend.xpm  \
1114         image/clist_descend.xpm \
1115         image/dn_arrow.xpm      \
1116         image/editcap.rc.in     \
1117         image/eexcl3d64.xpm     \
1118         image/eicon3d16.xpm     \
1119         image/eicon3d32.xpm     \
1120         image/eicon3d48.xpm     \
1121         image/eicon3d64.xpm     \
1122         image/elogo3d48x48.png  \
1123         image/ethereal.ico      \
1124         image/ethereal.rc.in    \
1125         image/ethereal48x48-trans.png  \
1126         image/ethereal48x48.png \
1127         image/hi16-app-ethereal.png     \
1128         image/hi32-app-ethereal.png     \
1129         image/hi48-app-ethereal.png     \
1130         image/icon-ethereal.xpm \
1131         image/icon-excl.xpm     \
1132         image/lo16-app-ethereal.png     \
1133         image/lo32-app-ethereal.png     \
1134         image/lo48-app-ethereal.png     \
1135         image/mergecap.rc.in    \
1136         image/nsis-checked.bmp  \
1137         image/nsis-unchecked.bmp        \
1138         image/tethereal.rc.in   \
1139         image/text2pcap.rc.in   \
1140         image/up_arrow.xpm      \
1141         make-manuf              \
1142         make-reg-dotc           \
1143         make-reg-dotc.py        \
1144         make-tapreg-dotc                \
1145         manuf                   \
1146         manuf.tmpl              \
1147         mergecap.c              \
1148         mobileipv4.xml          \
1149         nasreq.xml              \
1150         ncp2222.py              \
1151         packet-ncp2222.inc      \
1152         print.ps                \
1153         process-x11-fields.pl   \
1154         randpkt.c               \
1155         rdps.c                  \
1156         sunping.xml             \
1157         text2pcap-scanner.l     \
1158         text2pcap.c             \
1159         text2pcap.h             \
1160         wka.tmpl                \
1161         x11-fields
1162
1163 if SETUID_INSTALL
1164 install-exec-hook:
1165         -chmod +s $(DESTDIR)$(bindir)/ethereal
1166         -chmod +s $(DESTDIR)$(bindir)/tethereal
1167 else
1168 install-exec-hook:
1169 endif
1170
1171 #
1172 # Currently register.c can be included in the distribution because
1173 # we always build all protocol dissectors. We used to have to check
1174 # whether or not to build the snmp dissector. If we again need to
1175 # variably build something, making register.c non-portable, uncomment
1176 # the dist-hook line below.
1177 #
1178 # Oh, yuk.  We don't want to include "register.c" in the distribution, as
1179 # its contents depend on the configuration, and therefore we want it
1180 # to be built when the first "make" is done; however, Automake insists
1181 # on putting *all* source into the distribution.
1182 #
1183 # We work around this by having a "dist-hook" rule that deletes
1184 # "register.c", so that "dist" won't pick it up.
1185 #
1186 #dist-hook:
1187 #       @rm -f $(distdir)/register.c
1188
1189 DIST_SUBDIRS = tools wiretap doc epan plugins packaging gtk
1190
1191 if HAVE_PLUGINS
1192 SUBDIRS = tools wiretap doc epan plugins packaging @ethereal_SUBDIRS@
1193 else
1194 SUBDIRS = tools wiretap doc epan packaging @ethereal_SUBDIRS@
1195 endif
1196
1197 ethereal.1: ethereal doc/ethereal.pod.template
1198         (cd doc ; \
1199         $(MAKE) ../ethereal.1 )
1200
1201 tethereal.1: tethereal doc/tethereal.pod.template
1202         (cd doc ; \
1203         $(MAKE) ../tethereal.1 )
1204
1205 editcap.1: doc/editcap.pod
1206         (cd doc ; \
1207         $(MAKE) ../editcap.1 )
1208
1209 idl2eth.1: doc/idl2eth.pod
1210         (cd doc ; \
1211         $(MAKE) ../idl2eth.1 )
1212
1213 mergecap.1: doc/mergecap.pod
1214         (cd doc ; \
1215         $(MAKE) ../mergecap.1 )
1216
1217 text2pcap.1: doc/text2pcap.pod
1218         (cd doc ; \
1219         $(MAKE) ../text2pcap.1 )
1220
1221 packet-ncp2222.c : ncp2222.py
1222         $(PYTHON) $(srcdir)/ncp2222.py -o $@
1223
1224 libtool: $(LIBTOOL_DEPS)
1225         $(SHELL) ./config.status --recheck
1226
1227 # We load top_stagedir with an explicit path so that libtool doesn't freak.
1228 top_stagedir=`cd $(top_srcdir) && pwd`/packaging/svr4.stage
1229 stagedir=$(top_stagedir)/$(PACKAGE).stage
1230 host_cpu=@host_cpu@
1231 host_os=@host_os@
1232
1233 svr4-package: $(bin_SCRIPTS) $(lib_LTLIBRARIES)
1234         if test x$(HAVE_SVR4_PACKAGING) = xyes ; then \
1235                 rm -rf $(stagedir) ; \
1236                 $(MAKE) DESTDIR=$(stagedir) install; \
1237                 $(srcdir)/packaging/svr4/mkpkg \
1238                         $(PACKAGE) \
1239                         $(PACKAGE)-$(VERSION)-$(host_os)-$(host_cpu)-local \
1240                         $(prefix) \
1241                         $(top_stagedir) ; \
1242         else \
1243                 echo "Error: SVR4 packaging tools not found." ; \
1244                 echo "Package build abandoned." ; \
1245         fi
1246
1247 solaris-package: svr4-package
1248
1249 rpm_topdir=`cd $(top_srcdir) && pwd`/packaging/rpm
1250 rpm-package: dist
1251         if test x$(HAVE_RPM) = xyes ; then \
1252                 cd $(rpm_topdir) ; \
1253                 mkdir -p BUILD RPMS SOURCES ; \
1254                 cd SOURCES ; \
1255                 ln -s ../../../$(distdir).tar.gz ; \
1256                 cd .. ; \
1257                 rpm --define "_topdir `cd . && pwd`" -bb SPECS/ethereal.spec && \
1258                         echo "Package successfully built in `pwd`/RPMS." ; \
1259         else \
1260                 echo "Error: RPM executable and/or source directory not found." ; \
1261         fi
1262 srpm-package: dist
1263         if test x$(HAVE_RPM) = xyes ; then \
1264                 cd $(rpm_topdir) ; \
1265                 mkdir -p BUILD SRPMS SOURCES ; \
1266                 cd SOURCES ; \
1267                 ln -s ../../../$(distdir).tar.gz ; \
1268                 cd .. ; \
1269                 rpm --define "_topdir `cd . && pwd`" -bs SPECS/ethereal.spec && \
1270                         echo "Package successfully built in `pwd`/SRPMS." ; \
1271         else \
1272                 echo "Error: RPM executable and/or source directory not found." ; \
1273         fi
1274
1275 debian-package: debian/rules
1276         dpkg-buildpackage -rfakeroot -us -uc
1277
1278 clean-local:
1279         rm -rf $(top_stagedir)
1280
1281 test-splint: $(ethereal_SOURCES)
1282         splint \
1283                 -gnu-extensions -D_U_=""        \
1284                 -I. `glib-config --cflags` \
1285                 -I./epan \
1286                 -I./tools/lemon \
1287                 -I./wiretap     \
1288                 $(ethereal_SOURCES)