Subject: pkg/20703: WINE pkg fails to build on current with undefined refs.
To: None <gnats-bugs@gnats.netbsd.org>
From: None <jwjr@panix.com>
List: netbsd-bugs
Date: 03/14/2003 09:00:20
>Number:         20703
>Category:       pkg
>Synopsis:       Fails with undefined reference to `gethostbyname_r' and `gethostbyaddr_r'
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Mar 14 06:01:01 PST 2003
>Closed-Date:
>Last-Modified:
>Originator:     James B. Wetterau Jr.
>Release:        NetBSD 1.6P Tue Mar 11 15:06:39 EST 2003
>Organization:
Never!
>Environment:
System: NetBSD burden 1.6P NetBSD 1.6P (BURDEN) #0: Tue Mar 11 15:06:39 EST 2003 jwjr@burden:/usr/obj/sys/arch/i386/compile/BURDEN i386
Architecture: i386
Machine: i386
>Description:
When building WINE from pkgsrc on a current machine, I see the
following problem:

[ ... much successful stuff elided ... ]
cc -c -I. -I. -I../../include -I../../include  -O2 -I/usr/pkg/include -I/usr/X11R6/include -Wall -Wpointer-arith -mpreferred-stack-boundary=2 -gstabs+  -fPIC -D__WINESRC__ -DUSE_WS_PREFIX -D_REENTRANT -o async.o async.c
async.c: In function `_async_queryfun':
async.c:402: warning: implicit declaration of function `gethostbyname_r'
async.c:404: warning: implicit declaration of function `gethostbyaddr_r'
cc -c -I. -I. -I../../include -I../../include  -O2 -I/usr/pkg/include -I/usr/X11R6/include -Wall -Wpointer-arith -mpreferred-stack-boundary=2 -gstabs+  -fPIC -D__WINESRC__ -DUSE_WS_PREFIX -D_REENTRANT -o socket.o socket.c
socket.c: In function `__ws_gethostbyaddr':
socket.c:2951: warning: implicit declaration of function `gethostbyaddr_r'
socket.c: In function `__ws_gethostbyname':
socket.c:3014: warning: implicit declaration of function `gethostbyname_r'
LD_LIBRARY_PATH="../../library:../../unicode:$LD_LIBRARY_PATH" ../../tools/winebuild/winebuild -fPIC -D__WINESRC__ -DUSE_WS_PREFIX -o ws2_32.dll.dbg.c --debug -C. async.c socket.c 
cc -c -I. -I. -I../../include -I../../include  -O2 -I/usr/pkg/include -I/usr/X11R6/include -Wall -Wpointer-arith -mpreferred-stack-boundary=2 -gstabs+  -fPIC -D__WINESRC__ -DUSE_WS_PREFIX -D_REENTRANT -o ws2_32.dll.dbg.o ws2_32.dll.dbg.c
ld -r winsock.spec.o    async.o socket.o ws2_32.dll.dbg.o -o ws2_32.dll.tmp.o
strip --strip-unneeded ws2_32.dll.tmp.o
LD_LIBRARY_PATH="../../library:../../unicode:$LD_LIBRARY_PATH" ../../tools/winebuild/winebuild -fPIC -D__WINESRC__ -DUSE_WS_PREFIX -o ws2_32.spec.c --spec ./ws2_32.spec  ws2_32.dll.tmp.o  -L../../dlls  -luser32 -lkernel32 -lntdll
cc -c -I. -I. -I../../include -I../../include  -O2 -I/usr/pkg/include -I/usr/X11R6/include -Wall -Wpointer-arith -mpreferred-stack-boundary=2 -gstabs+  -fPIC -D__WINESRC__ -DUSE_WS_PREFIX -D_REENTRANT -o ws2_32.spec.o ws2_32.spec.c
cc -shared  -Wl,-Bsymbolic,-z,defs ws2_32.spec.o winsock.spec.o    async.o socket.o ws2_32.dll.dbg.o -o ws2_32.dll.so -L../../dlls  -L../../library -lwine  -lossaudio -li386 -lm   -Wl,-R/usr/X11R6/lib -L/usr/X11R6/lib -Wl,-R/usr/pkg/lib -L/usr/pkg/lib -lc -lc
async.o: In function `_async_queryfun':
/usr/pkgsrc/emulators/wine/work/wine-20030219/dlls/winsock/async.c:401: undefined reference to `gethostbyname_r'
/usr/pkgsrc/emulators/wine/work/wine-20030219/dlls/winsock/async.c:401: undefined reference to `gethostbyaddr_r'
socket.o: In function `__ws_gethostbyaddr':
/usr/pkgsrc/emulators/wine/work/wine-20030219/dlls/winsock/socket.c:2951: undefined reference to `gethostbyaddr_r'
socket.o: In function `__ws_gethostbyname':
/usr/pkgsrc/emulators/wine/work/wine-20030219/dlls/winsock/socket.c:3014: undefined reference to `gethostbyname_r'
gmake[2]: *** [ws2_32.dll.so] Error 1
gmake[2]: Leaving directory `/usr/pkgsrc/emulators/wine/work/wine-20030219/dlls/winsock'
gmake[1]: *** [winsock] Error 2
gmake[1]: Leaving directory `/usr/pkgsrc/emulators/wine/work/wine-20030219/dlls'
gmake: *** [dlls] Error 2
*** Error code 2

Stop.
make: stopped in /usr/pkgsrc/emulators/wine
*** Error code 1

Stop.
make: stopped in /usr/pkgsrc/emulators/wine


>How-To-Repeat:
	cd /usr/pkgsrc/emulators/wine;	make install
>Fix:
	
>Release-Note:
>Audit-Trail:
>Unformatted: