#1
|
||||
|
||||
[EventScripter] sys info are wrong
Hi,
Here is a sample script: Code:
var myEnvironment = getEnvironment(); // Get OS environment var sep = myEnvironment.getPathSeparator(); var arch = myEnvironment.getARCHFamily(); var java = myEnvironment.getJavaVersion(); var os = myEnvironment.getOS(); var fam = myEnvironment.getOSFamily(); var iJDCoreVersion = callAPI("jd", "getCoreRevision"); var iJDVersion = callAPI("jd", "version"); sText = "arch :" + arch + "\r\njava version: " + java + "\r\nOS: " + os + "\r\nOS family: " + fam + "\r\nPath Separator: " + sep + "\r\nJD version: " + iJDVersion + "\r\nJD core version: " + iJDCoreVersion; alert(sText); Is it a bug or
|
#2
|
||||
|
||||
arch returns generic CPU arch
Code:
NA X86 ARM PPC SPARC IA64
__________________
JD-Dev & Server-Admin |
#3
|
||||
|
||||
Java 1.8 Update 40 is too old Windows 8.1+ changed internals. You have to install/use a newer java version
bugs.openjdk.java.net/browse/JDK-8066504
__________________
JD-Dev & Server-Admin |
#4
|
||||
|
||||
There is also
is64BitOS() is64BitArch() is64BitJava()
__________________
JD-Dev & Server-Admin |
#5
|
||||
|
||||
Ok, I have now JD run with JRE 1.8.0.152.
Windows 10 is detected but myEnvironment.getARCHFamily() still returns x86. I'll use is64 methods. |
#6
|
||||
|
||||
Quote:
We use the generic CPU arch because -detecting the exact CPU arch is not always possible -it brings no advantages -you cannot use X86 or X64 alone to determine what application/bitness to use. You can have 32Bit CPU - 32Bit OS - 32Bit Java - can run 32bit exe only, can inlucde 32bit libs only 64Bit CPU - 32Bit OS - 32Bit Java - can run 32bit exe only, can include 32bit libs only 64Bit CPU - 64Bit OS - 32Bit Java - can run 32/64bit exe, can include 32bit libs only 64Bit CPU - 64Bit OS - 64Bit Java - can run 32/64bit exe, can inlucde 64bit libs only CPU arch helps to determine if you need to run a .exe or a elf binary .....or include a .dll or a .so ....
__________________
JD-Dev & Server-Admin Last edited by Jiaz; 24.10.2017 at 09:35. |
Thread Tools | |
Display Modes | |
|
|