Closed kthaya closed 3 years ago
The error says Freetype is missing. That's something that needs to be supplied by the user because it's only bundled on few platfroms. I'm not familiar with Install4J, so I don't know how to fix it.
Thanks. I have used IBM's JDK 8 and did not get this error. I upgraded to Java 11 recently end up with this issue. When I see the difference AdoptOpenJDK 11.0.9 AIX version's /jre/lib/
loaded with many library files like /jre/lib/libfontmanager.so
and particularly this libfontmanager.so
has few other system level dependencies as we can see in the error log:
Cannot load module /home/aowuw/app-8_0_0-aix-ppc64.sh.6750682.dir/jre/lib/libfontmanager.so. 0509-150 Dependent module libfreetype.a(libfreetype.so.6) could not be loaded. 0509-022 Cannot load module libfreetype.a(libfreetype.so.6). 0509-026 System error: A file or directory in the path name does not exist. 0509-022 Cannot load module /home/aowuw/app-8_0_0-aix-ppc64.sh.6750682.dir/jre/lib/libfontmanager.so. 0509-150 Dependent module /h
I don't think is related with install4j
, do you think we have to install these dependencies to AIX? and any idea why IBM's java 8 does not have these libraries like libfontmanager.so
inside /jre/lib
? Thanks
You can read more about the font situation on https://blog.adoptopenjdk.net/2021/01/prerequisites-for-font-support-in-adoptopenjdk/. If your AIX does not have those libraries, please let me know what packages have to be installed with the system's package manager and I'll update the article.
and any idea why IBM's java 8 does not have these libraries like libfontmanager.so inside /jre/lib?
Oracle JDK 8 in the early days looked significantly different in comparison to what we have now. And IBM JDK is a completely different beast with another VM.
As suggested in https://blog.adoptopenjdk.net/2021/01/prerequisites-for-font-support-in-adoptopenjdk/, installing Freetype and Fontconfig solved the problem. Thanks for the help :)
@kthaya What steps did you perform to install both? Would be a nice addition to the article.
I'm sorry, I made a mistake. I actually did not install Fontconfig. I have installed only Freetype.
Freetype have some dependencies, I have installed following in order in AIX.
Question
I'm getting following error when I install the application using install4j, I'm not certain the root cause, could you please help?
Error log
$ ./app-8_0_0-aix-ppc64.sh Unpacking JRE ... Starting Installer ... An error occurred: java.lang.RuntimeException: java.lang.reflect.InvocationTargetException Error log: /tmp/install4jError9845213310594816837.log java.lang.RuntimeException: java.lang.reflect.InvocationTargetException at com.install4j.runtime.installer.frontend.GUIHelper.invokeOnEDT(GUIHelper.java:716) at com.install4j.runtime.installer.frontend.headless.AbstractHeadlessScreenExecutor.init(AbstractHeadlessScreenExecutor.java:74) at com.install4j.runtime.installer.frontend.headless.ConsoleScreenExecutor.(ConsoleScreenExecutor.java:24)
at com.install4j.runtime.installer.frontend.headless.InstallerConsoleScreenExecutor.(InstallerConsoleScreenExecutor.java:6)
at com.install4j.runtime.installer.Installer.getScreenExecutor(Installer.java:91)
at com.install4j.runtime.installer.Installer.runInProcess(Installer.java:60)
at com.install4j.runtime.installer.Installer.main(Installer.java:46)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.base/java.lang.reflect.Method.invoke(Unknown Source)
at com.exe4j.runtime.LauncherEngine.launch(LauncherEngine.java:84)
at com.install4j.runtime.launcher.UnixLauncher.start(UnixLauncher.java:66)
at install4j.Installer371033952.main(Unknown Source)
Caused by: java.lang.reflect.InvocationTargetException
at java.desktop/java.awt.EventQueue.invokeAndWait(Unknown Source)
at java.desktop/java.awt.EventQueue.invokeAndWait(Unknown Source)
at com.install4j.runtime.installer.frontend.GUIHelper.invokeOnEDT(GUIHelper.java:712)
... 13 more
Caused by: java.lang.UnsatisfiedLinkError: /home/aowuw/app-8_0_0-aix-ppc64.sh.6750682.dir/jre/lib/libfontmanager.so: /home/aowuw/app-8_0_0-aix-ppc64.sh.6750682.dir/jre/lib/libfontmanager.so, LIBPATH=/home/aowuw/app-8_0_0-aix-ppc64.sh.6750682.dir/jre/lib/server:/home/aowuw/app-8_0_0-aix-ppc64.sh.6750682.dir/jre/lib:/home/aowuw/app-8_0_0-aix-ppc64.sh.6750682.dir/jre/lib/jli:/home/aowuw/app-8_0_0-aix-ppc64.sh.6750682.dir/jre/../lib:/home/aowuw/app-8_0_0-aix-ppc64.sh.6750682.dir/user:, LD_LIBRARY_PATH=/home/aowuw/app-8_0_0-aix-ppc64.sh.6750682.dir/user: : 0509-022 Cannot load module /home/aowuw/app-8_0_0-aix-ppc64.sh.6750682.dir/jre/lib/libfontmanager.so.
0509-150 Dependent module libfreetype.a(libfreetype.so.6) could not be loaded.
0509-022 Cannot load module libfreetype.a(libfreetype.so.6).
0509-026 System error: A file or directory in the path name does not exist.
0509-022 Cannot load module /home/aowuw/app-8_0_0-aix-ppc64.sh.6750682.dir/jre/lib/libfontmanager.so.
0509-150 Dependent module /h
at java.base/java.lang.ClassLoader$NativeLibrary.load0(Native Method)
at java.base/java.lang.ClassLoader$NativeLibrary.load(Unknown Source)
at java.base/java.lang.ClassLoader$NativeLibrary.loadLibrary(Unknown Source)
at java.base/java.lang.ClassLoader.loadLibrary0(Unknown Source)
at java.base/java.lang.ClassLoader.loadLibrary(Unknown Source)
at java.base/java.lang.Runtime.loadLibrary0(Unknown Source)
at java.base/java.lang.System.loadLibrary(Unknown Source)
at java.desktop/sun.font.FontManagerNativeLibrary$1.run(Unknown Source)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.desktop/sun.font.FontManagerNativeLibrary.(Unknown Source)
at java.desktop/sun.font.SunFontManager$1.run(Unknown Source)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.desktop/sun.font.SunFontManager.(Unknown Source)
at java.desktop/sun.font.FontDesignMetrics.getMetrics(Unknown Source)
at java.desktop/sun.swing.SwingUtilities2.getFontMetrics(Unknown Source)
at java.desktop/javax.swing.JComponent.getFontMetrics(Unknown Source)
at java.desktop/javax.swing.text.WrappedPlainView.updateMetrics(Unknown Source)
at java.desktop/javax.swing.text.WrappedPlainView.updateChildren(Unknown Source)
at java.desktop/javax.swing.text.WrappedPlainView.insertUpdate(Unknown Source)
at java.desktop/javax.swing.plaf.basic.BasicTextUI$RootView.insertUpdate(Unknown Source)
at java.desktop/javax.swing.plaf.basic.BasicTextUI$UpdateHandler.insertUpdate(Unknown Source)
at java.desktop/javax.swing.text.AbstractDocument.fireInsertUpdate(Unknown Source)
at java.desktop/javax.swing.text.AbstractDocument.handleInsertString(Unknown Source)
at java.desktop/javax.swing.text.AbstractDocument.insertString(Unknown Source)
at java.desktop/javax.swing.text.PlainDocument.insertString(Unknown Source)
at java.desktop/javax.swing.text.DefaultEditorKit.read(Unknown Source)
at java.desktop/javax.swing.JEditorPane.setText(Unknown Source)
at java.desktop/javax.swing.JEditorPane.(Unknown Source)
at com.install4j.runtime.installer.frontend.headless.AbstractHeadlessScreenExecutor.createEditorPane(AbstractHeadlessScreenExecutor.java:354)
at com.install4j.runtime.installer.frontend.headless.AbstractHeadlessScreenExecutor.initFontManager(AbstractHeadlessScreenExecutor.java:314)
at com.install4j.runtime.installer.frontend.headless.AbstractHeadlessScreenExecutor.access$400(AbstractHeadlessScreenExecutor.java:32)
at com.install4j.runtime.installer.frontend.headless.AbstractHeadlessScreenExecutor$2.run(AbstractHeadlessScreenExecutor.java:78)
at java.desktop/java.awt.event.InvocationEvent.dispatch(Unknown Source)
at java.desktop/java.awt.EventQueue.dispatchEventImpl(Unknown Source)
at java.desktop/java.awt.EventQueue$4.run(Unknown Source)
at java.desktop/java.awt.EventQueue$4.run(Unknown Source)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
at java.desktop/java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.run(Unknown Source)
Context
Java version: jdk11_0_9
Your operating system and platform: AIX 7.2 TL4