leto / math--gsl

Perl interface to the GNU Scientific Library
http://leto.net/code/Math-GSL
34 stars 25 forks source link

GSL 2.7: "undefined symbol: gsl_vector_sum" when testing with GSL 2.6 #239

Open hakonhagland opened 3 years ago

hakonhagland commented 3 years ago

After applying PR #238, I generated a new distribution

$ PATH="/opt/gsl/gsl-2.7/bin:$PATH" perl Build.PL
$ ./Build
$ ./Build dist

then tried to install this dist with GSL 2.6


$ cp Math-GSL-0.42.tar.gz /tmp
$ tar zxvf Math-GSL-0.42.tar.gz
$ cd Math-GSL-0.42
$ PATH="/opt/gsl/gsl-2.6/bin:$PATH" perl Build.PL
$ ./Build
$ PATH="/opt/gsl/gsl-2.6/bin:$PATH" ./Build test
Processing 2.6 XS files, GSL 2.6 (via gsl-config) at /opt/gsl/gsl-2.6
Compiler        = cc (Ubuntu 10.3.0-1ubuntu1) 10.3.0
Copyright (C) 2020 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

ccflags         = -fPIC -I/opt/gsl/gsl-2.6/include -fwrapv -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Wall -Wno-sometimes-uninitialized -Wno-unused-function -Wno-unused-value -Wno-unused-function -Wno-unused-variable -Wno-gnu -g -fPIC -fno-omit-frame-pointer -I/opt/gsl/gsl-2.6/include
ldflags         = -shared -L/opt/gsl/gsl-2.6/lib -lgsl -lgslcblas -lm -fPIC -fno-omit-frame-pointer
PERL5LIB        = 
LD_LIBRARY_PATH = /home/hakon/lib
t/00-load.t ........ 1/? 
#   Failed test 'use Math::GSL;'
#   at t/00-load.t line 11.
#     Tried to use 'Math::GSL'.
#     Error:  Can't load '/tmp/Math-GSL-0.42/blib/arch/auto/Math/GSL/Vector/Vector.so' for module Math::GSL::Vector: /tmp/Math-GSL-0.42/blib/arch/auto/Math/GSL/Vector/Vector.so: undefined symbol: gsl_vector_sum at /home/hakon/perlbrew/perls/perl-5.32.0/lib/5.32.0/x86_64-linux/DynaLoader.pm line 193.
#  at /tmp/Math-GSL-0.42/blib/lib/Math/GSL/Vector.pm line 11.
# Compilation failed in require at /tmp/Math-GSL-0.42/blib/lib/Math/GSL.pm line 13.
# BEGIN failed--compilation aborted at /tmp/Math-GSL-0.42/blib/lib/Math/GSL.pm line 13.
# Compilation failed in require at t/00-load.t line 11.
# BEGIN failed--compilation aborted at t/00-load.t line 11.
Undefined subroutine &main::gsl_version called at t/00-load.t line 13.
BEGIN failed--compilation aborted at t/00-load.t line 15.
# Tests were run but no plan was declared and done_testing() was not seen.
# Looks like your test exited with 255 just after 1.

[...]