I tried to install ROS on a fresh OS X with Homebrew (https://github.com/mxcl/homebrew/), but it didn't worked correctly... So i switched back to MacPorts. After installing different ports, i tried to build ROS. It did not work. I had to add -I/opt/local/include to CMAKE_CXX_FLAGS and now it would compile but there are linker failures?¿?
ld: warning: ignoring file /opt/local/lib/libboost_signals-mt.dylib, file was built for unsupported file format which is not the architecture being linked (i386)
When i run make with VERBOSE=1, this are the last line of output
Linking CXX executable ../../bin/rxconsole cd /Users/emkei/ros-underlay/build/rx/rxtools && /opt/local/bin/cmake -E cmake_link_script CMakeFiles/rxconsole.dir/link.txt --verbose=1 /usr/bin/c++ -I/opt/local/include -I/opt/local/include/wx-2.8 -Wl,-search_paths_first -Wl,-headerpad_max_install_names CMakeFiles/rxconsole.dir/src/rxconsole/rxconsole.cpp.o -o ../../bin/rxconsole -L/opt/local/lib ../../lib/librxtools.dylib ../../lib/librosconsole.dylib ../../lib/libroscpp.dylib ../../lib/librostime.dylib ../../lib/libroscpp_serialization.dylib ../../lib/libxmlrpcpp.dylib ../../lib/libroslib.dylib ../../lib/librosconsole.dylib /opt/local/lib/liblog4cxx.dylib ../../lib/librostime.dylib /opt/local/lib/libboost_date_time-mt.dylib ../../lib/libroscpp_serialization.dylib ../../lib/librospack.dylib /opt/local/lib/libboost_filesystem-mt.dylib /opt/local/lib/libboost_system-mt.dylib /opt/local/lib/libboost_program_options-mt.dylib -L/opt/local/lib -arch i386 -framework IOKit -framework Carbon -framework Cocoa -framework System -framework QuickTime -framework OpenGL -framework AGL -lwx_macu_richtext-2.8 -lwx_macu_aui-2.8 -lwx_macu_xrc-2.8 -lwx_macu_qa-2.8 -lwx_macu_html-2.8 -lwx_macu_adv-2.8 -lwx_macu_core-2.8 -lwx_base_carbonu_xml-2.8 -lwx_base_carbonu_net-2.8 -lwx_base_carbonu-2.8 /opt/local/lib/libboost_thread-mt.dylib /opt/local/lib/libboost_regex-mt.dylib /opt/local/lib/libboost_signals-mt.dylib ld: warning: ignoring file CMakeFiles/rxconsole.dir/src/rxconsole/rxconsole.cpp.o, file was built for unsupported file format which is not the architecture being linked (i386) ... AND SO ON ... Undefined symbols for architecture i386: "_main", referenced from: start in crt1.10.6.o ld: symbol(s) not found for architecture i386 clang: error: linker command failed with exit code 1 (use -v to see invocation) make[2]: *** [bin/rxconsole] Error 1 make[1]: *** [rx/rxtools/CMakeFiles/rxconsole.dir/all] Error 2 make: *** [all] Error 2
Why want cmake link with flag -arch i386? Is there a reason for this?
(The port boost was not compiled as universal.)
Originally posted by mano on ROS Answers with karma: 141 on 2012-07-02
Post score: 1