ruby: assume we always have finite, isinf and isnan for uClibc
PATCH 1/1 ruby: assume we always have finite, isinf and isnan for uClibc
uClibc has __finite, __isinf and __isnan, and Ruby's configure script checks for finite, isinf and isnan (note the missing leading __). Because of the naming difference the checks fail, therefore the symbols HAVE_FINITE, HAVE_ISINF and HAVE_ISNAN are not defined.
Ruby code relies on those symbols in order to define its own version of the finite, isinf and isnan functions. Since the symbols haven't been defined, those definitions cause conflicts with the already-existing functions.
Fixes:
http://autobuild.buildroot.net/results/f34/f34dc20749c6f6d12c51eddf3ee6c2ef41d7c13d/
--- package/ruby/ruby.mk | 7 +++++++ 1 file changed, 7 insertions(+)
package/ruby/ruby.mk +7 -0
@@ -29,6 +29,13 @@ RUBY_CFLAGS += -O2 endif RUBY_CONF_ENV = CFLAGS="$(RUBY_CFLAGS)" +ifeq ($(BR2_TOOLCHAIN_USES_UCLIBC),y) +RUBY_CONF_ENV += \ + ac_cv_func_finite=yes \ + ac_cv_func_isinf=yes \ + ac_cv_func_isnan=yes +endif + ifeq ($(BR2_bfin),y) RUBY_CONF_ENV += ac_cv_func_dl_iterate_phdr=no # Blackfin doesn't have FFI closure support, needed by the fiddle
Signature · 1 line
2.10.2
PATCH 1/1 ruby: assume we always have finite, isinf and isnan for uClibc
Hi Vicente,
Quoted 22 lines · Vicente Olivert Riera
uClibc has
__finite,__isinfand__isnan, and Ruby's configure script checks for finite, isinf and isnan (note the missing leading __). Because of the naming difference the checks fail, therefore the symbolsHAVE_FINITE,HAVE_ISINFandHAVE_ISNANare not defined.
Ruby code relies on those symbols in order to define its own version of the finite, isinf and isnan functions. Since the symbols haven't been defined, those definitions cause conflicts with the already-existing functions.Fixes:
http://autobuild.buildroot.net/results/f34/f34dc20749c6f6d12c51eddf3ee6c2ef41d7c13d/Signed-off-by Vicente Olivert Riera <[email protected]>--- package/ruby/ruby.mk | 7 +++++++ 1 file changed, 7 insertions(+)package/ruby/ruby.mk +0
-0
package/ruby/ruby.mk RUBY_CFLAGS += -O2 · line 32
Quoted 4 lines
package/ruby/ruby.mk +1
-0@@ -29,6 +29,13 @@ RUBY_CFLAGS += -O2 endif RUBY_CONF_ENV = CFLAGS="$(RUBY_CFLAGS)" +ifeq ($(BR2_TOOLCHAIN_USES_UCLIBC),y)
IIUC these symbols are always defined (either as macros or as functions), so why not make this unconditional?
package/ruby/ruby.mk RUBY_CFLAGS += -O2 · line 41
Quoted 9 lines
package/ruby/ruby.mk +6
-0+RUBY_CONF_ENV += \ + ac_cv_func_finite=yes \ + ac_cv_func_isinf=yes \ + ac_cv_func_isnan=yes +endif + ifeq ($(BR2_bfin),y) RUBY_CONF_ENV += ac_cv_func_dl_iterate_phdr=no # Blackfin doesn't have FFI closure support, needed by the fiddle
baruch
Signature · 3 lines
http://baruch.siach.name/blog/ ~. .~ Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
- baruch at tkos.co.il - tel: +972.52.368.4656, http://www.tkos.co.il -PATCH 1/1 ruby: assume we always have finite, isinf and isnan for uClibc
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Baruch" == Baruch Siach <[email protected]> writes:
Hi,
Quoted 4 lines
Quoted 1 line
+ifeq ($(BR2_TOOLCHAIN_USES_UCLIBC),y)
IIUC these symbols are always defined (either as macros or as functions), so why not make this unconditional?
True, but it is really a workaround for uClibc, so I've kept it like this.
Signature · 1 line
Bye, Peter Korsgaard
PATCH 1/1 ruby: assume we always have finite, isinf and isnan for uClibc
In reply to Vicente Olivert RieraQuoted 11 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Vicente" == Vicente Olivert Riera <[email protected]> writes:
uClibc has
__finite,__isinfand__isnan, and Ruby's configure script checks for finite, isinf and isnan (note the missing leading __). Because of the naming difference the checks fail, therefore the symbolsHAVE_FINITE,HAVE_ISINFandHAVE_ISNANare not defined.
Ruby code relies on those symbols in order to define its own version of the finite, isinf and isnan functions. Since the symbols haven't been defined, those definitions cause conflicts with the already-existing functions.
Quoted 4 lines
Fixes:
http://autobuild.buildroot.net/results/f34/f34dc20749c6f6d12c51eddf3ee6c2ef41d7c13d/Signed-off-by Vicente Olivert Riera <[email protected]>
Committed after extending the description and adding a comment in the .mk file, thanks.
Signature · 1 line
Bye, Peter Korsgaard