mirror of
https://github.com/Z3Prover/z3
synced 2025-04-06 17:44:08 +00:00
Allow to skip System.loadLibrary() calls from Java Native class (#4667)
This commit is contained in:
parent
6706b0dfcd
commit
7f0b5bc129
|
@ -542,8 +542,13 @@ def mk_java(java_dir, package_name):
|
|||
java_native.write(' public static native void setInternalErrorHandler(long ctx);\n\n')
|
||||
|
||||
java_native.write(' static {\n')
|
||||
java_native.write(' try { System.loadLibrary("z3java"); }\n')
|
||||
java_native.write(' catch (UnsatisfiedLinkError ex) { System.loadLibrary("libz3java"); }\n')
|
||||
java_native.write(' if (null == System.getProperty("z3.skipLibraryLoad")) {\n')
|
||||
java_native.write(' try {\n')
|
||||
java_native.write(' System.loadLibrary("z3java");\n')
|
||||
java_native.write(' } catch (UnsatisfiedLinkError ex) {\n')
|
||||
java_native.write(' System.loadLibrary("libz3java");\n')
|
||||
java_native.write(' }\n')
|
||||
java_native.write(' }\n')
|
||||
java_native.write(' }\n')
|
||||
|
||||
java_native.write('\n')
|
||||
|
|
Loading…
Reference in a new issue