Irrlicht and MSVC++ Express 2005

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
Mad-Mazda
Posts: 20
Joined: Mon Oct 20, 2008 5:44 am

Irrlicht and MSVC++ Express 2005

Post by Mad-Mazda »

Can Irlicht be used with Visual C++ Express 2005, or do you have to use Code Blocks?

Thanks
rogerborg
Admin
Posts: 3590
Joined: Mon Oct 09, 2006 9:36 am
Location: Scotland - gonnae no slag aff mah Engleesh
Contact:

Re: Irrlicht and MSVC++ Express 2005

Post by rogerborg »

Mad-Mazda wrote:Can Irlicht be used with Visual C++ Express 2005
Yes, it can, and the SDK comes with .sln files for VC 2005.
Please upload candidate patches to the tracker.
Need help now? IRC to #irrlicht on irc.freenode.net
How To Ask Questions The Smart Way
Mad-Mazda
Posts: 20
Joined: Mon Oct 20, 2008 5:44 am

Post by Mad-Mazda »

When i compile the engine from source, the build log comes up with unable to include "windows.h".
Dark_Kilauea
Posts: 368
Joined: Tue Aug 21, 2007 1:43 am
Location: The Middle of Nowhere

Post by Dark_Kilauea »

You need to install the platform sdk for msvc 2005 from Microsoft. (MSVC 2008 includes the platform sdk).
rogerborg wrote:Every time someone learns to use a debugger, an angel gets their wings.
Mad-Mazda
Posts: 20
Joined: Mon Oct 20, 2008 5:44 am

Post by Mad-Mazda »

Hey thanks for the reply, umm the download for the platform sdk from microsoft is 1.3GB...Umm do i need all that or only certain files...

If its only certain files could sombody upload them somwhere please. I have a bad connection so 1.3GB is a bit much

Thanks,
rogerborg
Admin
Posts: 3590
Joined: Mon Oct 09, 2006 9:36 am
Location: Scotland - gonnae no slag aff mah Engleesh
Contact:

Post by rogerborg »

I'm pretty sure that Visual C++ Express 2008 is smaller than that, so you may as well update to that instead of downloading the platform SDK.
Please upload candidate patches to the tracker.
Need help now? IRC to #irrlicht on irc.freenode.net
How To Ask Questions The Smart Way
bapi
Posts: 33
Joined: Fri Apr 04, 2008 1:57 pm
Location: India
Contact:

Post by bapi »

Ok, I had the same problem with windows.h file. So i downloaded the Platform SDK and install it. and than compile my aaplication and got this error.

=================================
msvcrt.lib(ti_inst.obj) : error LNK2005: "private: __thiscall type_info::type_info(class type_info const &)" (??0type_info@@AAE@ABV0@@Z) already defined in LIBCMTD.lib(typinfo.obj)
msvcrt.lib(ti_inst.obj) : error LNK2005: "private: class type_info & __thiscall type_info::operator=(class type_info const &)" (??4type_info@@AAEAAV0@ABV0@@Z) already defined in LIBCMTD.lib(typinfo.obj)
msvcrt.lib(MSVCR80.dll) : error LNK2005: _printf already defined in LIBCMTD.lib(printf.obj)
msvcrt.lib(MSVCR80.dll) : error LNK2005: __aligned_malloc already defined in LIBCMTD.lib(dbgheap.obj)
msvcrt.lib(MSVCR80.dll) : error LNK2005: __aligned_free already defined in LIBCMTD.lib(dbgheap.obj)
msvcrt.lib(MSVCR80.dll) : error LNK2005: _fclose already defined in LIBCMTD.lib(fclose.obj)
msvcrt.lib(MSVCR80.dll) : error LNK2005: ___iob_func already defined in LIBCMTD.lib(_file.obj)
msvcrt.lib(MSVCR80.dll) : error LNK2005: _fflush already defined in LIBCMTD.lib(fflush.obj)
msvcrt.lib(MSVCR80.dll) : error LNK2005: _vsprintf already defined in LIBCMTD.lib(vsprintf.obj)
msvcrt.lib(MSVCR80.dll) : error LNK2005: _strncmp already defined in LIBCMTD.lib(strncmp.obj)
msvcrt.lib(MSVCR80.dll) : error LNK2005: _strtoul already defined in LIBCMTD.lib(strtol.obj)
msvcrt.lib(MSVCR80.dll) : error LNK2005: _strchr already defined in LIBCMTD.lib(strchr.obj)
msvcrt.lib(MSVCR80.dll) : error LNK2005: _strrchr already defined in LIBCMTD.lib(strrchr.obj)
msvcrt.lib(MSVCR80.dll) : error LNK2005: _memmove already defined in LIBCMTD.lib(memmove.obj)
LIBCMTD.lib(crt0init.obj) : warning LNK4098: defaultlib 'msvcrt.lib' conflicts with use of other libs; use /NODEFAULTLIB:library
..\..\bin\Win32-VisualStudio\01.HelloWorld.exe : fatal error LNK1169: one or more multiply defined symbols found
===========================

What went wrong and how can i fix it.
Dark_Kilauea
Posts: 368
Joined: Tue Aug 21, 2007 1:43 am
Location: The Middle of Nowhere

Post by Dark_Kilauea »

Welcome to MSVC, lesson 2, the linker... You are going to need to mess around a bit to get your application to work. First, make sure if you are statically linking your application to the msvc libs, that ALL of your dependencies that you can modify are also statically linked to the msvc libs. Otherwise, you will need to link to the DLL version of the msvc runtime, because doing a half and half type thing doesn't seem to work in my experience. Then, you might need to exclude msvcrt.lib or libcmtd.lib from linking.

The switch between linking to the DLL and the static runtimes is in the C++ settings in your project's properties.
rogerborg wrote:Every time someone learns to use a debugger, an angel gets their wings.
bapi
Posts: 33
Joined: Fri Apr 04, 2008 1:57 pm
Location: India
Contact:

Post by bapi »

At first, Thaks for ur reply pal. But ca u explain it in easy way, what i have to do?
Dark_Kilauea
Posts: 368
Joined: Tue Aug 21, 2007 1:43 am
Location: The Middle of Nowhere

Post by Dark_Kilauea »

Eh, I can't exactly give you a tutorial because it depends on the current cocktail of libs you are using, the state of your msvc runtimes, whether said runtimes are SP 1 or not... Let's just say Microsoft has your work well cut out for you.
rogerborg wrote:Every time someone learns to use a debugger, an angel gets their wings.
bapi
Posts: 33
Joined: Fri Apr 04, 2008 1:57 pm
Location: India
Contact:

Post by bapi »

U were right Dark_Kilauea, I have fixed it. The problem was with LIB file.
Post Reply