Re: [gentoo-dev] [PATCH 1/5] font.eclass: introduce FONT_CONVERT_SFNT for converting old bitmap fonts
> On 15 Oct 2022, at 04:09, Sam James wrote: > >> =x11-libs/pango-1.44 dropped support for old bitmap fonts. We can convert > fonts from the legacy .bdf and .pcf formats into the OTB wrapper format > using x11-apps/fonttosfnt. > > This commit adds FONT_CONVERT_SFNT which packages installing bitmap fonts > can set to opt-in to conversion. > > Note that the font conversion isn't perfect -- it's good enough > in many cases, but in some cases they may require tweaking > via fontconfig to get pixel size right, antialiasing settings, ... > > Adds IUSE=+convert-sfnt to any ebuilds which set FONT_CONVERT_SFNT; > enabled by default given discoverability of this issue may be difficult > and presumably any font package enabling FONT_CONVERT_SFNT will be > useless without it anyway. > > See also https://fedoraproject.org/wiki/BitmapFontConversion. > > Bug: https://bugs.gentoo.org/698922 > Thanks-to: Kerin Millar > Signed-off-by: Sam James > --- > eclass/font.eclass | 35 +++ > 1 file changed, 35 insertions(+) > > diff --git a/eclass/font.eclass b/eclass/font.eclass > index 83636ac3fed5..4b7021ee0599 100644 > --- a/eclass/font.eclass > +++ b/eclass/font.eclass > [snip] > +# @FUNCTION: font_convert_sfnt > +# @DESCRIPTION: > +# Converts .bdf and .pcf fonts detected within ${ED} to the OTB wrapper > format > +# using x11-apps/fonttosfnt. Handles optional .gz extension. > +font_convert_sfnt() { > + local file tmpfile > + > + while IFS= read -rd '' file; do > + if [[ ${file} != *.gz ]] ; then ==, which I'll fix locally. signature.asc Description: Message signed with OpenPGP
[gentoo-dev] [PATCH 5/5] media-fonts/font-misc-misc: add FONT_CONVERT_SFNT support
Bug: https://bugs.gentoo.org/698922 Signed-off-by: Sam James --- .../font-misc-misc/font-misc-misc-1.1.2-r3.ebuild| 12 1 file changed, 12 insertions(+) create mode 100644 media-fonts/font-misc-misc/font-misc-misc-1.1.2-r3.ebuild diff --git a/media-fonts/font-misc-misc/font-misc-misc-1.1.2-r3.ebuild b/media-fonts/font-misc-misc/font-misc-misc-1.1.2-r3.ebuild new file mode 100644 index ..3f2bc252cc00 --- /dev/null +++ b/media-fonts/font-misc-misc/font-misc-misc-1.1.2-r3.ebuild @@ -0,0 +1,12 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 +XORG_PACKAGE_NAME="misc-misc" +FONT_CONVERT_SFNT=1 +inherit xorg-3 + +DESCRIPTION="X.Org miscellaneous fonts" + +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~x64-solaris ~x86-solaris" +IUSE="nls" -- 2.38.0
[gentoo-dev] [PATCH 4/5] profiles/arch/hppa: mask USE=convert-sfnt
Signed-off-by: Sam James --- profiles/arch/hppa/use.mask | 4 1 file changed, 4 insertions(+) diff --git a/profiles/arch/hppa/use.mask b/profiles/arch/hppa/use.mask index 83ae1d1951f6..a2cb9a72cc22 100644 --- a/profiles/arch/hppa/use.mask +++ b/profiles/arch/hppa/use.mask @@ -7,6 +7,10 @@ # NOTE: When masking a USE flag due to missing keywords, please file a keyword # request bug for the hppa arch. +# Sam James (2022-10-15) +# x11-apps/fonttosfnt is not keyworded here +convert-sfnt + # Matt Turner (2022-02-21) # app-crypt/tpm2-tss is not keyworded here tpm -- 2.38.0
[gentoo-dev] [PATCH 3/5] profiles: add USE=convert-sfnt
Bug: https://bugs.gentoo.org/698922 Signed-off-by: Sam James --- profiles/use.desc | 1 + 1 file changed, 1 insertion(+) diff --git a/profiles/use.desc b/profiles/use.desc index d7e841f80df6..cdf98b916af1 100644 --- a/profiles/use.desc +++ b/profiles/use.desc @@ -45,6 +45,7 @@ cjk - Add support for Multi-byte character languages (Chinese, Japanese, Korean) clamav - Add support for Clam AntiVirus software (usually with a plugin) colord - Support color management using x11-misc/colord connman - Add support for net-misc/connman +convert-sfnt - Convert BDF and PCF bitmap fonts to OTB wrapper format coreaudio - Build the CoreAudio driver on Mac OS X systems cracklib - Support for cracklib strong password checking crypt - Add support for encryption -- using mcrypt or gpg where applicable -- 2.38.0
[gentoo-dev] [PATCH 2/5] xorg-3.eclass: add FONT_CONVERT_SFNT support
Bug: https://bugs.gentoo.org/698922 Signed-off-by: Sam James --- 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 e120d23efd4f..4469efb73427 100644 --- a/eclass/xorg-3.eclass +++ b/eclass/xorg-3.eclass @@ -463,7 +463,13 @@ xorg-3_src_install() { # Don't install libtool archives (even for modules) find "${D}" -type f -name '*.la' -delete || die - [[ -n ${FONT} ]] && remove_font_metadata + if [[ -n ${FONT} ]] ; then + if [[ -n ${FONT_CONVERT_SFNT} ]] && in_iuse convert-sfnt && use convert-sfnt ; then + font_convert_sfnt + fi + + remove_font_metadata + fi } # @FUNCTION: xorg-3_pkg_postinst -- 2.38.0
[gentoo-dev] [PATCH 1/5] font.eclass: introduce FONT_CONVERT_SFNT for converting old bitmap fonts
>=x11-libs/pango-1.44 dropped support for old bitmap fonts. We can convert fonts from the legacy .bdf and .pcf formats into the OTB wrapper format using x11-apps/fonttosfnt. This commit adds FONT_CONVERT_SFNT which packages installing bitmap fonts can set to opt-in to conversion. Note that the font conversion isn't perfect -- it's good enough in many cases, but in some cases they may require tweaking via fontconfig to get pixel size right, antialiasing settings, ... Adds IUSE=+convert-sfnt to any ebuilds which set FONT_CONVERT_SFNT; enabled by default given discoverability of this issue may be difficult and presumably any font package enabling FONT_CONVERT_SFNT will be useless without it anyway. See also https://fedoraproject.org/wiki/BitmapFontConversion. Bug: https://bugs.gentoo.org/698922 Thanks-to: Kerin Millar Signed-off-by: Sam James --- eclass/font.eclass | 35 +++ 1 file changed, 35 insertions(+) diff --git a/eclass/font.eclass b/eclass/font.eclass index 83636ac3fed5..4b7021ee0599 100644 --- a/eclass/font.eclass +++ b/eclass/font.eclass @@ -46,6 +46,12 @@ FONTDIR=${FONTDIR:-/usr/share/fonts/${FONT_PN}} # Array containing fontconfig conf files to install. FONT_CONF=( "" ) +# @ECLASS_VARIABLE: FONT_CONVERT_SFNT +# @DEFAULT_UNSET +# @DESCRIPTION: +# Determines whether detected BDF and PCF font files should be converted +# to an SFNT wrapper, for use with newer Pango. + if [[ ${CATEGORY}/${PN} != media-fonts/encodings ]]; then IUSE="X" BDEPEND="X? ( @@ -54,6 +60,31 @@ if [[ ${CATEGORY}/${PN} != media-fonts/encodings ]]; then )" fi +if [[ -n ${FONT_CONVERT_SFNT} ]] ; then + IUSE+=" +convert-sfnt" + BDEPEND+=" convert-sfnt? ( x11-apps/fonttosfnt )" +fi + +# @FUNCTION: font_convert_sfnt +# @DESCRIPTION: +# Converts .bdf and .pcf fonts detected within ${ED} to the OTB wrapper format +# using x11-apps/fonttosfnt. Handles optional .gz extension. +font_convert_sfnt() { + local file tmpfile + + while IFS= read -rd '' file; do + if [[ ${file} != *.gz ]] ; then + tmpfile=${file%.*} + + gzip -cd -- "${file}" > "${tmpfile}" \ + && fonttosfnt -v -o "${file%.*}.otb" -- "${tmpfile}" \ + && rm -- "${tmpfile}" + else + fonttosfnt -v -o "${file%.*}.otb" -- "${file}" + fi || ! break + done < <(find "${ED}" \( -name '*.bdf' -o -name '*.bdf.gz' -o -name '*.pcf' -o -name '*.pcf.gz' \) -type f ! -type l -print0) || die +} + # @FUNCTION: font_xfont_config # @DESCRIPTION: # Generate Xorg font files (mkfontscale/mkfontdir). @@ -150,6 +181,10 @@ font_pkg_setup() { font_src_install() { local dir suffix commondoc + if [[ -n ${FONT_CONVERT_SFNT} ]] && in_iuse convert-sfnt && use convert-sfnt ; then + font_convert_sfnt + fi + if [[ $(declare -p FONT_S 2>/dev/null) == "declare -a"* ]]; then # recreate the directory structure if FONT_S is an array for dir in "${FONT_S[@]}"; do -- 2.38.0
Re: [gentoo-dev] New type
I don't know if it'll be attaching this message to the thread, but anyways I made two patches, metadata.xsd patch, and metadata.dtd patch, the two in git format. (attached)diff --git a/metadata.dtd b/metadata.dtd index e1207de..1d82071 100644 --- a/metadata.dtd +++ b/metadata.dtd @@ -58,7 +58,7 @@ - + diff --git a/metadata.xsd b/metadata.xsd index 3812045..991790e 100644 --- a/metadata.xsd +++ b/metadata.xsd @@ -271,6 +271,7 @@ +
Re: [gentoo-dev] New type
On 14/10/2022 20.26, red...@riseup.net wrote: > Hi, I want to use , but it's not available > yet. So i want to know what to do in these cases. > > According to this page: > https://devmanual.gentoo.org/ebuild-writing/misc-files/metadata/, I have > to email here if I want to use a new type value. > > - Redson > Please read at [1], especially the last part which lists what and where you need to add. [1] https://wiki.gentoo.org/wiki/Project:Quality_Assurance/Upstream_remote-id_types -- Arthur Zamarin arthur...@gentoo.org Gentoo Linux developer (Python, Arch Teams, pkgcore stack, GURU) OpenPGP_signature Description: OpenPGP digital signature
[gentoo-dev] New type
Hi, I want to use , but it's not available yet. So i want to know what to do in these cases. According to this page: https://devmanual.gentoo.org/ebuild-writing/misc-files/metadata/, I have to email here if I want to use a new type value. - Redson
[gentoo-dev] Last Rites: x11-terms/lilyterm
# Matt Turner (2022-10-14) # Last upstream release in 2013. Last upstream commit in 2019. No maintainer in # Gentoo. No reverse dependencies. EAPI=6. # Depends on unmaintained packages: # - x11-libs/vte:0 # Bug #811540. # Removal on 2022-11-14 x11-terms/lilyterm signature.asc Description: PGP signature
[gentoo-dev] Last Rites: x11-misc/gtkdialog
# Matt Turner (2022-10-14) # Unmaintained upstream with last commit in 2013. No reverse dependencies. # Depends on unmaintained packages: # - x11-libs/gtk+:2 # - x11-libs/vte:0 # Bugs #769131, #875704. # Removal on 2022-11-14 x11-misc/gtkdialog signature.asc Description: PGP signature
[gentoo-dev] Last Rites: net-libs/gnet
# Matt Turner (2022-10-14) # Unmaintained upstream. Last release in 2008. Only reverse dependency is # gnome-mud, which is masked for removal. # Bugs #349301, #713152, #802723, #808435, #870730, #877079. # Removal on 2022-11-14 net-libs/gnet signature.asc Description: PGP signature
[gentoo-dev] Last Rites: games-mud/gnome-mud
# Matt Turner (2022-10-14) # Needs upstream work to modernize codebase. Depends on lots of unmaintained # packages: # - app-text/rarian # - gnome-base/gconf # - gnome-base/libglade # - net-libs/gnet:2 # - x11-libs/gtk+:2 # - x11-libs/vte:0 # Bugs #670904, #873859 # Removal on 2022-11-14 games-mud/gnome-mud signature.asc Description: PGP signature