Qt: Fix leak on CaptureFileDialog preview of file with errors
[wireshark.git] / cmakeconfig.h.in
blobe53427b15a397c9b499e67ff91972e1767ccb5f4
1 /* cmakeconfig.h.in */
3 #ifndef __CONFIG_H__
4 #define __CONFIG_H__
6 /* Note: You cannot use earlier #defines in later #cmakedefines (cmake 2.6.2). */
8 /* Name of package */
9 #define PACKAGE "wireshark"
11 #define VERSION_EXTRA "$ENV{WIRESHARK_VERSION_EXTRA}"
13 /* Version number of Wireshark and associated utilities */
14 #define VERSION "${PROJECT_VERSION}${VERSION_EXTRA}"
15 #define VERSION_MAJOR ${PROJECT_MAJOR_VERSION}
16 #define VERSION_MINOR ${PROJECT_MINOR_VERSION}
17 #define VERSION_MICRO ${PROJECT_PATCH_VERSION}
19 /* Version number of Logray and associated utilities */
20 #define LOG_VERSION "${LOG_PROJECT_VERSION}${VERSION_EXTRA}"
22 #define PLUGIN_PATH_ID "${PLUGIN_PATH_ID}"
23 #define VERSION_FLAVOR "${VERSION_FLAVOR}"
25 /* Build wsutil with SIMD optimization */
26 #cmakedefine HAVE_SSE4_2 1
28 /* Define to 1 if we want to enable plugins */
29 #cmakedefine HAVE_PLUGINS 1
31 /* Define to 1 if we check hf conflict */
32 #cmakedefine ENABLE_CHECK_FILTER 1
34 /* Link Wireshark libraries statically */
35 #cmakedefine ENABLE_STATIC 1
37 /* Enable AddressSanitizer (and LeakSanitizer on clang/gcc) */
38 #cmakedefine ENABLE_ASAN 1
40 /* Enable AirPcap */
41 #cmakedefine HAVE_AIRPCAP 1
43 /* Define to 1 if you have the <arpa/inet.h> header file. */
44 #cmakedefine HAVE_ARPA_INET_H 1
46 /* Define to 1 if you have the `clock_gettime` function. */
47 #cmakedefine HAVE_CLOCK_GETTIME 1
49 /* Define to 1 if you have the `timespec_get` function. */
50 #cmakedefine HAVE_TIMESPEC_GET 1
52 /* Define to 1 if you have the `localtime_r` function. */
53 #cmakedefine HAVE_LOCALTIME_R 1
55 /* Define to 1 if you have the `gmtime_r` function. */
56 #cmakedefine HAVE_GMTIME_R 1
58 /* Define to 1 if you have the `timegm` function. */
59 #cmakedefine HAVE_TIMEGM 1
61 /* Define to 1 if you have the `tzset` function. */
62 #cmakedefine HAVE_TZSET 1
64 /* Define to use the MaxMind DB library */
65 #cmakedefine HAVE_MAXMINDDB 1
67 /* Define to 1 if you have the <ifaddrs.h> header file. */
68 #cmakedefine HAVE_IFADDRS_H 1
70 /* Define to 1 if yu have the `fseeko` function. */
71 #cmakedefine HAVE_FSEEKO 1
73 /* Define to 1 if you have the `getexecname' function. */
74 #cmakedefine HAVE_GETEXECNAME 1
76 /* Define to 1 if you have the `getifaddrs' function. */
77 #cmakedefine HAVE_GETIFADDRS 1
79 /* Define if LIBSSH support is enabled */
80 #cmakedefine HAVE_LIBSSH 1
82 /* Define if you have the 'dlget' function. */
83 #cmakedefine HAVE_DLGET 1
85 /* Define to 1 if you have the <grp.h> header file. */
86 #cmakedefine HAVE_GRP_H 1
88 /* Define to use heimdal kerberos */
89 #cmakedefine HAVE_HEIMDAL_KERBEROS 1
91 /* Define to 1 if you have the `krb5_pac_verify' function. */
92 #cmakedefine HAVE_KRB5_PAC_VERIFY 1
94 /* Define to 1 if you have the `krb5_c_fx_cf2_simple' function. */
95 #cmakedefine HAVE_KRB5_C_FX_CF2_SIMPLE 1
97 /* Define to 1 if you have the `decode_krb5_enc_tkt_part' function. */
98 #cmakedefine HAVE_DECODE_KRB5_ENC_TKT_PART 1
100 /* Define to 1 if you have the `encode_krb5_enc_tkt_part' function. */
101 #cmakedefine HAVE_ENCODE_KRB5_ENC_TKT_PART 1
103 /* Define to 1 if you have the `inflatePrime' function. */
104 #cmakedefine HAVE_INFLATEPRIME 1
106 /* Define to 1 if you have the `issetugid' function. */
107 #cmakedefine HAVE_ISSETUGID 1
109 /* Define to use kerberos */
110 #cmakedefine HAVE_KERBEROS 1
112 /* Define to use nghttp2 */
113 #cmakedefine HAVE_NGHTTP2 1
115 /* Define to use nghttp3 */
116 #cmakedefine HAVE_NGHTTP3 1
118 /* Define to use the libcap library */
119 #cmakedefine HAVE_LIBCAP 1
121 /* Define to use GnuTLS library */
122 #cmakedefine HAVE_LIBGNUTLS 1
124 /* Define to 1 if GnuTLS was built with pkcs11 support. */
125 #cmakedefine HAVE_GNUTLS_PKCS11 1
127 /* Enable libnl support */
128 #cmakedefine HAVE_LIBNL 1
130 /* libnl version 1 */
131 #cmakedefine HAVE_LIBNL1 1
133 /* libnl version 2 */
134 #cmakedefine HAVE_LIBNL2 1
136 /* libnl version 3 */
137 #cmakedefine HAVE_LIBNL3 1
139 /* Define to use libpcap library */
140 #cmakedefine HAVE_LIBPCAP 1
142 /* Define to 1 if you have the `smi' library (-lsmi). */
143 #cmakedefine HAVE_LIBSMI 1
145 /* Define to 1 if libsmi exports a version string (and that symbol is visible). */
146 #cmakedefine HAVE_SMI_VERSION_STRING 1
148 /* Define to use zlib library */
149 #cmakedefine HAVE_ZLIB 1
151 /* Define to use the minizip library */
152 #cmakedefine HAVE_MINIZIP 1
154 /* Define if `dos_date' (with underscore) field exists in `zip_fileinfo' */
155 #cmakedefine HAVE_MZCOMPAT_DOS_DATE 1
157 /* Define to use brotli library */
158 #cmakedefine HAVE_BROTLI 1
160 /* Define to use lz4 library */
161 #cmakedefine HAVE_LZ4 1
163 /* Check for lz4frame */
164 #cmakedefine HAVE_LZ4FRAME_H 1
166 /* Define to use snappy library */
167 #cmakedefine HAVE_SNAPPY 1
169 /* Define to use zstd library */
170 #cmakedefine HAVE_ZSTD 1
172 /* Define to 1 if you have the <linux/sockios.h> header file. */
173 #cmakedefine HAVE_LINUX_SOCKIOS_H 1
175 /* Define to 1 if you have the <linux/if_bonding.h> header file. */
176 #cmakedefine HAVE_LINUX_IF_BONDING_H 1
178 /* Define to use Lua */
179 #cmakedefine HAVE_LUA 1
181 /* Define to 1 if we have Lua with Unicode for Windows patches. */
182 #cmakedefine HAVE_LUA_UNICODE 1
184 /* The size of the lua_Integer type, if we have Lua. */
185 #cmakedefine LUA_INTEGER_SIZE ${LUA_INTEGER_SIZE}
187 /* Define to use MIT kerberos */
188 #cmakedefine HAVE_MIT_KERBEROS 1
190 /* Define to 1 if you have the <netdb.h> header file. */
191 #cmakedefine HAVE_NETDB_H 1
193 /* Define to 1 if you have the <netinet/in.h> header file. */
194 #cmakedefine HAVE_NETINET_IN_H 1
196 /* nl80211.h is new enough */
197 #cmakedefine HAVE_NL80211 1
199 /* SET_CHANNEL is supported */
200 #cmakedefine HAVE_NL80211_CMD_SET_CHANNEL 1
202 /* SPLIT_WIPHY_DUMP is supported */
203 #cmakedefine HAVE_NL80211_SPLIT_WIPHY_DUMP 1
205 /* VHT_CAPABILITY is supported */
206 #cmakedefine HAVE_NL80211_VHT_CAPABILITY 1
208 /* Define to 1 if you have macOS frameworks */
209 #cmakedefine HAVE_MACOS_FRAMEWORKS 1
211 /* Define to 1 if you have the macOS CFPropertyListCreateWithStream function */
212 #cmakedefine HAVE_CFPROPERTYLISTCREATEWITHSTREAM 1
214 /* Define to 1 if you have the `pcap_create' function. */
215 #cmakedefine HAVE_PCAP_CREATE 1
217 /* Define to 1 if the capture buffer size can be set. */
218 #cmakedefine CAN_SET_CAPTURE_BUFFER_SIZE 1
220 /* Define to 1 if you have the `pcap_freecode' function. */
221 #cmakedefine HAVE_PCAP_FREECODE 1
223 /* Define to 1 if you have the `pcap_free_datalinks' function. */
224 #cmakedefine HAVE_PCAP_FREE_DATALINKS 1
226 /* Define to 1 if you have the `pcap_open' function. */
227 #cmakedefine HAVE_PCAP_OPEN 1
229 /* Define to 1 if you have libpcap/WinPcap/Npcap remote capturing support. */
230 #cmakedefine HAVE_PCAP_REMOTE 1
232 /* Define to 1 if you have the `pcap_setsampling' function. */
233 #cmakedefine HAVE_PCAP_SETSAMPLING 1
235 /* Define to 1 if you have the `pcap_set_tstamp_precision' function. */
236 #cmakedefine HAVE_PCAP_SET_TSTAMP_PRECISION 1
238 /* Define to 1 if you have the `pcap_set_tstamp_type' function. */
239 #cmakedefine HAVE_PCAP_SET_TSTAMP_TYPE 1
241 /* Define to 1 if you have the `PCAP_ERROR_PROMISC_PERM_DENIED' symbol. */
242 #cmakedefine HAVE_PCAP_ERROR_PROMISC_PERM_DENIED 1
244 /* Define to 1 if you have the `PCAP_WARNING_TSTAMP_TYPE_NOTSUP' symbol. */
245 #cmakedefine HAVE_PCAP_WARNING_TSTAMP_TYPE_NOTSUP 1
247 /* Define to 1 if you have the <pwd.h> header file. */
248 #cmakedefine HAVE_PWD_H 1
250 /* Define to 1 if you want to playing SBC by standalone BlueZ SBC library */
251 #cmakedefine HAVE_SBC 1
253 /* Define to 1 if you have the SpanDSP library. */
254 #cmakedefine HAVE_SPANDSP 1
256 /* Define to 1 if you have the bcg729 library. */
257 #cmakedefine HAVE_BCG729 1
259 /* Define to 1 if you have the opencore-amrnb library. */
260 #cmakedefine HAVE_AMRNB 1
262 /* Define to 1 if you have the ilbc library. */
263 #cmakedefine HAVE_ILBC 1
265 /* Define to 1 if you have the opus library. */
266 #cmakedefine HAVE_OPUS 1
268 /* Define to 1 if you have the lixbml2 library. */
269 #cmakedefine HAVE_LIBXML2 1
271 /* Define to 1 if you have the `setresgid' function. */
272 #cmakedefine HAVE_SETRESGID 1
274 /* Define to 1 if you have the `setresuid' function. */
275 #cmakedefine HAVE_SETRESUID 1
277 /* Define to 1 if you have the Sparkle or WinSparkle library */
278 #cmakedefine HAVE_SOFTWARE_UPDATE 1
280 /* Define if you have the 'strptime' function. */
281 #cmakedefine HAVE_STRPTIME 1
283 /* Define if you have the 'memmem' function. */
284 #cmakedefine HAVE_MEMMEM 1
286 /* Define if you have the 'memrchr' function. */
287 #cmakedefine HAVE_MEMRCHR 1
289 /* Define if you have the 'strerrorname_np' function. */
290 #cmakedefine HAVE_STRERRORNAME_NP 1
292 /* Define if you have the 'vasprintf' function. */
293 #cmakedefine HAVE_VASPRINTF 1
295 /* Define to 1 if `st_birthtime' is a member of `struct stat'. */
296 #cmakedefine HAVE_STRUCT_STAT_ST_BIRTHTIME 1
298 /* Define if st_blksize field exists in struct stat */
299 #cmakedefine HAVE_STRUCT_STAT_ST_BLKSIZE 1
301 /* Define to 1 if `__st_birthtime' is a member of `struct stat'. */
302 #cmakedefine HAVE_STRUCT_STAT___ST_BIRTHTIME 1
304 /* Define to 1 if you have the <sys/socket.h> header file. */
305 #cmakedefine HAVE_SYS_SOCKET_H 1
307 /* Define to 1 if you have the <sys/time.h> header file. */
308 #cmakedefine HAVE_SYS_TIME_H 1
310 /* Define to 1 if you have the <sys/utsname.h> header file. */
311 #cmakedefine HAVE_SYS_UTSNAME_H 1
313 /* Define to 1 if you have the <sys/wait.h> header file. */
314 #cmakedefine HAVE_SYS_WAIT_H 1
316 /* Define if tm_gmtoff field exists in struct tm */
317 #cmakedefine HAVE_STRUCT_TM_TM_GMTOFF 1
319 /* Define if tm_zone field exists in struct tm */
320 #cmakedefine HAVE_STRUCT_TM_TM_ZONE 1
322 /* Define if tzname array exists */
323 #cmakedefine HAVE_TZNAME 1
325 /* Define to 1 if you have the <unistd.h> header file. */
326 #cmakedefine HAVE_UNISTD_H 1
328 /* Define if we have QtMultimedia */
329 #cmakedefine QT_MULTIMEDIA_LIB 1
331 /* Define if we have QtDBus */
332 #cmakedefine QT_DBUS_LIB 1
334 /* Build androiddump with libpcap instead of wireshark stuff */
335 #cmakedefine ANDROIDDUMP_USE_LIBPCAP 1
337 /* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a
338 `char[]'. */
339 /* Note: not use in the code */
340 #cmakedefine YYTEXT_POINTER
342 /* Define to 1 if the 'ssize_t' type exists. */
343 #cmakedefine HAVE_SSIZE_T 1
345 /* Define to 1 if we are using the msys2 environment to build. */
346 #cmakedefine HAVE_MSYSTEM 1
348 #if defined(_MSC_VER)
349 # define strncasecmp strnicmp
350 # define popen _popen
351 # define pclose _pclose
352 #endif
354 #if defined(_WIN32)
356 * Flex (v 2.5.35) uses this symbol to "exclude" unistd.h
358 # define YY_NO_UNISTD_H
360 # ifndef __STDC__
361 # define __STDC__ 0
362 # endif
365 * Make sure everyone is using the same API and that it's sufficient
366 * for our needs.
367 * This should match the following:
368 * - The <compatibility><application> section in resources\wireshark.exe.manifest.in
369 * - The WinVer parts of packaging\nsis\wireshark.nsi
370 * - The VersionNT parts of packaging\wix\Prerequisites.wxi
372 # ifndef NTDDI_VERSION
373 # define NTDDI_VERSION NTDDI_WIN10
374 # endif
376 # ifndef _WIN32_WINNT
377 # define _WIN32_WINNT _WIN32_WINNT_WIN10
378 # endif
379 #endif
381 #define PCRE2_CODE_UNIT_WIDTH 8
384 * If HAVE_PCAP_REMOTE is defined, it forces the WinPcap header files to
385 * define things required for remote capture, by defining HAVE_REMOTE.
387 * With all versions of the WinPcap SDK, if:
389 * 1) you are building with any current WinPcap SDK;
390 * 2) you do not define HAVE_REMOTE before including pcap.h (or
391 * pcap/pcap.h);
392 * 3) you define a struct pcap_stat and pass it to a call to
393 * pcap_stats();
394 * 4) the system you're running on has WinPcap, rather than Npcap,
395 * installed;
397 * whatever is in memory after the struct pcap_stat may get overwritten,
398 * with unpredictable results, because the pcap_stats() implementation for
399 * WinPcap will assume that the structure has the additional members that
400 * are added if and only if HAVE_REMOTE is defined, and will fill them in,
401 * even if they're not there.
403 * Yes, this is q WinPcap bug; if your project has a public header file
404 * that checks or otherwise uses a #define that's defined by your project's
405 * configuration process, and don't ensure that it's always defined
406 * appropriately when that header file is included, before its first use,
407 * you have made a mistake.
409 * In libpcap 1.7.0 and later, the pcap_stats() implementation for WinPcap
410 * will not fill those fields in; however, no WinPcap implementation was
411 * based on that recent a libpcap release, so they all have the bug.
413 * Npcap was originally based on libpcap 1.8.0, and later releases are
414 * based on later releases of libpcap, so they will not overwrite memory
415 * past the end of the structure.
417 * The header file bug is fixed in libpcap 1.9.0 or later - the fields
418 * are present on Windows, regardless of whether HAVE_REMOTE is defined
419 * or not when the header is included (and are not present on UN*X), so
420 * if you build with an SDK with libpcap 1.9.0 or later headers, you
421 * do not need to define HAVE_REMOTE before including pcap.h (including it
422 * will make no difference).
424 * No version of the WinPcap SDK provided libpcap 1.9.0-or-later headers.
425 * The Npcap SDK, as of SDK version 1.04, provides them, so this is
426 * only necessary for building with the WinPcap SDK.
428 #ifdef HAVE_PCAP_REMOTE
429 #define HAVE_REMOTE
430 #endif
432 #include <ws_log_defs.h>
434 #endif /* __CONFIG_H__ */