[Gambas-user] Compiling Gamabas2 (1.9.44) in SuSE 10.0

Ron Onstenk ronstk at ...239...
Tue Oct 10 02:30:04 CEST 2006


On Monday 09 October 2006 19:24, Benoit Minisini wrote:
> GB_COMPONENT(
>   sdl_sound,
>   SDL_SOUND,
>   [SDL sound],
>   [sound],
>   [GB_FIND(SDL_mixer.h SDL_cdrom.h, `sdl-config --prefix`, include/SDL)],
>   [GB_FIND(libSDL_mixer.$SHLIBEXT, /usr /usr/local `sdl-config --prefix`, 
>   lib)], 
>   [`sdl-config --libs` -lSDL_mixer],
>   [`sdl-config --cflags`])
> 

May I interupt this?

I'm using SuSE 1.0 (extreme case) and my packages compiled by SuSE using SDL v1.0.

Now I find a nice program thet need SDL v 8.8 so I downloas the source and compile myself.

SuSE make sure the result it is in /usr/local/bin

/usr/bin is the standard distribution global place for system wide on the box

/usr/local/bin is the private place for system wide on the box done by owner.

/home/ron/bin when the user only should touch it and is approved to be correct.
/home/ron/local/bin the same for the user for trial before it is actulized into bin (if he wants)

I can never compile gambas 1.9.44 because the SDL version is to low.
Compiling SDL into /usr/bin with --prefix=/usr/bin is also not allowed because 
it breaks the precompiled packages from SuSE (or other distributions)

When I do compile SDL with --prefix=/usr/local ( as SuSE does default) then 
no conflict will occur.

>   [GB_FIND(libSDL_mixer.$SHLIBEXT, /usr /usr/local `sdl-config --prefix`, 
>   lib)],
>   [`sdl-config --libs` -lSDL_mixer], [`sdl-config --cflags`]) 

This could find "libSDL_mixer.$SHLIBEXT" in 
/usr
/usr/local
`sdl-config --prefix`

Which one will be used? 
If it is the first one this is/could be wrong regarding the private updated box 
to higher versions without conflict to the basic version of the distribution.



> --8<-----------
> GB_COMPONENT(
>   mysql,
>   MYSQL,
>   [MySQL driver],
>   [src],
>   [GB_FIND(mysql.h my_config.h, /usr/local/lib /usr/local /opt /usr/lib /usr, 
>   include mysql*/include)],
>   [GB_FIND(libmysqlclient.$SHLIBEXT, /usr/local /opt /usr, lib mysql*/lib)],
>   [$C_LIB -lmysqlclient -lz])
> --8<-----------

Here the order of search is reversed.

I had very long ago the same version problem with CURL requirements against
available SuSE version where the packet manager (Yast) had strong dependency on.
`curl-config --prefix` returns the updated version location for new compile actions.

Reversing the order as /usr/local /usr `curl-config --prefix` solved the problem

As far I know it is recommended to do all private updates of programs and libraries 
in /usr/local to keep the distributions tree as clean as possible with non global
(real world wide installations) except if the distribution require this global update.


Ron







More information about the User mailing list