https://bugs.winehq.org/show_bug.cgi?id=51843
Bug ID: 51843 Summary: dlls/ws2_32/socket.c:839:17: error: ‘IP_ADD_SOURCE_MEMBERSHIP’ undeclared here Product: Wine Version: 6.18 Hardware: x86 OS: NetBSD Status: NEW Severity: blocker Priority: P2 Component: winsock Assignee: wine-bugs@winehq.org Reporter: austinenglish@gmail.com
gcc -c -o dlls/ws2_32/socket.o dlls/ws2_32/socket.c -Idlls/ws2_32 -Iinclude -D__WINESRC__ -DUSE_WS_PREFIX -D_REENTRANT -fno-PIC -fasynchronous-unwind-tables -Wall -pipe -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body -Wignored-qualifiers -Wshift-overflow=2 -Wstrict-prototypes -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op -march=i586 -gdwarf-2 -gstrict-dwarf -fno-omit-frame-pointer -I/usr/pkg/include -I/usr/include -I/usr/pkg/include/freetype2 -I/usr/X11R7/include -O2 -I/usr/pkg/include -I/usr/include -I/usr/pkg/include/freetype2 -I/usr/X11R7/include -g dlls/ws2_32/socket.c:839:17: error: ‘IP_ADD_SOURCE_MEMBERSHIP’ undeclared here (not in a function); did you mean ‘WS_IP_ADD_SOURCE_MEMBERSHIP’? MAP_OPTION( IP_ADD_SOURCE_MEMBERSHIP ), ^ dlls/ws2_32/socket.c:792:37: note: in definition of macro ‘MAP_OPTION’ #define MAP_OPTION(opt) { WS_##opt, opt } ^~~ dlls/ws2_32/socket.c:840:17: error: ‘IP_DROP_SOURCE_MEMBERSHIP’ undeclared here (not in a function); did you mean ‘WS_IP_DROP_SOURCE_MEMBERSHIP’? MAP_OPTION( IP_DROP_SOURCE_MEMBERSHIP ), ^ dlls/ws2_32/socket.c:792:37: note: in definition of macro ‘MAP_OPTION’ #define MAP_OPTION(opt) { WS_##opt, opt } ^~~ dlls/ws2_32/socket.c:841:17: error: ‘IP_BLOCK_SOURCE’ undeclared here (not in a function); did you mean ‘WS_IP_BLOCK_SOURCE’? MAP_OPTION( IP_BLOCK_SOURCE ), ^ dlls/ws2_32/socket.c:792:37: note: in definition of macro ‘MAP_OPTION’ #define MAP_OPTION(opt) { WS_##opt, opt } ^~~ dlls/ws2_32/socket.c:842:17: error: ‘IP_UNBLOCK_SOURCE’ undeclared here (not in a function); did you mean ‘IP_BLOCK_SOURCE’? MAP_OPTION( IP_UNBLOCK_SOURCE ), ^ dlls/ws2_32/socket.c:792:37: note: in definition of macro ‘MAP_OPTION’ #define MAP_OPTION(opt) { WS_##opt, opt } ^~~ dlls/ws2_32/socket.c:923:17: error: ‘AI_ALL’ undeclared here (not in a function); did you mean ‘P_ALL’? MAP_OPTION( AI_ALL ), ^ dlls/ws2_32/socket.c:792:37: note: in definition of macro ‘MAP_OPTION’ #define MAP_OPTION(opt) { WS_##opt, opt } ^~~ dlls/ws2_32/socket.c:923:17: warning: initialization makes integer from pointer without a cast [-Wint-conversion] MAP_OPTION( AI_ALL ), ^ dlls/ws2_32/socket.c:792:37: note: in definition of macro ‘MAP_OPTION’ #define MAP_OPTION(opt) { WS_##opt, opt } ^~~ dlls/ws2_32/socket.c:923:17: note: (near initialization for ‘ws_aiflag_map[4][1]’) MAP_OPTION( AI_ALL ), ^ dlls/ws2_32/socket.c:792:37: note: in definition of macro ‘MAP_OPTION’ #define MAP_OPTION(opt) { WS_##opt, opt } ^~~ dlls/ws2_32/socket.c:923:17: error: initializer element is not constant MAP_OPTION( AI_ALL ), ^ dlls/ws2_32/socket.c:792:37: note: in definition of macro ‘MAP_OPTION’ #define MAP_OPTION(opt) { WS_##opt, opt } ^~~ dlls/ws2_32/socket.c:923:17: note: (near initialization for ‘ws_aiflag_map[4][1]’) MAP_OPTION( AI_ALL ), ^ dlls/ws2_32/socket.c:792:37: note: in definition of macro ‘MAP_OPTION’ #define MAP_OPTION(opt) { WS_##opt, opt } ^~~ dlls/ws2_32/socket.c: In function ‘WS_setsockopt’: dlls/ws2_32/socket.c:5639:27: error: storage size of ‘mreq_source’ isn’t known struct ip_mreq_source mreq_source; ^~~~~~~~~~~ dlls/ws2_32/socket.c:5856:24: error: request for member ‘imr_interface’ in something not a structure or union mreq_source.imr_interface.s_addr = val->imr_interface.S_un.S_addr; ^ dlls/ws2_32/socket.c:5856:38: error: request for member ‘s_addr’ in something not a structure or union mreq_source.imr_interface.s_addr = val->imr_interface.S_un.S_addr; ^ dlls/ws2_32/socket.c:5856:13: warning: statement with no effect [-Wunused-value] mreq_source.imr_interface.s_addr = val->imr_interface.S_un.S_addr; ^~~~~~~~~~~ dlls/ws2_32/socket.c:5857:24: error: request for member ‘imr_multiaddr’ in something not a structure or union mreq_source.imr_multiaddr.s_addr = val->imr_multiaddr.S_un.S_addr; ^ dlls/ws2_32/socket.c:5857:38: error: request for member ‘s_addr’ in something not a structure or union mreq_source.imr_multiaddr.s_addr = val->imr_multiaddr.S_un.S_addr; ^ dlls/ws2_32/socket.c:5857:13: warning: statement with no effect [-Wunused-value] mreq_source.imr_multiaddr.s_addr = val->imr_multiaddr.S_un.S_addr; ^~~~~~~~~~~ dlls/ws2_32/socket.c:5858:24: error: request for member ‘imr_sourceaddr’ in something not a structure or union mreq_source.imr_sourceaddr.s_addr = val->imr_sourceaddr.S_un.S_addr; ^ dlls/ws2_32/socket.c:5858:39: error: request for member ‘s_addr’ in something not a structure or union mreq_source.imr_sourceaddr.s_addr = val->imr_sourceaddr.S_un.S_addr; ^ dlls/ws2_32/socket.c:5858:13: warning: statement with no effect [-Wunused-value] mreq_source.imr_sourceaddr.s_addr = val->imr_sourceaddr.S_un.S_addr; ^~~~~~~~~~~ dlls/ws2_32/socket.c:5861:20: warning: assignment makes integer from pointer without a cast [-Wint-conversion] optlen = sizeof(mreq_source); ^ dlls/ws2_32/socket.c:5639:27: warning: unused variable ‘mreq_source’ [-Wunused-variable] struct ip_mreq_source mreq_source; ^~~~~~~~~~~ dlls/ws2_32/socket.c: In function ‘WS_gethostbyaddr’: dlls/ws2_32/socket.c:6092:19: warning: implicit declaration of function ‘gethostbyaddr_r’; did you mean ‘gethostbyaddr’? [-Wimplicit-function-declaration] int res = gethostbyaddr_r(paddr, len, unixtype, ^~~~~~~~~~~~~~~ gethostbyaddr dlls/ws2_32/socket.c: In function ‘WS_gethostbyname’: dlls/ws2_32/socket.c:6284:23: warning: implicit declaration of function ‘gethostbyname_r’; did you mean ‘gethostbyname2’? [-Wimplicit-function-declaration] int res = gethostbyname_r(name, &hostentry, extrabuf, ebufsize, &host, &locerr); ^~~~~~~~~~~~~~~ gethostbyname2 At top level: dlls/ws2_32/socket.c:1796:12: warning: ‘set_ipx_packettype’ defined but not used [-Wunused-function] static int set_ipx_packettype(int sock, int ptype) ^~~~~~~~~~~~~~~~~~
https://bugs.winehq.org/show_bug.cgi?id=51843
Austin English austinenglish@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords| |download, source
https://bugs.winehq.org/show_bug.cgi?id=51843
--- Comment #1 from Alexandre Julliard julliard@winehq.org --- That's not Wine 6.18, you should update.
https://bugs.winehq.org/show_bug.cgi?id=51843
--- Comment #2 from Austin English austinenglish@gmail.com --- (In reply to Alexandre Julliard from comment #1)
That's not Wine 6.18, you should update.
You're right, sorry about that; I had checked out an older version check something else and forgot to reset back.
With wine-6.18-341-ged38d12833b (and the patch from bug 51841), there are two issues: gcc -c -o dlls/ntdll/unix/socket.o dlls/ntdll/unix/socket.c -Idlls/ntdll -Iinclude -D__WINESRC__ -D_NTSYSTEM_ -D_ACRTIMP= -DWINBASEAPI= -D_MSVCR_VER=0 -DWINE_UNIX_LIB -fPIC -fasynchronous-unwind-tables -Wall -pipe -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body -Wignored-qualifiers -Winit-self -Wshift-overflow=2 -Wstrict-prototypes -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op -march=i586 -gdwarf-2 -gstrict-dwarf -fno-omit-frame-pointer -I/usr/pkg/include -I/usr/include -I/usr/pkg/include/freetype2 -I/usr/X11R7/include -O2 -I/usr/pkg/include -I/usr/include -I/usr/pkg/include/freetype2 -I/usr/X11R7/include -g dlls/ntdll/unix/socket.c: In function ‘sock_ioctl’: dlls/ntdll/unix/socket.c:1707:59: error: ‘IP_ADD_SOURCE_MEMBERSHIP’ undeclared (first use in this function); did you mean ‘WS_IP_ADD_SOURCE_MEMBERSHIP’? return do_setsockopt( handle, io, IPPROTO_IP, IP_ADD_SOURCE_MEMBERSHIP, in_buffer, in_size );
^~~~~~~~~~~~~~~~~~~~~~~~
WS_IP_ADD_SOURCE_MEMBERSHIP dlls/ntdll/unix/socket.c:1707:59: note: each undeclared identifier is reported only once for each function it appears in dlls/ntdll/unix/socket.c:1710:59: error: ‘IP_BLOCK_SOURCE’ undeclared (first use in this function); did you mean ‘WS_IP_BLOCK_SOURCE’? return do_setsockopt( handle, io, IPPROTO_IP, IP_BLOCK_SOURCE, in_buffer, in_size ); ^~~~~~~~~~~~~~~ WS_IP_BLOCK_SOURCE dlls/ntdll/unix/socket.c:1768:59: error: ‘IP_DROP_SOURCE_MEMBERSHIP’ undeclared (first use in this function); did you mean ‘WS_IP_DROP_SOURCE_MEMBERSHIP’? return do_setsockopt( handle, io, IPPROTO_IP, IP_DROP_SOURCE_MEMBERSHIP, in_buffer, in_size );
^~~~~~~~~~~~~~~~~~~~~~~~~
WS_IP_DROP_SOURCE_MEMBERSHIP dlls/ntdll/unix/socket.c:1903:59: error: ‘IP_UNBLOCK_SOURCE’ undeclared (first use in this function); did you mean ‘IP_BLOCK_SOURCE’? return do_setsockopt( handle, io, IPPROTO_IP, IP_UNBLOCK_SOURCE, in_buffer, in_size ); ^~~~~~~~~~~~~~~~~ IP_BLOCK_SOURCE
gcc -c -o dlls/ws2_32/unixlib.o dlls/ws2_32/unixlib.c -Idlls/ws2_32 -Iinclude -D__WINESRC__ -D_UCRT -DWINE_UNIX_LIB -fPIC -fasynchronous-unwind-tables -Wall -pipe -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body -Wignored-qualifiers -Winit-self -Wshift-overflow=2 -Wstrict-prototypes -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op -march=i586 -gdwarf-2 -gstrict-dwarf -fno-omit-frame-pointer -I/usr/pkg/include -I/usr/include -I/usr/pkg/include/freetype2 -I/usr/X11R7/include -O2 -I/usr/pkg/include -I/usr/include -I/usr/pkg/include/freetype2 -I/usr/X11R7/include -g dlls/ws2_32/unixlib.c:132:10: error: ‘AI_ALL’ undeclared here (not in a function); did you mean ‘P_ALL’? MAP( AI_ALL ), ^ dlls/ws2_32/unixlib.c:119:27: note: in definition of macro ‘MAP’ #define MAP(x) {WS_ ## x, x} ^ dlls/ws2_32/unixlib.c: In function ‘unix_gethostbyaddr’: dlls/ws2_32/unixlib.c:865:16: warning: implicit declaration of function ‘gethostbyaddr_r’; did you mean ‘gethostbyaddr’? [-Wimplicit-function-declaration] while (gethostbyaddr_r( addr, params->len, unix_family, &stack_host, unix_buffer, ^~~~~~~~~~~~~~~ gethostbyaddr dlls/ws2_32/unixlib.c: In function ‘unix_gethostbyname’: dlls/ws2_32/unixlib.c:916:12: warning: implicit declaration of function ‘gethostbyname_r’; did you mean ‘gethostbyname2’? [-Wimplicit-function-declaration] while (gethostbyname_r( params->name, &stack_host, unix_buffer, unix_size, &unix_host, &locerr ) == ERANGE) ^~~~~~~~~~~~~~~ gethostbyname2
https://bugs.winehq.org/show_bug.cgi?id=51843
Zeb Figura z.figura12@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |z.figura12@gmail.com
--- Comment #3 from Zeb Figura z.figura12@gmail.com --- (In reply to Austin English from comment #2)
dlls/ws2_32/unixlib.c: In function ‘unix_gethostbyaddr’: dlls/ws2_32/unixlib.c:865:16: warning: implicit declaration of function ‘gethostbyaddr_r’; did you mean ‘gethostbyaddr’? [-Wimplicit-function-declaration] while (gethostbyaddr_r( addr, params->len, unix_family, &stack_host, unix_buffer, ^~~~~~~~~~~~~~~ gethostbyaddr dlls/ws2_32/unixlib.c: In function ‘unix_gethostbyname’: dlls/ws2_32/unixlib.c:916:12: warning: implicit declaration of function ‘gethostbyname_r’; did you mean ‘gethostbyname2’? [-Wimplicit-function-declaration] while (gethostbyname_r( params->name, &stack_host, unix_buffer, unix_size, &unix_host, &locerr ) == ERANGE) ^~~~~~~~~~~~~~~ gethostbyname2
We have a configure check for these, even in wine 6.18, and as far as I can tell through experimentation it should be working. Does NetBSD provide those functions?
https://bugs.winehq.org/show_bug.cgi?id=51843
--- Comment #4 from Zeb Figura z.figura12@gmail.com --- (In reply to Zeb Figura from comment #3)
(In reply to Austin English from comment #2)
dlls/ws2_32/unixlib.c: In function ‘unix_gethostbyaddr’: dlls/ws2_32/unixlib.c:865:16: warning: implicit declaration of function ‘gethostbyaddr_r’; did you mean ‘gethostbyaddr’? [-Wimplicit-function-declaration] while (gethostbyaddr_r( addr, params->len, unix_family, &stack_host, unix_buffer, ^~~~~~~~~~~~~~~ gethostbyaddr dlls/ws2_32/unixlib.c: In function ‘unix_gethostbyname’: dlls/ws2_32/unixlib.c:916:12: warning: implicit declaration of function ‘gethostbyname_r’; did you mean ‘gethostbyname2’? [-Wimplicit-function-declaration] while (gethostbyname_r( params->name, &stack_host, unix_buffer, unix_size, &unix_host, &locerr ) == ERANGE) ^~~~~~~~~~~~~~~ gethostbyname2
We have a configure check for these, even in wine 6.18, and as far as I can tell through experimentation it should be working. Does NetBSD provide those functions?
Never mind, I see bug 40865. I'll see if I can find a way to check that the symbol actually compiles...
https://bugs.winehq.org/show_bug.cgi?id=51843
Fabian Maurer dark.shadow4@web.de changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |dark.shadow4@web.de
https://bugs.winehq.org/show_bug.cgi?id=51843
Aida Jonikienė aidas957@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |aidas957@gmail.com
--- Comment #5 from Aida Jonikienė aidas957@gmail.com --- Do these compile issues still occur on Wine 9.0?
https://bugs.winehq.org/show_bug.cgi?id=51843
Austin English austinenglish@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |FIXED Fixed by SHA1| |09f7b203bbb27eaad4e6a8318d0 | |3bb3a61e238c2 Status|NEW |RESOLVED
--- Comment #6 from Austin English austinenglish@gmail.com --- (In reply to Aida Jonikienė from comment #5)
Do these compile issues still occur on Wine 9.0?
No, this was fixed by https://source.winehq.org/git/wine.git/commitdiff/09f7b203bbb27eaad4e6a8318d..., thanks Zeb!
https://bugs.winehq.org/show_bug.cgi?id=51843
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #7 from Alexandre Julliard julliard@winehq.org --- Closing bugs fixed in 9.2.