Skip to content

Commit

Permalink
Publish sgammon/[email protected] (#915)
Browse files Browse the repository at this point in the history
Co-authored-by: Sam Gammon <[email protected]>
  • Loading branch information
publish-to-bcr-bot[bot] and sgammon authored Sep 11, 2023
1 parent 201a910 commit 98e4c7d
Show file tree
Hide file tree
Showing 4 changed files with 274 additions and 1 deletion.
256 changes: 256 additions & 0 deletions modules/rules_graalvm/0.10.2/MODULE.bazel
Original file line number Diff line number Diff line change
@@ -0,0 +1,256 @@
"GraalVM Rules for Bazel"

module(
name = "rules_graalvm",
version = "0.10.2",
)

JAVA_VERSION = "20"

PYTHON_VERSION = "3.11"

NODE_VERSION = "20.5.0"

GRAALVM_VERSION = "20.0.2"

GRAALVM_DIST = "ce"

GRAALVM_SDK_VERSION = "23.0.1"

GRAALVM_COMPONENTS = [
"wasm",
"js",
]

##
## Dependencies: API
##

bazel_dep(
name = "platforms",
version = "0.0.7",
)
bazel_dep(
name = "bazel_features",
version = "1.0.0",
)
bazel_dep(
name = "rules_java",
version = "6.4.0",
)
bazel_dep(
name = "bazel_skylib",
version = "1.4.2",
)
bazel_dep(
name = "apple_support",
version = "1.8.1",
repo_name = "build_bazel_apple_support",
)

##
## Dependencies: Development
##

bazel_dep(
name = "rules_license",
version = "0.0.7",
dev_dependency = True,
)
bazel_dep(
name = "rules_cc",
version = "0.0.8",
dev_dependency = True,
)
bazel_dep(
name = "rules_python",
version = "0.25.0",
dev_dependency = True,
)
bazel_dep(
name = "rules_testing",
version = "0.4.0",
dev_dependency = True,
)
bazel_dep(
name = "aspect_bazel_lib",
version = "1.34.1",
dev_dependency = True,
)
bazel_dep(
name = "aspect_rules_js",
version = "1.32.0",
dev_dependency = True,
)
bazel_dep(
name = "rules_nodejs",
version = "6.0.1",
dev_dependency = True,
)
bazel_dep(
name = "protobuf",
version = "21.7",
dev_dependency = True,
repo_name = "com_google_protobuf",
)
bazel_dep(
name = "rules_go",
version = "0.41.0",
dev_dependency = True,
repo_name = "io_bazel_rules_go",
)
bazel_dep(
name = "gazelle",
version = "0.32.0",
dev_dependency = True,
repo_name = "bazel_gazelle",
)
bazel_dep(
name = "rules_jvm_external",
version = "5.3",
dev_dependency = True,
)
bazel_dep(
name = "stardoc",
version = "0.6.2",
dev_dependency = True,
repo_name = "io_bazel_stardoc",
)
bazel_dep(
name = "bazel_skylib_gazelle_plugin",
version = "1.4.2",
dev_dependency = True,
)
bazel_dep(
name = "contrib_rules_jvm",
version = "0.18.0",
dev_dependency = True,
)
bazel_dep(
name = "apple_rules_lint",
version = "0.3.2",
dev_dependency = True,
)
bazel_dep(
name = "buildifier_prebuilt",
version = "6.3.3",
dev_dependency = True,
)

################################################################################
# rules_jvm_external
################################################################################

MAVEN_ARTIFACTS = [
"org.graalvm.nativeimage:svm:%s" % GRAALVM_SDK_VERSION,
"org.graalvm.sdk:graal-sdk:%s" % GRAALVM_SDK_VERSION,
]

MAVEN_REPOSITORIES = [
"https://maven.pkg.st",
"https://maven.google.com",
"https://repo1.maven.org/maven2",
]

maven = use_extension(
"@rules_jvm_external//:extensions.bzl",
"maven",
dev_dependency = True,
)
maven.install(
name = "maven_gvm",
artifacts = MAVEN_ARTIFACTS,
lock_file = "//:maven_install.json",
repositories = MAVEN_REPOSITORIES,
)
use_repo(
maven,
"maven_gvm",
"unpinned_maven_gvm",
)

################################################################################
# rules_graalvm
################################################################################

gvm = use_extension(
":extensions.bzl",
"graalvm",
dev_dependency = True,
)
gvm.graalvm(
name = "graalvm",
components = GRAALVM_COMPONENTS,
distribution = GRAALVM_DIST,
java_version = JAVA_VERSION,
version = GRAALVM_VERSION,
)
use_repo(
gvm,
"graalvm",
)

register_toolchains(
"@graalvm//:jvm",
dev_dependency = True,
)

register_toolchains(
"@graalvm//:sdk",
dev_dependency = True,
)

################################################################################
# rules_python
################################################################################

python = use_extension(
"@rules_python//python/extensions:python.bzl",
"python",
dev_dependency = True,
)
python.toolchain(
configure_coverage_tool = True,
is_default = True,
python_version = PYTHON_VERSION,
)
use_repo(python, "python_3_11", "python_versions")

pip = use_extension(
"@rules_python//python/extensions:pip.bzl",
"pip",
dev_dependency = True,
)
pip.parse(
extra_pip_args = [
"--no-binary",
"grequests",
],
hub_name = "pip",
python_version = PYTHON_VERSION,
requirements_lock = "@//:requirements_lock.txt",
)
use_repo(pip, "pip", "pip_311")

################################################################################
# rules_js
################################################################################

node = use_extension(
"@rules_nodejs//nodejs:extensions.bzl",
"node",
dev_dependency = True,
)
node.toolchain(node_version = NODE_VERSION)

npm = use_extension(
"@aspect_rules_js//npm:extensions.bzl",
"npm",
dev_dependency = True,
)
npm.npm_translate_lock(
name = "npm",
pnpm_lock = "//:pnpm-lock.yaml",
verify_node_modules_ignored = "//:.bazelignore",
)
use_repo(npm, "npm")
11 changes: 11 additions & 0 deletions modules/rules_graalvm/0.10.2/presubmit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
bcr_test_module:
module_path: "example/integration_tests/bzlmod"
matrix:
platform: ["debian10", "macos", "ubuntu2004"]
tasks:
build_bzlmod_test:
name: "Build test module"
platform: ${{ platform }}
build_targets:
- "//sample"
5 changes: 5 additions & 0 deletions modules/rules_graalvm/0.10.2/source.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"integrity": "sha256-strXMaxE6hIvKVuig/mUl0TF8QGArts2+cdwi3NPElA=",
"strip_prefix": "rules_graalvm-0.10.2",
"url": "https://github.com/sgammon/rules_graalvm/releases/download/v0.10.2/rules_graalvm-0.10.2.zip"
}
3 changes: 2 additions & 1 deletion modules/rules_graalvm/metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
],
"versions": [
"0.10.0",
"0.10.1"
"0.10.1",
"0.10.2"
],
"yanked_versions": {}
}

0 comments on commit 98e4c7d

Please sign in to comment.