'Debug CGAL example using Boost on Mac OS

I have CGAL compiled manually and installed in ~/Library/CGAL/CGAL-4.0.2/. Boost (boost @1.50.0_0+debug+no_single+no_static) as well as cmake (2.8.8_1) are installed using macports. For compilation purposes of the provided examples things work nicely. My problem is when I try to debug an example. In particular, for instance, I ran cmake -DCMAKE_BUILD_TYPE=Debug . in the directory containing the Arrangements_on_surfaces_2 and then make. The generated binary functions as expected, but when running gdb foo in order to debug foo, I get the following warnings:

warning: Could not find object file "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_devel_boost/boost/work/boost_1_50_0/bin.v2/libs/thread/build/darwin-4.2.1/debug/address-model-64/architecture-x86/threading-multi/pthread/thread.o" - no debug information available for "libs/thread/src/pthread/thread.cpp".    

warning: Could not find object file "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_devel_boost/boost/work/boost_1_50_0/bin.v2/libs/thread/build/darwin-4.2.1/debug/address-model-64/architecture-x86/threading-multi/pthread/once.o" - no debug information available for "libs/thread/src/pthread/once.cpp".

warning: Could not find object file "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_devel_boost/boost/work/boost_1_50_0/bin.v2/libs/thread/build/darwin-4.2.1/debug/address-model-64/architecture-x86/threading-multi/future.o" - no debug information available for "libs/thread/src/future.cpp".

warning: Could not find object file "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_devel_boost/boost/work/boost_1_50_0/bin.v2/libs/system/build/darwin-4.2.1/debug/address-model-64/architecture-x86/threading-multi/error_code.o" - no debug information available for "libs/system/src/error_code.cpp".

I don't really know what to do. I tried downloading, compiling and installing boost manually and then recompile CGAL. However, once I tried to compile an example I got run time complain about missing boost libraries.

On the other hand, when trying to debug an XCode project (after creating it using the -G Xcode option for cmake) I could debug an example.

Any assistance will be helpful!



Solution 1:[1]

I also had problems with Boost when I tried installing CGAL with macports. Then I tried the same with homebrew, and it worked like a charm.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Glorfindel