[oe] meta-openembedded/meta-ruby: ruby-1.9.3-disable-versioned-paths.patch misses one path

Martin Jansa martin.jansa at gmail.com
Thu Nov 5 12:57:33 UTC 2015


On Thu, Nov 05, 2015 at 01:38:18PM +0100, Ulf Magnusson wrote:
> Hello,
> 
> ruby-1.9.3-disable-versioned-paths.patch adds the
> --disable-versioned-paths option, which strips Ruby's version number
> from some install paths. The patch misses a spot however, which causes
> TOPDIR to get an incorrect value (nil) in rbconfig.rb. This in turn
> causes problems e.g. when trying to cross-compile native extensions.
> 
> The following patch fixes this. It assumes
> ruby-1.9.3-disable-versioned-paths.patch has already been applied.

ruby was already moved from meta-ruby to oe-core, send proper patch to
oe-core ML (ruby-1.9.3-disable-versioned-paths.patch isn't there).

commit 10fd3b41449d1af15ac9432bc1a7fe26c6f1dae1
Author: Alexander Kanavin <alexander.kanavin at linux.intel.com>
Date:   Thu Jun 4 13:17:31 2015 +0300

    ruby: add a recipe from meta-ruby

commit e04d53bdc83b0ae26fcde85b37fff20963232d9e
Author: Alexander Kanavin <alexander.kanavin at linux.intel.com>
Date:   Mon Sep 14 15:26:47 2015 +0300

    ruby: remove the recipe due to its move to oe-core

> 
> ---
>  tool/mkconfig.rb | 8 ++++++--
>  1 file changed, 6 insertions(+), 2 deletions(-)
> 
> diff --git a/tool/mkconfig.rb b/tool/mkconfig.rb
> index 10dbe65..aa54512 100755
> --- a/tool/mkconfig.rb
> +++ b/tool/mkconfig.rb
> @@ -44,6 +44,7 @@ vars = {}
>  continued_name = nil
>  continued_line = nil
>  path_version = "/$(ruby_version)"
> +prefix_version = "/#{version}"
>  File.foreach "config.status" do |line|
>    next if /^#/ =~ line
>    name = nil
> @@ -149,7 +150,10 @@ File.foreach "config.status" do |line|
>      when "ruby_version"
>        version = val[/\A"(.*)"\z/, 1]
>      when /^USE_VERSIONED_PATHS$/
> -      path_version = nil if /NO/ =~ val
> +      if /NO/ =~ val
> +        path_version = nil
> +        prefix_version = nil
> +      end
>      end
>    end
>  #  break if /^CEOF/
> @@ -157,7 +161,7 @@ end
> 
>  drive = File::PATH_SEPARATOR == ';'
> 
> -prefix = "/#{v_runtime[:libdir] || 'lib'}/ruby/#{version}/#{arch}"
> +prefix = "/#{v_runtime[:libdir] || 'lib'}/ruby#{prefix_version}/#{arch}"
>  print "  TOPDIR = File.dirname(__FILE__).chomp!(#{prefix.dump})\n"
>  print "  DESTDIR = ", (drive ? "TOPDIR && TOPDIR[/\\A[a-z]:/i] || " :
> ""), "'' unless defined? DESTDIR\n"
>  print <<'ARCH' if universal
> -- 
> 2.1.4
> 
> 
> Another "bug" is that meta/recipes-devtools/ruby (i.e., the newer Ruby
> recipe) uses --disable-versioned-paths too even though afaics no such
> option exists in that version. Maybe I should report that separately.
> 
> Cheers,
> Ulf

-- 
Martin 'JaMa' Jansa     jabber: Martin.Jansa at gmail.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <http://lists.openembedded.org/pipermail/openembedded-devel/attachments/20151105/fe8baeb5/attachment-0002.sig>


More information about the Openembedded-devel mailing list