SDL, gcc & Fedora
Hi there, I have installed FEDORA 16 Recently. I am learning graphics in c programming.
I have installed SDL using: sudo yum install SDL* sudo yum groupinstall 'Development Tools' On compiling I am getting lot of undefined references to SDL_Init, MapRGB, LockSurface, UnlockSurface etc.. I am clueless. please tell me how to solve this problem.. thanks in advance |
you might want to read the gcc porting guides for the VERY VERY VERY new gcc4.6 in fedora 16
http://gcc.gnu.org/ http://gcc.gnu.org/gcc-4.6/ http://gcc.gnu.org/gcc-4.6/changes.html code that is no longer supported in 4.6 http://gcc.gnu.org/gcc-4.5/changes.html#obsoleted most programs WILL need to be hacked in order to build with gcc 4.6 welcome to life using fedora fedora is almost always way too new for most things . MOST programs WILL need some editing/hacking to build in fedora 16 googling the errors will help you and point you in the right direction . But then you should already know this from the research you did on just what fedora is , before you installed it. |
SDL_Init : A symbol in libSDL.so. Package name = SDL-devel
MapRGB : The same. LockSurface : Not found in any SDL library. ( SDL_LockSurface is present.) Same for UnlockSurface. The symbol name is SDL_UnlockSurface. About gcc : Install compat-gcc-34-c++. Use with e.g. : ./configure CC=gcc34 CXX=g++34 Or : make CC=gcc34 CXX=g++34 . |
actually it was an error of 'missing path to library' .. SDL libraries were outside the standard lib folder.. I added the SDL library path in the compile command and it worked very well... thanks a lot..
|
All times are GMT -5. The time now is 06:04 AM. |