Login
Username:

Password:

Remember me



Lost Password?

Register now!

Sections

Who's Online
88 user(s) are online (70 user(s) are browsing Forums)

Members: 0
Guests: 88

more...

Support us!

Headlines

Report message:*
 

Re: SDL2

Subject: Re: SDL2
by Raziel on 2021/2/28 23:23:29

@SinanSam460

As others have already pointed out you need to rearrange your link libs.

In your example with uMario you have to set them at least like so:

-lSDL2 -lSDL2_image -ljpeg -lpng -ltiff -lwebp -lSDL2_mixer -lsmpeg2 -lflac -lmikmod -lmodplug -lvorbis -logg -lopus -lmpg123 -lz -lpthread

As you can see you need to place the corresponding libs after their "master" includes...so, image libs after -lSDL2_image and audio libs after -SDL2_mixer.

You should also always place -lpthread and -lz at the end of your linker line, as it will be used "globally" then and don't need to be repeated (if needed).

Good luck

Powered by XOOPS 2.0 © 2001-2016 The XOOPS Project