Project

General

Profile

Actions

Bug #3662

closed

not building on OSX 10.13.4

Added by dstuart over 5 years ago. Updated 9 months ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Target version:
-
Start date:
10/18/2018
Due date:
% Done:

0%

Spec Reference:

Description

I am having issues with linking libgrgsm.dylib in OSX. I believe it need just a few extra CXX_FLAGS to link to boost correctly.

[ 1%] Linking CXX shared library libgrgsm.dylib
Undefined symbols for architecture x86_64:
"boost::detail::thread_data_base::~thread_data_base()", referenced from:
boost::detail::thread_data<boost::_bi::bind_t<void, boost::_mfi::mf0<void, gr::gsm::burst_file_source_impl>, boost::_bi::list1<boost::_bi::value<gr::gsm::burst_file_source_impl*> > > >::~thread_data() in burst_file_source_impl.cc.o
boost::detail::thread_data<boost::_bi::bind_t<void, boost::_mfi::mf0<void, gr::gsm::burst_file_source_impl>, boost::_bi::list1<boost::_bi::value<gr::gsm::burst_file_source_impl*> > > >::~thread_data() in burst_file_source_impl.cc.o
boost::detail::thread_data<boost::_bi::bind_t<void, boost::_mfi::mf0<void, gr::gsm::message_file_source_impl>, boost::_bi::list1<boost::_bi::value<gr::gsm::message_file_source_impl*> > > >::~thread_data() in message_file_source_impl.cc.o
boost::detail::thread_data<boost::_bi::bind_t<void, boost::_mfi::mf0<void, gr::gsm::message_file_source_impl>, boost::_bi::list1<boost::_bi::value<gr::gsm::message_file_source_impl*> > > >::~thread_data() in message_file_source_impl.cc.o
boost::detail::thread_data<boost::_bi::bind_t<void, boost::_mfi::mf0<void, gr::gsm::udp_socket>, boost::_bi::list1<boost::_bi::value<gr::gsm::udp_socket*> > > >::~thread_data() in udp_socket.cc.o
boost::detail::thread_data<boost::_bi::bind_t<void, boost::_mfi::mf0<void, gr::gsm::udp_socket>, boost::_bi::list1<boost::_bi::value<gr::gsm::udp_socket*> > > >::~thread_data() in udp_socket.cc.o
boost::detail::thread_data<boost::_bi::bind_t<void, boost::_mfi::mf0<void, gr::gsm::burst_source_impl>, boost::_bi::list1<boost::_bi::value<gr::gsm::burst_source_impl*> > > >::~thread_data() in burst_source_impl.cc.o
...
"boost::thread::join_noexcept()", referenced from:
gr::gsm::burst_file_source_impl::stop() in burst_file_source_impl.cc.o
gr::gsm::message_file_source_impl::stop() in message_file_source_impl.cc.o
gr::gsm::udp_socket::~udp_socket() in udp_socket.cc.o
gr::gsm::burst_source_impl::stop() in burst_source_impl.cc.o
gr::gsm::message_source_impl::stop() in message_source_impl.cc.o
"boost::thread::native_handle()", referenced from:
gr::gsm::burst_file_source_impl::stop() in burst_file_source_impl.cc.o
gr::gsm::message_file_source_impl::stop() in message_file_source_impl.cc.o
gr::gsm::udp_socket::~udp_socket() in udp_socket.cc.o
gr::gsm::burst_source_impl::stop() in burst_source_impl.cc.o
gr::gsm::message_source_impl::stop() in message_source_impl.cc.o
"boost::thread::start_thread_noexcept()", referenced from:
gr::gsm::burst_file_source_impl::start() in burst_file_source_impl.cc.o
gr::gsm::message_file_source_impl::start() in message_file_source_impl.cc.o
gr::gsm::udp_socket::udp_socket(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&, 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&, unsigned long) in udp_socket.cc.o
gr::gsm::burst_source_impl::start() in burst_source_impl.cc.o
gr::gsm::message_source_impl::start() in message_source_impl.cc.o
"boost::thread::detach()", referenced from:
void boost::detail::sp_pointer_construct<boost::thread, boost::thread>(boost::shared_ptr<boost::thread>*, boost::thread*, boost::detail::shared_count&) in burst_file_source_impl.cc.o
boost::detail::sp_counted_impl_p<boost::thread>::dispose() in burst_file_source_impl.cc.o
void boost::detail::sp_pointer_construct<boost::thread, boost::thread>(boost::shared_ptr<boost::thread>*, boost::thread*, boost::detail::shared_count&) in message_file_source_impl.cc.o
boost::detail::sp_counted_impl_p<boost::thread>::dispose() in message_file_source_impl.cc.o
gr::gsm::udp_socket::udp_socket(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&, 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&, unsigned long) in udp_socket.cc.o
gr::gsm::udp_socket::~udp_socket() in udp_socket.cc.o
void boost::detail::sp_pointer_construct<boost::thread, boost::thread>(boost::shared_ptr<boost::thread>*, boost::thread*, boost::detail::shared_count&) in burst_source_impl.cc.o
...
"boost::thread::interrupt()", referenced from:
gr::gsm::burst_file_source_impl::stop() in burst_file_source_impl.cc.o
gr::gsm::message_file_source_impl::stop() in message_file_source_impl.cc.o
gr::gsm::udp_socket::~udp_socket() in udp_socket.cc.o
gr::gsm::burst_source_impl::stop() in burst_source_impl.cc.o
gr::gsm::message_source_impl::stop() in message_source_impl.cc.o
"boost::thread::thread()", referenced from:
gr::gsm::udp_socket::udp_socket(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&, 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&, unsigned long) in udp_socket.cc.o
"typeinfo for boost::detail::thread_data_base", referenced from:
typeinfo for boost::detail::thread_data<boost::_bi::bind_t<void, boost::_mfi::mf0<void, gr::gsm::burst_file_source_impl>, boost::_bi::list1<boost::_bi::value<gr::gsm::burst_file_source_impl*> > > > in burst_file_source_impl.cc.o
typeinfo for boost::detail::thread_data<boost::_bi::bind_t<void, boost::_mfi::mf0<void, gr::gsm::message_file_source_impl>, boost::_bi::list1<boost::_bi::value<gr::gsm::message_file_source_impl*> > > > in message_file_source_impl.cc.o
typeinfo for boost::detail::thread_data<boost::_bi::bind_t<void, boost::_mfi::mf0<void, gr::gsm::udp_socket>, boost::_bi::list1<boost::_bi::value<gr::gsm::udp_socket*> > > > in udp_socket.cc.o
typeinfo for boost::detail::thread_data<boost::_bi::bind_t<void, boost::_mfi::mf0<void, gr::gsm::burst_source_impl>, boost::_bi::list1<boost::_bi::value<gr::gsm::burst_source_impl*> > > > in burst_source_impl.cc.o
typeinfo for boost::detail::thread_data<boost::_bi::bind_t<void, boost::_mfi::mf0<void, gr::gsm::message_source_impl>, boost::_bi::list1<boost::_bi::value<gr::gsm::message_source_impl*> > > > in message_source_impl.cc.o
"vtable for boost::detail::thread_data_base", referenced from:
boost::detail::thread_data_base::thread_data_base() in burst_file_source_impl.cc.o
boost::detail::thread_data_base::thread_data_base() in message_file_source_impl.cc.o
boost::detail::thread_data_base::thread_data_base() in udp_socket.cc.o
boost::detail::thread_data_base::thread_data_base() in burst_source_impl.cc.o
boost::detail::thread_data_base::thread_data_base() in message_source_impl.cc.o
NOTE: a missing vtable usually means the first non-inline virtual member function has no definition.
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make2: * [lib/libgrgsm.0.42.2..dylib] Error 1
make1:
[lib/CMakeFiles/grgsm.dir/all] Error 2
make: *
* [all] Error 2

Actions #1

Updated by ptrkrysik over 5 years ago

Welcome the first user bug report in the new osmocom home of the project :).

I think '-lboost_thread' or '-lboost_thread-mt' might be missing.

Can you run

VERBOSE=1 make

and send the result? You can attach it as a file to keep the report smaller.

I don't have OSX so you will be better off to try to fix it yourself (and then send feedback here). For example you can try to play with this part:
http://git.osmocom.org/gr-gsm/tree/lib/CMakeLists.txt#n99

and add there something like: "boost_thread" or "boost_thread-mt" and see what happens then.

Actions #2

Updated by dstuart over 5 years ago

Hi,

Thanks for that it did the trick "boost_thread-mt" I had to do some modification to a few files OSX wasn't great in finding some headers. But hit a huge blocker at about 91% of the way through the build which is gr-gsm requires gnuradio companion python binds which which with the current stable version requires QT4 which is no longer supported on OSX. So I am currently in the rather painful process of building gnuradio-3.8tech-preview which is built off QT5 but its not ready to just compile, then I will return to gr-gsm and see if it build from there..

Thanks for you help and will update any findings changes

Actions #3

Updated by ptrkrysik over 5 years ago

Try adding this option to cmake:
-DENABLE_GRCC=NO

You won't have grgsm_livemon. I don't know if it would run if GRC is not
running on your computer anyway. At least we will see if there aren't
other problems.

Actions #4

Updated by dstuart over 5 years ago

So it runs fine adding the disable GRC option, thanks. But I was kind of hoping to use livemon, So I compiled gnuradio using the gnuradio-3.8tech-preview which was painful but I got there in the end and grc works with QT5. I can compile grgsm against that with the -DENABLE_GRCC=NO fine using python3.7 (with some modifications to the python, mostly to do with print statements). But its not playing nicely with grc.

A minor issue it they changed grcc option -d to -o but that can be changed in the ./apps/CMakeFiles/pygen_apps.dir/build.make file
The main issue the the GRC blocks, I keep getting errors connecting the blocks as per block. I have seen other issues in this list saying just get the right grc path but the block xml has definitely been copied into /usr/local/share/gnuradio/grc/blocks, interestingly all the files in that directory are now yaml not xml

<<< Welcome to GNU Radio Companion Compiler v3.8-compat-xxx-xunknown >>>

Block paths:
/Users/dstuart/.grc_gnuradio
/usr/local/src/gr-gsm/grc
/usr/local/share/gnuradio/grc/blocks

Loading: /usr/local/src/gr-gsm/apps/grgsm_livemon.grc
Converting from XML

Block id "gsm_bcch_ccch_demapper" not found

Load Error: /usr/local/src/gr-gsm/apps/grgsm_livemon.grc: 'id'

Compilation error
make2: * [apps/grgsm_livemon] Error 1
make1:
[apps/CMakeFiles/pygen_apps.dir/all] Error 2
make: *
* [all] Error 2

Actions #5

Updated by ptrkrysik over 5 years ago

There GNU Radio guys merged some significant changes after last GRCon. I
hope they maintain somehow backward compatibility. I need to check that.

Thanks for reporting this!

Actions #6

Updated by ptrkrysik 9 months ago

  • Status changed from New to Closed
Actions

Also available in: Atom PDF

Add picture from clipboard (Maximum size: 48.8 MB)