Bug 25617 - Installing any package in Octave fails with many "undefined reference" errors
Summary: Installing any package in Octave fails with many "undefined reference" errors
Status: RESOLVED FIXED
Alias: None
Product: Mageia
Classification: Unclassified
Component: RPM Packages (show other bugs)
Version: 7
Hardware: All Linux
Priority: Normal normal
Target Milestone: ---
Assignee: QA Team
QA Contact:
URL:
Whiteboard: MGA7-64-OK
Keywords: advisory, validated_update
Depends on:
Blocks:
 
Reported: 2019-10-26 01:15 CEST by Martin Whitaker
Modified: 2019-11-08 00:38 CET (History)
5 users (show)

See Also:
Source RPM: octave-5.1.0-7.mga7
CVE:
Status comment:


Attachments

Description Martin Whitaker 2019-10-26 01:15:31 CEST
To reproduce:

1. Install the octave and octave-devel packages.
2. Run octave from the command line.
3. Execute the octave command "pkg install -verbose -forge io".

e.g.

octave:1> pkg install -verbose io
mkdir (/tmp/oct-YvSp8y)
untar (io-2.4.13.tar.gz, /tmp/oct-YvSp8y)
checking for mkoctfile... /usr/bin/mkoctfile-5.1.0 --verbose
checking for octave-config... /usr/bin/octave-config-5.1.0
checking whether the C++ compiler works... yes
checking for C++ compiler default output file name... a.out
checking for suffix of executables... 
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking how to run the C++ preprocessor... g++ -E
checking   is_numeric_type or isnumeric... isnumeric
checking   is_cell or iscell... iscell
checking   is_empty or isempty... isempty
configure: creating ./config.status
config.status: creating config.h
make: Entering directory '/tmp/oct-YvSp8y/io-2.4.13/src'
/usr/bin/mkoctfile-5.1.0 --verbose csvexplode.cc
/usr/bin/mkoctfile-5.1.0 --verbose csv2cell.cc
/usr/bin/mkoctfile-5.1.0 --verbose csvconcat.cc
/usr/bin/mkoctfile-5.1.0 --verbose cell2csv.cc
/usr/bin/mkoctfile-5.1.0 --verbose col2num.cc
/usr/bin/mkoctfile-5.1.0 --verbose num2col.cc
g++ -c -O2 -g -pipe -Wformat -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -fasynchronous-unwind-tables -DH5_USE_16_API -fPIC -I/usr/include/octave-5.1.0/octave/.. -I/usr/include/octave-5.1.0/octave  -pthread -fopenmp -O2 -g -pipe -Wformat -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -fasynchronous-unwind-tables    csvconcat.cc -o /tmp/oct-LmExW3.o
g++ -c -O2 -g -pipe -Wformat -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -fasynchronous-unwind-tables -DH5_USE_16_API -fPIC -I/usr/include/octave-5.1.0/octave/.. -I/usr/include/octave-5.1.0/octave  -pthread -fopenmp -O2 -g -pipe -Wformat -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -fasynchronous-unwind-tables    csvexplode.cc -o /tmp/oct-5p0cP3.o
g++ -c -O2 -g -pipe -Wformat -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -fasynchronous-unwind-tables -DH5_USE_16_API -fPIC -I/usr/include/octave-5.1.0/octave/.. -I/usr/include/octave-5.1.0/octave  -pthread -fopenmp -O2 -g -pipe -Wformat -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -fasynchronous-unwind-tables    cell2csv.cc -o /tmp/oct-G9C2S3.o
g++ -c -O2 -g -pipe -Wformat -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -fasynchronous-unwind-tables -DH5_USE_16_API -fPIC -I/usr/include/octave-5.1.0/octave/.. -I/usr/include/octave-5.1.0/octave  -pthread -fopenmp -O2 -g -pipe -Wformat -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -fasynchronous-unwind-tables    csv2cell.cc -o /tmp/oct-a0aMR3.o
g++ -c -O2 -g -pipe -Wformat -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -fasynchronous-unwind-tables -DH5_USE_16_API -fPIC -I/usr/include/octave-5.1.0/octave/.. -I/usr/include/octave-5.1.0/octave  -pthread -fopenmp -O2 -g -pipe -Wformat -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -fasynchronous-unwind-tables    col2num.cc -o /tmp/oct-7e9MM3.o
g++ -c -O2 -g -pipe -Wformat -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -fasynchronous-unwind-tables -DH5_USE_16_API -fPIC -I/usr/include/octave-5.1.0/octave/.. -I/usr/include/octave-5.1.0/octave  -pthread -fopenmp -O2 -g -pipe -Wformat -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -fasynchronous-unwind-tables    num2col.cc -o /tmp/oct-iM0tM3.o
g++ -I/usr/include/octave-5.1.0/octave/.. -I/usr/include/octave-5.1.0/octave  -pthread -fopenmp -O2 -g -pipe -Wformat -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -fasynchronous-unwind-tables -shared -Wl,-Bsymbolic  -Wl,--as-needed -Wl,--no-undefined -Wl,-z,relro -Wl,-O1 -Wl,--build-id -Wl,--enable-new-dtags  -o cell2csv.oct  /tmp/oct-G9C2S3.o    -L/usr/lib64   -Wl,--as-needed -Wl,--no-undefined -Wl,-z,relro -Wl,-O1 -Wl,--build-id -Wl,--enable-new-dtags 
/usr/bin/ld: /tmp/oct-G9C2S3.o: in function `Gcell2csv':
/tmp/oct-YvSp8y/io-2.4.13/src/cell2csv.cc:60: undefined reference to `check_version(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'

followed by many more undefined reference error messages.
Comment 1 Lewis Smith 2019-10-26 20:45:22 CEST
Thank you Martin for reporting this. Is the problem just for pkg install? Do other aspects of the package work?

Assigning to Shlomi as regietered maintainer for 'octave'.

Assignee: bugsquad => shlomif

Comment 2 Martin Whitaker 2019-10-26 21:38:49 CEST
The core functions of Octave all work, but any use of mkoctfile (called implicitly when you import a package) is affected.

I built and installed Octave locally, using the octave-5.1.0.tar.xz tarball from the Mageia 7 SRPM abut with the default configuration, and everything works as it should. So the fault is in the Mageia build/packaging.

CC'ing eatdirt, whose name appears a lot in the commit log.

CC: (none) => eatdirt

Comment 3 Chris Denice 2019-11-05 13:59:40 CET
I suspect it is related to the disable-rpath we apply for distro building and some "bad" packaging within octave using absolute path, or missing explicit link dependencies in the third party packages.

Anyway, they seem to be aware of this issues as there is a compilation flag to force all deps to be imported: "--enable-link-all-dependencies".

I have recompiled the whole package with this, it seems to work.

pkg install -verbose -forge io

compiles and install without errors. Please test, package landing in updates_testing.

Suggested advisory:
========================

Updated octave package to ease compilation of third party packages. The new version of Octave is compiled by forcing exhaustive link dependencies.


References:
https://bugs.mageia.org/show_bug.cgi?id=25617
========================

Updated packages in core/updates_testing:
========================
octave-5.1.0-7.1.mga7
octave-devel-5.1.0-7.1.mga7
octave-doc-5.1.0-7.1.mga7.noarch

Source RPMs: 
octave-5.1.0-7.1.mga7.src.rpm

Assignee: shlomif => qa-bugs

Comment 4 Herman Viaene 2019-11-07 10:04:53 CET
MGA7-64 Plasma on Lenovo B50
No installation issues (drawing in 120 additional packages)

$ octave
GNU Octave, version 5.1.0
Copyright (C) 2019 John W. Eaton and others.
This is free software; see the source code for copying conditions.
There is ABSOLUTELY NO WARRANTY; not even for MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE.  For details, type 'warranty'.

Octave was configured for "x86_64-mageia-linux-gnu".

Additional information about Octave is available at https://www.octave.org.

Please contribute if you find this software useful.
For more information, visit https://www.octave.org/get-involved.html

Read https://www.octave.org/bugs.html to learn how to submit bug reports.
For information about changes from previous versions, type 'news'.

octave:1> pkg install -verbose -forge io

Followed by same list of messages as in Martins description, except that thereare no errors anymore.
Looks OK

Whiteboard: (none) => MGA7-64-OK
CC: (none) => herman.viaene

Comment 5 Thomas Andrews 2019-11-07 16:44:01 CET
Validating. Advisory in Comment 3.

Keywords: (none) => validated_update
CC: (none) => andrewsfarm, sysadmin-bugs

Thomas Backlund 2019-11-07 22:47:27 CET

Keywords: (none) => advisory
CC: (none) => tmb

Comment 6 Mageia Robot 2019-11-08 00:38:19 CET
An update for this issue has been pushed to the Mageia Updates repository.

https://advisories.mageia.org/MGAA-2019-0196.html

Resolution: (none) => FIXED
Status: NEW => RESOLVED


Note You need to log in before you can comment on or make changes to this bug.