Bug 477373 - Please convert to new font packaging guidelines
Summary: Please convert to new font packaging guidelines
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: cjkuni-fonts
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Caius Chance
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On: 253813
Blocks: F11-new-font-rules
TreeView+ depends on / blocked
 
Reported: 2008-12-21 00:24 UTC by Nicolas Mailhot
Modified: 2009-02-04 01:18 UTC (History)
4 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2009-02-04 01:18:23 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
.spec w/ %_font_pkg but not buildable. (9.75 KB, text/plain)
2009-01-12 04:15 UTC, Caius Chance
no flags Details

Description Nicolas Mailhot 2008-12-21 00:24:53 UTC
This bug has been filed because we've detected your package includes one or several font files:                                                                                                                                                             repoquery -C --repoid=rawhide -f '*.ttf' -f '*.otf' -f '*.pfb' -f '*.pfa' --qf='%{SOURCERPM}\n' |sed -e 's+-[0-9.-]*\.fc[123456789]\(.*\)src.rpm++g'|sort|uniq                                                                                                                                                             Unfortunately the script does not detect symlinks to other packages, so if that's your case, you can close this bug report now.                                                                                                                                                              Otherwise, you should know that:                                                                                                                                                              - Fedora guidelines demand the packaging of fonts in a separate package or subpackage: http://fedoraproject.org/wiki/Packaging/Guidelines#Avoid_bundling_of_fonts_in_other_packages                                                                                - our font packaging guidelines recently changed, and every package that ships fonts must be adapted to the new templates available in the fontpackages-devel package. http://fedoraproject.org/wiki/PackagingDrafts/Fonts_packaging_automation_(2008-11-18) http://fedoraproject.org/wiki/Fedora_fonts_policy_package http://fedoraproject.org/wiki/Simple_fonts_spec_template http://fedoraproject.org/wiki/Fonts_spec_template_for_multiple_fonts                                                                                                                                                              Please make your package conform to the current guidelines in rawhide.                                                                                                                                                             If your package is not principaly a font package, depending on a separate font package or subpackage is the prefered solution. If your application does not use fontconfig you can always package symlinks to the files provided by the font package and installed in the correct fontconfig directories.                                                                                                                                                              It is preferred to make a font package or subpackage per font family, though it is not currently a hard guidelines requirement (it may become before Fedora 11 is released). The definition of a font family is given on http://fedoraproject.org/wiki/Fonts_spec_template_notes/font-family                                                                                                                                                              The new templates should make the creation of font subpackages easy and safe.                                                                                                                                                              The following packages have already been converted and can serve as examples: - andika-fonts - apanov-heuristica-fonts - bitstream-vera-fonts - charis-fonts - dejavu-fonts - ecolier-court-fonts - edrip-fonts - gfs-ambrosia-fonts - gfs-artemisia-fonts - gfs-baskerville-fonts - gfs-bodoni-classic-fonts - gfs-bodoni-fonts - gfs-complutum-fonts - gfs-didot-classic-fonts - gfs-didot-fonts - gfs-eustace-fonts - gfs-fleischman-fonts - gfs-garaldus-fonts - gfs-gazis-fonts - gfs-jackson-fonts - gfs-neohellenic-fonts - gfs-nicefore-fonts - gfs-olga-fonts - gfs-porson-fonts - gfs-solomos-fonts - gfs-theokritos-fonts - stix-fonts - yanone-kaffeesatz-fonts                                                                                                                                                           If you have any remaining questions about the new guidelines please ask them on fedora-fonts-list at redhat.com

Comment 1 Nicolas Mailhot 2008-12-21 00:55:12 UTC
[Since the bot made a mess of the text here it is again in properly indented form.]

This bug has been filed because we've detected your package includes one or several font files:

repoquery -C --repoid=rawhide -f '*.ttf' -f '*.otf' -f '*.pfb' -f '*.pfa' --qf='%{SOURCERPM}\n' |sed -e 's+-[0-9.-]*\.fc[123456789]\(.*\)src.rpm++g'|sort|uniq

Unfortunately this script does not detect symlinks to other packages, so if that's your case, you can close this bug report now.

Otherwise, you should know that:

— Fedora guidelines demand the packaging of fonts in a separate package (or subpackage):
http://fedoraproject.org/wiki/Packaging/Guidelines#Avoid_bundling_of_fonts_in_other_packages

— our font packaging guidelines recently changed, and every package that ships fonts must be adapted to the new templates available in the fontpackages-devel package:
  – http://fedoraproject.org/wiki/PackagingDrafts/Fonts_packaging_automation_(2008-11-18)
  – http://fedoraproject.org/wiki/Fedora_fonts_policy_packagehttp://fedoraproject.org/wiki/Simple_fonts_spec_templatehttp://fedoraproject.org/wiki/Fonts_spec_template_for_multiple_fonts

Please make your package conform to the current guidelines in rawhide (you can use the fontpackages package in F9 or F10 to test, but only submit changes to rawhide please).

If your package is not principaly a font package, depending on a separate font package or subpackage is the prefered solution. If your application does not use fontconfig you can always package symlinks to the files provided by the font package and installed in the correct fontconfig directories.

It is preferred to create a font package or subpackage per font family, though it is not currently a hard guidelines requirement (it may become before Fedora 11 is released). The definition of a font family is given on:
http://fedoraproject.org/wiki/Fonts_spec_template_notes/font-family

The new templates should make the creation of font subpackages easy and safe.

The following packages have already been converted by their packager and can serve as examples:
❄ andika-fonts
❄ apanov-heuristica-fonts
❄ bitstream-vera-fonts
❄ charis-fonts
❄ dejavu-fonts
❄ ecolier-court-fonts
❄ edrip-fonts
❄ gfs-ambrosia-fonts
❄ gfs-artemisia-fonts
❄ gfs-baskerville-fonts
❄ gfs-bodoni-classic-fonts
❄ gfs-bodoni-fonts
❄ gfs-complutum-fonts
❄ gfs-didot-classic-fonts
❄ gfs-didot-fonts
❄ gfs-eustace-fonts
❄ gfs-fleischman-fonts
❄ gfs-garaldus-fonts
❄ gfs-gazis-fonts
❄ gfs-jackson-fonts
❄ gfs-neohellenic-fonts
❄ gfs-nicefore-fonts
❄ gfs-olga-fonts
❄ gfs-porson-fonts
❄ gfs-solomos-fonts
❄ gfs-theokritos-fonts
❄ stix-fonts
❄ yanone-kaffeesatz-fonts

If you have any remaining questions about the new guidelines please ask them on:
fedora-fonts-list at redhat.com

Comment 2 Nicolas Mailhot 2009-01-06 07:26:44 UTC
(note that the macros used in the new templates are integral part of the new guidelines)

Comment 3 Caius Chance 2009-01-08 07:22:47 UTC
built

http://koji.fedoraproject.org/koji/buildinfo?buildID=77668

Comment 4 Nicolas Mailhot 2009-01-09 14:20:47 UTC
Please use the %_font_pkg macro; its an integral part of the official font
packaging guidelines.

Comment 5 Nicolas Mailhot 2009-01-11 15:19:15 UTC
To help packagers manage the transition to the new guidelines, we've published the following FAQ

http://fedoraproject.org/wiki/Shipping_fonts_in_other_packages_(FAQ)

Comment 6 Caius Chance 2009-01-12 04:13:18 UTC
I added:

%_font_pkg -n uming -f *-ttf-arphic-uming*.conf uming.ttc

in .spec file. Then it isn't buildable since then with errors:

rpmbuild --define "_sourcedir /home/cchance/src/fedora/rpms/cjkunifonts/devel" --define "_spmake: *** [noarch] Error 1
ora/rpms/cjkunifonts/devel" --define "_builddir /home/cchance/src/fedora/rpms/cjkunifonts/devel" --define "_srcrpmdir /home/cchance/src/fedora/rpms/cjkunifonts/devel" --define "_rpmdir /home/cchance/src/fedora/rpms/cjkunifonts/devel" --define "dist .fc11" --define "fedora 11" --define "fc11 1" --target noarch -ba cjkunifonts.spec 2>&1 | tee .build--.log ; exit ${PIPESTATUS[0]}
error: line 142: Second %post
Building target platforms: noarch
Building for target noarch

What would I need to do to get it work?

Comment 7 Caius Chance 2009-01-12 04:15:07 UTC
Created attachment 328691 [details]
.spec w/ %_font_pkg but not buildable.

Comment 9 Caius Chance 2009-01-14 06:33:15 UTC
built w/ macro used

http://koji.fedoraproject.org/koji/buildinfo?buildID=78415

Comment 10 Nicolas Mailhot 2009-01-17 13:47:34 UTC
FPC requested much stricter font package naming rules so some naming changes are in order too (sorry)

http://fedoraproject.org/wiki/Shipping_fonts_in_Fedora_(FAQ)#fpc_renaming

Comment 11 Nicolas Mailhot 2009-01-18 21:21:17 UTC
Some additional QA comments (appart from the naming issue)

— do not define a fontdir, use the %{_fontdir} provided by the fontpackages macro set
— I think you'll find out if you check the descriptions of the resulting packages that they are a bit redundant
— I'm almost certain Behdad would be horrified by all the legacy compat hackery cruft in this package. Please consider dropping some of it. Or at least move it to separate optional -compat packages
— Please do not include the same files in the two subpackages; the multi-fonts official spec templates provides a common subpackage for this kind of stuff

Comment 12 Caius Chance 2009-01-19 06:17:08 UTC
updated in cvs tree, requested rel-eng for fedora 11 tree of new package name

https://bugzilla.redhat.com/show_bug.cgi?id=253813

Comment 13 Nicolas Mailhot 2009-01-21 23:29:25 UTC
Some comments on
http://cvs.fedoraproject.org/viewvc/devel/cjkuni-fonts/cjkuni-fonts.spec?revision=1.1&view=markup

1. you do not need those in the -common subpackage or the fonts subpackages. Put them in the -compat subpackage only
Conflicts:    fonts-chinese <= 3.03-9.fc8
Obsoletes:    fonts-chinese < 3.03-13
Obsoletes:    ttfonts-zh_CN <= 2.14-10, ttfonts-zh_TW <= 2.11-28

2. your
Obsoletes:    %{name}-uming < 0.2.20080216.1-16

should be changed to
Obsoletes:    cjkunifonts-uming < 0.2.20080216.1-16

since your package %{name} is now cjkuni-fonts (same for ukai and compat)

Didn't see anything else obvious, of course testing the upgrade path yourself once the package is built is the best way to catch problems

Comment 14 Caius Chance 2009-01-22 02:27:26 UTC
changed to cjkuni-fonts because of new naming rules

Comment 15 Caius Chance 2009-02-02 23:48:12 UTC
Patched in rawhide.

Comment 16 Caius Chance 2009-02-04 01:18:23 UTC
latest;

http://koji.fedoraproject.org/koji/buildinfo?buildID=81269


Note You need to log in before you can comment on or make changes to this bug.