1 |
On Wednesday 07 Apr 2004 16:24, Corvus Corax wrote: |
2 |
> probably the matter has been discussed earlier, but not recently, so |
3 |
> please excuse me asking: |
4 |
> |
5 |
> i plan writing an ebuild for my little software project, motiontrack, |
6 |
> (motiontrack.sf.net) which needs an image I/O library, either libGD |
7 |
> or ImageMagick to compile. |
8 |
> |
9 |
> but it cant compile against both of them. |
10 |
> |
11 |
> if only one is present the configure script auto-detects the |
12 |
> installed, and compiles with it, if there are both, configure prefers |
13 |
> libGD since it might be faster, on the other hand ImageMagick |
14 |
> provides better debug output when trying things out (view images on X |
15 |
> screen ...) so configure's behaviour can be tweaked to force usage of |
16 |
> Imagemagick even if GD is present (or visa versa) |
17 |
> |
18 |
> the obvious approach would be use-flags ;) , however there are a |
19 |
> global useflag both for gd and imagemagick, and the problem persists |
20 |
> if both are set. |
21 |
> |
22 |
> So is there to be an extra-lokal useflag? Or should it silently |
23 |
> default to one of the libs? What is if libgd but not imagemagick is |
24 |
> installed, but the imagemagick, and not gd useflag is set? compile |
25 |
> with the installed libgd and ignore imagemagick? (nah, that would be |
26 |
> stupid - or not?) should the ebuild read an env-var like openoffice |
27 |
> does for the language? |
28 |
> |
29 |
> This all are questions i'd like to hear some opinions before trying |
30 |
> to write an ebuild. |
31 |
> |
32 |
You can use a construction like this in your ebuild: |
33 |
|
34 |
DEPEND="libgd? ( >=media-libs/libgd-2.0.22 ) |
35 |
imagemagick? ( >=media-gfx/imagemagick-5.5.7.15 )" |
36 |
|
37 |
That isn't the logic you want but you should be able to adapt it to your |
38 |
case. The above statement means that at least one of libgd or |
39 |
imagemagick is required. |
40 |
|
41 |
-- |
42 |
Peter |
43 |
======================================================================== |
44 |
Gentoo Linux: Portage 2.0.50-r3. kernel-2.6.3-gentoo-r2. |
45 |
i686 AMD Athlon(tm) XP 3200+. gcc(GCC): 3.3.2. |
46 |
KDE: 3.2.1. Qt: 3.3.1. |
47 |
======================================================================== |
48 |
|
49 |
-- |
50 |
gentoo-dev@g.o mailing list |