[erlang-patches] [PATCH] Set WINVER and _WIN32_WINNT to 0x0501

Niclas Axelsson <>
Mon Dec 6 16:05:50 CET 2010


On 12/04/2010 05:44 PM, Tuncer Ayaz wrote:
> The Windows implementation of inet:getifaddrs/0 depends on
> WINVER>= 0x0501. Update WINVER and _WIN32_WINNT definitions
> accordingly.
> ---
>   erts/configure.in              |    2 +-
>   lib/erl_interface/configure.in |    2 +-
>   lib/wx/configure.in            |    8 ++++----
>   3 files changed, 6 insertions(+), 6 deletions(-)
>
> diff --git a/erts/configure.in b/erts/configure.in
> index 8d629c2..7820a6b 100644
> --- a/erts/configure.in
> +++ b/erts/configure.in
> @@ -389,7 +389,7 @@ case $host_os in
>       win32)
>   	# The ethread library requires _WIN32_WINNT of at least 0x0403.
>   	# -D_WIN32_WINNT=* from CPPFLAGS is saved in ETHR_DEFS.
> -	CPPFLAGS="$CPPFLAGS -D_WIN32_WINNT=0x0500 -DWINVER=0x0500"
> +	CPPFLAGS="$CPPFLAGS -D_WIN32_WINNT=0x0501 -DWINVER=0x0501"
>   	# _USE_32BIT_TIME_T is needed when using VC++ 2005 (ctime() will fail
>   	# otherwise since we pass it a 32-bit value).
>   	#
> diff --git a/lib/erl_interface/configure.in b/lib/erl_interface/configure.in
> index 72ac8c7..0bb94e5 100644
> --- a/lib/erl_interface/configure.in
> +++ b/lib/erl_interface/configure.in
> @@ -288,7 +288,7 @@ case "$threads_disabled" in
>   	        ;;
>   	    win32_threads)
>   		EI_THREADS="true"	
> -		THR_DEFS="$THR_DEFS -D_WIN32_WINNT=0x0500 -DWINVER=0x0500"
> +		THR_DEFS="$THR_DEFS -D_WIN32_WINNT=0x0501 -DWINVER=0x0501"
>   		;;
>   	    pthread)	
>   		EI_THREADS="true"
> diff --git a/lib/wx/configure.in b/lib/wx/configure.in
> index f7128db..ada52f9 100755
> --- a/lib/wx/configure.in
> +++ b/lib/wx/configure.in
> @@ -145,14 +145,14 @@ case $host_os in
>   	CPPFLAGS="$CPPFLAGS -D_MACOSX $PTHR_CFLAGS"
>   	;;
>       mingw32)
> -	CFLAGS="$CFLAGS -DWIN32 -DWINVER=0x0500 -D_WINDOWS -D_UNICODE -DUNICODE"
> -	CPPFLAGS="$CPPFLAGS -D_WIN32_WINNT=0x0500"	
> +	CFLAGS="$CFLAGS -DWIN32 -DWINVER=0x0501 -D_WINDOWS -D_UNICODE -DUNICODE"
> +	CPPFLAGS="$CPPFLAGS -D_WIN32_WINNT=0x0501"
>   	AC_MSG_WARN([Reverting to 32-bit time_t])
>   	CPPFLAGS="$CPPFLAGS -D_USE_32BIT_TIME_T"
>   	;;
>       win32)
> -	CFLAGS="$CFLAGS -DWIN32 -DWINVER=0x0500 -D_WINDOWS -D_UNICODE -DUNICODE"
> -	CPPFLAGS="$CPPFLAGS -D_WIN32_WINNT=0x0500"
> +	CFLAGS="$CFLAGS -DWIN32 -DWINVER=0x0501 -D_WINDOWS -D_UNICODE -DUNICODE"
> +	CPPFLAGS="$CPPFLAGS -D_WIN32_WINNT=0x0501"
>   	;;
>       *)
>   	CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE $PTHR_CFLAGS"
>
> ________________________________________________________________
> erlang-patches (at) erlang.org mailing list.
> See http://www.erlang.org/faq.html
> To unsubscribe; mailto:
>    
Thank you, Tuncer. Will include this into 'pu'.

Regards,
Niclas Axelsson, Erlang/OTP


More information about the erlang-patches mailing list