[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openjdk-2d-dev
Subject:    Re: [OpenJDK 2D-Dev] "java.lang.Error: Probable fatal error:No fonts found" does not show on 11
From:       Bernd Eckenfels <ecki () zusammenkunft ! net>
Date:       2019-02-28 8:56:25
Message-ID: DB7PR08MB330758381A4329F72D30EB3EFF750 () DB7PR08MB3307 ! eurprd08 ! prod ! outlook ! com
[Download RAW message or body]

Hello,

I can confirm the same ugly error stack with 12-b33 EA, this time with debug:

$ jdk-12/bin/java -cp . -Dsun.java2d.debugfonts=true FontTest
Are we headless? true
g = sun.java2d.HeadlessGraphicsEnvironment headless: true
Feb 28, 2019 9:50:32 AM sun.awt.X11FontManager registerFontDir
INFO: ParseFontDir /home/vagrant/jdk-12/lib/fonts
Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration <init>
INFO: Creating standard Font Configuration
Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl
INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.7.3.1611.properties Feb 28, 2019 9:50:32 \
                AM sun.awt.FontConfiguration findImpl
INFO: Looking for binary fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.7.3.1611.bfc Feb 28, 2019 9:50:32 AM \
                sun.awt.FontConfiguration findImpl
INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.7.properties Feb 28, 2019 9:50:32 AM \
                sun.awt.FontConfiguration findImpl
INFO: Looking for binary fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.7.bfc Feb 28, 2019 9:50:32 AM \
                sun.awt.FontConfiguration findImpl
INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.properties Feb 28, 2019 9:50:32 AM \
                sun.awt.FontConfiguration findImpl
INFO: Looking for binary fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.bfc Feb 28, 2019 9:50:32 AM \
                sun.awt.FontConfiguration findImpl
INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.7.3.1611.properties Feb 28, 2019 9:50:32 AM \
                sun.awt.FontConfiguration findImpl
INFO: Looking for binary fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.7.3.1611.bfc Feb 28, 2019 9:50:32 AM \
                sun.awt.FontConfiguration findImpl
INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.7.properties Feb 28, 2019 9:50:32 AM \
                sun.awt.FontConfiguration findImpl
INFO: Looking for binary fontconfig file : /home/vagrant/jdk-12/lib/fontconfig.7.bfc
Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl
INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.properties Feb 28, 2019 9:50:32 AM \
                sun.awt.FontConfiguration findImpl
INFO: Looking for binary fontconfig file : /home/vagrant/jdk-12/lib/fontconfig.bfc
Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration findFontConfigFile
INFO: Did not find a fontconfig file.
Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration <init>
INFO: Creating standard Font Configuration
Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl
INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.7.3.1611.properties Feb 28, 2019 9:50:32 \
                AM sun.awt.FontConfiguration findImpl
INFO: Looking for binary fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.7.3.1611.bfc Feb 28, 2019 9:50:32 AM \
                sun.awt.FontConfiguration findImpl
INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.7.properties Feb 28, 2019 9:50:32 AM \
                sun.awt.FontConfiguration findImpl
INFO: Looking for binary fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.7.bfc Feb 28, 2019 9:50:32 AM \
                sun.awt.FontConfiguration findImpl
INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.properties Feb 28, 2019 9:50:32 AM \
                sun.awt.FontConfiguration findImpl
INFO: Looking for binary fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.bfc Feb 28, 2019 9:50:32 AM \
                sun.awt.FontConfiguration findImpl
INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.7.3.1611.properties Feb 28, 2019 9:50:32 AM \
                sun.awt.FontConfiguration findImpl
INFO: Looking for binary fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.7.3.1611.bfc Feb 28, 2019 9:50:32 AM \
                sun.awt.FontConfiguration findImpl
INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.7.properties Feb 28, 2019 9:50:32 AM \
                sun.awt.FontConfiguration findImpl
INFO: Looking for binary fontconfig file : /home/vagrant/jdk-12/lib/fontconfig.7.bfc
Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl
INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.properties Feb 28, 2019 9:50:32 AM \
                sun.awt.FontConfiguration findImpl
INFO: Looking for binary fontconfig file : /home/vagrant/jdk-12/lib/fontconfig.bfc
Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration findFontConfigFile
INFO: Did not find a fontconfig file.
Feb 28, 2019 9:50:32 AM sun.font.FontConfigManager initFontConfigFonts
INFO: Fontconfig returned no font for sans:regular:roman
Feb 28, 2019 9:50:32 AM sun.font.FontConfigManager initFontConfigFonts
INFO: Fontconfig returned no font for sans:bold:roman
Feb 28, 2019 9:50:32 AM sun.font.FontConfigManager initFontConfigFonts
INFO: Fontconfig returned no font for sans:regular:italic
Feb 28, 2019 9:50:32 AM sun.font.FontConfigManager initFontConfigFonts
INFO: Fontconfig returned no font for sans:bold:italic
Feb 28, 2019 9:50:32 AM sun.font.FontConfigManager initFontConfigFonts
INFO: Fontconfig returned no font for serif:regular:roman
Feb 28, 2019 9:50:32 AM sun.font.FontConfigManager initFontConfigFonts
INFO: Fontconfig returned no font for serif:bold:roman
Feb 28, 2019 9:50:32 AM sun.font.FontConfigManager initFontConfigFonts
INFO: Fontconfig returned no font for serif:regular:italic
Feb 28, 2019 9:50:32 AM sun.font.FontConfigManager initFontConfigFonts
INFO: Fontconfig returned no font for serif:bold:italic
Feb 28, 2019 9:50:32 AM sun.font.FontConfigManager initFontConfigFonts
INFO: Fontconfig returned no font for monospace:regular:roman
Feb 28, 2019 9:50:32 AM sun.font.FontConfigManager initFontConfigFonts
INFO: Fontconfig returned no font for monospace:bold:roman
Feb 28, 2019 9:50:32 AM sun.font.FontConfigManager initFontConfigFonts
INFO: Fontconfig returned no font for monospace:regular:italic
Feb 28, 2019 9:50:32 AM sun.font.FontConfigManager initFontConfigFonts
INFO: Fontconfig returned no font for monospace:bold:italic
Feb 28, 2019 9:50:32 AM sun.font.FontConfigManager initFontConfigFonts
INFO: Fontconfig returned no fonts at all.
Feb 28, 2019 9:50:32 AM sun.font.FcFontConfiguration warning
WARNING: Failed to get info from libfontconfig
Feb 28, 2019 9:50:32 AM sun.font.FcFontConfiguration warning
WARNING: Failed to get info from libfontconfig
Exception in thread "main" java.lang.InternalError: \
                java.lang.reflect.InvocationTargetException
       at java.desktop/sun.font.FontManagerFactory$1.run(FontManagerFactory.java:86)
       at java.base/java.security.AccessController.doPrivileged(AccessController.java:310)
                
       at java.desktop/sun.font.FontManagerFactory.getInstance(FontManagerFactory.java:74)
                
       at java.desktop/sun.java2d.SunGraphicsEnvironment.getFontManagerForSGE(SunGraphicsEnvironment.java:189)
                
       at java.desktop/sun.java2d.SunGraphicsEnvironment.getAvailableFontFamilyNames(SunGraphicsEnvironment.java:223)
                
       at java.desktop/sun.java2d.SunGraphicsEnvironment.getAvailableFontFamilyNames(SunGraphicsEnvironment.java:251)
                
       at java.desktop/sun.java2d.HeadlessGraphicsEnvironment.getAvailableFontFamilyNames(HeadlessGraphicsEnvironment.java:75)



Gruss
Bernd
--
http://bernd.eckenfels.net

________________________________
Von: Philip Race <philip.race@oracle.com>
Gesendet: Donnerstag, Februar 28, 2019 12:45 AM
An: Bernd Eckenfels; 2d-dev
Cc: awt-dev@openjdk.java.net; Java Core Libs
Betreff: Re: "java.lang.Error: Probable fatal error:No fonts found" does not show on \
11

Wrong list. You want 2d-dev.

-phil.

On 2/27/19, 3:26 PM, Bernd Eckenfels wrote:
> Hello,
> 
> (please let me know in case I picked the wrong list.)
> 
> Since OpenJDK does not ship Default *.ttf font files the change that a JRE is \
> installed in a way that no System Fonts can be found is quite high. 
> In OpenJDK8 it is a bit unfortunate that in this situation even for the headless \
> graphics context that you can can a Java.lang.Error: 
> I wonder if this is intentional. How About returnign an empty Array or Maybe a \
> RntimeException instead? In my case by upgrading from Oracle JRE to Open JDK (in my \
> case Azul) a perfectly fine working Installation is not aborting. 
> The JasperReports component used is failing does not even need the System Fonts \
> (which I will report to them seperately). For Zulu it is enough to install Dejavu \
> Fonts in System Directory or copy them to JRE/lib/fonts/, but I have also seen \
> OpenJDK builds which seem to use fontmanager libraries instead of fixed file path. \
> Here I guess the dependency on System config is even higher. 
> I tested on a minimal System with no X11:
> 
> > ls /usr/share/fonts
> > cat /etc/centos-release
> CentOS Linux release 7.3.1611 (Core)
> 
> And my test program (below) Returns for Java 8:
> 
> > zulu8*x64/bin/java -cp . FontTest
> Are we headless? true
> g = sun.java2d.HeadlessGraphicsEnvironment headless: true
> Exception in thread "main" java.lang.Error: Probable fatal error:No fonts found.
> at sun.font.SunFontManager.getDefaultPhysicalFont(SunFontManager.java:1236)
> at sun.font.SunFontManager.initialiseDeferredFont(SunFontManager.java:1100)
> …
> at sun.font.SunFontManager.getDefaultPhysicalFont(SunFontManager.java:1220)
> at sun.font.SunFontManager.initialiseDeferredFont(SunFontManager.java:1100)
> at sun.font.SunFontManager.initialiseDeferredFonts(SunFontManager.java:927)
> at sun.font.SunFontManager.loadFonts(SunFontManager.java:3302)
> at sun.awt.X11FontManager.loadFonts(X11FontManager.java:466)
> at sun.font.SunFontManager.loadFontFiles(SunFontManager.java:3429)
> at sun.font.SunFontManager.getInstalledFontFamilyNames(SunFontManager.java:3766)
> at sun.java2d.SunGraphicsEnvironment.getAvailableFontFamilyNames(SunGraphicsEnvironment.java:225)
>  at sun.java2d.SunGraphicsEnvironment.getAvailableFontFamilyNames(SunGraphicsEnvironment.java:252)
>  at sun.java2d.HeadlessGraphicsEnvironment.getAvailableFontFamilyNames(HeadlessGraphicsEnvironment.java:94)
>  at FontTest.main(FontTest.java:15)
> 
> So the error in itself is one topic I wanted to inquire About. However, even worse \
> in OpenJDK 11 the error seems to have degenerated quite a bit, it Looks for me: 
> > zulu11*x64/bin/java -cp . FontTest
> Are we headless? true
> g = sun.java2d.HeadlessGraphicsEnvironment headless: true
> Exception in thread "main" java.lang.InternalError: \
> java.lang.reflect.InvocationTargetException at \
> java.desktop/sun.font.FontManagerFactory$1.run(FontManagerFactory.java:86) at \
> java.base/java.security.AccessController.doPrivileged(Native Method) at \
> java.desktop/sun.font.FontManagerFactory.getInstance(FontManagerFactory.java:74) at \
> java.desktop/sun.java2d.SunGraphicsEnvironment.getFontManagerForSGE(SunGraphicsEnvironment.java:189)
>  at java.desktop/sun.java2d.SunGraphicsEnvironment.getAvailableFontFamilyNames(SunGraphicsEnvironment.java:223)
>  at java.desktop/sun.java2d.SunGraphicsEnvironment.getAvailableFontFamilyNames(SunGraphicsEnvironment.java:251)
>  at java.desktop/sun.java2d.HeadlessGraphicsEnvironment.getAvailableFontFamilyNames(HeadlessGraphicsEnvironment.java:75)
>  at FontTest.main(FontTest.java:15)
> Caused by: java.lang.reflect.InvocationTargetException
> at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native \
> Method) at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
>  at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
>  at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:490)
> at java.desktop/sun.font.FontManagerFactory$1.run(FontManagerFactory.java:84)
> ... 7 more
> Caused by: java.lang.NullPointerException
> at java.desktop/sun.awt.FontConfiguration.getVersion(FontConfiguration.java:1262)
> at java.desktop/sun.awt.FontConfiguration.readFontConfigFile(FontConfiguration.java:225)
>  at java.desktop/sun.awt.FontConfiguration.init(FontConfiguration.java:107)
> at java.desktop/sun.awt.X11FontManager.createFontConfiguration(X11FontManager.java:719)
>  at java.desktop/sun.font.SunFontManager$2.run(SunFontManager.java:367)
> at java.base/java.security.AccessController.doPrivileged(Native Method)
> at java.desktop/sun.font.SunFontManager.<init>(SunFontManager.java:312)
> at java.desktop/sun.awt.FcFontManager.<init>(FcFontManager.java:35)
> at java.desktop/sun.awt.X11FontManager.<init>(X11FontManager.java:56)
> ... 12 mor
> 
> If there is no known issue for that, is it worth to file a Bug for it? (I Need to \
> recreate it with a Oracle OpenJDK binary yet if it is only a fontconfig Problem – \
> but in that case a null check is probably also a good thing?) 
> Gruss
> Bernd


[Attachment #3 (text/html)]

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Windows-1252">
</head>
<body>
<div><style id="ms-outlook-ios-style" type="text/css">html {
background-color: transparent;
}

body {
color: #333;
line-height: 150%;
font-family: "-apple-system", "HelveticaNeue";
margin: 0;
}

.ms-outlook-ios-reference-expand {
display: block;
color: #999;
padding: 20px 0px;
text-decoration: none;
}

.ms-outlook-ios-availability-container {
max-width: 500px;
margin: auto;
padding: 12px 15px 15px 15px;
border: 1px solid #C7E0F4;
border-radius: 4px;
}

.ms-outlook-ios-availability-container > .ms-outlook-ios-availability-delete-button {
width: 25px;
height: 25px;
right: -12px;
top: -12px;
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEsAAABLCAYAAAA4T \
nrqAAAAAXNSR0IArs4c6QAACxpJREFUeAHlnFuMXlUVx/fcOzNtp0ynF0U7hWKrEmKLosZEjUZ9MgZIQBNC0uA \
tJr745oOJIT74xgskJkQbAlQN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Oq \
P4+Jd/jOJTW+g0Lhgf21MNHdeQNC8ARWAymcHIf5X8osVZ01b27AzgC7Holz4nH+B9KDAKvqrfCDBgB9hUdPy4 \
O8l9WjpRFtqvmfUMzXIB9U8cP2v+YFOcf8yYr227sTLHCwexgXb3JasAIsB/oOHgMZuUsxXha2hX/jrQZ3CxgJ \
oe1LSLuCCSLfvteczuWuANXOK3KrDT4ZXIEZA4dsqRXuuRPdD3ah2XJ5DwAEs1C16MV0hXpksznWgSMXz0j1vZ \
+18FqE2A4/YfFUU9JK7/G6Zuqv9QXQxpNdwpt0YDvN8p0szhoZ6hQYOcyHFZVvDSe+5Z9W9RRCxsU3ydeEnczt \
eQrRy0BUSgdEP+jS9Hqju9n+UgLKL6l9XXx0S4BrTu/zFYDWr/AOig+skagdf83/3zAOBZQvOryRTEf+Donbid \
15GuS0eOsWlBC/gsl9iW/LP6C+PPi68TN0usS8EcxH6z4be2qZrPCG5XvCFi1FQu8SZ1j6YdXYeC9YuLxiZyGicQltpuoRPiEmJVLwqPgZwXOtNKO0v8BzRAPSFNM7HEAAAAASUVORK5CYII=");
                
background-size: 25px 25px;
background-position: center;
}

#ms-outlook-ios-main-container {
margin: 0 0 0 0;
margin-top: 120;
padding: 8;
}

#ms-outlook-ios-content-container {
padding: 0;
padding-top: 12;
padding-bottom: 20;
}

.ms-outlook-ios-mention {
color: #333;
background-color: #f1f1f1;
border-radius: 4px;
padding: 0 2px 0 2px;
pointer-events: none;
text-decoration: none;
}

.ms-outlook-ios-mention-external {
color: #ba8f0d;
background-color: #fdf7e7;
}

.ms-outlook-ios-mention-external-clear-design {
color: #ba8f0d;
background-color: #f1f1f1;
}</style>
<meta name="viewport" content="width=device-width, user-scalable=no, \
initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0"> <div>
<div>
<div>Hello,</div>
<div><br>
</div>
<div style="direction: ltr;">I can confirm the same ugly error stack with 12-b33 EA, \
this time with debug:</div> <div><br>
</div>
<div style="direction: ltr;">$ jdk-12/bin/java -cp . -Dsun.java2d.debugfonts=true \
FontTest</div> <div style="direction: ltr;">Are we headless? true</div>
<div style="direction: ltr;">g = sun.java2d.HeadlessGraphicsEnvironment headless: \
true</div> <div style="direction: ltr;">Feb 28, 2019 9:50:32 AM \
sun.awt.X11FontManager registerFontDir</div> <div style="direction: ltr;">INFO: \
ParseFontDir /home/vagrant/jdk-12/lib/fonts</div> <div style="direction: ltr;">Feb \
28, 2019 9:50:32 AM sun.awt.FontConfiguration &lt;init&gt;</div> <div \
style="direction: ltr;">INFO: Creating standard Font Configuration</div> <div \
style="direction: ltr;">Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration \
findImpl</div> <div style="direction: ltr;">INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.7.3.1611.properties</div> <div \
style="direction: ltr;">Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration \
findImpl</div> <div style="direction: ltr;">INFO: Looking for binary fontconfig file \
: /home/vagrant/jdk-12/lib/fontconfig.RedHat.7.3.1611.bfc</div> <div \
style="direction: ltr;">Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration \
findImpl</div> <div style="direction: ltr;">INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.7.properties</div> <div style="direction: \
ltr;">Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl</div> <div \
style="direction: ltr;">INFO: Looking for binary fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.7.bfc</div> <div style="direction: \
ltr;">Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl</div> <div \
style="direction: ltr;">INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.properties</div> <div style="direction: \
ltr;">Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl</div> <div \
style="direction: ltr;">INFO: Looking for binary fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.bfc</div> <div style="direction: ltr;">Feb \
28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl</div> <div style="direction: \
ltr;">INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.7.3.1611.properties</div> <div style="direction: \
ltr;">Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl</div> <div \
style="direction: ltr;">INFO: Looking for binary fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.7.3.1611.bfc</div> <div style="direction: \
ltr;">Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl</div> <div \
style="direction: ltr;">INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.7.properties</div> <div style="direction: \
ltr;">Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl</div> <div \
style="direction: ltr;">INFO: Looking for binary fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.7.bfc</div> <div style="direction: ltr;">Feb 28, \
2019 9:50:32 AM sun.awt.FontConfiguration findImpl</div> <div style="direction: \
ltr;">INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.properties</div> <div style="direction: ltr;">Feb \
28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl</div> <div style="direction: \
ltr;">INFO: Looking for binary fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.bfc</div> <div style="direction: ltr;">Feb 28, \
2019 9:50:32 AM sun.awt.FontConfiguration findFontConfigFile</div> <div \
style="direction: ltr;">INFO: Did not find a fontconfig file.</div> <div \
style="direction: ltr;">Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration \
&lt;init&gt;</div> <div style="direction: ltr;">INFO: Creating standard Font \
Configuration</div> <div style="direction: ltr;">Feb 28, 2019 9:50:32 AM \
sun.awt.FontConfiguration findImpl</div> <div style="direction: ltr;">INFO: Looking \
for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.7.3.1611.properties</div> <div \
style="direction: ltr;">Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration \
findImpl</div> <div style="direction: ltr;">INFO: Looking for binary fontconfig file \
: /home/vagrant/jdk-12/lib/fontconfig.RedHat.7.3.1611.bfc</div> <div \
style="direction: ltr;">Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration \
findImpl</div> <div style="direction: ltr;">INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.7.properties</div> <div style="direction: \
ltr;">Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl</div> <div \
style="direction: ltr;">INFO: Looking for binary fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.7.bfc</div> <div style="direction: \
ltr;">Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl</div> <div \
style="direction: ltr;">INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.properties</div> <div style="direction: \
ltr;">Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl</div> <div \
style="direction: ltr;">INFO: Looking for binary fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.RedHat.bfc</div> <div style="direction: ltr;">Feb \
28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl</div> <div style="direction: \
ltr;">INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.7.3.1611.properties</div> <div style="direction: \
ltr;">Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl</div> <div \
style="direction: ltr;">INFO: Looking for binary fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.7.3.1611.bfc</div> <div style="direction: \
ltr;">Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl</div> <div \
style="direction: ltr;">INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.7.properties</div> <div style="direction: \
ltr;">Feb 28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl</div> <div \
style="direction: ltr;">INFO: Looking for binary fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.7.bfc</div> <div style="direction: ltr;">Feb 28, \
2019 9:50:32 AM sun.awt.FontConfiguration findImpl</div> <div style="direction: \
ltr;">INFO: Looking for text fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.properties</div> <div style="direction: ltr;">Feb \
28, 2019 9:50:32 AM sun.awt.FontConfiguration findImpl</div> <div style="direction: \
ltr;">INFO: Looking for binary fontconfig file : \
/home/vagrant/jdk-12/lib/fontconfig.bfc</div> <div style="direction: ltr;">Feb 28, \
2019 9:50:32 AM sun.awt.FontConfiguration findFontConfigFile</div> <div \
style="direction: ltr;">INFO: Did not find a fontconfig file.</div> <div \
style="direction: ltr;">Feb 28, 2019 9:50:32 AM sun.font.FontConfigManager \
initFontConfigFonts</div> <div style="direction: ltr;">INFO: Fontconfig returned no \
font for sans:regular:roman</div> <div style="direction: ltr;">Feb 28, 2019 9:50:32 \
AM sun.font.FontConfigManager initFontConfigFonts</div> <div style="direction: \
ltr;">INFO: Fontconfig returned no font for sans:bold:roman</div> <div \
style="direction: ltr;">Feb 28, 2019 9:50:32 AM sun.font.FontConfigManager \
initFontConfigFonts</div> <div style="direction: ltr;">INFO: Fontconfig returned no \
font for sans:regular:italic</div> <div style="direction: ltr;">Feb 28, 2019 9:50:32 \
AM sun.font.FontConfigManager initFontConfigFonts</div> <div style="direction: \
ltr;">INFO: Fontconfig returned no font for sans:bold:italic</div> <div \
style="direction: ltr;">Feb 28, 2019 9:50:32 AM sun.font.FontConfigManager \
initFontConfigFonts</div> <div style="direction: ltr;">INFO: Fontconfig returned no \
font for serif:regular:roman</div> <div style="direction: ltr;">Feb 28, 2019 9:50:32 \
AM sun.font.FontConfigManager initFontConfigFonts</div> <div style="direction: \
ltr;">INFO: Fontconfig returned no font for serif:bold:roman</div> <div \
style="direction: ltr;">Feb 28, 2019 9:50:32 AM sun.font.FontConfigManager \
initFontConfigFonts</div> <div style="direction: ltr;">INFO: Fontconfig returned no \
font for serif:regular:italic</div> <div style="direction: ltr;">Feb 28, 2019 9:50:32 \
AM sun.font.FontConfigManager initFontConfigFonts</div> <div style="direction: \
ltr;">INFO: Fontconfig returned no font for serif:bold:italic</div> <div \
style="direction: ltr;">Feb 28, 2019 9:50:32 AM sun.font.FontConfigManager \
initFontConfigFonts</div> <div style="direction: ltr;">INFO: Fontconfig returned no \
font for monospace:regular:roman</div> <div style="direction: ltr;">Feb 28, 2019 \
9:50:32 AM sun.font.FontConfigManager initFontConfigFonts</div> <div \
style="direction: ltr;">INFO: Fontconfig returned no font for \
monospace:bold:roman</div> <div style="direction: ltr;">Feb 28, 2019 9:50:32 AM \
sun.font.FontConfigManager initFontConfigFonts</div> <div style="direction: \
ltr;">INFO: Fontconfig returned no font for monospace:regular:italic</div> <div \
style="direction: ltr;">Feb 28, 2019 9:50:32 AM sun.font.FontConfigManager \
initFontConfigFonts</div> <div style="direction: ltr;">INFO: Fontconfig returned no \
font for monospace:bold:italic</div> <div style="direction: ltr;">Feb 28, 2019 \
9:50:32 AM sun.font.FontConfigManager initFontConfigFonts</div> <div \
style="direction: ltr;">INFO: Fontconfig returned no fonts at all.</div> <div \
style="direction: ltr;">Feb 28, 2019 9:50:32 AM sun.font.FcFontConfiguration \
warning</div> <div style="direction: ltr;">WARNING: Failed to get info from \
libfontconfig</div> <div style="direction: ltr;">Feb 28, 2019 9:50:32 AM \
sun.font.FcFontConfiguration warning</div> <div style="direction: ltr;">WARNING: \
Failed to get info from libfontconfig</div> <div style="direction: ltr;">Exception in \
thread &quot;main&quot; java.lang.InternalError: \
java.lang.reflect.InvocationTargetException</div> <div style="direction: \
ltr;">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;at \
java.desktop/sun.font.FontManagerFactory$1.run(FontManagerFactory.java:86)</div> <div \
style="direction: ltr;">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;at \
java.base/java.security.AccessController.doPrivileged(AccessController.java:310)</div>
 <div style="direction: ltr;">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;at \
java.desktop/sun.font.FontManagerFactory.getInstance(FontManagerFactory.java:74)</div>
 <div style="direction: ltr;">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;at \
java.desktop/sun.java2d.SunGraphicsEnvironment.getFontManagerForSGE(SunGraphicsEnvironment.java:189)</div>
 <div style="direction: ltr;">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;at \
java.desktop/sun.java2d.SunGraphicsEnvironment.getAvailableFontFamilyNames(SunGraphicsEnvironment.java:223)</div>
 <div style="direction: ltr;">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;at \
java.desktop/sun.java2d.SunGraphicsEnvironment.getAvailableFontFamilyNames(SunGraphicsEnvironment.java:251)</div>
 <div style="direction: ltr;">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;at \
java.desktop/sun.java2d.HeadlessGraphicsEnvironment.getAvailableFontFamilyNames(HeadlessGraphicsEnvironment.java:75)</div>
 <div><br>
</div>
</div>
<div><br>
</div>
<div class="ms-outlook-ios-signature">
<div style="direction: ltr;">Gruss</div>
<div style="direction: ltr;">Bernd</div>
<div style="direction: ltr;">-- </div>
<div style="direction: ltr;">http://bernd.eckenfels.net</div>
</div>
</div>
<div>&nbsp;</div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="dir=&quot;ltr&quot;"><font face="Calibri, sans-serif" \
style="font-size:11pt" color="#000000"><b>Von:</b> Philip Race \
&lt;philip.race@oracle.com&gt;<br> <b>Gesendet:</b> Donnerstag, Februar 28, 2019 \
12:45 AM<br> <b>An:</b> Bernd Eckenfels; 2d-dev<br>
<b>Cc:</b> awt-dev@openjdk.java.net; Java Core Libs<br>
<b>Betreff:</b> Re: &quot;java.lang.Error: Probable fatal error:No fonts found&quot; \
does not show on 11 <div>&nbsp;</div>
</font></div>
Wrong list. You want 2d-dev. <br>
<br>
-phil. <br>
<br>
On 2/27/19, 3:26 PM, Bernd Eckenfels wrote: <br>
&gt; Hello, <br>
&gt; <br>
&gt; (please let me know in case I picked the wrong list.) <br>
&gt; <br>
&gt; Since OpenJDK does not ship Default *.ttf font files the change that a JRE is \
installed in a way that no System Fonts can be found is quite high. <br>
&gt; <br>
&gt; In OpenJDK8 it is a bit unfortunate that in this situation even for the headless \
graphics context that you can can a Java.lang.Error: <br>
&gt; <br>
&gt; I wonder if this is intentional. How About returnign an empty Array or Maybe a \
RntimeException instead? In my case by upgrading from Oracle JRE to Open JDK (in my \
case Azul) a perfectly fine working Installation is not aborting. <br>
&gt; <br>
&gt; The JasperReports component used is failing does not even need the System Fonts \
(which I will report to them seperately). For Zulu it is enough to install Dejavu \
Fonts in System Directory or copy them to JRE/lib/fonts/, but I have also seen \
OpenJDK builds  which seem to use fontmanager libraries instead of fixed file path. \
Here I guess the dependency on System config is even higher. <br>
&gt; <br>
&gt; I tested on a minimal System with no X11: <br>
&gt; <br>
&gt;&gt; ls /usr/share/fonts <br>
&gt;&gt; cat /etc/centos-release <br>
&gt; CentOS Linux release 7.3.1611 (Core) <br>
&gt; <br>
&gt; And my test program (below) Returns for Java 8: <br>
&gt; <br>
&gt;&gt; zulu8*x64/bin/java -cp . FontTest <br>
&gt; Are we headless? true <br>
&gt; g = sun.java2d.HeadlessGraphicsEnvironment headless: true <br>
&gt; Exception in thread &quot;main&quot; java.lang.Error: Probable fatal error:No \
fonts found. <br>
&gt; at sun.font.SunFontManager.getDefaultPhysicalFont(SunFontManager.java:1236) <br>
&gt; at sun.font.SunFontManager.initialiseDeferredFont(SunFontManager.java:1100) <br>
&gt; … <br>
&gt; at sun.font.SunFontManager.getDefaultPhysicalFont(SunFontManager.java:1220) <br>
&gt; at sun.font.SunFontManager.initialiseDeferredFont(SunFontManager.java:1100) <br>
&gt; at sun.font.SunFontManager.initialiseDeferredFonts(SunFontManager.java:927) <br>
&gt; at sun.font.SunFontManager.loadFonts(SunFontManager.java:3302) <br>
&gt; at sun.awt.X11FontManager.loadFonts(X11FontManager.java:466) <br>
&gt; at sun.font.SunFontManager.loadFontFiles(SunFontManager.java:3429) <br>
&gt; at sun.font.SunFontManager.getInstalledFontFamilyNames(SunFontManager.java:3766)
<br>
&gt; at sun.java2d.SunGraphicsEnvironment.getAvailableFontFamilyNames(SunGraphicsEnvironment.java:225)
 <br>
&gt; at sun.java2d.SunGraphicsEnvironment.getAvailableFontFamilyNames(SunGraphicsEnvironment.java:252)
 <br>
&gt; at sun.java2d.HeadlessGraphicsEnvironment.getAvailableFontFamilyNames(HeadlessGraphicsEnvironment.java:94)
 <br>
&gt; at FontTest.main(FontTest.java:15) <br>
&gt; <br>
&gt; So the error in itself is one topic I wanted to inquire About. However, even \
worse in OpenJDK 11 the error seems to have degenerated quite a bit, it Looks for me: \
<br> &gt; <br>
&gt;&gt; zulu11*x64/bin/java -cp . FontTest <br>
&gt; Are we headless? true <br>
&gt; g = sun.java2d.HeadlessGraphicsEnvironment headless: true <br>
&gt; Exception in thread &quot;main&quot; java.lang.InternalError: \
java.lang.reflect.InvocationTargetException <br>
&gt; at java.desktop/sun.font.FontManagerFactory$1.run(FontManagerFactory.java:86) \
<br> &gt; at java.base/java.security.AccessController.doPrivileged(Native Method) \
<br> &gt; at java.desktop/sun.font.FontManagerFactory.getInstance(FontManagerFactory.java:74)
 <br>
&gt; at java.desktop/sun.java2d.SunGraphicsEnvironment.getFontManagerForSGE(SunGraphicsEnvironment.java:189)
 <br>
&gt; at java.desktop/sun.java2d.SunGraphicsEnvironment.getAvailableFontFamilyNames(SunGraphicsEnvironment.java:223)
 <br>
&gt; at java.desktop/sun.java2d.SunGraphicsEnvironment.getAvailableFontFamilyNames(SunGraphicsEnvironment.java:251)
 <br>
&gt; at java.desktop/sun.java2d.HeadlessGraphicsEnvironment.getAvailableFontFamilyNames(HeadlessGraphicsEnvironment.java:75)
 <br>
&gt; at FontTest.main(FontTest.java:15) <br>
&gt; Caused by: java.lang.reflect.InvocationTargetException <br>
&gt; at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native \
Method) <br>
&gt; at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
 <br>
&gt; at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
 <br>
&gt; at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:490) \
<br> &gt; at java.desktop/sun.font.FontManagerFactory$1.run(FontManagerFactory.java:84) \
<br> &gt; ... 7 more <br>
&gt; Caused by: java.lang.NullPointerException <br>
&gt; at java.desktop/sun.awt.FontConfiguration.getVersion(FontConfiguration.java:1262)
 <br>
&gt; at java.desktop/sun.awt.FontConfiguration.readFontConfigFile(FontConfiguration.java:225)
 <br>
&gt; at java.desktop/sun.awt.FontConfiguration.init(FontConfiguration.java:107) <br>
&gt; at java.desktop/sun.awt.X11FontManager.createFontConfiguration(X11FontManager.java:719)
 <br>
&gt; at java.desktop/sun.font.SunFontManager$2.run(SunFontManager.java:367) <br>
&gt; at java.base/java.security.AccessController.doPrivileged(Native Method) <br>
&gt; at java.desktop/sun.font.SunFontManager.&lt;init&gt;(SunFontManager.java:312) \
<br> &gt; at java.desktop/sun.awt.FcFontManager.&lt;init&gt;(FcFontManager.java:35) \
<br> &gt; at java.desktop/sun.awt.X11FontManager.&lt;init&gt;(X11FontManager.java:56) \
<br> &gt; ... 12 mor <br>
&gt; <br>
&gt; If there is no known issue for that, is it worth to file a Bug for it? (I Need \
to recreate it with a Oracle OpenJDK binary yet if it is only a fontconfig Problem – \
but in that case a null check is probably also a good thing?) <br>
&gt; <br>
&gt; Gruss <br>
&gt; Bernd <br>
</div>
</body>
</html>



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic