Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Machuse

Pages: [1]
1
C / VS 2010 and C - initial test program compile problem
« on: May 01, 2011, 05:17:12 pm »
Thank you,

That actually got it working right out the box.
I am using the standard VS2010.

Only strange thing is, I have to use the extern - even when using the dll's is this correct?

i.e. linking to csfml-system.lib;csfml-window.lib;csfml-graphics.lib;
and  SFML_DYNAMIC macro set

2
C / VS 2010 and C - initial test program compile problem
« on: May 01, 2011, 03:41:53 pm »
Just trying to get my feet wet.
using VS 2010 and SFML 1.6

I have included the libs in additional dependicies :
csfml-system-s.lib;csfml-window-s.lib;csfml-graphics-s.lib;

Code: [Select]

 #include <SFML/Audio.h>
 #include <SFML/Graphics.h>
 
 int main()
 {
     sfWindowSettings Settings = {24, 8, 0};
     sfVideoMode Mode = {800, 600, 32};
     sfRenderWindow* App;


     /* Create the main window */
     App = sfRenderWindow_Create(Mode, "SFML window", sfResize | sfClose, Settings);
     if (!App)
         return EXIT_FAILURE;

 
     sfRenderWindow_Destroy(App);
 
     return EXIT_SUCCESS;
 }



I am getting


Error   3   error LNK1120: 2 unresolved externals   B:\Dropbox\***\Experimentation\Gorgon\Dev\Gorgon\Source\Gorgon\Release\Gorgon.exe   Gorgon
Error   1   error LNK2001: unresolved external symbol "struct sfRenderWindow * __cdecl sfRenderWindow_Create(struct sfVideoMode,char const *,unsigned long,struct sfWindowSettings)" (?sfRenderWindow_Create@@YAPAUsfRenderWindow@@UsfVideoMode@@PBDKUsfWindowSettings@@@Z)
   B:\Dropbox\***\Experimentation\Gorgon\Dev\Gorgon\Source\Gorgon\main.obj   Gorgon
Error   2   error LNK2001: unresolved external symbol "void __cdecl sfRenderWindow_Destroy(struct sfRenderWindow *)" (?sfRenderWindow_Destroy@@YAXPAUsfRenderWindow@@@Z)   B:\Dropbox\PrideOfConcept\Experimentation\Gorgon\Dev\Gorgon\Source\Gorgon\main.obj   Gorgon

I get this error when using the static libs and the dll's (with the corresponding Macro enabled)


Thanks[/code]

Pages: [1]
anything