Building openjdk8 on windows 7, tests fail for i18n problems
David Holmes
david.holmes at oracle.com
Tue Dec 20 03:35:34 UTC 2016
Hi Peter, I'm cc'ing awt-dev as the client folk should have a better
idea how font libraries are supposed to work on windows.
David
On 20/12/2016 12:49 PM, Peter Koellner wrote:
> Thanks,
> I am not sure the debug output is helping very much. There seem to be
> lots of ClassNotFound exceptions there. I can see the window opening,
> but then nothing works.
> I have now reconfigured tzhe program did a make
> CONF=windows-x86-normal-server-fastdebug
> and then a
> $ build/windows-x86-normal-server-fastdebug/jdk/bin/java
> -XX:+TraceExceptions
> -jar e:/javatest/testjava/out/artifacts/testjava_jar/testjava.jar >
> crap.log 2>
> & 1
>
> I guess the decisive part is this:
>
> Exception <a 'java/lang/UnsatisfiedLinkError'> (0x2f032de8)
> thrown in interpreter method <{method} {0x3f0684e4} 'load'
> '(Ljava/lang/String;Z)V' in 'java/lang/ClassLoader$NativeLibrary'>
> at bci 0 for thread 0x00a4f400
> Exception <a 'java/lang/UnsatisfiedLinkError'> (0x2f032de8)
> thrown in interpreter method <{method} {0x3ef4551c} 'loadLibrary0'
> '(Ljava/lang/Class;Ljava/io/File;)Z' in 'java/lang/ClassLoader>
> at bci 328 for thread 0x00a4f400
> Exception <a 'java/lang/UnsatisfiedLinkError'> (0x2f032de8)
> thrown in interpreter method <{method} {0x3ef4551c} 'loadLibrary0'
> '(Ljava/lang/Class;Ljava/io/File;)Z' in 'java/lang/ClassLoader>
> at bci 352 for thread 0x00a4f400
> Exception <a 'java/lang/UnsatisfiedLinkError'> (0x2f032de8)
> thrown in interpreter method <{method} {0x3ef4551c} 'loadLibrary0'
> '(Ljava/lang/Class;Ljava/io/File;)Z' in 'java/lang/ClassLoader>
> at bci 398 for thread 0x00a4f400
> Exception <a 'java/lang/UnsatisfiedLinkError'> (0x2f032de8)
> thrown in interpreter method <{method} {0x3ef4551c} 'loadLibrary0'
> '(Ljava/lang/Class;Ljava/io/File;)Z' in 'java/lang/ClassLoader>
> at bci 406 for thread 0x00a4f400
> Exception <a 'java/lang/UnsatisfiedLinkError'> (0x2f032de8)
> thrown in interpreter method <{method} {0x3ef45164} 'loadLibrary'
> '(Ljava/lang/Class;Ljava/lang/String;Z)V' in 'java/lang/ClassLo>
> at bci 217 for thread 0x00a4f400
> Exception <a 'java/lang/UnsatisfiedLinkError'> (0x2f032de8)
> thrown in interpreter method <{method} {0x3f00e4dc} 'loadLibrary0'
> '(Ljava/lang/Class;Ljava/lang/String;)V' in 'java/lang/Runtime>
> at bci 54 for thread 0x00a4f400
> Exception <a 'java/lang/UnsatisfiedLinkError'> (0x2f032de8)
> thrown in interpreter method <{method} {0x3ef47b14} 'loadLibrary'
> '(Ljava/lang/String;)V' in 'java/lang/System'>
> at bci 7 for thread 0x00a4f400
> Exception <a 'java/lang/UnsatisfiedLinkError'> (0x2f032de8)
> thrown in interpreter method <{method} {0x4122072c} 'run'
> '()Ljava/lang/Object;' in 'sun/font/FontManagerNativeLibrary$1'>
> at bci 26 for thread 0x00a4f400
> Exception <a 'java/lang/UnsatisfiedLinkError'> (0x2f032de8)
> thrown [C:\openjdk\jdk8u\hotspot\src\share\vm\prims\jvm.cpp, line 1394]
> for thread 0x00a4f400
> Exception <a 'java/lang/UnsatisfiedLinkError'> (0x2f032de8)
> thrown in interpreter method <{method} {0x3efd3384} 'doPrivileged'
> '(Ljava/security/PrivilegedAction;)Ljava/lang/Object;' in 'jav>
> at bci 0 for thread 0x00a4f400
> Exception <a 'java/lang/UnsatisfiedLinkError'> (0x2f032de8)
> thrown in interpreter method <{method} {0x412202f4} '<clinit>' '()V' in
> 'sun/font/FontManagerNativeLibrary'>
> at bci 7 for thread 0x00a4f400
> Exception <a 'java/lang/UnsatisfiedLinkError'> (0x2f032de8)
> thrown [C:\openjdk\jdk8u\hotspot\src\share\vm\oops\instanceKlass.cpp,
> line 959]
> for thread 0x00a4f400
> Exception <a 'java/lang/UnsatisfiedLinkError'> (0x2f032de8)
> thrown in interpreter method <{method} {0x4121fd74} 'run'
> '()Ljava/lang/Object;' in 'sun/font/SunFontManager$1'>
> at bci 0 for thread 0x00a4f400
> Exception <a 'java/lang/UnsatisfiedLinkError'> (0x2f032de8)
> thrown [C:\openjdk\jdk8u\hotspot\src\share\vm\prims\jvm.cpp, line 1394]
> for thread 0x00a4f400
> Exception <a 'java/lang/UnsatisfiedLinkError'> (0x2f032de8)
> thrown in interpreter method <{method} {0x3efd3384} 'doPrivileged'
> '(Ljava/security/PrivilegedAction;)Ljava/lang/Object;' in 'jav>
> at bci 0 for thread 0x00a4f400
> Exception <a 'java/lang/UnsatisfiedLinkError'> (0x2f032de8)
> thrown in interpreter method <{method} {0x4121d024} '<clinit>' '()V' in
> 'sun/font/SunFontManager'>
> at bci 40 for thread 0x00a4f400
> Exception <a 'java/lang/UnsatisfiedLinkError'> (0x2f032de8)
> thrown [C:\openjdk\jdk8u\hotspot\src\share\vm\oops\instanceKlass.cpp,
> line 959]
> for thread 0x00a4f400
>
>
>
>
> And in jdk/src/share/classes/sun/font/FontManagerNativeLibrary.java
>
> public Object run() {
> /* REMIND do we really have to load awt here? */
> System.loadLibrary("awt");
> if (FontUtilities.isOpenJDK &&
> System.getProperty("os.name").startsWith("Windows")) {
> /* Ideally fontmanager library should not depend on
> particular implementation of the font scaler.
> However, freetype scaler is basically small
> wrapper on
> top of freetype library (that is used in binary
> form).
>
> This wrapper is compiled into fontmanager and this
> make
> fontmanger library depending on freetype library.
>
> On Windows DLL's in the JRE's BIN directory cannot be
> found by windows DLL loading as that directory is not
> on the Windows PATH.
>
> To avoid link error we have to load freetype
> explicitly
> before we load fontmanager.
>
> Note that we do not need to do this for T2K because
> fontmanager.dll does not depend on t2k.dll.
>
> NB: consider moving freetype wrapper part to separate
> shared library in order to avoid dependency. */
> System.loadLibrary("freetype");
> }
> System.loadLibrary("fontmanager");
>
> return null;
>
>
>
> So I guess it does not find awt, freetype or fontmanager libraries, so
> it probably is the freetype library. Now the configure script asked for
> the freetype lib to be installed and gave explicit instructions how to
> rename teh library - but do I have to do something with that manually so
> the runtime finds it then?
>
> The freetype.dll is located inside the bin folder, as well as awt and
> fontmanager:
>
> /cygdrive/c/openjdk/jdk8u/build/windows-x86-normal-server-fastdebug/jdk/bin
> $ ls
> appletviewer.exe jaas_nt.dll java-rmi.exe
> jjs.pdb keytool.exe pack200.exe sunmscapi.pdb
> appletviewer.pdb jaas_nt.pdb java-rmi.pdb
> jli.dll keytool.pdb pack200.pdb tnameserv.exe
> attach.dll jabswitch.exe javaw.exe
> jli.pdb kinit.exe policytool.exe tnameserv.pdb
> attach.pdb jabswitch.pdb javaw.pdb
> jmap.exe kinit.pdb policytool.pdb unpack.dll
> awt.dll jar.exe jawt.dll
> jmap.pdb klist.exe rmic.exe unpack.pdb
> awt.pdb jar.pdb jawt.pdb
> jpeg.dll klist.pdb rmic.pdb unpack200.exe
> dt_shmem.dll jarsigner.exe JAWTAccessBridge.dll
> jpeg.pdb ktab.exe rmid.exe verify.dll
> dt_shmem.pdb jarsigner.pdb JAWTAccessBridge.pdb
> jps.exe ktab.pdb rmid.pdb verify.pdb
> dt_socket.dll java.dll JAWTAccessBridge-32.dll
> jps.pdb lcms.dll rmiregistry.exe w2k_lsa_auth.dll
> dt_socket.pdb java.exe JAWTAccessBridge-32.pdb
> jrunscript.exe lcms.pdb rmiregistry.pdb w2k_lsa_auth.pdb
> extcheck.exe java.pdb jcmd.exe
> jrunscript.pdb management.dll sawindbg.dll WindowsAccessBridge.dll
> extcheck.pdb java_crw_demo.dll jcmd.pdb
> jsadebugd.exe management.pdb sawindbg.map WindowsAccessBridge.pdb
> fontmanager.dll java_crw_demo.pdb jconsole.exe
> jsadebugd.pdb mlib_image.dll sawindbg.pdb
> WindowsAccessBridge-32.dll
> fontmanager.pdb JavaAccessBridge.dll jconsole.pdb
> jsdt.dll mlib_image.pdb schemagen.exe
> WindowsAccessBridge-32.pdb
> freetype.dll ...
>
> So maybe a problem with paths? or this .pdb file missing for
> freetype.dll? not sure what that is.
>
> It probably would be easier if FileNotFoundExceptions would actually
> give out the filename somewhere instead of a bloated stacktrace, which
> is something that really have been bothering me frequently since I wrote
> my first applet in 1996...
>
> the cc to jdk8u-dev has to wait, I still have not received the
> subscription confirmation request.
>
>
> On Tue, 20 Dec 2016, David Holmes wrote:
>
>> On 20/12/2016 9:34 AM, Peter Koellner wrote:
>>> On Tue, 20 Dec 2016, David Holmes wrote:
>>>
>>>> On 20/12/2016 7:41 AM, Peter Koellner wrote:
>>>>> How do I add jvm args to the make test java processes? localized
>>>>> windows
>>>>> 7 home can't change the locale to en, but setting -Duser.country=US
>>>>> -Duser-language=en should solve a number of i18n related test
>>>>> failures...
>>>>
>>>> It might work to run:
>>>>
>>>> make test JAVA_VM_ARGS="-Duser.country=US -Duser-language=en"
>>>
>>> Thanks. I'll do that after the next build tomorrow. Can I also increase
>>> the timeouts for the tests somehow?
>>
>> Try adding:
>>
>> JTREG_TIMEOUT_OPTION=-timeoutFactor:4
>>
>> but increase 4 to whatever you think suitable.
>>
>> BTW I'm determining this by reading jdk/test/Makefile and seeing how
>> the jtreg tests get run.
>>
>> David
>
>
More information about the jdk8-dev
mailing list