[PATCH] font-util: Add a shorthand --disable-all-encodings option.

Alan Coopersmith alan.coopersmith at oracle.com
Thu Oct 7 10:47:53 PDT 2010


Gaetan Nadon wrote:
> On Thu, 2010-10-07 at 17:31 +0200, Michał Górny wrote:
>> This option is useful to disable all possible font encodings at once,
>> without fine-graining the calling ebuilds for a list of encodings
>> supported by each font package.
>>
>> The option is parsed before all other encoding options, so it basically
>> sets defaults for all of them. Afterwards, any encoding can be
>> re-enabled back using '--enable-<encoding>' (much like
>> '--disable-all-encodings --enable-iso8859-2').
> 
> Forgive me as I am not familiar with the font module. If I understand,
> all encodings are enabled by default,
> which forced you to hunt down the list of encodings to disable. With
> this patch, you can control the
> "default" encoding enablement. You can have all encodings disabled by
> default, allowing you
> to only specify the ones you know and care about.

Correct.  For instance, since we build the OpenSolaris/Solaris 11 font
packages per encoding, we end up having a list of all the encodings,
and disable all the ones except the one we are building for that package:

# All the encodings defined in font-util/fontutil.m4.in
ALL_ENCODINGS = \
        iso8859-1  iso8859-2  iso8859-3  iso8859-4  iso8859-5  \
        iso8859-6  iso8859-7  iso8859-8  iso8859-9  iso8859-10 \
        iso8859-11 iso8859-12 iso8859-13 iso8859-14 iso8859-15 \
        iso8859-16 jisx0201   koi8-r

DISABLE_ALL_ENCODINGS = $(ALL_ENCODINGS:%=--disable-%)

iso8859-1_ENCODING_CONFIG_OPTS = \
        $(DISABLE_ALL_ENCODINGS:--disable-iso8859-1=--enable-iso8859-1)
iso8859-2_ENCODING_CONFIG_OPTS = \
        $(DISABLE_ALL_ENCODINGS:--disable-iso8859-2=--enable-iso8859-2)
iso8859-3_ENCODING_CONFIG_OPTS = \
        $(DISABLE_ALL_ENCODINGS:--disable-iso8859-3=--enable-iso8859-3)
iso8859-4_ENCODING_CONFIG_OPTS = \
        $(DISABLE_ALL_ENCODINGS:--disable-iso8859-4=--enable-iso8859-4)
[...]

This would simplify that down to --disable-all --enable-iso8859-1.
(I don't expect to ever add a new bitmap font encoding - the future should
 be Unicode, the others are legacy/compatibility.)

-- 
	-Alan Coopersmith-        alan.coopersmith at oracle.com
	 Oracle Solaris Platform Engineering: X Window System



More information about the xorg-devel mailing list