Sha256: e7ac8a45d9d3cfa8f30bda652a17adf4ca5ddeb63e6ff042c6e5f6d6a2dc0739
Contents?: true
Size: 1.2 KB
Versions: 1
Compression:
Stored size: 1.2 KB
Contents
require 'mkmf' require 'numo/narray' $defs << '-DUSE_INT64' if with_config('use-int64', false) $LOAD_PATH.each do |lp| if File.exist?(File.join(lp, 'numo/numo/narray.h')) $INCFLAGS = "-I#{lp}/numo #{$INCFLAGS}" break end end unless have_header('numo/narray.h') puts 'numo/narray.h not found.' exit(1) end if RUBY_PLATFORM =~ /mswin|cygwin|mingw/ $LOAD_PATH.each do |lp| if File.exist?(File.join(lp, 'numo/libnarray.a')) $LDFLAGS = "-L#{lp}/numo #{$LDFLAGS}" break end end unless have_library('narray', 'nary_new') puts 'libnarray.a not found.' exit(1) end end $srcs = Dir.glob("#{$srcdir}/**/*.c").map { |path| File.basename(path) } blas_dir = with_config('blas-dir') $LDFLAGS = "-L#{blas_dir} #{$LDFLAGS}" unless blas_dir.nil? if RUBY_PLATFORM.match?(/darwin/) && Gem::Version.new('3.1.0') <= Gem::Version.new(RUBY_VERSION) if try_link('int main(void){return 0;}', '-Wl,-undefined,dynamic_lookup') $LDFLAGS << ' -Wl,-undefined,dynamic_lookup' end end blas_lib = with_config('blas-lib') unless blas_lib.nil? abort "#{blas_lib} not found." unless have_library(blas_lib) $srcs.delete('blas.c') end $VPATH << "$(srcdir)/src" create_makefile('lbfgsb/lbfgsbext')
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
lbfgsb-0.5.2 | ext/lbfgsb/extconf.rb |