From 07176222ab78871d244d1eed31bafb93deafe458 Mon Sep 17 00:00:00 2001 From: Fredrik Fornwall Date: Mon, 21 Aug 2017 01:34:21 +0200 Subject: [PATCH] ruby: Do not use CFLAGS when running cpp (mkmf.rb) This avoids problem with cpp in the NDK which is provided by gcc and does not understand clang specific flags (e.g. -Oz). --- packages/ruby/mkmf.rb.patch | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/packages/ruby/mkmf.rb.patch b/packages/ruby/mkmf.rb.patch index c7b30b72..7bada190 100644 --- a/packages/ruby/mkmf.rb.patch +++ b/packages/ruby/mkmf.rb.patch @@ -1,7 +1,16 @@ -diff -u -r ../ruby-2.1.2/lib/mkmf.rb ./lib/mkmf.rb ---- ../ruby-2.1.2/lib/mkmf.rb 2014-02-21 15:14:26.000000000 +0100 -+++ ./lib/mkmf.rb 2014-06-26 11:45:44.278140512 +0200 -@@ -1825,7 +1825,7 @@ +diff -u -r ../ruby-2.4.1/lib/mkmf.rb ./lib/mkmf.rb +--- ../ruby-2.4.1/lib/mkmf.rb 2017-03-11 19:46:17.000000000 +0100 ++++ ./lib/mkmf.rb 2017-08-21 01:04:18.918432148 +0200 +@@ -500,7 +500,7 @@ + if $universal and (arch_flag = conf['ARCH_FLAG']) and !arch_flag.empty? + conf['ARCH_FLAG'] = arch_flag.gsub(/(?:\G|\s)-arch\s+\S+/, '') + end +- RbConfig::expand("$(CPP) #$INCFLAGS #$CPPFLAGS #$CFLAGS #{opt} #{CONFTEST_C} #{outfile}", ++ RbConfig::expand("$(CPP) #$INCFLAGS #$CPPFLAGS #{opt} #{CONFTEST_C} #{outfile}", + conf) + end + +@@ -1894,7 +1894,7 @@ vpath = $VPATH.dup CONFIG["hdrdir"] ||= $hdrdir mk << %{ -- 2.11.0