[Gambas-user] how to override opengl pkg-config requirements???

B Bruen bbruen at ...2308...
Sat Jun 28 01:29:31 CEST 2014


On Fri, 27 Jun 2014 10:04:26 -0430
PICCORO McKAY Lenz <mckaygerhard at ...626...> wrote:

> Date: Fri, 27 Jun 2014 08:47:52 +0930
> From: B Bruen <bbruen at ...2308...>
> 
> > Elsewhere I received advice to delete ALL the pkg-config files on the system in order to get a non-gambas
> >application to build properly.  Since I did that I have had no problems, neither with gambas3 nor other source builds.
> >There is information regarding the "pains" of pkg-config in various places on the internet, check first for some
> >related to your distro.
> that's not the case bruce, i used a older version of xorg that do not
> provide pkg-config files,
> 

This is, if I recall correctly, where the problem starts. The pkg-config files for other libraries are what causes the problem.  I can't say that I really understand what actually happens, but what I THINK is your gb.xyz configure (as built by the auto... tools) attempts to check via pkg-config for the direct requirements of your gb.xyz library and then cascades through each of the required libraries specified in that library's .pc (???) file and checks for them etc etc. But just because gb.xyz needs libabc (which resolves to libabc.so.1.2.3 or whatever, which is nicely installled and dynamically linkable) then in the libabc.pc file it says they require libOzarquon - which you dont have. So the build fails!  Also I THINK that the error gets "incorrectly" reported as can't find libabc.so which is actually there.

If you delete the libabc.pc file from your system, the cascasing checks don't get invoked. This gb.xyz builds properly ( and links to libabc properly as well).

So I suspect that somewhere on your system, there is a .pc file that thinks it requires some libXfordprefect library or something.

Now - how the toolchain works is dependant on your distro. So you need to find any help on this (known) pkg-config issue specific for your distro and go from there. I believe the pkg-config spec files are generally suffixed ".pc" and tend to live in /lib/pkg-config but again this maybe distro specific.

Here, I deleted all the .pc files and magically could make the non-gambas app successfully. When I next maked the gambas3 development version about n-thousand warnings disappeared and the overall build took about half the time (and the gb.sdl components all suddenly worked, which I could never get to happen before).



> so i must parse all linker and includes manually, how i can do that? i
> cannot see in configure script before run autopoint

That's my point, you would have to inspect all the .pc files for the entire dependency tree specified therein to find the anomaly (or anomalies!). Manually. i.e. not a good idea.
If deleting these files scares you (as it did me the first time) then just backup the pkg-config dir somewhere as they (the .pc files) are actually just text files containing the  specifications to "help" the dynamic linker.  Then delete all those files (leaving the /lib/pkg-config dir "almost" empty). Then try the gambas build again.  If the result is still failure then just copy all those .pc files back in and look elsewhere for the problem.


hth
Bruce

> 
> Lenz McKAY Gerardo (PICCORO)
> http://qgqlochekone.blogspot.com
> 

p.s. Oh and googling for "What are .pc files" is a BAD idea. You will get a LOT of disinformation. Better to start with something like "<your_distro> pkg-config fail" and got from there.

-- 
B Bruen <bbruen at ...2308...>




More information about the User mailing list