From: Brian Candler Date: 2008-11-08T05:14:08+09:00 Subject: [ruby-core:19725] [Bug #720] [patch] autoconf changes needed for uClibc stdio Bug #720: [patch] autoconf changes needed for uClibc stdio http://redmine.ruby-lang.org/issues/show/720 Author: Brian Candler Status: Open, Priority: Normal [Migrated from http://rubyforge.org/tracker/index.php?func=detail&aid=15677&group_id=426&atid=1698] ruby doesn't work properly under uClibc without a patch. This is because uClibc uses __bufpos and __bufread (rather than bufpos and bufread), which configure.in isn't currently detecting. The most immediate symptom is that an exception is raised if you try to read from a UDP socket: root@OpenWrt:~# irb irb(main):001:0> require 'socket' => true irb(main):002:0> s = UDPSocket.new => # irb(main):003:0> s.bind("0.0.0.0",1234) => 0 irb(main):004:0> d = s.recvfrom(512) IOError: recv for buffered IO from (irb):4:in `recvfrom' from (irb):4 irb(main):005:0> [Tested using OpenWrt, an embedded Linux distro which uses uClibc] The simple fix is attached. Previously posted to ruby-core for comment, but no response forthcoming. http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-core/12020 http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-core/13262 ---------------------------------------- http://redmine.ruby-lang.org