in a java webstart file (jnlp) you can specify the nativelib tag to load binaries. you can also specify toload different ones for different operating systems by also specifying the os attribute.
for example:
<resources os="Linux">
<nativelib href="....jar"/>
</resources>
<resources os="Windows">
<nativelib href="....jar"/>
</resources>
<resources os="Mac OS X">
<nativelib href="....jar"/>
</resources>
but how can i specify even different binaries for different architectures? for example win32 and win64 or linux 32 and linux 64bit. operating systems. where can i find a list of options for the os-attribute?
To determine that you basically need the os.arch
property. Also see http://lopica.sourceforge.net/os.html for a complete list. You can use the arch
attribute of the <resources>
element for this.
According to http://jcp.org/aboutJava/communityprocess/mrel/jsr056/index3.html:
"os attribute: Specifies the operating system for which the resources element should be considered. If the value is a prefix of the os.name system property, then the resources element can be used. If the attribute is not specified, it matches all operating systems."
So you need to do some investigation of the value of the os.name system property on the platforms you want to deploy to.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With