1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
5 USE_RUBY="ruby24 ruby25 ruby26 ruby27"
7 RUBY_FAKEGEM_NAME="gsl"
8 inherit ruby-fakegem multilib
10 RUBY_FAKEGEM_RECIPE_DOC="rdoc"
11 RUBY_FAKEGEM_EXTRADOC="ChangeLog README.md"
13 DESCRIPTION="Ruby interface to GNU Scientific Library"
14 HOMEPAGE="https://github.com/SciRuby/rb-gsl"
21 DEPEND+=" >=sci-libs/gsl-2.3[deprecated]"
22 RDEPEND+=" >=sci-libs/gsl-2.3[deprecated]"
26 ruby_add_bdepend "dev-ruby/narray"
27 ruby_add_rdepend "dev-ruby/narray"
30 sed -i -e '/LOCAL_LIBS/ s: -l: -L#{path.gsub("ext", "lib")} -l:' ext/gsl_native/extconf.rb || die
32 rm -r test/gsl/nmatrix_tests || die
35 each_ruby_configure() {
36 NARRAY=1 ${RUBY} -Cext/gsl_native extconf.rb || die
37 sed -i -e 's:-Wl,--no-undefined::' ext/gsl_native/Makefile || die
41 NARRAY=1 emake -Cext/gsl_native V=1
42 cp ext/gsl_native/*$(get_modname) lib/ || die
46 NARRAY=1 ${RUBY} -Ilib:test:. -e 'Dir["test/**/*_test.rb"].each{|f| require f}' || die