RFC: Mk/bsd.jpeg.mk to automagically handle jpeg dependency
Ade Lovett
ade at FreeBSD.org
Wed Jun 16 09:38:42 UTC 2010
On Jun 15, 2010, at 18:09 , Mario Sergio Fujikawa Ferreira wrote:
> Hi,
>
> Ever since the addition of graphics/libjpeg-turbo, I had
> been wondering how one could possibly build the whole ports tree
> with it instead of graphics/jpeg. I wanted the choice.
>
> Therefore, I wrote the attached bsd.jpeg.mk as a suggestion.
I have other concerns, but the fundamental one is bsd.jpeg.mk is way too specific, and could easily lead to bsd.tiff.mk, bsd.gd.mk, etc.. etc..
You might want to consider abstracting it out a little further (compare with bsd.database.mk) to, say, bsd.graphics.mk
It might then be possible to do weird and wonderful things like:
USE_GRAPHICS= jpeg-turbo openexr gd tiff
in ports Makefiles, and have them do the right thing, or at least offer up include and library paths, along with relevant *_DEPENDS additions.
It's a little more work in the short term, but there's plenty of existing Mk/* files to use as reference for parsing a possible USE_GRAPHICS stanza, and it is much more extensible.
-aDe
More information about the freebsd-ports
mailing list