link error building tutorials.

Issue #63 resolved
Anonymous created an issue

I've used Premake4.3 to generate the project files for codeblocks10.05(premake4 codeblocks) with the MinGW compiler and successfully compiled the glsdk_0.4.1 and framework files but all of the tutorials give me the same error. ld.exe cannot find -lglloadD.

"Tut 01 MainD.exe" obj\Debug\tut1.o
-lframeworkD -lglloadD -lglimgD -lglutilD -lglmeshD -lfreeglutD -ltinyxml_pmD -lglu32 -lopengl32 -lgdi32 -lwinmm -luser32 c:/program files (x86)/codeblocks/mingw/bin/../lib/gcc/mingw32/4.4.1/ ../../../../mingw32/bin/ld.exe: cannot find -lglloadD

I thought it might be something simple because I'm not familiar with codeblocks as I use devc++(which Premake doesn't generate files for) so I tried using Visual Studio 2010 Express(premake4 vs2010) only to get the exact same problem, everything builds except the tutorials. Here is the error message I get for each tutorial. LINK : fatal error LNK1104: cannot open file 'glloadD.lib'

Please help me resolve this problem, I wouldn't like to bother anyone with what might be a simple newbie mistake but Ive been at it for over 13 hours.

Comments (4)

  1. Jason McKesson repo owner
    • changed status to open

    I would like to help, but you posted this issue anonymously, so you won't get an e-mail reply back. So it's unlikely that you'll read this. But in the off chance that you do:

    You say that you built the GLSDK 0.4.1. I'm guessing that you downloaded that. You weren't supposed to; these tutorials come with a copy of the GLSDK as part of the distribution. It's in the `glsdk` subdirectory of the tutorials, and that is what you should be building.

  2. Anonymous

    Thanks for replying. I've managed to build the projects in VisualStudio2010 but when I try to run them, a messagebox pops up an says Unable the start program. Tutorial0.3.7\dlsdk\glload\lib\glloadD.lib' The specified file is an unrecognized or unsupported binary format.

    If I try with codeblocks, it only lets me have one project at a time which I can add files to(which seems right to me), but I'm getting all kinds of errors. I'm so confused. I don't even know what is supposed to be running, I've never had to deal with files scattered throughout multiple projects before. Is it really necessary to use premake? Is it not just for convenience? Can't I just start a blank project in devc++ or codeblocks and add only the required .h and .cpp files(including the ones they include and so on) to it and including them using double quotes and store them all in the same directory(the same one as the project)?.

    I would really appreciate some foolproof step by step instructions on getting just the first tutorial working in codeblocks the way you intended or preferably the way I just described if it's possible(I don't see why not). Any help will be appreciated and even if I posted annonymously you can be sure I will get your response(which could be helpful for others to see too).

  3. Jason McKesson repo owner

    I would like to try to walk you through the process, but this method of communication (via an issue in my bug database) is simply not going to work. This is something that is best worked out via e-mail or some kind of chat system. Probably the best way to do this is by creating a Bitbucket account, then using the "Inbox" system to directly contact me, so that we can have a useful exchange of messages.

    Alternatively, you could try the OpenGL.org forums, which I frequent under the name "Alfonse". BTW, were you the guy who created this thread? http://www.opengl.org/discussion_boards/ubbthreads.php?ubb=showflat&Number=306205#Post306205 If so, I was not "bothered" by you. I was trying to get you to tell me what was going on so that I could help.

    "Is it really necessary to use premake?"

    Yes. I designed both the SDK and the tutorials to work with Premake4. I'm sure you could manually find a way to create a build file for the project, but I wouldn't know how to do it, and I certainly don't suggest it. I've built the tutorials in VS 2008, 2010, Code::Blocks (for GCC), and on Linux with GNU Make.

    If the Premake4 build system isn't working, I want to know why so that I can fix it, not find a way to not use it.

    "which could be helpful for others to see too"

    The best way to be helpful to others is for me to adjust the instructions, which can only happen when I figure out what step did not work.

  4. Log in to comment