Initial compile bug and fix
by Ace · in Torque Game Engine · 11/04/2003 (6:12 am) · 9 replies
Im using win98se and vc6, and recently got interested in torque again.
For some reason on the first compile vc generated a resource.h file in the vc6 folder and wont finish the compile untill the resource file is removed.
my guess is someone goofed up on the workspace settings cuz this never used to happen. the same thing happen if i get the latest haed and latest release.
Stupid thing, took me a week to figger it out al most gave up on torque, please fix this so someone eles dont have this trouble.
-edit-
heres the contents of resource.h that i removed.
//{{NO_DEPENDENCIES}}
// Microsoft Developer Studio generated include file.
// Used by TorqueDemo.rc
//
#define IDI_ICON1 101
// Next default values for new objects
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 102
#define _APS_NEXT_COMMAND_VALUE 40001
#define _APS_NEXT_CONTROL_VALUE 1000
#define _APS_NEXT_SYMED_VALUE 101
#endif
#endif
is this file needed?
-/edit-
For some reason on the first compile vc generated a resource.h file in the vc6 folder and wont finish the compile untill the resource file is removed.
my guess is someone goofed up on the workspace settings cuz this never used to happen. the same thing happen if i get the latest haed and latest release.
Stupid thing, took me a week to figger it out al most gave up on torque, please fix this so someone eles dont have this trouble.
-edit-
heres the contents of resource.h that i removed.
//{{NO_DEPENDENCIES}}
// Microsoft Developer Studio generated include file.
// Used by TorqueDemo.rc
//
#define IDI_ICON1 101
// Next default values for new objects
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 102
#define _APS_NEXT_COMMAND_VALUE 40001
#define _APS_NEXT_CONTROL_VALUE 1000
#define _APS_NEXT_SYMED_VALUE 101
#endif
#endif
is this file needed?
-/edit-
About the author
Ace Owner of NoESCape.sytes.net starting from the beginning on 3d torque
#2
Go to the project settings and tell it to ignore either libc or libcmt. You're linking with two runtimes, which results (none too surprisingly) in duplicate definitions like this.
11/05/2003 (8:05 am)
" defaultlib "LIBCMT" conflicts with use of other libs; use /NODEFAULTLIB:library"Go to the project settings and tell it to ignore either libc or libcmt. You're linking with two runtimes, which results (none too surprisingly) in duplicate definitions like this.
#3
The above erors happened with the enterprize edition of vc60 so i uninstalled it and reinstalled standard edition, now i get less errors and still seems to be the texture2bm8 file/s in error, heres what it says now:
inking...
LINK : error LNK2001: unresolved external symbol _mainCRTStartup
../tools/texture2bm8.exe : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.
texture2bm8.exe - 2 error(s), 0 warning(s)
i think i will reinstall enterprize again to night so i can try your fix on the duplicate lib thing , but can you be more specific on how to tell vc to ig nor the lib?
thanks.
11/06/2003 (6:37 am)
Thanks for you reply Ben, I understand what you are saying, but i dont know how to tell vc to ignor stuff.The above erors happened with the enterprize edition of vc60 so i uninstalled it and reinstalled standard edition, now i get less errors and still seems to be the texture2bm8 file/s in error, heres what it says now:
inking...
LINK : error LNK2001: unresolved external symbol _mainCRTStartup
../tools/texture2bm8.exe : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.
texture2bm8.exe - 2 error(s), 0 warning(s)
i think i will reinstall enterprize again to night so i can try your fix on the duplicate lib thing , but can you be more specific on how to tell vc to ig nor the lib?
thanks.
#4
I think the map2dif and maybe a couple other tools have this isse as well.
-Ron
11/06/2003 (7:01 am)
Reinstalling VC will not resolve these errors.. they are project related, you will need to go to the project settings and either do as Ben mentions or set texture2bm8 to Debug multi Threaded (for debug build) and Multi Threaded (for release build).I think the map2dif and maybe a couple other tools have this isse as well.
-Ron
#5
I'd tell you to check the help files, but in my experience they're no good for finding a single option amongst the veritable haystack of options available...
11/06/2003 (8:56 am)
It's in the project settings. You'll have to dig around a bit, or find the place that lets you enter command line options directly and add a /NODEFAULTLIB:LIBCMTI'd tell you to check the help files, but in my experience they're no good for finding a single option amongst the veritable haystack of options available...
#6
ya vc is way over my head, before, i just followed gg instructions and it all worked perfect, but i know things change and eventualy i figger it out.
i may have other questions , heh.
thanks again
11/06/2003 (4:57 pm)
Thanks again for the replys guys,i did know the reinstalling wasnt going to fix any of them errors, but i screwed the settings so bad in the current install (and other installs), at this point i think it best to start over.ya vc is way over my head, before, i just followed gg instructions and it all worked perfect, but i know things change and eventualy i figger it out.
i may have other questions , heh.
thanks again
#7
i went into the texture2bm8 settings (release)clicked the "Link" tab and under Category "input" there was the box for ignor libraries, typed in libcmt and clicked ok, did a quick clean (not the one that make vc recompile everything) and the errors went away.
That placed /NODEFAULTLIB:"LIBCMT" inthe project options box
(man, this was making me pull out my hair}
thank you very much.
11/08/2003 (7:30 am)
Yeah! heres what i did:i went into the texture2bm8 settings (release)clicked the "Link" tab and under Category "input" there was the box for ignor libraries, typed in libcmt and clicked ok, did a quick clean (not the one that make vc recompile everything) and the errors went away.
That placed /NODEFAULTLIB:"LIBCMT" inthe project options box
(man, this was making me pull out my hair}
thank you very much.
#8
11/08/2003 (7:40 am)
By the way, when it comes to newtome things, if i dont have a stepbystep, it takes me a while to figger out what the heck you are talking about:) thanks again
#9
11/08/2003 (12:16 pm)
Glad you solved your problem, Ace :)
Torque Owner Ace
Linking...
LIBCMT.lib(dosmap.obj) : error LNK2005: __dosmaperr already defined in LIBC.lib(dosmap.obj)
LIBCMT.lib(osfinfo.obj) : error LNK2005: __alloc_osfhnd already defined in LIBC.lib(osfinfo.obj)
LIBCMT.lib(osfinfo.obj) : error LNK2005: __set_osfhnd already defined in LIBC.lib(osfinfo.obj)
LIBCMT.lib(osfinfo.obj) : error LNK2005: __free_osfhnd already defined in LIBC.lib(osfinfo.obj)
LIBCMT.lib(osfinfo.obj) : error LNK2005: __get_osfhandle already defined in LIBC.lib(osfinfo.obj)
LIBCMT.lib(osfinfo.obj) : error LNK2005: __open_osfhandle already defined in LIBC.lib(osfinfo.obj)
LIBCMT.lib(read.obj) : error LNK2005: __read already defined in LIBC.lib(read.obj)
LIBCMT.lib(lseek.obj) : error LNK2005: __lseek already defined in LIBC.lib(lseek.obj)
LIBCMT.lib(write.obj) : error LNK2005: __write already defined in LIBC.lib(write.obj)
LINK : warning LNK4098: defaultlib "LIBCMT" conflicts with use of other libs; use /NODEFAULTLIB:library
../tools/texture2bm8.exe : fatal error LNK1169: one or more multiply defined symbols found
Error executing link.exe.
texture2bm8.exe - 10 error(s), 1 warning(s)
What exactly can i do?