Add main_menubar.c
[obnox/wireshark/wip.git] / gtk / CMakeLists.txt
1 # CMakeLists.txt
2 #
3 # $Id$
4 #
5 # Wireshark - Network traffic analyzer
6 # By Gerald Combs <gerald@wireshark.org>
7 # Copyright 1998 Gerald Combs
8 #
9 # This program is free software; you can redistribute it and/or
10 # modify it under the terms of the GNU General Public License
11 # as published by the Free Software Foundation; either version 2
12 # of the License, or (at your option) any later version.
13 #
14 # This program is distributed in the hope that it will be useful,
15 # but WITHOUT ANY WARRANTY; without even the implied warranty of
16 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17 # GNU General Public License for more details.
18 #
19 # You should have received a copy of the GNU General Public License
20 # along with this program; if not, write to the Free Software
21 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
22 #
23
24
25 set(WIRESHARK_GTK_SRC
26         about_dlg.c
27         airpcap_dlg.c
28         airpcap_gui_utils.c
29         capture_dlg.c
30         capture_file_dlg.c
31         capture_if_dlg.c
32         capture_info_dlg.c
33         cfilter_combo_utils.c
34         color_dlg.c
35         color_edit_dlg.c
36         color_utils.c
37         conversations_table.c
38         decode_as_ber.c
39         decode_as_dcerpc.c
40         decode_as_dlg.c
41         dfilter_expr_dlg.c
42         dissector_tables_dlg.c
43         dlg_utils.c
44         drag_and_drop.c
45         expert_comp_table.c
46         export_object.c
47         export_object_dicom.c
48         export_object_http.c
49         export_object_smb.c
50         export_sslkeys.c
51         filter_autocomplete.c
52         file_dlg.c
53         file_import_dlg.c
54         fileset_dlg.c
55         filter_dlg.c
56         filter_utils.c
57         find_dlg.c
58         firewall_dlg.c
59         follow_ssl.c
60         follow_stream.c
61         follow_tcp.c
62         follow_udp.c
63         font_utils.c
64         goto_dlg.c
65         graph_analysis.c
66         gtkvumeter.c
67         gui_stat_util.c
68         gui_utils.c
69         help_dlg.c
70         hostlist_table.c
71         macros_dlg.c
72         main.c
73         main_airpcap_toolbar.c
74         main_filter_toolbar.c
75         main_menubar.c
76         main_proto_draw.c
77         main_statusbar.c
78         main_toolbar.c
79         main_welcome.c
80         manual_addr_resolv.c
81         mcast_stream.c
82         menus.c
83         new_packet_list.c
84         packet_history.c
85         packet_list_store.c
86         packet_win.c
87         pixmap_save.c
88         plugins_dlg.c
89         prefs_capture.c
90         prefs_column.c
91         prefs_dlg.c
92         prefs_gui.c
93         prefs_layout.c
94         prefs_nameres.c
95         prefs_print.c
96         prefs_protocols.c
97         prefs_taps.c
98         prefs_stream.c
99         print_dlg.c
100         profile_dlg.c
101         progress_dlg.c
102         proto_dlg.c
103         proto_help.c
104         proto_hier_stats_dlg.c
105         range_utils.c
106         recent.c
107         rtp_player.c
108         rtp_stream.c
109         sctp_byte_graph_dlg.c
110         sctp_error_dlg.c
111         sctp_graph_dlg.c
112         sctp_stat.c
113         service_response_time_table.c
114         simple_dialog.c
115         stock_icons.c
116         summary_dlg.c
117         supported_protos_dlg.c
118         tap_param_dlg.c
119         text_import.c
120         text_page_utils.c
121         time_shift_dlg.c
122         uat_gui.c
123         voip_calls.c
124         webbrowser.c
125 )
126
127 set(WIRESHARK_TAP_SRC
128         afp_stat.c
129         ansi_a_stat.c
130         ansi_map_stat.c
131         bootp_stat.c
132         camel_counter.c
133         camel_srt.c
134         compare_stat.c
135         conversations_eth.c
136         conversations_fc.c
137         conversations_fddi.c
138         conversations_ip.c
139         conversations_ipv6.c
140         conversations_ipx.c
141         conversations_jxta.c
142         conversations_ncp.c
143         conversations_rsvp.c
144         conversations_sctp.c
145         conversations_tcpip.c
146         conversations_tr.c
147         conversations_udpip.c
148         conversations_usb.c
149         conversations_wlan.c
150         dcerpc_stat.c
151         diameter_stat.c
152         expert_comp_dlg.c
153         fc_stat.c
154         flow_graph.c
155         funnel_stat.c
156         gsm_a_stat.c
157         gsm_map_stat.c
158         gsm_map_summary.c
159         gtp_stat.c
160         h225_counter.c
161         h225_ras_srt.c
162         hostlist_eth.c
163         hostlist_fc.c
164         hostlist_fddi.c
165         hostlist_ip.c
166         hostlist_ipv6.c
167         hostlist_ipx.c
168         hostlist_jxta.c
169         hostlist_ncp.c
170         hostlist_rsvp.c
171         hostlist_sctp.c
172         hostlist_tcpip.c
173         hostlist_tr.c
174         hostlist_udpip.c
175         hostlist_usb.c
176         hostlist_wlan.c
177         iax2_analysis.c
178         io_stat.c
179         ldap_stat.c
180         mac_lte_stat_dlg.c
181         mcast_stream_dlg.c
182         megaco_stat.c
183         mgcp_stat.c
184         mtp3_stat.c
185         mtp3_summary.c
186         ncp_stat.c
187         radius_stat.c
188         rlc_lte_stat_dlg.c
189         rpc_progs.c
190         rpc_stat.c
191         rtp_analysis.c
192         rtp_stream_dlg.c
193         scsi_stat.c
194         sctp_assoc_analyse.c
195         sctp_chunk_stat.c
196         sctp_chunk_stat_dlg.c
197         sctp_stat_dlg.c
198         sip_stat.c
199         smb_stat.c
200         smb2_stat.c
201         stats_tree_stat.c
202         tcp_graph.c
203         voip_calls_dlg.c
204         wlan_stat_dlg.c
205         wsp_stat.c
206 )
207
208 set(CLEAN_FILES
209         ${WIRESHARK_GTK_SRC}
210         ${WIRESHARK_TAP_SRC}
211 )
212
213 add_lex_files(WIRESHARK_GTK_SRC
214         text_import_scanner.l
215 )
216
217 if (WERROR)
218         set_source_files_properties(
219                 ${CLEAN_FILES}
220                 PROPERTIES
221                 COMPILE_FLAGS -Werror
222         )
223 endif()
224
225 if (UI_MANAGER)
226         add_definitions(
227                 -DMAIN_MENU_USE_UIMANAGER=1
228         )
229 endif()
230
231 if (NOT ENABLE_GTK3)
232         add_definitions(
233                 # We are only allowed to include gtk/gtk.h, no other files. When
234                 # violating this with gtk3 the compiler will complain anyway.
235                 -DGTK_DISABLE_SINGLE_INCLUDES
236
237                 # GTK+ 3 removes many implementation details and struct members from its
238                 # public headers. Make the compiler catch all uses of direct access to
239                 # struct fields so that you can go through them one by one and replace
240                 # them with a call to an accessor function instead.
241                 -DGSEAL_ENABLE
242
243                 # To verify that your program does not use any deprecated symbols,
244                 # you can use defines to remove deprecated symbols from the header files
245                 #-DGDK_DISABLE_DEPRECATED
246                 -DGTK_DISABLE_DEPRECATED
247         )
248 endif()
249
250 if (WANT_PACKET_EDITOR)
251         add_definitions(
252                 -DWANT_PACKET_EDITOR=1
253         )
254 endif()
255
256 register_tap_files(wireshark-tap-register.c
257         ${WIRESHARK_TAP_SRC}
258 )
259
260 add_library(ui STATIC
261         ${WIRESHARK_GTK_SRC}
262         ${WIRESHARK_TAP_SRC}
263         wireshark-tap-register.c
264 )
265 set_target_properties(ui PROPERTIES LINK_FLAGS "${WS_LINK_FLAGS}")
266
267 #install(TARGETS ui
268 #       LIBRARY DESTINATION lib
269 #       RUNTIME DESTINATION lib
270 #       ARCHIVE DESTINATION lib
271 #)
272