1 |
2012/11/28 Justin <jlec@g.o>: |
2 |
> Hi, |
3 |
> |
4 |
> and another one. |
5 |
> |
6 |
> Problem: |
7 |
> Some packages aren't lucky and their buildsystem doesn't create |
8 |
> pkg-config files out of the box. |
9 |
> |
10 |
> Solution: |
11 |
> Create them by hand. |
12 |
> |
13 |
> Eclass: |
14 |
> Simplifies this by providing a general function for that. |
15 |
> |
16 |
> Example: |
17 |
> https://github.com/gentoo-science/sci/blob/pkg-config/sci-libs/mmdb/mmdb-1.24.ebuild |
18 |
> |
19 |
> Thanks for comments, |
20 |
> Justin |
21 |
Great jobs, I had a similar eclass on my mind for a long time. It will |
22 |
for sure be useful for Gentoo prefix builds. |
23 |
|
24 |
However, I have some suggestions: |
25 |
- Cflags should contain -I${includedir} and Libs should contain |
26 |
-L${libdir} by default (see |
27 |
<http://people.freedesktop.org/~dbn/pkg-config-guide.html#concepts>). |
28 |
- Reduce the number of global variables. Arguments to create_pkgconfig |
29 |
are as useful as global variables. |
30 |
- arguments like -{l,L}* can be used as Libs to avoid redundancy in |
31 |
the syntax (example: "-lm" instead of "-l -lm"), same for -I* |
32 |
- it is only one function, maybe it could be added to eutils eclass |
33 |
- pc files created by this eclass should go into a Gentoo specific |
34 |
directory (/usr/share/gentoo/lib/pkgconfig?) to avoid confusion with |
35 |
upstream pc files. This directory can then be added to PKG_CONFIG_PATH |
36 |
during the build. |
37 |
|
38 |
Can you also remind me what should go into these private variables and |
39 |
what not? Since Fedora has started their DSO Linking policy I am very |
40 |
confused about flags like -lm and -pthreads. |
41 |
|
42 |
-- |
43 |
Christoph Junghans |
44 |
http://dev.gentoo.org/~ottxor/ |