Cannot open file 'tgui-d.lib'

Started by Crimsowned, 05 October 2017, 05:54:06

Crimsowned

I get this error when I try to compile the simple test program from the "minimal code" tutorial. I've got the SFML and TGUI include directories added, as well as the libraries.  I also made sure to put the dll in the project folder. Lastly, I know SFML is working as I've ran some code using it before installing TGUI.
Anything I forgot to do?

edit: v 0.8-dev

texus

I don't see any reason why it wouldn't find it, unless there is no tgui-d.lib in "C:\Users\charles\TGUI-0.8-dev\lib" or "C:\Users\charles\TGUI-0.8-dev\lib" does not exist.

Could you send the project file (vcxproj file)?

In case neither of us can figure out what's wrong, I think you could also just copy the lib file next to your project as a workaround.

Crimsowned

The tgui-d.lib file is inside the debug folder, which is in the lib folder. If I move it directly into the lib folder, I get a "cannot open file *\TGUI-test.exe" error, which I'm unsure is an improvement. In any case, here's the file.

Thanks for your time.

texus

The file should be directly in the lib folder, there should not be a Debug or Release folder inside the lib folder.

I don't know why you get the "cannot open file *\TGUI-test.exe" error though. Is that the only error you get? Are there no compile or linking errors?

Crimsowned

#4
This is the exact message.

The Debug folder was created when I ran cMake, so I find it a little odd that it is there if it should not be. I think I`ll try rebuilding TGUI...


edit: tried rebuilding the solution and I still get the same error. Same happens if I try to use the pre compiled libraries.

edit2: created a new project and managed to make that one compile. Still do not know where the previous error came from, but thanks for your help nonetheless! :)

Crimsowned

In case you see something.

texus

I don't know what was wrong, based on what I can find about the error it would usually occur when the exe is locked somehow (still running or some build process crashed while still having the file locked).

QuoteThe Debug folder was created when I ran cMake, so I find it a little odd that it is there if it should not be
It's not CMake that is to blame here though, it's Visual Studio. With gcc I can just copy the build/lib folder next to the include folder but with VS I have to delete the Debug or Release folder inside it. The precompiled downloads don't have the subfolders.