-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix!: add alias indirection for
gvm
toolchain
- fix: add `gvm` toolchain to toolchain config repo - fix: add aliases from `graalvm` → toolchain targets - fix: adjust instructions for registering toolchains - fix: adjust workspace toolchain registration logic Breaking change: When registering toolchains in a Bzlmod installation of these rules, the target `@graalvm//:all` must be changed to two toolchain registrations, based on the desired functionality: Register the Java toolchain: register_toolchains("@graalvm//:jvm") Register the GVM toolchain: register_toolchains("@graalvm//:sdk") Fixes and closes #66. Relates-To: #66 Signed-off-by: Sam Gammon <[email protected]>
- Loading branch information
Showing
23 changed files
with
1,140 additions
and
58 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
# Nothing at thie time. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
7.0.0-pre.20230816.3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
bazel-* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
workspace(name = "rules_graalvm_sample") | ||
|
||
local_repository( | ||
name = "rules_graalvm", | ||
path = "../../..", | ||
) | ||
|
||
load("@rules_graalvm//graalvm:workspace.bzl", "rules_graalvm_repositories") | ||
|
||
rules_graalvm_repositories() | ||
|
||
load("@rules_graalvm//graalvm:repositories.bzl", "graalvm_repository") | ||
|
||
graalvm_repository( | ||
name = "graalvm", | ||
distribution = "ce", | ||
java_version = "20", | ||
version = "20.0.2", | ||
) |
17 changes: 17 additions & 0 deletions
17
example/integration_tests/inert-workspace/sample/BUILD.bazel
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
java_library( | ||
name = "java", | ||
srcs = ["Main.java"], | ||
) | ||
|
||
java_binary( | ||
name = "main", | ||
main_class = "Main", | ||
runtime_deps = [ | ||
":java", | ||
], | ||
) | ||
|
||
alias( | ||
name = "sample", | ||
actual = "main", | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
public class Main { | ||
public static void main(String args[]) { | ||
System.out.println("Hello, GraalVM!"); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
build --enable_bzlmod |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
7.0.0-pre.20230816.3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
"Sample bzlmod-style project which uses the GraalVM Rules for Bazel." | ||
|
||
module( | ||
name = "rules_graalvm_bzlmod_sample", | ||
version = "0.0.1", | ||
) | ||
|
||
bazel_dep( | ||
name = "rules_java", | ||
version = "6.5.0", | ||
) | ||
bazel_dep( | ||
name = "rules_graalvm", | ||
version = "0.0.0", | ||
) | ||
local_path_override( | ||
module_name = "rules_graalvm", | ||
path = "../../..", | ||
) | ||
|
||
gvm = use_extension("@rules_graalvm//:extensions.bzl", "graalvm") | ||
gvm.graalvm( | ||
name = "graalvm", | ||
distribution = "ce", | ||
java_version = "20", | ||
version = "20.0.2", | ||
) |
Oops, something went wrong.