From St├ęphane Gorse:
[metze/wireshark/wip.git] / Makefile.common
1 # Makefile.common
2 #     Contains the stuff from Makefile.am and Makefile.nmake that is
3 #     a) common to both files and
4 #     b) portable between both files
5 #
6 # $Id$
7 #
8 # Wireshark - Network traffic analyzer
9 # By Gerald Combs <gerald@wireshark.org>
10 # Copyright 1998 Gerald Combs
11 #
12 # This program is free software; you can redistribute it and/or
13 # modify it under the terms of the GNU General Public License
14 # as published by the Free Software Foundation; either version 2
15 # of the License, or (at your option) any later version.
16 #
17 # This program is distributed in the hope that it will be useful,
18 # but WITHOUT ANY WARRANTY; without even the implied warranty of
19 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
20 # GNU General Public License for more details.
21 #
22 # You should have received a copy of the GNU General Public License
23 # along with this program; if not, write to the Free Software
24 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
25
26 # "BUILT_SOURCES" are built before any "make all" or "make check" targets.
27 BUILT_HEADER_FILES =    \
28         svnversion.h
29
30 BUILT_C_FILES =         \
31         ps.c
32
33 BUILT_SOURCES = $(BUILT_C_FILES) $(BUILT_HEADER_FILES)
34
35 # Header files generated from source files.
36 GENERATED_HEADER_FILES = \
37         $(BUILT_HEADER_FILES)
38
39 # C source files generated from source files.
40 GENERATED_C_FILES = \
41         $(BUILT_C_FILES)        \
42         tshark-tap-register.c
43
44 # All the generated files.
45 GENERATED_FILES = $(GENERATED_C_FILES) $(GENERATED_HEADER_FILES)
46
47 # sources common for wireshark, tshark, and rawshark
48 WIRESHARK_COMMON_SRC =  \
49         $(PLATFORM_SRC) \
50         capture-pcap-util.c     \
51         cfile.c \
52         clopts_common.c \
53         disabled_protos.c       \
54         frame_data_sequence.c   \
55         packet-range.c  \
56         print.c \
57         ps.c    \
58         sync_pipe_write.c       \
59         timestats.c     \
60         util.c  \
61         tap-megaco-common.c     \
62         tap-rtp-common.c        \
63         version_info.c
64
65 # corresponding headers
66 WIRESHARK_COMMON_INCLUDES =     \
67         svnversion.h            \
68         capture-pcap-util.h     \
69         capture-pcap-util-int.h \
70         cfile.h \
71         clopts_common.h \
72         cmdarg_err.h    \
73         console_io.h    \
74         color.h \
75         disabled_protos.h       \
76         file.h  \
77         fileset.h       \
78         frame_data_sequence.h   \
79         isprint.h       \
80         packet-range.h  \
81         print.h \
82         ps.h    \
83         register.h      \
84         tempfile.h      \
85         timestats.h     \
86         util.h  \
87         tap-megaco-common.h     \
88         tap-rtp-common.h        \
89         version_info.h
90
91 # sources common for wireshark and tshark, but not rawshark;
92 # these are for programs that capture traffic by running dumpcap
93 SHARK_COMMON_CAPTURE_SRC =      \
94         capture_errs.c          \
95         capture_ifinfo.c        \
96         capture_ui_utils.c
97
98 # corresponding headers
99 SHARK_COMMON_CAPTURE_INCLUDES = \
100         capture_errs.h  \
101         capture_ifinfo.h        \
102         capture_ui_utils.h
103
104 # sources for TShark taps
105 TSHARK_TAP_SRC =        \
106         tap-afpstat.c   \
107         tap-ansi_astat.c        \
108         tap-bootpstat.c \
109         tap-camelcounter.c      \
110         tap-camelsrt.c  \
111         tap-comparestat.c       \
112         tap-dcerpcstat.c        \
113         tap-diameter-avp.c \
114         tap-funnel.c \
115         tap-gsm_astat.c \
116         tap-h225counter.c       \
117         tap-h225rassrt.c        \
118         tap-hosts.c     \
119         tap-httpstat.c  \
120         tap-icmpstat.c  \
121         tap-icmpv6stat.c        \
122         tap-iostat.c    \
123         tap-iousers.c   \
124         tap-mgcpstat.c  \
125         tap-megacostat.c        \
126         tap-protocolinfo.c      \
127         tap-protohierstat.c     \
128         tap-radiusstat.c        \
129         tap-rpcstat.c   \
130         tap-rpcprogs.c  \
131         tap-rtp.c       \
132         tap-rtspstat.c  \
133         tap-scsistat.c  \
134         tap-sctpchunkstat.c     \
135         tap-sipstat.c \
136         tap-smbsids.c   \
137         tap-smbstat.c   \
138         tap-stats_tree.c        \
139         tap-sv.c \
140         tap-wspstat.c
141
142 # wireshark specifics
143 wireshark_SOURCES =     \
144         $(WIRESHARK_COMMON_SRC) \
145         $(SHARK_COMMON_CAPTURE_SRC) \
146         airpcap_loader.c \
147         alert_box.c     \
148         capture.c       \
149         capture_info.c  \
150         capture_opts.c \
151         capture_sync.c  \
152         color_filters.c \
153         file.c  \
154         fileset.c       \
155         filters.c       \
156         g711.c \
157         merge.c \
158         proto_hier_stats.c      \
159         summary.c       \
160         tempfile.c      \
161         u3.c
162
163 # corresponding headers
164 wireshark_INCLUDES =    \
165         airpcap.h       \
166         airpcap_loader.h \
167         alert_box.h     \
168         capture.h       \
169         capture_info.h  \
170         capture_opts.h  \
171         capture_sync.h  \
172         color_filters.h \
173         filters.h       \
174         g711.h  \
175         globals.h       \
176         log.h   \
177         main_statusbar.h        \
178         merge.h \
179         progress_dlg.h  \
180         proto_hier_stats.h      \
181         simple_dialog.h \
182         stat_menu.h     \
183         summary.h       \
184         sync_pipe.h     \
185         u3.h    \
186         ui_util.h
187
188 # tshark specifics
189 tshark_SOURCES =        \
190         $(WIRESHARK_COMMON_SRC) \
191         $(SHARK_COMMON_CAPTURE_SRC) \
192         $(TSHARK_TAP_SRC)       \
193         capture_opts.c          \
194         capture_sync.c          \
195         tempfile.c              \
196         tshark-tap-register.c   \
197         tshark.c
198
199 # rawshark specifics
200 rawshark_SOURCES =      \
201         $(WIRESHARK_COMMON_SRC) \
202         rawshark.c
203
204 # text2pcap specifics
205 text2pcap_SOURCES = \
206         text2pcap.c \
207         text2pcap-scanner.l
208
209 # mergecap specifics
210 mergecap_SOURCES = \
211         mergecap.c \
212         merge.c \
213         svnversion.h
214
215 # editcap specifics
216 editcap_SOURCES = \
217         editcap.c       \
218         epan/crypt/crypt-md5.c \
219         epan/nstime.c \
220         $(WTAP_PLUGIN_SOURCES)
221
222 capinfos_SOURCES = \
223         capinfos.c \
224         $(WTAP_PLUGIN_SOURCES)
225
226 # dftest specifics
227 dftest_SOURCES =        \
228         dftest.c        \
229         util.c
230
231 # randpkt specifics
232 randpkt_SOURCES = \
233         randpkt.c
234
235 # dumpcap specifics
236 dumpcap_SOURCES =       \
237         $(PLATFORM_SRC) \
238         capture_opts.c \
239         capture-pcap-util.c     \
240         capture_stop_conditions.c       \
241         clopts_common.c \
242         conditions.c    \
243         dumpcap.c       \
244         pcapio.c        \
245         ringbuffer.c    \
246         sync_pipe_write.c       \
247         tempfile.c      \
248         version_info.c
249
250 # corresponding headers
251 dumpcap_INCLUDES = \
252         capture_stop_conditions.h       \
253         conditions.h    \
254         pcapio.h        \
255         ringbuffer.h
256
257 # this target needed for distribution only
258 noinst_HEADERS =        \
259         $(WIRESHARK_COMMON_INCLUDES) \
260         $(SHARK_COMMON_CAPTURE_INCLUDES) \
261         $(wireshark_INCLUDES) \
262         $(dumpcap_INCLUDES)