Linker error

edited March 2009 in Help request
Hello,
I just downloaded orx today and I've been playing around with, basicly following the video tutorials. Everything seemed to work fine up until I tried the clock tutorial, when I got the following linker errors:
1>MyTest.obj : error LNK2001: unresolved external symbol _orxFALSE

1>MyTest.obj : error LNK2001: unresolved external symbol _orxFLOAT_0

1>MyTest.obj : error LNK2001: unresolved external symbol _orxTRUE


I just copied in the code from 02_Clock.c from the tutorial zip-file. I guess I should say the tutorial project files compiled and linked without any errors.

Thanks in advance, and thanks for your work on orx.

Comments

  • edited March 2009
    Hi Ekerik!

    Those linking errors basically happen when trying to link against the wrong library (there are 2 versions of orx library: one statically linked and one dynamically linked) or using the wrong preprocessor defines.

    I've simplified all this in orx if you're using the svn version (which also has a lot of other simplifications + some new features).

    You have 2 solutions: either taking current orx version from svn (don't sync the extern folder if you don't plan on building orx yourself, as this folder is quite big! ;) ) or try looking at project properties in the tutorials (especially the library used to link against and the preprocessor flags).

    If you're still stuck, please send me your projet file and I'll fix it for you as fast as I can!

    Thanks for your appreciation on orx! :)

    PS: A third solution would be to wait till I release orx v1.0 but it might not be before a couple of weeks! ;)
  • edited March 2009
    Thanks for the fast reply,

    I went through the project settings and found a missing __orxDLL__ in the preprocessor definitions. Evertyhing links correctly now.
  • edited March 2009
    I'm glad you found the solution fast enough. In the current svn version, all the preprocessor flags have been removed except for __orxDEBUG__ for the debug version and __orxDLL__ only needed now when linking an exe against the dynamic version of orx. Plugins don't need it anymore.

    If you have any comment or suggestion, please share with us as it's hard to know who's trying this engine and we have close to no feedback at all! :)
Sign In or Register to comment.