[Solved] Compiling problem - Visual Studio 2008

I followed the guide on how to compile in visual studio 2008 in detail. But still I get errors.

Errors:

1>------ Rebuild All started: Project: PandaTemplate, Configuration: Release Win32 ------
1>Deleting intermediate and output files for project 'PandaTemplate', configuration 'Release|Win32'
1>Compiling...
1>Main.cpp
1>c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\vector(439) : warning C4275: non dll-interface class 'std::_Container_base_aux' used as base for dll-interface class 'std::_Container_base_aux_alloc_real<_Alloc>'
1>        with
1>        [
1>            _Alloc=pallocator_array<std::string>
1>        ]
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\xutility(377) : see declaration of 'std::_Container_base_aux'
1>        c:\program files (x86)\panda3d-1.6.2\include\vector_src.h(64) : see reference to class template instantiation 'std::vector<_Ty,_Ax>' being compiled
1>        with
1>        [
1>            _Ty=std::string,
1>            _Ax=pallocator_array<std::string>
1>        ]
1>c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\vector(439) : warning C4275: non dll-interface class 'std::_Container_base_aux' used as base for dll-interface class 'std::_Container_base_aux_alloc_real<_Alloc>'
1>        with
1>        [
1>            _Alloc=pallocator_array<Config::SymbolEnt>
1>        ]
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\xutility(377) : see declaration of 'std::_Container_base_aux'
1>        c:\program files (x86)\panda3d-1.6.2\include\vector_src.h(64) : see reference to class template instantiation 'std::vector<_Ty,_Ax>' being compiled
1>        with
1>        [
1>            _Ty=Config::SymbolEnt,
1>            _Ax=pallocator_array<Config::SymbolEnt>
1>        ]
1>c:\program files (x86)\panda3d-1.6.2\python\include\pyconfig.h(51) : warning C4005: 'HAVE_IO_H' : macro redefinition
1>        c:\program files (x86)\panda3d-1.6.2\include\dtool_config.h(56) : see previous definition of 'HAVE_IO_H'
1>c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\vector(439) : warning C4275: non dll-interface class 'std::_Container_base_aux' used as base for dll-interface class 'std::_Container_base_aux_alloc_real<_Alloc>'
1>        with
1>        [
1>            _Alloc=pallocator_array<TypedWritable *>
1>        ]
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\xutility(377) : see declaration of 'std::_Container_base_aux'
1>        c:\program files (x86)\panda3d-1.6.2\include\vector_src.h(64) : see reference to class template instantiation 'std::vector<_Ty,_Ax>' being compiled
1>        with
1>        [
1>            _Ty=TypedWritable *,
1>            _Ax=pallocator_array<TypedWritable *>
1>        ]
1>c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\vector(439) : warning C4275: non dll-interface class 'std::_Container_base_aux' used as base for dll-interface class 'std::_Container_base_aux_alloc_real<_Alloc>'
1>        with
1>        [
1>            _Alloc=pallocator_array<int>
1>        ]
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\xutility(377) : see declaration of 'std::_Container_base_aux'
1>        c:\program files (x86)\panda3d-1.6.2\include\vector_src.h(64) : see reference to class template instantiation 'std::vector<_Ty,_Ax>' being compiled
1>        with
1>        [
1>            _Ty=int,
1>            _Ax=pallocator_array<int>
1>        ]
1>c:\program files (x86)\panda3d-1.6.2\include\socket_address.h(182) : warning C4996: 'sprintf': This function or variable may be unsafe. Consider using sprintf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\stdio.h(366) : see declaration of 'sprintf'
1>c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\vector(439) : warning C4275: non dll-interface class 'std::_Container_base_aux' used as base for dll-interface class 'std::_Container_base_aux_alloc_real<_Alloc>'
1>        with
1>        [
1>            _Alloc=pallocator_array<unsigned char>
1>        ]
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\xutility(377) : see declaration of 'std::_Container_base_aux'
1>        c:\program files (x86)\panda3d-1.6.2\include\vector_src.h(64) : see reference to class template instantiation 'std::vector<_Ty,_Ax>' being compiled
1>        with
1>        [
1>            _Ty=unsigned char,
1>            _Ax=pallocator_array<unsigned char>
1>        ]
1>c:\program files (x86)\panda3d-1.6.2\include\time_clock.h(195) : warning C4996: 'gmtime': This function or variable may be unsafe. Consider using gmtime_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\time.inl(101) : see declaration of 'gmtime'
1>c:\program files (x86)\panda3d-1.6.2\include\time_clock.h(198) : warning C4996: 'gmtime': This function or variable may be unsafe. Consider using gmtime_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\time.inl(101) : see declaration of 'gmtime'
1>c:\program files (x86)\panda3d-1.6.2\include\time_clock.h(212) : warning C4996: 'localtime': This function or variable may be unsafe. Consider using localtime_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\time.inl(114) : see declaration of 'localtime'
1>c:\program files (x86)\panda3d-1.6.2\include\time_clock.h(218) : warning C4996: 'localtime': This function or variable may be unsafe. Consider using localtime_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\time.inl(114) : see declaration of 'localtime'
1>c:\program files (x86)\panda3d-1.6.2\include\time_clock.h(250) : warning C4996: 'sprintf': This function or variable may be unsafe. Consider using sprintf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\stdio.h(366) : see declaration of 'sprintf'
1>c:\program files (x86)\panda3d-1.6.2\include\time_clock.h(264) : warning C4996: 'localtime': This function or variable may be unsafe. Consider using localtime_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\time.inl(114) : see declaration of 'localtime'
1>c:\program files (x86)\panda3d-1.6.2\include\time_clock.h(298) : warning C4996: 'sprintf': This function or variable may be unsafe. Consider using sprintf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\stdio.h(366) : see declaration of 'sprintf'
1>c:\program files (x86)\panda3d-1.6.2\include\time_clock.h(311) : warning C4996: 'gmtime': This function or variable may be unsafe. Consider using gmtime_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\time.inl(101) : see declaration of 'gmtime'
1>c:\program files (x86)\panda3d-1.6.2\include\time_span.h(372) : warning C4996: 'sprintf': This function or variable may be unsafe. Consider using sprintf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\stdio.h(366) : see declaration of 'sprintf'
1>c:\program files (x86)\panda3d-1.6.2\include\time_span.h(375) : warning C4996: 'sprintf': This function or variable may be unsafe. Consider using sprintf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\stdio.h(366) : see declaration of 'sprintf'
1>c:\program files (x86)\panda3d-1.6.2\include\time_span.h(378) : warning C4996: 'sprintf': This function or variable may be unsafe. Consider using sprintf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\stdio.h(366) : see declaration of 'sprintf'
1>c:\program files (x86)\panda3d-1.6.2\include\time_span.h(381) : warning C4996: 'sprintf': This function or variable may be unsafe. Consider using sprintf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\stdio.h(366) : see declaration of 'sprintf'
1>c:\program files (x86)\panda3d-1.6.2\include\time_span.h(384) : warning C4996: 'sprintf': This function or variable may be unsafe. Consider using sprintf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\stdio.h(366) : see declaration of 'sprintf'
1>c:\program files (x86)\panda3d-1.6.2\include\time_general.h(161) : warning C4996: 'sscanf': This function or variable may be unsafe. Consider using sscanf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\stdio.h(324) : see declaration of 'sscanf'
1>c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\vector(439) : warning C4275: non dll-interface class 'std::_Container_base_aux' used as base for dll-interface class 'std::_Container_base_aux_alloc_real<_Alloc>'
1>        with
1>        [
1>            _Alloc=pallocator_array<GraphicsWindowInputDevice>
1>        ]
1>        c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\xutility(377) : see declaration of 'std::_Container_base_aux'
1>        c:\program files (x86)\panda3d-1.6.2\include\vector_src.h(64) : see reference to class template instantiation 'std::vector<_Ty,_Ax>' being compiled
1>        with
1>        [
1>            _Ty=GraphicsWindowInputDevice,
1>            _Ax=pallocator_array<GraphicsWindowInputDevice>
1>        ]
1>Linking...
1>MSVCRT.lib(crtexew.obj) : error LNK2001: unresolved external symbol _WinMain@16
1>C:\Users\Christer\Documents\Visual Studio 2008\Projects\PandaTemplate\Release\PandaTemplate.exe : fatal error LNK1120: 1 unresolved externals
1>Build log was saved at "file://c:\Users\Christer\Documents\Visual Studio 2008\Projects\PandaTemplate\PandaTemplate\Release\BuildLog.htm"
1>PandaTemplate - 2 error(s), 22 warning(s)
========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ==========

Thanks for the help :slight_smile:

Hi, and welcome to the forums!
You appear to be experiencing the same problem as described in this thread:
discourse.panda3d.org/viewtopic.php?t=7968

Thanks! I had to make a console app. :slight_smile: