Skip to Content.
Sympa Menu

cgal-discuss - 回复:[cgal-discuss] How to Configure Visual Studio 2005 for CGAL ? ? ?

Subject: CGAL users discussion list

List archive

回复:[cgal-discuss] How to Configure Visual Studio 2005 for CGAL ? ? ?


Chronological Thread 
  • From:
  • To:
  • Subject: 回复:[cgal-discuss] How to Configure Visual Studio 2005 for CGAL ? ? ?
  • Date: Wed, 27 Aug 2008 18:51:58 +0800

Hello my friend,

You may try this website,here my classmates and I have installed CGAL 3.3.1 with VC8 in windows.

And she writed down that how to install here. Maybe it will be helpful to you.

http://applewq1987.spaces.live.com/
----- Original Message -----
From: Samay Kumar <>
To: ,   
Subject: [cgal-discuss] How to Configure Visual Studio 2005 for CGAL ? ? ?
Date: 2008-8-27 00:02:08

Hello friends,

I am new in Visual Studio Programming. In my project, I am intended to use CGAL 3.2.1 in Visual Studio 2005. But I am having building error with it. Though I have tried with Visual Studio.net 2003 where it works fine. But still it gives error. I might be missing something to configure but really I am filling helpless. Well, it would be better if I can get the CGAL configured with Visual Studio 2005.

May be anyone can give me hint, how to proceed.. This is how I proceeded...

First I tried with Visual Studio 2005 (but din't work). I configured all stuff in my PC according to........
http://www.cs.tau.ac.il/~ophirset/robotics/ex2/Windows.html

1. Build successful of ($CGALDIR)\src\CGAL
2. Build successful of ($CGALDIR)\src\Core [So now I have ($CGALDIR)\lib\CGAL and ($CGALDIR)\lib\core++ built with VS-2005]
3. Building not successful of ($CGALDIR)\example\polygon\example.vcproj
4. Every time I get such linking error, even with other examples.

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

1>------ Build started: Project: Example, Configuration: Debug Win32 ------
1>Compiling...
1>Example.C
1>Compiling manifest to resources...
1>Linking...
1>Example.obj : error LNK2019: unresolved external symbol __imp___CrtDbgReportW referenced in function "public: class CGAL::Point_2<struct CGAL::Cartesian<double> > const & __thiscall std::list<class CGAL::Point_2<struct CGAL::Cartesian<double> >,class std::allocator<class CGAL::Point_2<struct CGAL::Cartesian<double> > > >::_Const_iterator<1>::operator*(void)const " (??D?$_Const_iterator@$00@?$list@V?$Point_2@U?$Cartesian@N@CGAL@@@CGAL@@V?$allocator@V?$Point_2@U?$Cartesian@N@CGAL@@@CGAL@@@std@@@std@@QBEABV?$Point_2@U?$Cartesian@N@CGAL@@@CGAL@@XZ)
1>Debug/Example.exe : fatal error LNK1120: 1 unresolved externals
1>Build log was saved at "file://d:\Workspace\cgal_example\Polygon\Debug\BuildLog.htm"
1>Example - 2 error(s), 0 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

=======XXXX=======XXXX=======XXXX=======XXXX=======XXXX=======XXXX=======XXXX=======XXXX=======XXXX=======


Then, I tried with Visual Studio.net 2003 (worked but faced some other problem). In this procedure I used original version of source code, not the modified after building with VisualStudio 2005.

1. Build successful of ($CGALDIR)\src\CGAL
2. Build successful of ($CGALDIR)\src\Core [So now I have ($CGALDIR)\lib\CGAL and ($CGALDIR)\lib\core++ built with VS-2003 which is default I think]
3. Opened the same project. ($CGALDIR)\example\polygon\example.vcproj.
4. Cleaned the existing solution.
5. Build successful

*****************************************************************************************************************************************************************************

------ Build started: Project: Example, Configuration: Debug Win32 ------

Compiling...
Example.C
Linking...

Build log was saved at "file://d:\Workspace\cgal_example\Polygon\Debug\BuildLog.htm"
Example - 0 error(s), 0 warning(s)


---------------------- Done ----------------------

    Build: 1 succeeded, 0 failed, 0 skipped

*****************************************************************************************************************************************************************************

6. Then I just added header #include <windows.h>  and one statement in main(), that's  Sleep(2000);
7. Build failed
8. I can not understand what the problem is...

############################################################################################################################

------ Build started: Project: Example, Configuration: Debug Win32 ------

Compiling...
Example.C
Example.C(16) : error C2365: 'Polygon' : redefinition; previous definition was a 'function'
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\PlatformSDK\Include\WinGDI.h(3760) : see declaration of 'Polygon'
Example.C(27) : error C2146: syntax error : missing ';' before identifier 'p'
Example.C(27) : warning C4551: function call missing argument list
Example.C(27) : error C2065: 'p' : undeclared identifier
Example.C(28) : error C2228: left of '.push_back' must have class/struct/union type
        type is ''unknown-type''
Example.C(28) : error C3861: 'p': identifier not found, even with argument-dependent lookup
Example.C(29) : error C2228: left of '.push_back' must have class/struct/union type
        type is ''unknown-type''
Example.C(29) : error C3861: 'p': identifier not found, even with argument-dependent lookup
Example.C(30) : error C2228: left of '.push_back' must have class/struct/union type
        type is ''unknown-type''
Example.C(30) : error C3861: 'p': identifier not found, even with argument-dependent lookup
Example.C(31) : error C2228: left of '.push_back' must have class/struct/union type
        type is ''unknown-type''
Example.C(31) : error C3861: 'p': identifier not found, even with argument-dependent lookup
Example.C(32) : error C2228: left of '.push_back' must have class/struct/union type
        type is ''unknown-type''
Example.C(32) : error C3861: 'p': identifier not found, even with argument-dependent lookup
Example.C(36) : error C2593: 'operator <<' is ambiguous
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(434): could be 'std::basic_ostream<_Elem,_Traits>::_Myt &std::basic_ostream<_Elem,_Traits>::operator <<(std::basic_ostream<_Elem,_Traits>::_Mysb *)'
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(414): or       'std::basic_ostream<_Elem,_Traits>::_Myt &std::basic_ostream<_Elem,_Traits>::operator <<(const void *)'
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(394): or       'std::basic_ostream<_Elem,_Traits>::_Myt &std::basic_ostream<_Elem,_Traits>::operator <<(long double)'
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(374): or       'std::basic_ostream<_Elem,_Traits>::_Myt &std::basic_ostream<_Elem,_Traits>::operator <<(double)'
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(354): or       'std::basic_ostream<_Elem,_Traits>::_Myt &std::basic_ostream<_Elem,_Traits>::operator <<(float)'
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(333): or       'std::basic_ostream<_Elem,_Traits>::_Myt &std::basic_ostream<_Elem,_Traits>::operator <<(unsigned __int64)'
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(313): or       'std::basic_ostream<_Elem,_Traits>::_Myt &std::basic_ostream<_Elem,_Traits>::operator <<(__int64)
'
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(292): or       'std::basic_ostream<_Elem,_Traits>::_Myt &std::basic_ostream<_Elem,_Traits>::operator <<(unsigned long)'
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(272): or       'std::basic_ostream<_Elem,_Traits>::_Myt &std::basic_ostream<_Elem,_Traits>::operator <<(long)'
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(252): or       'std::basic_ostream<_Elem,_Traits>::_Myt &std::basic_ostream<_Elem,_Traits>::operator <<(unsigned int)'
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(227): or       'std::basic_ostream<_Elem,_Traits>::_Myt &std::basic_ostream<_Elem,_Traits>::operator <<(int)'
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(207): or       'std::basic_ostream<_Elem,_Traits>::_Myt &std::basic_ostream<_Elem,_Traits>::operator <<(unsigned short)'
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(174): or       'std::basic_ostream<_Elem,_Traits>::_Myt &std::basic_ostream<_Elem,_Traits>::operator <<(short)'
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(154): or       'std::basic_ostream<_Elem,_Traits>::_Myt &std::basic_ostream<_Elem,_Traits>::operator <<(std::_Bool)'
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(148): or       'std::basic_ostream<_Elem,_Traits>::_Myt &std::basic_ostream<_Elem,_Traits>::operator <<(std::ios_base &(__cdecl *)(std::ios_base &))'
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(142): or       'std::basic_ostream<_Elem,_Traits>::_Myt &std::basic_ostream<_Elem,_Traits>::operator <<(std::basic_ostream<_Elem,_Traits>::_Myios &(__cdecl *)(std::basic_ostream<_Elem,_Traits>::_Myios &))'
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(137): or       'std::basic_ostream<_Elem,_Traits>::_Myt &std::basic_ostream<_Elem,_Tra
its>::operator <<(std::basic_ostream<_Elem,_Traits>::_Myt &(__cdecl *)(std::basic_ostream<_Elem,_Traits>::_Myt &))'
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(887): or       'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,unsigned char)' [found using argument-dependent lookup]
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(880): or       'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,const unsigned char *)' [found using argument-dependent lookup]
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(873): or       'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,signed char)' [found using argument-dependent lookup]
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(866): or       'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,const signed char *)' [found using argument-dependent lookup]
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(744): or       'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,char)' [found using argument-dependent lookup]
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(697): or       'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,const char *)' [found using argument-dependent lookup]
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(659): or       'std::basic_ostream<_Elem,_Traits> &std::operator <<<char,std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,char)' [found using argument-dependent lookup]
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        d:\ProgramFiles\Microsoft Visual Studio .NET 2003\Vc7\include\ostream(613): or       'std::basic_ostream<_Elem,_Traits> &std::operator <<<char,std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,const char *)' [found using argument-dependent lookup]
        with
        [
            _Elem=char,
            _Traits=std::char_traits<char>
        ]
        while trying to match the argument list '(std::ostream, 'unknown-type')'
Example.C(36) : error C3861: 'p': identifier not found, even with argument-dependent lookup
Example.C(40) : error C2228: left of '.is_simple' must have class/struct/union type
        type is ''unknown-type''
Example.C(40) : error C3861: 'p': identifier not found, even with argument-dependent lookup
Example.C(41) : error C2228: left of '.is_convex' must have class/struct/union type
        type is ''unknown-type''
Example.C(41) : error C3861: 'p': identifier not found, even with argument-dependent lookup
Example.C(42) : error C2228: left of '.orientation' must have class/struct/union type
        type is ''unknown-type''
Example.C(42) : error C3861: 'p': identifier not found, even with argument-dependent lookup
Example.C(43) : error C2228: left of '.area' must have class/struct/union type
        type is ''unknown-type''
Example.C(43) : error C3861: 'p': identifier not found, even with argument-dependent lookup
Example.C(65) : error C2228: left of '.bounded_side' must have class/struct/union type
        type is ''unknown-type''
Example.C(65) : error C3861: 'p': identifier not found, even with argument-dependent lookup
Example.C(73) : error C2228: left of '.vertices_begin' must have class/struct/union type
        type is ''unknown-type''
Example.C(73) : error C3861: 'p': identifier not found, even with argument-dependent lookup
Example.C(73) : error C2228: left of '.vertices_end' must have class/struct/union type
        type is ''unknown-type''
Example.C(73) : error C3861: 'p': identifier not found, even with argument-dependent lookup
Example.C(78) : error C2228: left of '.edges_begin' must have class/struct/union type
        type is ''unknown-type''
Example.C(78) : error C3861: 'p': identifier not found, even with argument-dependent lookup
Example.C(78) : error C2228: left of '.edges_end' must have class/struct/union type
        type is ''unknown-type''
Example.C(78) : error C3861: 'p': identifier not found, even with argument-dependent lookup

Build log was saved at "file://d:\Workspace\cgal_example\Polygon\Debug\BuildLog.htm"
Example - 33 error(s), 1 warning(s)


---------------------- Done ----------------------

    Build: 0 succeeded, 1 failed, 0 skipped

############################################################################################################################


It would be really great if anyone help me to get Visual Studio 2005 working with CGAL. Thanks in advance for any kind of hint or details.

Greetings,
Samay



注册新浪2G免费邮箱

  • 回复:[cgal-discuss] How to Configure Visual Studio 2005 for CGAL ? ? ?, 666556602z, 08/27/2008

Archive powered by MHonArc 2.6.16.

Top of Page