Add extracted tools: CitrineOS, OpenOCPP, ShapeShifter
- CitrineOS core extracted (CSMS OCPP 2.0.1) - OpenOCPP extracted (firmware OCPP 1.6J/2.0.1) - ShapeShifter library installed (pip install -e) - ShapeShifter specification extracted - EVerest extracted TODO updated with progress
This commit is contained in:
235
tools/EVerest-main/MODULE.bazel
Normal file
235
tools/EVerest-main/MODULE.bazel
Normal file
@@ -0,0 +1,235 @@
|
||||
module(
|
||||
name = "everest-core",
|
||||
version = "2026.02.0",
|
||||
)
|
||||
|
||||
###############################################################################
|
||||
# B A Z E L C E N T R A L R E G I S T R Y # https://registry.bazel.build/
|
||||
###############################################################################
|
||||
|
||||
bazel_dep(name = "bazel_features", version = "1.21.0")
|
||||
bazel_dep(name = "bazel_skylib", version = "1.7.1")
|
||||
|
||||
BOOST_VERSION = "1.87.0"
|
||||
|
||||
bazel_dep(name = "boost.asio", version = BOOST_VERSION)
|
||||
bazel_dep(name = "boost.process", version = BOOST_VERSION)
|
||||
bazel_dep(name = "boost.uuid", version = BOOST_VERSION)
|
||||
bazel_dep(name = "boost.exception", version = BOOST_VERSION)
|
||||
bazel_dep(name = "boost.log", version = BOOST_VERSION)
|
||||
bazel_dep(name = "boost.utility", version = BOOST_VERSION)
|
||||
bazel_dep(name = "boost.program_options", version = BOOST_VERSION)
|
||||
bazel_dep(name = "catch2", version = "3.13.0")
|
||||
bazel_dep(name = "cxx.rs", version = "1.0.194")
|
||||
bazel_dep(name = "fast_float", version = "6.1.6")
|
||||
bazel_dep(name = "fmt", version = "12.1.0", repo_name = "com_github_fmtlib_fmt")
|
||||
bazel_dep(name = "googletest", version = "1.17.0.bcr.2")
|
||||
bazel_dep(name = "nlohmann_json", version = "3.12.0.bcr.1", repo_name = "com_github_nlohmann_json")
|
||||
bazel_dep(name = "libcap", version = "2.27.bcr.1")
|
||||
bazel_dep(name = "libevent", version = "2.1.12-stable.bcr.0")
|
||||
bazel_dep(name = "openssl", version = "3.3.1.bcr.9")
|
||||
bazel_dep(name = "platforms", version = "0.0.11")
|
||||
bazel_dep(name = "pugixml", version = "1.15")
|
||||
bazel_dep(name = "rapidyaml", version = "0.10.0")
|
||||
bazel_dep(name = "rules_cc", version = "0.2.14")
|
||||
bazel_dep(name = "rules_foreign_cc", version = "0.14.0")
|
||||
bazel_dep(name = "rules_license", version = "0.0.7")
|
||||
bazel_dep(name = "rules_python", version = "1.3.0")
|
||||
bazel_dep(name = "rules_rust", version = "0.67.0")
|
||||
bazel_dep(name = "rules_shell", version = "0.6.1")
|
||||
bazel_dep(name = "pybind11_bazel", version = "3.0.0")
|
||||
bazel_dep(name = "sqlite3", version = "3.51.2")
|
||||
|
||||
single_version_override(
|
||||
module_name = "boost.context",
|
||||
patches = ["//third-party/bazel/patches:boost.context.patch"],
|
||||
)
|
||||
|
||||
###############################################################################
|
||||
# C R O S S - C O M P I L A T I O N T O O L C H A I N S
|
||||
###############################################################################
|
||||
|
||||
# Module extension for cross-compilation toolchain repositories
|
||||
cross_toolchains = use_extension("//third-party/bazel/toolchains:extensions.bzl", "toolchains")
|
||||
use_repo(
|
||||
cross_toolchains,
|
||||
"cc_toolchain_aarch64-linux-gnu-x86_64-linux",
|
||||
"cc_toolchain_aarch64-linux-musl-x86_64-linux",
|
||||
"cc_toolchain_armv7-linux-gnu-x86_64-linux",
|
||||
"cc_toolchain_armv7-linux-musl-x86_64-linux",
|
||||
)
|
||||
|
||||
register_toolchains("@cc_toolchain_aarch64-linux-gnu-x86_64-linux//:aarch64-linux-glibc_toolchain_toolchain")
|
||||
|
||||
register_toolchains("@cc_toolchain_aarch64-linux-musl-x86_64-linux//:aarch64-linux-musl_toolchain_toolchain")
|
||||
|
||||
register_toolchains("@cc_toolchain_armv7-linux-musl-x86_64-linux//:armv7-linux-musl_toolchain_toolchain")
|
||||
|
||||
register_toolchains("@cc_toolchain_armv7-linux-gnu-x86_64-linux//:armv7-linux-gnu_toolchain_toolchain")
|
||||
|
||||
###############################################################################
|
||||
# N O N M O D U L E
|
||||
###############################################################################
|
||||
|
||||
deps = use_extension("//third-party/bazel:extension.bzl", "deps")
|
||||
use_repo(
|
||||
deps,
|
||||
"com_github_HowardHinnant_date",
|
||||
"com_github_pboettch_json-schema-validator",
|
||||
"com_github_warmcatt_libwebsockets",
|
||||
"mosquitto",
|
||||
"openssl_source",
|
||||
"pybind11_json",
|
||||
"sigslot",
|
||||
)
|
||||
|
||||
###############################################################################
|
||||
# P Y T H O N
|
||||
###############################################################################
|
||||
|
||||
python = use_extension("@rules_python//python/extensions:python.bzl", "python")
|
||||
python.toolchain(
|
||||
is_default = True,
|
||||
python_version = "3.10",
|
||||
)
|
||||
use_repo(python, "python_3_10")
|
||||
|
||||
pip_deps = use_extension("@rules_python//python/extensions:pip.bzl", "pip")
|
||||
pip_deps.parse(
|
||||
hub_name = "everest-testing_pip_deps",
|
||||
python_version = "3.10",
|
||||
requirements_lock = "//applications/utils:requirements-bazel.txt",
|
||||
)
|
||||
use_repo(pip_deps, "everest-testing_pip_deps")
|
||||
|
||||
###############################################################################
|
||||
# R U S T
|
||||
###############################################################################
|
||||
|
||||
RUST_EDITION = "2021"
|
||||
|
||||
RUST_VERSION = "1.86.0"
|
||||
|
||||
RUST_EXTRA_TARGET_TRIPLES = {
|
||||
"armv7-unknown-linux-musleabihf": [
|
||||
"@platforms//os:linux",
|
||||
"@platforms//cpu:armv7",
|
||||
"@everest-core//third-party/bazel/toolchains:musl",
|
||||
],
|
||||
"armv7-unknown-linux-gnueabihf": [
|
||||
"@platforms//os:linux",
|
||||
"@platforms//cpu:armv7",
|
||||
"@everest-core//third-party/bazel/toolchains:gnu",
|
||||
],
|
||||
"aarch64-unknown-linux-musl": [
|
||||
"@platforms//os:linux",
|
||||
"@platforms//cpu:aarch64",
|
||||
"@everest-core//third-party/bazel/toolchains:musl",
|
||||
],
|
||||
"aarch64-unknown-linux-gnu": [
|
||||
"@platforms//os:linux",
|
||||
"@platforms//cpu:aarch64",
|
||||
"@everest-core//third-party/bazel/toolchains:gnu",
|
||||
],
|
||||
}
|
||||
|
||||
rust = use_extension("@rules_rust//rust:extensions.bzl", "rust")
|
||||
rust.toolchain(
|
||||
edition = RUST_EDITION,
|
||||
versions = [
|
||||
RUST_VERSION,
|
||||
"nightly/2026-02-09",
|
||||
],
|
||||
)
|
||||
|
||||
[
|
||||
rust.repository_set(
|
||||
name = "rust_{}_repository_set_x86_64-unknown-linux-gnu".format(target_triple.replace("-", "_")),
|
||||
edition = RUST_EDITION,
|
||||
exec_triple = "x86_64-unknown-linux-gnu",
|
||||
target_compatible_with = target_compatible_with,
|
||||
target_triple = target_triple,
|
||||
versions = [RUST_VERSION],
|
||||
)
|
||||
for (target_triple, target_compatible_with) in RUST_EXTRA_TARGET_TRIPLES.items()
|
||||
]
|
||||
|
||||
use_repo(rust, "rust_toolchains")
|
||||
|
||||
register_toolchains("@rust_toolchains//:all")
|
||||
|
||||
everest_crate_index = use_extension("@rules_rust//crate_universe:extensions.bzl", "crate")
|
||||
everest_crate_index.from_cargo(
|
||||
name = "everest_crate_index",
|
||||
cargo_lockfile = "@everest-core//modules:Cargo.lock",
|
||||
manifests = [
|
||||
"@everest-core//modules:Cargo.toml",
|
||||
"@everest-core//modules/HardwareDrivers/PowerMeters/RsIskraMeter:Cargo.toml",
|
||||
"@everest-core//modules/HardwareDrivers/Payment/RsPaymentTerminal:Cargo.toml",
|
||||
"@everest-core//modules/Examples/RustExamples/RsExample:Cargo.toml",
|
||||
"@everest-core//modules/Examples/RustExamples/RsExampleUser:Cargo.toml",
|
||||
],
|
||||
supported_platform_triples = [
|
||||
"x86_64-unknown-linux-gnu",
|
||||
"aarch64-unknown-linux-gnu",
|
||||
"armv7-unknown-linux-gnueabihf",
|
||||
],
|
||||
)
|
||||
everest_crate_index.annotation(
|
||||
crate = "everestrs",
|
||||
crate_features = ["build_bazel"],
|
||||
repositories = ["everest_crate_index"],
|
||||
deps = [
|
||||
"//lib/everest/framework/everestrs/everestrs",
|
||||
"//lib/everest/framework/everestrs/everestrs-build",
|
||||
],
|
||||
)
|
||||
use_repo(
|
||||
everest_crate_index,
|
||||
"everest_crate_index",
|
||||
)
|
||||
|
||||
###############################################################################
|
||||
# F R A M E W O R K C R A T E I N D I C E S
|
||||
###############################################################################
|
||||
|
||||
everest_framework_crate_index = use_extension("@rules_rust//crate_universe:extensions.bzl", "crate")
|
||||
everest_framework_crate_index.from_cargo(
|
||||
name = "everest_framework_crate_index",
|
||||
cargo_lockfile = "//lib/everest/framework/everestrs:Cargo.lock",
|
||||
manifests = [
|
||||
"//lib/everest/framework/everestrs:Cargo.toml",
|
||||
"//lib/everest/framework/everestrs/everestrs:Cargo.toml",
|
||||
"//lib/everest/framework/everestrs/everestrs-build:Cargo.toml",
|
||||
"//lib/everest/framework/everestrs/everestrs-derive:Cargo.toml",
|
||||
],
|
||||
supported_platform_triples = [
|
||||
"x86_64-unknown-linux-gnu",
|
||||
"aarch64-unknown-linux-gnu",
|
||||
"armv7-unknown-linux-gnueabihf",
|
||||
],
|
||||
)
|
||||
|
||||
everest_crate_index.annotation(
|
||||
crate = "log",
|
||||
override_target_lib = "@everest_framework_crate_index//:log",
|
||||
repositories = ["everest_crate_index"],
|
||||
)
|
||||
|
||||
use_repo(
|
||||
everest_framework_crate_index,
|
||||
"everest_framework_crate_index",
|
||||
)
|
||||
|
||||
everest_framework_validate_crate_index = use_extension("@rules_rust//crate_universe:extensions.bzl", "crate")
|
||||
everest_framework_validate_crate_index.from_cargo(
|
||||
name = "everest_framework_validate_crate_index",
|
||||
cargo_lockfile = "//lib/everest/framework/bazel/validate:Cargo.lock",
|
||||
manifests = [
|
||||
"//lib/everest/framework/bazel/validate:Cargo.toml",
|
||||
],
|
||||
)
|
||||
use_repo(
|
||||
everest_framework_validate_crate_index,
|
||||
"everest_framework_validate_crate_index",
|
||||
)
|
||||
Reference in New Issue
Block a user