Skip to content
This repository has been archived by the owner on May 10, 2019. It is now read-only.

brew install gnu radio fails with ld: symbol(s) not found for architecture x86_64 #49

Open
coaic opened this issue Mar 14, 2014 · 11 comments

Comments

@coaic
Copy link

coaic commented Mar 14, 2014

brew install gnuradio
==> Downloading http://gnuradio.org/releases/gnuradio/gnuradio-3.6.5.1.tar.gz
Already downloaded: /Library/Caches/Homebrew/gnuradio-3.6.5.1.tar.gz
==> Patching
patching file grc/CMakeLists.txt
patching file gr-qtgui/lib/spectrumdisplayform.ui
==> cmake .. -DCMAKE_PREFIX_PATH=/usr/local/Cellar/gnuradio/3.6.5.1 -DQWT_INCLUDE_DIRS=/usr/local/lib/qwt.framework/Headers -DCMAK
==> make
ld: symbol(s) not found for architecture x86_64
collect2: ld returned 1 exit status
make[2]: *** [gnuradio-core/src/lib/libgnuradio-core.3.6.5.1.dylib] Error 1
make[1]: *** [gnuradio-core/src/lib/CMakeFiles/gnuradio-core.dir/all] Error 2
make: *** [all] Error 2

From the brew log:

Undefined symbols for architecture x86_64:
"boost::filesystem::path_traits::dispatch(boost::filesystem::directory_entry const&, std::basic_string<char, std::char_traits, std::allocator >&, std::codecvt<wchar_t, char, _mbstate_t> const&)", referenced from:
boost::filesystem::path::pathboost::filesystem::directory_entry(boost::filesystem::directory_entry const&, boost::enable_ifboost::filesystem::path_traits::is_pathable<boost::decayboost::filesystem::directory_entry::type, void>::type
)in gr_prefs.cc.o
ld: symbol(s) not found for architecture x86_64
collect2: ld returned 1 exit status
make[2]: *_* [gnuradio-core/src/lib/libgnuradio-core.3.6.5.1.dylib] Error 1
make[1]: *** [gnuradio-core/src/lib/CMakeFiles/gnuradio-core.dir/all] Error 2
make: *** [all] Error 2

HOMEBREW_VERSION: 0.9.5
HEAD: c5b1d4268075991722504aee3189d7e3fa3fe7ec
CPU: 8-core 64-bit ivybridge
OS X: 10.9.2-x86_64
Xcode: 5.1
CLT: 5.1.0.0.1.1393561416
X11: 2.7.5 => /opt/X11
~

@a1k0n
Copy link

a1k0n commented Mar 14, 2014

Seconded; same problem. https://gist.github.com/a1k0n/9554723

@sdd
Copy link

sdd commented Mar 21, 2014

I'm getting the same.Has anyone resolved this?

@sdd
Copy link

sdd commented Mar 21, 2014

@sdd
Copy link

sdd commented Mar 22, 2014

I managed to get it working. I added the following to boost.rb, just before the call to bootstrap.sh:

bargs << "--with-toolset=clang"
args << "toolset=clang" << "cxxflags=-std=c++11" << "cxxflags=-stdlib=libc++" << "linkflags=-stdlib=libc++"

Then I rebuilt boost:

brew remove boost
brew install boost --build-from-source --cxx11

Then I modified gnuradio.rb, so that it compiles using clang (I've got XCode 5 / clang 5.0 (clang-500.2.79) ):

    ENV['CC'] = '/usr/bin/clang'
    ENV['LD'] = '/usr/bin/clang'
    ENV['CXX'] = '/usr/bin/clang++'

Then, in gnuradio.rb, just above where python_prefix gets set, I added the following:

boost_prefix = Formula['boost'].prefix
args << "-DBOOST_ROOT=#{Formula['boost'].prefix}"
args << "-DBoost_INCLUDE_DIR=#{Formula['boost'].include}"
args << "-DBoost_LIBRARY_DIRS=#{Formula['boost'].lib}"

Then I build gnuradio using:

brew install gnuradio

NB I've not got it to compile yet with --with-qt.

@Oxtay
Copy link

Oxtay commented Apr 24, 2014

I ran to the exact same problem. Does this still work for you? I tried the same exact steps that you had explained above, but it seems that clang hasn't been installed in /usr/bin by following the above steps. There is still only gpp-4.2 and g++-4.2, so when trying to install gnuradio I get nowhere with the following error:

CMake Error: Could not find cmake module file: /tmp/gnuradio-lkM8/gnuradio-3.6.5.1/build/CMakeFiles/2.8.12.2/CMakeCCompiler.cmake
CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
CMake Error: CMAKE_C_COMPILER not set, after EnableLanguage

@johnny2k
Copy link

I tried Sc0tty's solution and get this ....

==> cmake .. -DCMAKE_PREFIX_PATH=/usr/local/Cellar/gnuradio/3.6.5.1 -DQWT_INCLUDE_DIRS=/usr/local/lib/qwt.framework/Headers -DCMAKE_INSTALL_PREFIX=/usr/local/Cellar/gnuradio/3.6.5.1 -DCMAKE_BUILD_TYPE=None -DCMAKE_FIND_FRAMEWORK=LAST -DCM
==> make
4 errors generated.
make[2]: *** [gnuradio-core/src/lib/CMakeFiles/gnuradio-core.dir/io/ppio_ppdev.cc.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [gnuradio-core/src/lib/CMakeFiles/gnuradio-core.dir/all] Error 2
make: *** [all] Error 2

@ahtkhan
Copy link

ahtkhan commented Sep 15, 2014

Hi,

I have installed GNU radio but I m getting error at last in cd build gnuradio that volk boost build error.Please can anyone tell me hoe to resolve it

@phy5ics
Copy link

phy5ics commented Dec 3, 2014

I tried Sc0tty's solution as well and ended up with the same result:

4 errors generated.
make[2]: *** [gnuradio-core/src/lib/CMakeFiles/gnuradio-core.dir/io/ppio_ppdev.cc.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [gnuradio-core/src/lib/CMakeFiles/gnuradio-core.dir/all] Error 2
make: *** [all] Error 2

@ahtkhan
Copy link

ahtkhan commented Dec 6, 2014

hi

I am working on Spectrum Sensing by Energy Detector for cognitive radio on
usrp and GNU Radio hardware platform. Can you Please help for that?

regards,
Ahtesham Khan

On Wed, Dec 3, 2014 at 11:29 PM, John Barton [email protected]
wrote:

I tried Sc0tty's solution as well and ended up with the same result:

4 errors generated.
make[2]: ***
[gnuradio-core/src/lib/CMakeFiles/gnuradio-core.dir/io/ppio_ppdev.cc.o]
Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [gnuradio-core/src/lib/CMakeFiles/gnuradio-core.dir/all]
Error 2
make: *** [all] Error 2


Reply to this email directly or view it on GitHub
#49 (comment)
.

@evilantnie
Copy link

I was running into the same make errors on Mavericks w/ Xcode 6.1.1 following @sc0ttyd's instructions above.

I discovered a clang compile error and created a small patch that seems to fix the compile problem. Just run brew edit gnuradio and add this diff to the bottom of gnuradio.rb https://gist.github.com/evilantnie/06f80638ce0dab8c2e4d

@ahtkhan
Copy link

ahtkhan commented Mar 15, 2015

Is there any way that I can encrypt my data when I'm using a file source in
gnu radio. I want to encrypt my data in the file which I have saved with
.bin extension but I am confused regarding how to go about the encryption
of data in my file. Please provide help with the out of tree module for
encryption if there is any or else can anyone suggest a solution.

Thank you
On Jan 1, 2015 3:51 AM, "Anthony M" [email protected] wrote:

I was running into the same make errors on Mavericks w/ Xcode 6.1.1
following @sc0ttyd https://github.com/sc0ttyd's instructions above.

I discovered a clang compile error and created a small patch that seems to
fix the compile problem. Just run brew edit gnuradio and add this diff to
the bottom of gnuradio.rb
https://gist.github.com/evilantnie/06f80638ce0dab8c2e4d


Reply to this email directly or view it on GitHub
#49 (comment)
.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants