forked from osmocom/wireshark
CMake: Set the Windows build target to Vista.
Set NTDDI_VERSION and _WIN32_WINNT to their Vista values so that ws2tcpip.h will define inet_pton and inet_ntop. Remove the associated compiler version checks so that everyone is on the same page. Add breadcrumbs to the various parts of the code where we set a minimum Windows version. Change-Id: I83bba5fa1024bfbc02e07b120412807ad259e291 Reviewed-on: https://code.wireshark.org/review/24080 Petri-Dish: Gerald Combs <gerald@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net> Reviewed-by: Gerald Combs <gerald@wireshark.org>
This commit is contained in:
parent
de6fcf2f21
commit
b7f7bee8cf
|
@ -406,6 +406,16 @@
|
|||
#cmakedefine YYTEXT_POINTER
|
||||
|
||||
#if defined(_WIN32)
|
||||
/*
|
||||
* Make sure everyone is using the same API and that it's sufficient
|
||||
* for our needs.
|
||||
* This should match the following:
|
||||
* - The <compatibility><application> section in image\wireshark.exe.manifest.in
|
||||
* - The GetWindowsVersion parts of packaging\nsis\wireshark.nsi
|
||||
* - The VersionNT parts of packaging\wix\Prerequisites.wxi
|
||||
*/
|
||||
# define NTDDI_VERSION NTDDI_VISTA
|
||||
# define _WIN32_WINNT _WIN32_WINNT_VISTA
|
||||
|
||||
/* WpdPack/INclude/pcap/pcap.h checks for "#if defined(WIN32)" */
|
||||
# ifndef WIN32
|
||||
|
@ -418,20 +428,12 @@
|
|||
|
||||
/* FIXME: Detection doesn't work */
|
||||
# define HAVE_NTDDNDIS_H 1
|
||||
/* Visual C 9 (2008), Visual C 10 (2010), Visual C 11 (2012) and Visual C 12 (2013)
|
||||
* need these prototypes
|
||||
* XXX: Can we use MSC_VER >= 1500 ?? */
|
||||
# if _MSC_VER == 1500 || _MSC_VER == 1600 || _MSC_VER == 1700 || _MSC_VER == 1800
|
||||
# define NTDDI_VERSION NTDDI_WINXPSP3
|
||||
# define _WIN32_WINNT _WIN32_WINNT_WINXP
|
||||
# endif
|
||||
|
||||
/*
|
||||
* Flex (v 2.5.35) uses this symbol to "exclude" unistd.h
|
||||
*/
|
||||
# define YY_NO_UNISTD_H
|
||||
|
||||
|
||||
# define strncasecmp strnicmp
|
||||
# define popen _popen
|
||||
# define pclose _pclose
|
||||
|
|
|
@ -29,10 +29,15 @@
|
|||
</requestedPrivileges>
|
||||
</security>
|
||||
</trustInfo>
|
||||
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
|
||||
<application>
|
||||
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
|
||||
<application>
|
||||
<!-- This should match the following:
|
||||
- The NTDDI_VERSION and _WIN32_WINNT parts of cmakeconfig.h.in
|
||||
- The GetWindowsVersion parts of packaging\nsis\wireshark.nsi
|
||||
- The VersionNT parts of packaging\wix\Prerequisites.wxi
|
||||
-->
|
||||
<!-- Windows Vista -->
|
||||
<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}"/>
|
||||
<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}"/>
|
||||
<!-- Windows 7 -->
|
||||
<supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}"/>
|
||||
<!-- Windows 8 -->
|
||||
|
@ -41,6 +46,6 @@
|
|||
<supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}"/>
|
||||
<!-- Windows 10 -->
|
||||
<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}"/>
|
||||
</application>
|
||||
</application>
|
||||
</compatibility>
|
||||
</assembly>
|
||||
</assembly>
|
||||
|
|
|
@ -238,6 +238,11 @@ Function .onInit
|
|||
; Get the Windows version
|
||||
${GetWindowsVersion} $R0
|
||||
|
||||
; This should match the following:
|
||||
; - The NTDDI_VERSION and _WIN32_WINNT parts of cmakeconfig.h.in
|
||||
; - The <compatibility><application> section in image\wireshark.exe.manifest.in
|
||||
; - The VersionNT parts of packaging\wix\Prerequisites.wxi
|
||||
|
||||
; Uncomment to test.
|
||||
; MessageBox MB_OK "You're running Windows $R0."
|
||||
|
||||
|
|
|
@ -14,6 +14,11 @@
|
|||
to ensure the entire fragment is included. -->
|
||||
<Property Id="IncludePrerequisites">1</Property>
|
||||
|
||||
<!-- This should match the following:
|
||||
- The NTDDI_VERSION and _WIN32_WINNT parts of cmakeconfig.h.in
|
||||
- The <compatibility><application> section in image\wireshark.exe.manifest.in
|
||||
- The GetWindowsVersion parts of packaging\nsis\wireshark.nsi
|
||||
-->
|
||||
<Condition Message="Windows 2000 is no longer supported. Please install $(var.WiresharkName) 1.2 or 1.0 instead.">
|
||||
<![CDATA[Installed OR (VersionNT < 500) OR (VersionNT > 500)]]>
|
||||
</Condition>
|
||||
|
|
Loading…
Reference in New Issue