bugGNU Octave - Bugs: bug #60687, octave control: Undefined symbols...

 
 

bug #60687: octave control: Undefined symbols for architecture x86_64

Submitted by:  Marius Schamschula <mschamschula>
Submitted on:  Fri 28 May 2021 04:59:11 PM UTC  
 
Category:  Octave Forge Package Severity:  3 - Normal
Priority:  5 - Normal Item Group:  None
Status:  None Assigned to:  None
Originator Name:  Marius Schamschula Open/Closed:  Open
Release:  6.2.0 Operating System:  Mac OS

Add a New Comment (Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Fri 28 May 2021 08:48:37 PM UTC, comment #5: 

helloworld.cc built and works fine.

Marius Schamschula <mschamschula>
Fri 28 May 2021 08:38:18 PM UTC, comment #4: 

The nan package uses the mex interface.

Can you try a basic oct file like examples/code/helloworld.cc: https://hg.savannah.gnu.org/hgweb/octave/file/97e12df28ee6/examples/code/helloworld.cc

#include <octave/oct.h>

DEFUN_DLD (helloworld, args, nargout,
           "Hello World Help String")
{
  octave_stdout << "Hello World has "
                << args.length () << " input arguments and "
                << nargout << " output arguments.\n";

  // Return empty matrices for any outputs
  octave_value_list retval (nargout);
  for (int i = 0; i < nargout; i++)
    retval(i) = octave_value (Matrix ());

  return retval;
}

>> mkoctfile helloworld.cc
>> [x, y, z] = helloworld (1, 2, 3, 4);
Hello World has 4 input arguments and 3 output arguments.

Mike Miller <mtmiller>
Project Administrator
Fri 28 May 2021 08:37:22 PM UTC, comment #3: 

Note: the below information was for an Intel machine. Building on an M1 (arm64) Mac, I don't even get that far:

/opt/local/bin/gfortran-mp11 -c -fPIC -pipe -Os -m32 -m64 AB01MD.f AB01MD.o
gfortran-mp11: error: unrecognized command-line option '-m32'

Marius Schamschula <mschamschula>
Fri 28 May 2021 08:26:59 PM UTC, comment #2: 

Just checked a couple of other octave packages. Of those that compiled code: nan built and linked fine, but gsl had a similar error as control.

Marius Schamschula <mschamschula>
Fri 28 May 2021 08:14:21 PM UTC, comment #1: 

These same like basic functions, I don't think this is specific to the control package, maybe update the summary if you can confirm that any trivial oct file shows similar problems.

There has been some work recently on the development branch related to library symbol visibility, and some of that is specific to macOS, but I haven't followed too closely, nor do I use macOS. Refer to the thread here: https://octave.discourse.group/t/visibility-of-symbols-in-octave-libraries/1146?u=mtmiller

Mike Miller <mtmiller>
Project Administrator
Fri 28 May 2021 04:59:11 PM UTC, original submission:  

While upgrading my work MacBook Pro to Big Sur, I ran into the following error rebuilding the control package, using MacPorts.

:info:configure rm -rf sltmp slicot
:info:configure LFLAGS="-L/opt/local/lib/octave/6.2.0 -L/opt/local/lib  -L/opt/local/lib -lopenblas -L/opt/local//lib/gcc11 -lgfortran -lquadmath -lm" \
:info:configure     /usr/bin/arch -arch x86_64 /opt/local/bin/mkoctfile-6.2.0 --verbose -Wall -Wno-deprecated-declarations  _control_slicot_functions_.cc common.cc slicotlibrary.a
:info:configure warning: LFLAGS is deprecated and will be removed in a future version of Octave, use LDFLAGS instead
:info:configure /usr/bin/clang++ -c -I/opt/local/include -isysroot/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.3.sdk -fPIC -I/opt/local/include/octave-6.2.0/octave/.. -I/opt/local/include/octave-6.2.0/octave -I/opt/local/include  -D_THREAD_SAFE -pthread -pipe -Os -std=c++11 -stdlib=libc++ -isysroot/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.3.sdk -arch x86_64  -Wall -Wno-deprecated-declarations   _control_slicot_functions_.cc -o /opt/local/var/macports/build/_Users_marius_Development_MacPorts_ports_math_octave-control/octave-control/work/.tmp/oct-eB8otE.o
:info:configure /usr/bin/clang++ -c -I/opt/local/include -isysroot/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.3.sdk -fPIC -I/opt/local/include/octave-6.2.0/octave/.. -I/opt/local/include/octave-6.2.0/octave -I/opt/local/include  -D_THREAD_SAFE -pthread -pipe -Os -std=c++11 -stdlib=libc++ -isysroot/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.3.sdk -arch x86_64  -Wall -Wno-deprecated-declarations   common.cc -o /opt/local/var/macports/build/_Users_marius_Development_MacPorts_ports_math_octave-control/octave-control/work/.tmp/oct-QmRaYL.o
:info:configure /usr/bin/clang++ -I/opt/local/include/octave-6.2.0/octave/.. -I/opt/local/include/octave-6.2.0/octave -I/opt/local/include  -D_THREAD_SAFE -pthread -pipe -Os -std=c++11 -stdlib=libc++ -isysroot/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.3.sdk -arch x86_64  -Wall -Wno-deprecated-declarations -o _control_slicot_functions_.oct  /opt/local/var/macports/build/_Users_marius_Development_MacPorts_ports_math_octave-control/octave-control/work/.tmp/oct-eB8otE.o /opt/local/var/macports/build/_Users_marius_Development_MacPorts_ports_math_octave-control/octave-control/work/.tmp/oct-QmRaYL.o  slicotlibrary.a -bundle -bundle_loader /opt/local/bin/octave-6.2.0 -L/opt/local/lib -Wl,-headerpad_max_install_names -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.3.sdk -arch x86_64  -L/opt/local/lib/octave/6.2.0 -L/opt/local/lib  -L/opt/local/lib -lopenblas -L/opt/local//lib/gcc11 -lgfortran -lquadmath -lm  -L/opt/local//lib -Wl,-headerpad_max_install_names -L/opt/local//libexec/qt5/lib -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.3.sdk -arch x86_64 -loctinterp -loctave
:info:configure ld: warning: dylib (/opt/local/lib/libopenblas.dylib) was built for newer macOS version (11.3) than being linked (11.0)
:info:configure ld: warning: dylib (/opt/local//lib/gcc11/libgfortran.dylib) was built for newer macOS version (11.3) than being linked (11.0)
:info:configure ld: warning: dylib (/opt/local//lib/gcc11/libquadmath.dylib) was built for newer macOS version (11.3) than being linked (11.0)
:info:configure Undefined symbols for architecture x86_64:
:info:configure   "check_version(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)", referenced from:
:info:configure       G__sl_ab08nd_ in oct-eB8otE.o
:info:configure       G__sl_ab13dd_ in oct-eB8otE.o
:info:configure       G__sl_sb10hd_ in oct-eB8otE.o
:info:configure       G__sl_sb10ed_ in oct-eB8otE.o
:info:configure       G__sl_ab13bd_ in oct-eB8otE.o
:info:configure       G__sl_sb01bd_ in oct-eB8otE.o
:info:configure       G__sl_sb10fd_ in oct-eB8otE.o
:info:configure       ...
:info:configure   "octave_dld_function::create(octave_value_list (*)(octave_value_list const&, int), octave::dynamic_library const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)", referenced from:
:info:configure       G__sl_ab08nd_ in oct-eB8otE.o
:info:configure       G__sl_ab13dd_ in oct-eB8otE.o
:info:configure       G__sl_sb10hd_ in oct-eB8otE.o
:info:configure       G__sl_sb10ed_ in oct-eB8otE.o
:info:configure       G__sl_ab13bd_ in oct-eB8otE.o
:info:configure       G__sl_sb01bd_ in oct-eB8otE.o
:info:configure       G__sl_sb10fd_ in oct-eB8otE.o
:info:configure       ...
:info:configure   "Array<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >::nil_rep()", referenced from:
:info:configure       Array<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >::Array() in oct-eB8otE.o
:info:configure   "Array<std::__1::complex<double> >::fill(std::__1::complex<double> const&)", referenced from:
:info:configure       Array<std::__1::complex<double> >::Array(dim_vector const&, std::__1::complex<double> const&) in oct-eB8otE.o
:info:configure   "Array<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >::resize_fill_value() const", referenced from:
:info:configure       vtable for Array<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > in oct-eB8otE.o
:info:configure   "Array<std::__1::complex<double> >::resize_fill_value() const", referenced from:
:info:configure       vtable for ComplexColumnVector in oct-eB8otE.o
:info:configure       vtable for MArray<std::__1::complex<double> > in oct-eB8otE.o
:info:configure       vtable for Array<std::__1::complex<double> > in oct-eB8otE.o
:info:configure ld: symbol(s) not found for architecture x86_64

Marius Schamschula <mschamschula>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #51493:  main.log added by mschamschula (376KiB - application/octet-stream)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by mschamschula (Submitted the item)
  • -email is unavailable- added by mschamschula
  •  

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.

     

     

     

    Follow 2 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2021-05-28 mschamschula Attached File- => Added main.log, #51493
        Carbon-Copy- => Added marius@schamschula.com

    Back to the top


    Powered by Savane 3.7