From: Lyle Johnson Date: 2000-12-28T06:10:02+09:00 Subject: [ruby-talk:8140] Re: Ruby 1.6.2 "Lyle Johnson" wrote in message news:t4kauk9h0vcs1e@corp.supernews.com... > I ran into trouble building Ruby 1.6.2 from the sources, on Windows 2000 > using the latest Cygwin toys. For what it's worth, I was able to compile all > of Ruby 1.6.1 from sources using the same development tools, a few weeks > back. The library and several extension modules build fine, but it breaks > while trying to link the "socket" extension: Okay, I know what's wrong but I think this suggests a needed fix for the Makefile(s). The problem was that after building Ruby 1.6.1 previously, I used "make install" to install it. The library (for this platform, libcygwin-ruby16.a) was installed into /usr/local/lib. Now, when building Ruby 1.6.2 and linking the extensions, observe the linker flags: dllwrap --target=cygwin --as=as --dlltool-name=dlltool --driver-name=gcc --export-all -s --def=socket.def -L/usr/local/lib -L//c/src/ruby-1.6.2 -o socket.so ... The important thing to note is that /usr/local/lib is specified before the Ruby build directory (//c/src/ruby-1.6.2) in the list of directories to search for the Ruby library. In other words, it was picking up the Ruby 1.6.1 version of "libcygwin-ruby16.a", which didn't contain rb_io_taint_check(), instead of the newer version. All of the makefile(s) that link in this library need to be reviewed, to make sure that these linker flags are re-ordered so that the correct library is picked up! After I move the older version of libcygwin-ruby16.a out of the way, and then did a make clean & re-make, the build goes through fine. Hope this helps, Lyle