~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/scripts/check-variable-fonts.sh

Version: ~ [ linux-6.11.5 ] ~ [ linux-6.10.14 ] ~ [ linux-6.9.12 ] ~ [ linux-6.8.12 ] ~ [ linux-6.7.12 ] ~ [ linux-6.6.58 ] ~ [ linux-6.5.13 ] ~ [ linux-6.4.16 ] ~ [ linux-6.3.13 ] ~ [ linux-6.2.16 ] ~ [ linux-6.1.114 ] ~ [ linux-6.0.19 ] ~ [ linux-5.19.17 ] ~ [ linux-5.18.19 ] ~ [ linux-5.17.15 ] ~ [ linux-5.16.20 ] ~ [ linux-5.15.169 ] ~ [ linux-5.14.21 ] ~ [ linux-5.13.19 ] ~ [ linux-5.12.19 ] ~ [ linux-5.11.22 ] ~ [ linux-5.10.228 ] ~ [ linux-5.9.16 ] ~ [ linux-5.8.18 ] ~ [ linux-5.7.19 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.284 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.322 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.336 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.337 ] ~ [ linux-4.4.302 ] ~ [ linux-3.10.108 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.9 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

Diff markup

Differences between /scripts/check-variable-fonts.sh (Version linux-6.11.5) and /scripts/check-variable-fonts.sh (Version linux-5.5.19)


  1 #!/bin/sh                                         
  2 # SPDX-License-Identifier: GPL-2.0-only           
  3 # Copyright (C) Akira Yokosawa, 2024              
  4 #                                                 
  5 # For "make pdfdocs", reports of build errors     
  6 # arriving early 2024 [1, 2].  It turned out t    
  7 # tumbleweed have started deploying variable-f    
  8 # fonts [4, 5].  For PDF, a LaTeX package name    
  9 # (Chinese, Japanese, Korean) pages.  xeCJK re    
 10 # does not (and likely never will) understand     
 11 # reasons.                                        
 12 #                                                 
 13 # The build error happens even when both of va    
 14 # fonts are found on the build system.  To mak    
 15 # variable "Noto CJK" fonts in the requirement    
 16 # -zh_TW, etc.  Hence developers who have inte    
 17 # likely to encounter the build errors.           
 18 #                                                 
 19 # This script is invoked from the error path o    
 20 # suggestions if variable-font files of "Noto     
 21 # fonts accessible from XeTeX.                    
 22 #                                                 
 23 # References:                                     
 24 # [1]: https://lore.kernel.org/r/8734tqsrt7.fs    
 25 # [2]: https://lore.kernel.org/r/1708585803.60    
 26 # [3]: https://en.wikipedia.org/wiki/Variable_    
 27 # [4]: https://fedoraproject.org/wiki/Changes/    
 28 # [5]: https://build.opensuse.org/request/show    
 29 #                                                 
 30 #=============================================    
 31 # Workarounds for building translations.pdf       
 32 #=============================================    
 33 #                                                 
 34 # * Denylist "variable font" Noto CJK fonts.      
 35 #   - Create $HOME/deny-vf/fontconfig/fonts.co    
 36 #     tweaks if necessary.  Remove leading "#     
 37 #   - Path of fontconfig/fonts.conf can be ove    
 38 #     variable FONTS_CONF_DENY_VF.                
 39 #                                                 
 40 #     * Template:                                 
 41 # --------------------------------------------    
 42 # <?xml version="1.0"?>                           
 43 # <!DOCTYPE fontconfig SYSTEM "urn:fontconfig:    
 44 # <fontconfig>                                    
 45 # <!--                                            
 46 #   Ignore variable-font glob (not to break xe    
 47 # -->                                             
 48 #     <selectfont>                                
 49 #         <rejectfont>                            
 50 #             <!--                                
 51 #                 for Fedora                      
 52 #             -->                                 
 53 #             <glob>/usr/share/fonts/google-no    
 54 #             <!--                                
 55 #                 for openSUSE tumbleweed         
 56 #             -->                                 
 57 #             <glob>/usr/share/fonts/truetype/    
 58 #         </rejectfont>                           
 59 #     </selectfont>                               
 60 # </fontconfig>                                   
 61 # --------------------------------------------    
 62 #                                                 
 63 #     The denylisting is activated for "make p    
 64 #                                                 
 65 # * For skipping CJK pages in PDF                 
 66 #   - Uninstall texlive-xecjk.                    
 67 #     Denylisting is not needed in this case.     
 68 #                                                 
 69 # * For printing CJK pages in PDF                 
 70 #   - Need non-variable "Noto CJK" fonts.         
 71 #     * Fedora                                    
 72 #       - google-noto-sans-cjk-fonts              
 73 #       - google-noto-serif-cjk-fonts             
 74 #     * openSUSE tumbleweed                       
 75 #       - Non-variable "Noto CJK" fonts are no    
 76 #         as of April, 2024.  Fetch a set of f    
 77 #         CJK Font released at:                   
 78 #           https://github.com/notofonts/noto-    
 79 #         and at:                                 
 80 #           https://github.com/notofonts/noto-    
 81 #         , then uncompress and deploy them.      
 82 #       - Remember to update fontconfig cache     
 83 #                                                 
 84 # !!! Caution !!!                                 
 85 #     Uninstalling "variable font" packages ca    
 86 #     They might be depended upon by other pac    
 87 #     Denylisting should be less invasive, as     
 88 #     XeLaTeX runs in "make pdfdocs".             
 89                                                   
 90 # Default per-user fontconfig path (overridden    
 91 : ${FONTS_CONF_DENY_VF:=$HOME/deny-vf}            
 92                                                   
 93 export XDG_CONFIG_HOME=${FONTS_CONF_DENY_VF}      
 94                                                   
 95 notocjkvffonts=`fc-list : file family variable    
 96                 grep 'variable=True' | \          
 97                 grep -E -e 'Noto (Sans|Sans Mo    
 98                 sed -e 's/^/    /' -e 's/: Not    
 99                                                   
100 if [ "x$notocjkvffonts" != "x" ] ; then           
101         echo '================================    
102         echo 'XeTeX is confused by "variable f    
103         echo "$notocjkvffonts"                    
104         echo                                      
105         echo 'For CJK pages in PDF, they need     
106         echo 'Or, CJK pages can be skipped by     
107         echo                                      
108         echo 'For more info on denylisting, ot    
109         echo 'comments of scripts/check-variab    
110         echo '================================    
111 fi                                                
112                                                   
113 # As this script is invoked from Makefile's er    
114 # regardless of whether any variable font is d    
115 exit 1                                            
                                                      

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

sflogo.php