* [gentoo-dev] [PATCH 1/2] xorg-3.eclass: Fix font IUSE=nls handling
@ 2020-10-01 5:18 Matt Turner
2020-10-01 5:18 ` [gentoo-dev] [PATCH 2/2] xorg-3.eclass: Require --disable-all-encodings for fonts Matt Turner
2020-10-01 8:06 ` [gentoo-dev] [PATCH 1/2] xorg-3.eclass: Fix font IUSE=nls handling Ulrich Mueller
0 siblings, 2 replies; 4+ messages in thread
From: Matt Turner @ 2020-10-01 5:18 UTC (permalink / raw
To: gentoo-dev; +Cc: Matt Turner
The previous logic incorrectly added IUSE=nls for font-bitstream-100dpi,
font-bitstream-75dpi, font-cronyx-cyrillic, font-misc-cyrillic,
font-screen-cyrillic, and font-winitzki-cyrillic. This caused
"QA Notice: Unrecognized configure options: ..." with USE=-nls.
Closes: https://bugs.gentoo.org/745756
Signed-off-by: Matt Turner <mattst88@gentoo.org>
---
eclass/xorg-3.eclass | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/eclass/xorg-3.eclass b/eclass/xorg-3.eclass
index 78c843401cc..515c1aeea2e 100644
--- a/eclass/xorg-3.eclass
+++ b/eclass/xorg-3.eclass
@@ -169,7 +169,13 @@ if [[ ${FONT} == yes ]]; then
FONT_DIR=${FONT_DIR/type1/Type1}
FONT_DIR=${FONT_DIR/speedo/Speedo}
- [[ ${PN} = font-misc-misc || ${PN} = font-schumacher-misc || ${PN##*-} = 75dpi || ${PN##*-} = 100dpi || ${PN##*-} = cyrillic ]] && IUSE+=" nls"
+ case ${PN#font-} in
+ adobe-100dpi|adobe-utopia-100dpi|bh-100dpi|bh-lucidatypewriter-100dpi|\
+ adobe-75dpi |adobe-utopia-75dpi |bh-75dpi |bh-lucidatypewriter-75dpi|\
+ misc-misc|schumacher-misc)
+ IUSE+=" nls"
+ ;;
+ esac
fi
# @ECLASS-VARIABLE: XORG_STATIC
--
2.26.2
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [gentoo-dev] [PATCH 2/2] xorg-3.eclass: Require --disable-all-encodings for fonts
2020-10-01 5:18 [gentoo-dev] [PATCH 1/2] xorg-3.eclass: Fix font IUSE=nls handling Matt Turner
@ 2020-10-01 5:18 ` Matt Turner
2020-10-01 8:06 ` [gentoo-dev] [PATCH 1/2] xorg-3.eclass: Fix font IUSE=nls handling Ulrich Mueller
1 sibling, 0 replies; 4+ messages in thread
From: Matt Turner @ 2020-10-01 5:18 UTC (permalink / raw
To: gentoo-dev; +Cc: Matt Turner
Presumably in the distant past all font packages did not support this
option. They do today, so we can simplify our logic.
Signed-off-by: Matt Turner <mattst88@gentoo.org>
---
eclass/xorg-3.eclass | 28 +++++-----------------------
1 file changed, 5 insertions(+), 23 deletions(-)
diff --git a/eclass/xorg-3.eclass b/eclass/xorg-3.eclass
index 515c1aeea2e..543021af46e 100644
--- a/eclass/xorg-3.eclass
+++ b/eclass/xorg-3.eclass
@@ -338,30 +338,12 @@ xorg-3_font_configure() {
debug-print-function ${FUNCNAME} "$@"
if has nls ${IUSE//+} && ! use nls; then
- if grep -q -s "disable-all-encodings" ${ECONF_SOURCE:-.}/configure; then
- FONT_OPTIONS+="
- --disable-all-encodings
- --enable-iso8859-1"
- else
- FONT_OPTIONS+="
- --disable-iso8859-2
- --disable-iso8859-3
- --disable-iso8859-4
- --disable-iso8859-5
- --disable-iso8859-6
- --disable-iso8859-7
- --disable-iso8859-8
- --disable-iso8859-9
- --disable-iso8859-10
- --disable-iso8859-11
- --disable-iso8859-12
- --disable-iso8859-13
- --disable-iso8859-14
- --disable-iso8859-15
- --disable-iso8859-16
- --disable-jisx0201
- --disable-koi8-r"
+ if ! grep -q -s "disable-all-encodings" ${ECONF_SOURCE:-.}/configure; then
+ die "--disable-all-encodings option not available in configure"
fi
+ FONT_OPTIONS+="
+ --disable-all-encodings
+ --enable-iso8859-1"
fi
}
--
2.26.2
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [gentoo-dev] [PATCH 1/2] xorg-3.eclass: Fix font IUSE=nls handling
2020-10-01 5:18 [gentoo-dev] [PATCH 1/2] xorg-3.eclass: Fix font IUSE=nls handling Matt Turner
2020-10-01 5:18 ` [gentoo-dev] [PATCH 2/2] xorg-3.eclass: Require --disable-all-encodings for fonts Matt Turner
@ 2020-10-01 8:06 ` Ulrich Mueller
2020-10-01 21:31 ` Matt Turner
1 sibling, 1 reply; 4+ messages in thread
From: Ulrich Mueller @ 2020-10-01 8:06 UTC (permalink / raw
To: Matt Turner; +Cc: gentoo-dev
[-- Attachment #1: Type: text/plain, Size: 572 bytes --]
>>>>> On Thu, 01 Oct 2020, Matt Turner wrote:
> - [[ ${PN} = font-misc-misc || ${PN} = font-schumacher-misc || ${PN##*-} = 75dpi || ${PN##*-} = 100dpi || ${PN##*-} = cyrillic ]] && IUSE+=" nls"
> + case ${PN#font-} in
> + adobe-100dpi|adobe-utopia-100dpi|bh-100dpi|bh-lucidatypewriter-100dpi|\
> + adobe-75dpi |adobe-utopia-75dpi |bh-75dpi |bh-lucidatypewriter-75dpi|\
> + misc-misc|schumacher-misc)
> + IUSE+=" nls"
> + ;;
> + esac
This looks like the kind of logic that would better be moved to ebuilds.
Especially when it has just proven to be error prone.
Ulrich
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 507 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [gentoo-dev] [PATCH 1/2] xorg-3.eclass: Fix font IUSE=nls handling
2020-10-01 8:06 ` [gentoo-dev] [PATCH 1/2] xorg-3.eclass: Fix font IUSE=nls handling Ulrich Mueller
@ 2020-10-01 21:31 ` Matt Turner
0 siblings, 0 replies; 4+ messages in thread
From: Matt Turner @ 2020-10-01 21:31 UTC (permalink / raw
To: Ulrich Mueller; +Cc: gentoo development
On Thu, Oct 1, 2020 at 1:07 AM Ulrich Mueller <ulm@gentoo.org> wrote:
>
> >>>>> On Thu, 01 Oct 2020, Matt Turner wrote:
>
> > - [[ ${PN} = font-misc-misc || ${PN} = font-schumacher-misc || ${PN##*-} = 75dpi || ${PN##*-} = 100dpi || ${PN##*-} = cyrillic ]] && IUSE+=" nls"
> > + case ${PN#font-} in
> > + adobe-100dpi|adobe-utopia-100dpi|bh-100dpi|bh-lucidatypewriter-100dpi|\
> > + adobe-75dpi |adobe-utopia-75dpi |bh-75dpi |bh-lucidatypewriter-75dpi|\
> > + misc-misc|schumacher-misc)
> > + IUSE+=" nls"
> > + ;;
> > + esac
>
> This looks like the kind of logic that would better be moved to ebuilds.
> Especially when it has just proven to be error prone.
Yeah, that seems like a good idea. In fact, that seems easier since
it's actually xorg-3_font_configure() that uses the presence of nls to
choose configure arguments. I think I can simply add IUSE="nls" to the
relevant packages and remove this code from the eclass.
Thanks for making me think through that again!
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2020-10-01 21:31 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-10-01 5:18 [gentoo-dev] [PATCH 1/2] xorg-3.eclass: Fix font IUSE=nls handling Matt Turner
2020-10-01 5:18 ` [gentoo-dev] [PATCH 2/2] xorg-3.eclass: Require --disable-all-encodings for fonts Matt Turner
2020-10-01 8:06 ` [gentoo-dev] [PATCH 1/2] xorg-3.eclass: Fix font IUSE=nls handling Ulrich Mueller
2020-10-01 21:31 ` Matt Turner
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox