Skip to content

Commit cd68dd6

Browse files
LesiaChabanolyagpl
authored andcommitted
Replace GRAALVM_HOME with JAVA_HOME in graal/docs
1 parent 216a9dc commit cd68dd6

File tree

14 files changed

+57
-57
lines changed

14 files changed

+57
-57
lines changed

docs/getting-started/graalvm-community/get-started-graalvm-community.md

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ Further below you will find information on how to add other optionally available
4242
The `java` launcher runs the JVM with the GraalVM default compiler - Graal.
4343
Check the Java version upon the installation:
4444
```shell
45-
$GRAALVM_HOME/bin/java -version
45+
$JAVA_HOME/bin/java -version
4646
```
4747

4848
Take a look at this typical `HelloWorld` class:
@@ -74,10 +74,10 @@ The JavaScript runtime is optionally available and can be installed with this co
7474
gu install js
7575
```
7676

77-
It installs the `js` launcher in the `$GRAALVM_HOME/bin` directory.
77+
It installs the `js` launcher in the `$JAVA_HOME/bin` directory.
7878
With the JavaScript runtime installed, you can execute plain JavaScript code, both in REPL mode and by executing script files directly:
7979
```shell
80-
$GRAALVM_HOME/bin/js
80+
$JAVA_HOME/bin/js
8181
> 1 + 2
8282
3
8383
```
@@ -88,21 +88,21 @@ The Node.js support is not installed by default, but can be easily added with th
8888
gu install nodejs
8989
```
9090

91-
Both `node` and `npm` launchers then become available in the `$GRAALVM_HOME/bin` directory.
91+
Both `node` and `npm` launchers then become available in the `$JAVA_HOME/bin` directory.
9292

9393
```shell
94-
$GRAALVM_HOME/bin/node -v
95-
$GRAALVM_HOME/bin/npm show <package name> version
94+
$JAVA_HOME/bin/node -v
95+
$JAVA_HOME/bin/npm show <package name> version
9696
```
9797

9898
More than 100,000 npm packages are regularly tested and are compatible with GraalVM, including modules like express, react, async, request, browserify, grunt, mocha, and underscore.
99-
To install a Node.js module, use the `npm` executable from `$GRAALVM_HOME/bin`, which is installed together with `node`.
99+
To install a Node.js module, use the `npm` executable from `$JAVA_HOME/bin`, which is installed together with `node`.
100100
The `npm` command is equivalent to the default Node.js command and supports all Node.js APIs.
101101

102102
Install the modules `colors`, `ansispan`, and `express` using `npm install`.
103103
After the modules are installed, you can use them from your application.
104104
```shell
105-
$GRAALVM_HOME/bin/npm install colors ansispan express
105+
$JAVA_HOME/bin/npm install colors ansispan express
106106
```
107107

108108
Use the following code snippet and save it as the `app.js` file in the same directory where you installed the Node.js modules:
@@ -121,7 +121,7 @@ setTimeout(function() { console.log("DONE!"); process.exit(); }, 2000);
121121

122122
Run _app.js_ on GraalVM Enterprise using the `node` command:
123123
```shell
124-
$GRAALVM_HOME/bin/node app.js
124+
$JAVA_HOME/bin/node app.js
125125
```
126126

127127
For more detailed documentation and information on compatibility with Node.js, proceed to [JavaScript and Node.js](../../reference-manual/js/README.md).
@@ -132,14 +132,14 @@ The GraalVM LLVM runtime can execute C/C++, Rust, and other programming language
132132

133133
The LLVM runtime is optionally available and can be installed with this command:
134134
```shell
135-
$GRAALVM_HOME/bin/gu install llvm
135+
$JAVA_HOME/bin/gu install llvm
136136
```
137137

138-
It installs the GraalVM implementation of `lli` in the `$GRAALVM_HOME/bin` directory.
138+
It installs the GraalVM implementation of `lli` in the `$JAVA_HOME/bin` directory.
139139
Check the version upon the installation:
140140

141141
```shell
142-
$GRAALVM_HOME/bin/lli --version
142+
$JAVA_HOME/bin/lli --version
143143
```
144144

145145
With the LLVM runtime installed, you can execute programs in LLVM bitcode format on GraalVM.
@@ -181,11 +181,11 @@ gu install python
181181

182182
It installs the `graalpy` launcher. Check the version, and you can already run Python programs:
183183
```shell
184-
$GRAALVM_HOME/bin/graalpy --version
184+
$JAVA_HOME/bin/graalpy --version
185185
```
186186

187187
```shell
188-
$GRAALVM_HOME/bin/graalpy
188+
$JAVA_HOME/bin/graalpy
189189
...
190190
>>> 1 + 2
191191
3
@@ -204,14 +204,14 @@ gu install ruby
204204

205205
Once it is installed, Ruby launchers like `ruby`, `gem`, `irb`, `rake`, `rdoc`, and `ri` become available to run Ruby programs:
206206
```shell
207-
$GRAALVM_HOME/bin/ruby [options] program.rb
207+
$JAVA_HOME/bin/ruby [options] program.rb
208208
```
209209

210210
GraalVM runtime for Ruby uses the [same options as the standard implementation of Ruby](../../reference-manual/ruby/options.md), with some additions.
211211
For example:
212212
```shell
213213
gem install chunky_png
214-
$GRAALVM_HOME/bin/ruby -r chunky_png -e "puts ChunkyPNG::Color.to_hex(ChunkyPNG::Color('mintcream @ 0.5'))"
214+
$JAVA_HOME/bin/ruby -r chunky_png -e "puts ChunkyPNG::Color.to_hex(ChunkyPNG::Color('mintcream @ 0.5'))"
215215
#f5fffa80
216216
```
217217

@@ -227,7 +227,7 @@ gu install R
227227

228228
When the language is installed, you can execute R scripts and use the R REPL:
229229
```shell
230-
$GRAALVM_HOME/bin/R
230+
$JAVA_HOME/bin/R
231231
...
232232

233233
> 1 + 1
@@ -270,7 +270,7 @@ emcc -o floyd.wasm floyd.c
270270

271271
Then you can run the compiled WebAssembly binary on GraalVM as follows:
272272
```shell
273-
$GRAALVM_HOME/bin/wasm --Builtins=wasi_snapshot_preview1 floyd.wasm
273+
$JAVA_HOME/bin/wasm --Builtins=wasi_snapshot_preview1 floyd.wasm
274274
```
275275

276276
More details can be found in the [WebAssembly reference manual](../../reference-manual/wasm/README.md).

docs/getting-started/graalvm-enterprise/get-started-graalvm-enterprise.md

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ Further below you will find information on how to add other optionally available
4949
The `java` launcher runs the JVM with the GraalVM default compiler - Graal.
5050
Check the Java version upon the installation:
5151
```shell
52-
$GRAALVM_HOME/bin/java -version
52+
$JAVA_HOME/bin/java -version
5353
```
5454

5555
Take a look at this typical `HelloWorld` class:
@@ -80,10 +80,10 @@ The JavaScript runtime is optionally available and can be installed with this co
8080
gu install js
8181
```
8282

83-
It installs the `js` launcher in the `$GRAALVM_HOME/bin` directory.
83+
It installs the `js` launcher in the `$JAVA_HOME/bin` directory.
8484
With the JavaScript runtime installed, you can execute plain JavaScript code, both in REPL mode and by executing script files directly:
8585
```shell
86-
$GRAALVM_HOME/bin/js
86+
$JAVA_HOME/bin/js
8787
> 1 + 2
8888
3
8989
```
@@ -94,11 +94,11 @@ The Node.js support is not installed by default, but can be easily added with th
9494
gu install nodejs
9595
```
9696

97-
Both `node` and `npm` launchers then become available in the `$GRAALVM_HOME/bin` directory.
97+
Both `node` and `npm` launchers then become available in the `$JAVA_HOME/bin` directory.
9898

9999
```shell
100-
$GRAALVM_HOME/bin/node -v
101-
$GRAALVM_HOME/bin/npm show <package name> version
100+
$JAVA_HOME/bin/node -v
101+
$JAVA_HOME/bin/npm show <package name> version
102102
```
103103

104104
More than 100,000 npm packages are regularly tested and are compatible with GraalVM Enterprise, including modules like express, react, async, request, browserify, grunt, mocha, and underscore.
@@ -108,7 +108,7 @@ The `npm` command is equivalent to the default Node.js command and supports all
108108
Install the modules `colors`, `ansispan`, and `express` using `npm install`.
109109
After the modules are installed, you can use them from your application.
110110
```shell
111-
$GRAALVM_HOME/bin/npm install colors ansispan express
111+
$JAVA_HOME/bin/npm install colors ansispan express
112112
```
113113

114114
Use the following code snippet and save it as the `app.js` file in the same directory where you installed the Node.js modules:
@@ -138,14 +138,14 @@ The GraalVM LLVM runtime can execute C/C++, Rust, and other programming language
138138

139139
The LLVM runtime is optionally available and can be installed with this command:
140140
```shell
141-
$GRAALVM_HOME/bin/gu install llvm
141+
$JAVA_HOME/bin/gu install llvm
142142
```
143143

144-
It installs the GraalVM implementation of `lli` in the `$GRAALVM_HOME/bin` directory.
144+
It installs the GraalVM implementation of `lli` in the `$JAVA_HOME/bin` directory.
145145
Check the version upon the installation:
146146

147147
```shell
148-
$GRAALVM_HOME/bin/lli --version
148+
$JAVA_HOME/bin/lli --version
149149
```
150150

151151
With the LLVM runtime installed, you can execute programs in LLVM bitcode format on GraalVM.
@@ -187,11 +187,11 @@ gu install python
187187

188188
It installs the `graalpy` launcher. Check the version, and you can already run Python programs:
189189
```shell
190-
$GRAALVM_HOME/bin/graalpy --version
190+
$JAVA_HOME/bin/graalpy --version
191191
```
192192

193193
```shell
194-
$GRAALVM_HOME/bin/graalpy
194+
$JAVA_HOME/bin/graalpy
195195
...
196196
>>> 1 + 2
197197
3
@@ -210,14 +210,14 @@ gu install ruby
210210

211211
Once it is installed, Ruby launchers like `ruby`, `gem`, `irb`, `rake`, `rdoc`, and `ri` become available to run Ruby programs:
212212
```shell
213-
$GRAALVM_HOME/bin/ruby [options] program.rb
213+
$JAVA_HOME/bin/ruby [options] program.rb
214214
```
215215

216216
GraalVM runtime for Ruby uses the [same options as the standard implementation of Ruby](../../reference-manual/ruby/options.md), with some additions.
217217
For example:
218218
```shell
219219
gem install chunky_png
220-
$GRAALVM_HOME/bin/ruby -r chunky_png -e "puts ChunkyPNG::Color.to_hex(ChunkyPNG::Color('mintcream @ 0.5'))"
220+
$JAVA_HOME/bin/ruby -r chunky_png -e "puts ChunkyPNG::Color.to_hex(ChunkyPNG::Color('mintcream @ 0.5'))"
221221
#f5fffa80
222222
```
223223

@@ -233,7 +233,7 @@ gu install R
233233

234234
When the language is installed, you can execute R scripts and use the R REPL:
235235
```shell
236-
$GRAALVM_HOME/bin/R
236+
$JAVA_HOME/bin/R
237237
...
238238

239239
> 1 + 1
@@ -278,7 +278,7 @@ emcc -o floyd.wasm floyd.c
278278

279279
Then you can run the compiled WebAssembly binary on GraalVM as follows:
280280
```shell
281-
$GRAALVM_HOME/bin/wasm --Builtins=wasi_snapshot_preview1 floyd.wasm
281+
$JAVA_HOME/bin/wasm --Builtins=wasi_snapshot_preview1 floyd.wasm
282282
```
283283

284284
More details can be found in the [WebAssembly reference manual](../../reference-manual/wasm/README.md).

docs/reference-manual/embedding/embed-languages.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -401,11 +401,11 @@ native-image --language:python -cp . HelloPolyglot
401401
./hellopolyglot
402402
```
403403

404-
In case an installed GraalVM is available, it is possible to use language homes from the GraalVM home directory. A GraalVM home can be specified at runtime using the option `-Dorg.graalvm.home=$GRAALVM_HOME`, assuming the environment variable `GRAALVM_HOME` is populated with an absolute path to the GraalVM home directory.
404+
In case an installed GraalVM is available, it is possible to use language homes from the GraalVM home directory. A GraalVM home can be specified at runtime using the option `-Dorg.graalvm.home=$JAVA_HOME`, assuming the environment variable `JAVA_HOME` is populated with an absolute path to the GraalVM home directory.
405405
Language homes are automatically discovered in the specified directory. For example:
406406

407407
```shell
408-
./hellopolyglot -Dorg.graalvm.home=$GRAALVM_HOME
408+
./hellopolyglot -Dorg.graalvm.home=$JAVA_HOME
409409
```
410410

411411
> Note: The `-Dorg.graalvm.home` option has precedence over any relative language home paths stored in the image.

docs/reference-manual/java-on-truffle/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ Having downloaded the appropriate JAR file in consideration of the operating sys
4444
gu install -L espresso.jar
4545
```
4646

47-
It installs the `jvm` runtime library under the `GRAALVM_HOME/lib/truffle/` location.
47+
It installs the `jvm` runtime library under the `$JAVA_HOME/lib/truffle/` location.
4848

4949
## Run Java on Truffle
5050

docs/reference-manual/llvm/Compiling.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ for building native projects such as a linker (`ld`), or an archiver (`ar`) for
3232

3333
The LLVM toolchain can be added to GraalVM on demand with the [GraalVM Updater](../graalvm-updater.md) tool:
3434
```shell
35-
$GRAALVM_HOME/bin/gu install llvm-toolchain
35+
$JAVA_HOME/bin/gu install llvm-toolchain
3636
```
3737

3838
The above command will install the LLVM toolchain from the GitHub catalog for GraalVM Community users.

docs/reference-manual/llvm/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,10 @@ This allows seamless interoperability with the dynamic languages supported by Gr
1717
Since GraalVM 22.2, the LLVM runtime is packaged in a separate GraalVM component. It can be installed with GraalVM Updater:
1818

1919
```shell
20-
$GRAALVM_HOME/bin/gu install llvm
20+
$JAVA_HOME/bin/gu install llvm
2121
```
2222

23-
This installs GraalVM's implementation of `lli` in the `$GRAALVM_HOME/bin` directory.
23+
This installs GraalVM's implementation of `lli` in the `$JAVA_HOME/bin` directory.
2424
With the LLVM runtime installed, you can execute programs in LLVM bitcode format on GraalVM.
2525

2626
Additionally to installing the LLVM runtime, you can add the LLVM toolchain:

docs/reference-manual/native-image/InspectTool.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,10 @@ redirect_from: /$version/reference-manual/native-image/inspect/
99
# Native Image Inspection Tool
1010

1111
Native Image Enterprise Edition includes a tool to list the methods included in an executable or shared library created by GraalVM Native Image.
12-
The tool is available as the command `$GRAALVM_HOME/bin/native-image-inspect <path_to_binary>`. It lists methods as a JSON array in the following format:
12+
The tool is available as the command `$JAVA_HOME/bin/native-image-inspect <path_to_binary>`. It lists methods as a JSON array in the following format:
1313

1414
```shell
15-
$GRAALVM_HOME/bin/native-image-inspect helloworld
15+
$JAVA_HOME/bin/native-image-inspect helloworld
1616
{
1717
"methods": [
1818
{
@@ -52,7 +52,7 @@ The SBOM is also compressed in order to limit the SBOM's impact on the native ex
5252
Even though the tool is not yet supported on Windows, Windows users can still embed the SBOM with this experimental option.
5353
The SBOM is stored in the `gzip` format with the exported `sbom` symbol referencing its start address and the `sbom_length` symbol its size.
5454

55-
After embedding the compressed SBOM into the executable, the tool is able to extract the compressed SBOM using an optional `--sbom` parameter accessible through `$GRAALVM_HOME/bin/native-image-inspect --sbom <path_to_binary>` and outputs the SBOM in the following format:
55+
After embedding the compressed SBOM into the executable, the tool is able to extract the compressed SBOM using an optional `--sbom` parameter accessible through `$JAVA_HOME/bin/native-image-inspect --sbom <path_to_binary>` and outputs the SBOM in the following format:
5656

5757
```json
5858
{
@@ -91,7 +91,7 @@ The tool can extract the SBOM from both executables and shared libraries.
9191
To scan for any vulnerable libraries, submit the SBOM to a vulnerability scanner.
9292
For example, the popular [Anchore software supply chain management platform](https://anchore.com/) makes the `grype` scanner freely available.
9393
You can check whether the libraries given in your SBOMs have known vulnerabilities documented in Anchore's database.
94-
For this purpose, the output of the tool can be fed directly to the `grype` scanner to check for vulnerable libraries, using the command `$GRAALVM_HOME/bin/native-image-inspect --sbom <path_to_binary> | grype` which produces the following output:
94+
For this purpose, the output of the tool can be fed directly to the `grype` scanner to check for vulnerable libraries, using the command `$JAVA_HOME/bin/native-image-inspect --sbom <path_to_binary> | grype` which produces the following output:
9595
```shell
9696
NAME INSTALLED VULNERABILITY SEVERITY
9797
netty-codec-http2 4.1.76.Final CVE-2022-24823 Medium

docs/reference-manual/native-image/JNIInvocationAPI.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ The second parameter is a reference to the `jclass` value for the class declarin
3737
The third parameter is a portable (e.g., `long`) identifier of the [Native Image isolatethread](C-API.md).
3838
The rest of the parameters are the actual parameters of the Java `Native.add` method described in the next section. Compile the code with the `--shared` option:
3939
```shell
40-
$GRAALVM/bin/native-image --shared -H:Name=libnativeimpl -cp nativeimpl
40+
$JAVA_HOME/bin/native-image --shared -H:Name=libnativeimpl -cp nativeimpl
4141
```
4242
The `libnativeimpl.so` is generated. We are ready to use it from standard Java code.
4343

docs/reference-manual/native-image/guides/build-native-shared-library.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -73,11 +73,11 @@ The C application takes a string as its argument, passes it to the shared librar
7373
7474
#### Prerequisites
7575
76-
You have set the `GRAALVM_HOME` environment variable to the location of the GraalVM installation.
76+
You have set the `JAVA_HOME` environment variable to the location of the GraalVM installation.
7777
7878
You have have installed LLVM toolchain support to GraalVM, as follows:
7979
```shell
80-
$GRAALVM_HOME/bin/gu install llvm-toolchain
80+
$JAVA_HOME/bin/gu install llvm-toolchain
8181
```
8282

8383
>Note: The llvm-toolchain GraalVM component is not available on Microsoft Windows.
@@ -115,8 +115,8 @@ $GRAALVM_HOME/bin/gu install llvm-toolchain
115115
2. Compile the Java code and build a native shared library, as follows:
116116

117117
```shell
118-
$GRAALVM_HOME/bin/javac LibEnvMap.java
119-
$GRAALVM_HOME/bin/native-image -H:Name=libenvmap --shared
118+
$JAVA_HOME/bin/javac LibEnvMap.java
119+
$JAVA_HOME/bin/native-image -H:Name=libenvmap --shared
120120
```
121121

122122
It will produce the following artifacts:
@@ -168,7 +168,7 @@ $GRAALVM_HOME/bin/gu install llvm-toolchain
168168
5. Compile the C application using `clang`.
169169

170170
```shell
171-
$GRAALVM_HOME/languages/llvm/native/bin/clang -I ./ -L ./ -l envmap -Wl,-rpath ./ -o main main.c
171+
$JAVA_HOME/languages/llvm/native/bin/clang -I ./ -L ./ -l envmap -Wl,-rpath ./ -o main main.c
172172
```
173173

174174
6. Run the C application by passing a string as an argument. For example:

docs/reference-manual/native-image/guides/create-heap-dump-from-native-executable.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ This can be useful to identify which objects the Native Image build process allo
3737
For a HelloWorld example, use the option as follows:
3838

3939
```shell
40-
$GRAALVM_HOME/bin/native-image HelloWorld --enable-monitoring=heapdump
40+
$JAVA_HOME/bin/native-image HelloWorld --enable-monitoring=heapdump
4141
./helloworld -XX:+DumpHeapAndExit
4242
Heap dump created at '/path/to/helloworld.hprof'.
4343
```

docs/tools/visualvm.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,11 @@ VisualVM is shipped as an installable component and can be added to GraalVM usin
2323
gu install visualvm
2424
```
2525

26-
This installs VisualVM in the `$GRAALVM_HOME/bin` directory.
26+
This installs VisualVM in the `$JAVA_HOME/bin` directory.
2727
To start VisualVM, execute `jvisualvm`:
2828

2929
```shell
30-
$GRAALVM_HOME/bin/jvisualvm
30+
$JAVA_HOME/bin/jvisualvm
3131
```
3232
Immediately after startup, the tool shows all locally running Java processes in the Applications area, including the VisualVM process, itself.
3333

@@ -73,7 +73,7 @@ JFR is a tool for collecting diagnostic and profiling data about a running Java
7373
It is integrated into the Java Virtual Machine (JVM) and causes almost no performance overhead, so it can be used even in heavily loaded production environments.
7474

7575
To install the JFR support, released as a plugin:
76-
1. Run `<GRAALVM_HOME>/bin/jvisualvm` to start VisualVM;
76+
1. Run `$JAVA_HOME/bin/jvisualvm` to start VisualVM;
7777
2. Navigate to Tools > Plugins > Available Plugins to list all available plugins, then install the _VisualVM-JFR_ and
7878
_VisualVM-JFR-Generic_ modules.
7979

sulong/docs/contributor/INTEROP.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ GraalVM LLVM runtime. The [last section](./INTEROP.md#interoperability-and-stati
88

99
Detailed reference documentation of Polyglot interop support in the GraalVM LLVM
1010
runtime can be found in [`graalvm/llvm/polyglot.h`](../../projects/com.oracle.truffle.llvm.libraries.graalvm.llvm/include/graalvm/llvm/polyglot.h)
11-
(located in `$GRAALVM_HOME/jre/languages/llvm/include/graalvm/llvm/polyglot.h` in the GraalVM
11+
(located in `$JAVA_HOME/jre/languages/llvm/include/graalvm/llvm/polyglot.h` in the GraalVM
1212
distribution).
1313

1414
To use the functions from `graalvm/llvm/*` headers, binaries have to link against `-lgraalvm-llvm`.

0 commit comments

Comments
 (0)