Page 1 of 1

linux linking errors?

Posted: Wed Aug 13, 2008 2:39 am
by wolfwood2x
I tried to do some basic sprite spikes and when i have nothing more than

Code: Select all

InitSprite()
 OpenScreen(1024,768,16,"Window")
 
 ;--Sprite Loader--
    LoadSprite(0,"level.jpg",0)
    LoadSprite(2, "walls.jpg",0)
I get a linker error related to SDL_ShowCursor
I am using Ubuntu Hardy and PB 4.2 I double checked and I have sdl 1.2.13 installed
Am I doing something fundamentally wrong or is this an install issue with pb?

Posted: Wed Aug 13, 2008 4:10 am
by GBeebe
I use Ubuntu Hardy as well and haven't had a linker problem in a while. Check and make sure you have the libSDL.so in the usr/lib/ directory. Does the sprite.pb example work for you?

Oooh, can't tell from your small portion of code, but do you have UseJPEGImageDecoder() in there? That is needed to read Jpegs, I guess.

Posted: Wed Aug 13, 2008 8:47 am
by Thalius
devel versions also installed ?

Posted: Wed Aug 13, 2008 9:06 am
by Little John
When I had installed PB on Linux, I stumbled across the issue that the packages which are required by PB, have different names on different Linux distributions. I tried to "translate" the information from the Readme file:
README file of PB 4.20 for Linux wrote:Requierement:
-------------
- gcc
- GTK+ 2.0 devel (and optionally GTK+ 1.2 devel for old application support)
- SDL 1.2 devel
- libstdc++ devel
- iodbc and iodbc-devel to be able to use the Database commands (see www.iodbc.org)
- libgtkembedmoz.so shoud be installed to have the WebGadget() working (comes with the Mozilla package).
Once the Mozilla package is installed, you could have to do an ldconfig after have added the right path
(/usr/lib/mozilla.x.x) to /etc/ld.so.config.
- xine and xine-devel for the Movie commands
- libgnomeprintui2.2 and libgnomeprintui2.2-devel for the print commands
As far as I can see, on Ubuntu 8.04 the names of the mentioned packages/files are:
- gcc
- libgtk2.0-dev
- libsdl1.2-dev
- libstdc++6-4.2-dev
- libiodbc2 (?) and libiodbc2-dev (?)
- libgtkembedmoz.so
- libxine1 and libxine-dev
- libgnomeprintui2.2-0 and libgnomeprintui2.2-dev
Due to my limited knowledge of Linux, there may be mistakes in the above list. Anyway, the listed packages are installed here, and PB 4.20 runs fine.

I hope this is a little helpful.

Regards, Little John

Posted: Wed Aug 13, 2008 1:32 pm
by wolfwood2x
:shock: Im a nub... i had the regular sdl lib installed and not the devel packages. Thanks guys