From: Jon Forums Date: 2011-11-27T04:36:02+09:00 Subject: [ruby-core:41314] [ruby-trunk - Bug #5675][Open] [mingw] static build fails due to socket extension build failure Issue #5675 has been reported by Jon Forums. ---------------------------------------- Bug #5675: [mingw] static build fails due to socket extension build failure http://redmine.ruby-lang.org/issues/5675 Author: Jon Forums Status: Open Priority: Normal Assignee: Category: ext Target version: 1.9.3 ruby -v: ruby 1.9.3p0 (2011-11-08 revision 33661) [i386-mingw32] I get the following failure on my Win7 32bit system while trying to build ruby_1_9_3@33661 The problem likely exists on trunk@33852 but #5674 blocks me from trying to replicate. Providing `--with-out-ext=socket` to `./configure` is a one (undesirable) workaround. No failure when building on Arch. C:\Users\Jon\Documents\RubyDev\ruby-git\build>sh -c "../configure --disable-shared --disable-install-doc && make" ... make[2]: Entering directory `/c/Users/Jon/Documents/RubyDev/ruby-git/build/ext/socket' generating socket-i386-mingw32.def generating constant definitions compiling ../../../ext/socket/init.c compiling ../../../ext/socket/constants.c compiling ../../../ext/socket/basicsocket.c compiling ../../../ext/socket/socket.c ../../../ext/socket/socket.c: In function 'rsock_sock_s_socketpair': ../../../ext/socket/socket.c:114:5: warning: implicit declaration of function 'socketpair' compiling ../../../ext/socket/ipsocket.c compiling ../../../ext/socket/tcpsocket.c compiling ../../../ext/socket/tcpserver.c compiling ../../../ext/socket/sockssocket.c compiling ../../../ext/socket/udpsocket.c compiling ../../../ext/socket/unixsocket.c compiling ../../../ext/socket/unixserver.c compiling ../../../ext/socket/option.c compiling ../../../ext/socket/ancdata.c compiling ../../../ext/socket/raddrinfo.c linking shared-object socket.so socket.o: In function `rsock_sock_s_socketpair': c:\Users\Jon\Documents\RubyDev\ruby-git\build\ext\socket/../../../ext/socket/socket.c:114: undefined reference to `socketpair' c:\Users\Jon\Documents\RubyDev\ruby-git\build\ext\socket/../../../ext/socket/socket.c:117: undefined reference to `socketpair' collect2: ld returned 1 exit status make[2]: *** [../../.ext/i386-mingw32/socket.so] Error 1 make[2]: Leaving directory `/c/Users/Jon/Documents/RubyDev/ruby-git/build/ext/socket' make[1]: *** [ext/socket/all] Error 2 make[1]: Leaving directory `/c/Users/Jon/Documents/RubyDev/ruby-git/build' make: *** [build-ext] Error 2 -- http://redmine.ruby-lang.org