Skip to Content.
Sympa Menu

cgal-discuss - Re: [cgal-discuss] Another boring linking question

Subject: CGAL users discussion list

List archive

Re: [cgal-discuss] Another boring linking question


Chronological Thread 
  • From: Rhys D <>
  • To: cgal-discuss <>
  • Subject: Re: [cgal-discuss] Another boring linking question
  • Date: Thu, 24 Jan 2013 11:32:33 +1300

Thanks for the help.

I found the problem in the end:
in the preprocessor definitions, I needed to add: BOOST_ALL_DYN_LINK

Thanks!

R


On 23 January 2013 23:21, Laurent Rineau (CGAL/GeometryFactory) <> wrote:
Le mercredi 23 janvier 2013 16:01:14 Rhys D a écrit :
> Hi,
>
> I have just started with CGAL and can't get any of the demos to compile.
>
> I am using Boost 1.51
>
> Here is the verbose VC++ error
> You can see that it is searching in what seems to me to be the correct lib
> file but is still failing.
>
> My environment:
>
> Windows 7 x64
> Visual Studio 2010
> Boost 1.51 - 64 downloaded from here: http://www.boostpro.com/download/
> CGAL-4.1
>
> I have reinstalled everything from scratch but still keep coming up against
> the same error.
> I am building Release x64. at all steps I have chosen
>
> Any ideas?
>
> Rhys.
>
> ==============================
>
> 1>      Searching
> C:\dev\CGAL-4.1-static\CGAL-4.1\build\lib\Release\CGAL-vc100-mt-4.1.lib:
> 1>      Searching C:\dev\boost_1_51\lib\libboost_thread-vc100-mt-1_51.lib:
> 1>      Searching C:\dev\boost_1_51\lib\libboost_system-vc100-mt-1_51.lib:
> 1>      Searching
> C:\dev\boost_1_51\lib\libboost_date_time-vc100-mt-1_51.lib:
> 1>      Searching C:\dev\boost_1_51\lib\libboost_chrono-vc100-mt-1_51.lib:
> 1>      Searching C:\Program Files (x86)\Microsoft Visual Studio
> 10.0\VC\lib\amd64\MSVCRT.lib:
> 1>      Searching C:\Program Files (x86)\Microsoft Visual Studio
> 10.0\VC\lib\amd64\OLDNAMES.lib:
> 1>
> 1>  Finished searching libraries
> 1>
> 1>  Finished pass 1
> 1>
> 1>nntest.obj : error LNK2001: unresolved external symbol "class
> boost::system::error_category const & __cdecl
> boost::system::system_category(void)" (?system_category@system@boost@
> @YAAEBVerror_category@12@XZ)
> 1>nntest.obj : error LNK2001: unresolved external symbol "class
> boost::system::error_category const & __cdecl
> boost::system::generic_category(void)" (?generic_category@system@boost@
> @YAAEBVerror_category@12@XZ)
> 1>C:\dev\tests\cgal_nn_test\nntest\x64\Release\nntest.exe : fatal error
> LNK1120: 2 unresolved externals
> 1>

When you configured the compilation of CGAL libraries, have you turned the
CMake variable CGAL_Boost_USE_STATIC_LIBS to OFF?

It seems that in your build of "nntest.exe", you are linking with the static
version of the Boost libraries, whereas the CGAL libraries are linked by
default with the DLL versions of Boost libraries.

--
Laurent Rineau, PhD
R&D Engineer at GeometryFactory           http://www.geometryfactory.com/
Release Manager of the CGAL Project       http://www.cgal.org/


--
You are currently subscribed to cgal-discuss.
To unsubscribe or access the archives, go to
https://sympa.inria.fr/sympa/info/cgal-discuss






Archive powered by MHonArc 2.6.18.

Top of Page