aboutsummaryrefslogtreecommitdiff
path: root/docs/markdown/Dependencies.md
diff options
context:
space:
mode:
Diffstat (limited to 'docs/markdown/Dependencies.md')
-rw-r--r--docs/markdown/Dependencies.md17
1 files changed, 14 insertions, 3 deletions
diff --git a/docs/markdown/Dependencies.md b/docs/markdown/Dependencies.md
index a7e34e5..8165955 100644
--- a/docs/markdown/Dependencies.md
+++ b/docs/markdown/Dependencies.md
@@ -494,23 +494,34 @@ Deprecated name for JNI. `dependency('jdk')` instead of `dependency('jni')`.
*(added 0.62.0)*
+`modules` is an optional list of strings containing any of `jvm` and `awt`.
+
Provides access to compiling with the Java Native Interface (JNI). The lookup
will first check if `JAVA_HOME` is set in the environment, and if not will use
the resolved path of `javac`. Systems will usually link your preferred JDK to
well known paths like `/usr/bin/javac` on Linux for instance. Using the path
from `JAVA_HOME` or the resolved `javac`, this dependency will place the JDK
installation's `include` directory and its platform-dependent subdirectory on
-the compiler's include path.
+the compiler's include path. If `modules` is non-empty, then the proper linker
+arguments will also be added.
```meson
-dep = dependency('jni', version: '>= 1.8.0')
+dep = dependency('jni', version: '>= 1.8.0', modules: ['jvm'])
```
**Note**: Due to usage of a resolved path, upgrading the JDK may cause the
-various headers to not be found. In that case, please reconfigure the build
+various paths to not be found. In that case, please reconfigure the build
directory. One workaround is to explicitly set `JAVA_HOME` instead of relying on
the fallback `javac` resolved path behavior.
+**Note**: Include paths might be broken on platforms other than `linux`,
+`windows`, `darwin`, and `sunos`. Please submit a PR or open an issue in this
+case.
+
+**Note**: Use of the `modules` argument on a JDK `<= 1.8` may be broken if your
+system is anything other than `x86_64`. Please submit a PR or open an issue in
+this case.
+
## libgcrypt
*(added 0.49.0)*