User forums > Help
<filename>.lib: No such file or directory error **SOLVED**
darklordsatan:
I might be wrong, but arent you supossed to link the OgreMain.lib -notice the .lib- (not just OgreMain, since this import schema is used with *.a libraries, and this would be if the library was called libOgreMain.a...)
This is, in your first screenie, the "Link Libraries" should show "OgreMain.lib" and not "OgreMain" (perhaps you're using the template here...?)
Rune Hunter:
There is no difference in putting .lib or not, and I am not using the Ogre template.
rickg22:
OK. a) Nevermind, forget it.
About the Compiler log: You forgot to change the compiler settings as I told you. In menu "Settings", choose "compiler", there's some tabs "Compiler, Linker, Directories, Custom Variables, programs, other". Switch to "Other". There's an option entitled "Compiler Logging:" [Task description]. Click on [Task description] and change it to [Full command line].
Close the settings, and recompile. Then paste again the error in here.
Anyway, please don't think it's too tedious to fix a simple configuration mistake, we have to do it for the sake of the other codeblocks users. Be it a bug or not, this configuration error is very probable to happen to another user, and we don't want that.
See, this isn't the first time we get these kind of bug reports / support requests, and I'm kinda getting tired of them. So I want to know what's going wrong (a missing explanation in the dialogs? In the help? A default option that people mistakingly assume it's another thing?) with the setup.
And when I know what's wrong with YOUR setup and compilation process, I'l be able to modify Code::Blocks and make it much more newbie-friendly. Hope you can bear with me.
So, now that i explained myself :lol:, what's the full command line compiler log? Thanks.
Rune Hunter:
Well I do feel this is a burdon on all of us, but I this has to be solved. My guess it is somthing small, but I checked every little thing.
I did exactly what you told me to do about the compiler log. And there is no change. I rebooted the program, double checked to make sure I have it right. It really doesn't show up as an error, just a message above the Process terminated message.
mingw32-g++.exe: OgreMain.lib: No such file or directory
Also I am using a exe called cl.exe to compiler (Visual c++ toolkit), why does that error say mingw32-g++.exe. Under the compiler options -> Programs it says cl.exe for C/C++ compiling, and Link.exe for linking of libraries. No debuger and mingw32-make.exe for make files or somthing. I also do not have "work with make files" on, I have invoke compiler directly.
So the error might be around there.
rickg22:
Please slap me for not expressing myself correctly :( What I needed to get is the FULL COMPILER LOG. Since the compilation starts to the end of linking. On the "Compiler" tab in the messages pane, you should read something like this:
Project : (project name)
Compiler : (compiler name)
Directory : C:\some path\some dir\etc
--------------------------------------------------------------------------------
Switching to target: (some target)
mingw32-g++.exe -Wall -g -pipe -mthreads -fno-pcc-struct-return -fno-rtti -fmessage-length=0 (LOTS OF LIBRARIES HERE)
(etc)
*THIS* is what I need to know what's going on in the linking. And this is why i asked you to switch the compiler settings to "FULL COMMAND LINE", so I could get the ENTIRE compilation log.
Anyway, you say you use VC++ toolking, and then you got mingw32-etc in the compiler log?
Please answer me two questions.
Did you import the project / workspace from a VC++ project/workspace/solution ? If so, I assume that the importer asked you if you wanted to use the "default compiler". I think that's the case, because your project somehow is using GCC and not Visual C++.
Check out your project settings, you might have to change the compiler for it. A dialog box will ask you if you want to change the compiler for all targets. Say "YES".
So, to summarize this, I need you to:
a) Give me the full compiler log! (From the beginning)
b) Answer all the questions I asked you (even if you managed to get it working, remember it's also a usability problem we're trying to tackle here)
Thanks.
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version