Skip to content

Commit c254860

Browse files
Update modules
1 parent a9f6f8f commit c254860

File tree

8 files changed

+713
-0
lines changed

8 files changed

+713
-0
lines changed
Lines changed: 312 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,312 @@
1+
# *******************************************************************************
2+
# Copyright (c) 2024-2026 Contributors to the Eclipse Foundation
3+
#
4+
# See the NOTICE file(s) distributed with this work for additional
5+
# information regarding copyright ownership.
6+
#
7+
# This program and the accompanying materials are made available under the
8+
# terms of the Apache License Version 2.0 which is available at
9+
# https://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# SPDX-License-Identifier: Apache-2.0
12+
# *******************************************************************************
13+
module(name = "score_communication")
14+
15+
bazel_dep(name = "platforms", version = "0.1.4")
16+
17+
bazel_dep(name = "gcc_toolchain", version = "0.9.0", dev_dependency = True)
18+
19+
gcc_toolchains = use_extension("@gcc_toolchain//toolchain:module_extensions.bzl", "gcc_toolchains", dev_dependency = True)
20+
gcc_toolchains.toolchain(
21+
name = "gcc_toolchain_x86_64",
22+
extra_ldflags = [
23+
"-lstdc++",
24+
"-lrt",
25+
"-latomic",
26+
],
27+
gcc_version = "15.2.0",
28+
target_arch = "x86_64",
29+
)
30+
use_repo(gcc_toolchains, "gcc_toolchain_x86_64")
31+
32+
bazel_dep(name = "score_bazel_cpp_toolchains", version = "0.3.0", dev_dependency = True)
33+
git_override(
34+
module_name = "score_bazel_cpp_toolchains",
35+
commit = "79982259df6dfa9d82cc458163a6d9b08bd24471",
36+
remote = "https://github.com/eclipse-score/bazel_cpp_toolchains.git",
37+
)
38+
39+
score_gcc = use_extension("@score_bazel_cpp_toolchains//extensions:gcc.bzl", "gcc", dev_dependency = True)
40+
score_gcc.toolchain(
41+
name = "score_gcc_x86_64_toolchain",
42+
target_cpu = "x86_64",
43+
target_os = "linux",
44+
use_base_constraints_only = True,
45+
use_default_package = True,
46+
version = "12.2.0",
47+
)
48+
score_gcc.toolchain(
49+
name = "score_qcc_x86_64_toolchain",
50+
sdp_version = "8.0.0",
51+
target_cpu = "x86_64",
52+
target_os = "qnx",
53+
use_default_package = True,
54+
version = "12.2.0",
55+
)
56+
score_gcc.toolchain(
57+
name = "score_qcc_aarch64_toolchain",
58+
sdp_version = "8.0.0",
59+
target_cpu = "aarch64",
60+
target_os = "qnx",
61+
use_default_package = True,
62+
version = "12.2.0",
63+
)
64+
use_repo(
65+
score_gcc,
66+
"score_gcc_x86_64_toolchain",
67+
"score_qcc_aarch64_toolchain",
68+
"score_qcc_x86_64_toolchain",
69+
)
70+
71+
# For the moment we still need the old toolchain for ifs generation.
72+
# Migrate once rules_imagefs is ready to be used (https://github.com/eclipse-score/rules_imagefs/pull/1).
73+
bazel_dep(name = "score_toolchains_qnx", version = "0.0.7", dev_dependency = True)
74+
75+
toolchains_qnx = use_extension(
76+
"@score_toolchains_qnx//:extensions.bzl",
77+
"toolchains_qnx",
78+
dev_dependency = True,
79+
)
80+
toolchains_qnx.sdp(
81+
sha256 = "f2e0cb21c6baddbcb65f6a70610ce498e7685de8ea2e0f1648f01b327f6bac63",
82+
strip_prefix = "installation",
83+
url = "https://www.qnx.com/download/download/79858/installation.tgz",
84+
)
85+
use_repo(toolchains_qnx, "toolchains_qnx_ifs")
86+
87+
bazel_dep(name = "toolchains_llvm", version = "1.5.0", dev_dependency = True)
88+
89+
llvm = use_extension(
90+
"@toolchains_llvm//toolchain/extensions:llvm.bzl",
91+
"llvm",
92+
dev_dependency = True,
93+
)
94+
llvm.toolchain(
95+
compile_flags = {"": [
96+
"-march=nehalem",
97+
"-ffp-model=strict",
98+
# Security
99+
"-U_FORTIFY_SOURCE", # https://github.com/google/sanitizers/issues/247
100+
"-fstack-protector",
101+
"-fno-omit-frame-pointer",
102+
# Diagnostics
103+
"-fcolor-diagnostics",
104+
"-Wno-deprecated-declarations",
105+
"-Wno-error=self-assign-overloaded",
106+
"-Wthread-safety",
107+
]},
108+
cxx_standard = {"": "c++17"},
109+
link_libs = {"": [
110+
"-lrt",
111+
# This is the agreed way to ensure linking for targets using std::atomic operations.
112+
"-latomic",
113+
]},
114+
llvm_version = "19.1.7",
115+
)
116+
use_repo(llvm, "llvm_toolchain")
117+
118+
bazel_dep(name = "score_toolchains_rust", version = "0.7.0", dev_dependency = True)
119+
120+
gcc_ferrocene = use_extension(
121+
"@score_toolchains_rust//extensions:ferrocene_toolchain_ext.bzl",
122+
"ferrocene_toolchain_ext",
123+
dev_dependency = True,
124+
)
125+
gcc_ferrocene.toolchain(
126+
name = "ferrocene_x86_64_unknown_linux_gnu_llvm",
127+
coverage_tools_sha256 = "497958e925bc94833ea226d68f6d5ba38bd890f571c73e230141d2923e30dd94",
128+
coverage_tools_strip_prefix = "779fbed05ae9e9fe2a04137929d99cc9b3d516fd/x86_64-unknown-linux-gnu",
129+
coverage_tools_url = "https://github.com/eclipse-score/ferrocene_toolchain_builder/releases/download/1.0.1/coverage-tools-779fbed05ae9e9fe2a04137929d99cc9b3d516fd-x86_64-unknown-linux-gnu.tar.gz",
130+
exec_triple = "x86_64-unknown-linux-gnu",
131+
extra_rustc_flags = [
132+
"-Clink-arg=-Wl,--no-as-needed",
133+
"-Clink-arg=-lc++",
134+
"-Clink-arg=-lm",
135+
"-Clink-arg=-lc",
136+
],
137+
sha256 = "4c08b41eaafd39cff66333ca4d4646a5331c780050b8b9a8447353fcd301dddc",
138+
target_compatible_with = [
139+
"@platforms//cpu:x86_64",
140+
"@platforms//os:linux",
141+
],
142+
target_triple = "x86_64-unknown-linux-gnu",
143+
url = "https://github.com/eclipse-score/ferrocene_toolchain_builder/releases/download/1.0.1/ferrocene-779fbed05ae9e9fe2a04137929d99cc9b3d516fd-x86_64-unknown-linux-gnu.tar.gz",
144+
)
145+
use_repo(
146+
gcc_ferrocene,
147+
"ferrocene_x86_64_unknown_linux_gnu_llvm",
148+
)
149+
150+
# We use here a pre-compiled fully static and hermetic clang_format binary
151+
# and not the one provided by llvm_toolchain, because the one from llvm_toolchain is not fully hermetic (and different version for now)
152+
download_file = use_repo_rule("@download_utils//download/file:defs.bzl", "download_file")
153+
154+
download_file(
155+
name = "clang_format",
156+
executable = True,
157+
output = "executable",
158+
urls = ["https://github.com/muttleyxd/clang-tools-static-binaries/releases/download/master-2da3e7b/clang-format-19_linux-amd64"],
159+
)
160+
161+
bazel_dep(name = "rules_cc", version = "0.1.5")
162+
163+
bazel_dep(name = "aspect_rules_lint", version = "2.2.0", dev_dependency = True)
164+
bazel_dep(name = "googletest", version = "1.17.0.bcr.2", dev_dependency = True)
165+
bazel_dep(name = "google_benchmark", version = "1.9.5", dev_dependency = True)
166+
167+
bazel_dep(name = "rules_rust", version = "0.68.1-score")
168+
169+
bazel_dep(name = "buildifier_prebuilt", version = "8.2.1.2", dev_dependency = True)
170+
171+
bazel_dep(name = "score_crates", version = "0.0.7", repo_name = "score_communication_crate_index")
172+
bazel_dep(name = "boost.program_options", version = "1.87.0")
173+
bazel_dep(name = "boost.interprocess", version = "1.87.0")
174+
175+
bazel_dep(name = "download_utils", version = "1.2.2", dev_dependency = True)
176+
177+
download_archive = use_repo_rule("@download_utils//download/archive:defs.bzl", "download_archive")
178+
179+
download_archive(
180+
name = "json_schema_validator",
181+
build = "//third_party/json_schema_validator:json_schema_validator.BUILD",
182+
strip_prefix = "json-schema-validator-2.1.0",
183+
urls = ["https://github.com/pboettch/json-schema-validator/archive/refs/tags/2.1.0.tar.gz"],
184+
)
185+
186+
download_archive(
187+
name = "jsonschema",
188+
build = "//third_party/jsonschema:jsonschema.BUILD",
189+
strip_prefix = "jsonschema-4.23.0",
190+
urls = ["https://github.com/python-jsonschema/jsonschema/archive/refs/tags/v4.23.0.tar.gz"],
191+
)
192+
193+
bazel_dep(name = "nlohmann_json", version = "3.11.3")
194+
bazel_dep(name = "bazel_skylib", version = "1.8.1")
195+
196+
bazel_dep(name = "rules_doxygen", version = "2.6.1", dev_dependency = True)
197+
bazel_dep(name = "score_docs_as_code", version = "3.0.1", dev_dependency = True)
198+
199+
# Force score_docs_as_code to 3.0.1 to resolve compatibility conflict between score_logging and score_baselibs
200+
single_version_override(
201+
module_name = "score_docs_as_code",
202+
version = "3.0.1",
203+
)
204+
205+
# Apply patch to fix Doxyfile template for our use cases
206+
single_version_override(
207+
module_name = "rules_doxygen",
208+
patch_strip = 1,
209+
patches = ["//third_party/rule_doxygen:Doxyfile.patch"],
210+
)
211+
212+
# Apply patch to fix visibility issue with interprocess_notification target
213+
bazel_dep(name = "score_baselibs", version = "0.2.4")
214+
bazel_dep(name = "score_logging", version = "0.1.0")
215+
bazel_dep(name = "score_baselibs_rust", version = "0.1.0")
216+
217+
# Doxygen extension for documentation generation
218+
doxygen_extension = use_extension("@rules_doxygen//:extensions.bzl", "doxygen_extension", dev_dependency = True)
219+
use_repo(doxygen_extension, "doxygen")
220+
221+
# Python 3.12 toolchain for Bazel
222+
bazel_dep(name = "rules_python", version = "1.5.1")
223+
224+
python = use_extension("@rules_python//python/extensions:python.bzl", "python", dev_dependency = True)
225+
python.toolchain(
226+
python_version = "3.12",
227+
)
228+
229+
# Python pip dependencies
230+
pip = use_extension("@rules_python//python/extensions:pip.bzl", "pip", dev_dependency = True)
231+
pip.parse(
232+
hub_name = "score_communication_pip",
233+
python_version = "3.12",
234+
requirements_lock = "//:requirements_lock.txt",
235+
)
236+
use_repo(pip, "score_communication_pip")
237+
238+
pip.parse(
239+
hub_name = "codeql_coding_standards_pip_hub",
240+
python_version = "3.12",
241+
requirements_lock = "//third_party/codeql:requirements_lock.txt",
242+
)
243+
use_repo(pip, "codeql_coding_standards_pip_hub")
244+
245+
# TRLC dependency for requirements traceability
246+
bazel_dep(name = "trlc", version = "0.0.0", dev_dependency = True)
247+
git_override(
248+
module_name = "trlc",
249+
commit = "a4f7e95210d8093ba208b91cbc5b681eae8d502b", # trlc-2.0.3 release
250+
remote = "https://github.com/bmw-software-engineering/trlc.git",
251+
)
252+
253+
lobster_ext = use_extension("//third_party/lobster:lobster.bzl", "lobster_ext")
254+
use_repo(lobster_ext, "lobster")
255+
256+
# Use lobster's upstream requirements.txt directly for this module's Python hub
257+
pip.parse(
258+
hub_name = "lobster_dependencies",
259+
python_version = "3.12",
260+
requirements_lock = "@lobster//:requirements.txt",
261+
)
262+
use_repo(pip, "lobster_dependencies")
263+
264+
bazel_dep(name = "score_bazel_platforms", version = "0.1.1")
265+
266+
bazel_dep(name = "rules_oci", version = "1.8.0", dev_dependency = True)
267+
268+
oci = use_extension("@rules_oci//oci:extensions.bzl", "oci", dev_dependency = True)
269+
oci.pull(
270+
name = "ubuntu_24_04",
271+
digest = "sha256:2e863c44b718727c860746568e1d54afd13b2fa71b160f5cd9058fc436217b30",
272+
image = "ubuntu",
273+
platforms = ["linux/amd64"],
274+
tag = "24.04",
275+
)
276+
use_repo(oci, "ubuntu_24_04")
277+
278+
bazel_dep(name = "rules_distroless", version = "0.6.2", dev_dependency = True)
279+
280+
apt = use_extension(
281+
"@rules_distroless//apt:extensions.bzl",
282+
"apt",
283+
dev_dependency = True,
284+
)
285+
apt.install(
286+
name = "ubuntu24_04",
287+
lock = "@@//quality/integration_testing/environments/ubuntu24_04_docker:ubuntu24_04.lock.json",
288+
manifest = "//quality/integration_testing/environments/ubuntu24_04_docker:ubuntu24_04.yaml",
289+
)
290+
use_repo(apt, "ubuntu24_04")
291+
292+
bazel_dep(name = "rules_pkg", version = "1.2.0", dev_dependency = True)
293+
294+
bazel_dep(name = "score_tooling", version = "1.1.2")
295+
296+
http_archive = use_repo_rule("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
297+
298+
http_archive(
299+
name = "codeql_bundle",
300+
build_file = "//third_party/codeql:codeql.BUILD",
301+
sha256 = "",
302+
url = "https://github.com/github/codeql-action/releases/download/codeql-bundle-v2.23.6/codeql-bundle-linux64.tar.gz",
303+
)
304+
305+
git_repository = use_repo_rule("@bazel_tools//tools/build_defs/repo:git.bzl", "git_repository")
306+
307+
git_repository(
308+
name = "codeql_coding_standards",
309+
build_file = "//third_party/codeql:codeql_coding_standards.BUILD",
310+
commit = "781f1eecfa2fc9970fb08447588a0b4d19a7908d",
311+
remote = "https://github.com/github/codeql-coding-standards.git",
312+
)
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
--- a/MODULE.bazel
2+
+++ b/MODULE.bazel
3+
@@ -12,7 +12,7 @@
4+
# *******************************************************************************
5+
module(name = "score_communication")
6+
7+
-bazel_dep(name = "platforms", version = "1.0.0")
8+
+bazel_dep(name = "platforms", version = "0.1.4")
9+
10+
bazel_dep(name = "gcc_toolchain", version = "0.9.0", dev_dependency = True)
11+
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{
2+
"integrity": "sha256-183x4Mn0/WXstiKYjFs5r9zGttdcF1/O/4uEKbd4k08=",
3+
"strip_prefix": "communication-0.1.4",
4+
"url": "https://github.com/eclipse-score/communication/archive/refs/tags/v0.1.4.tar.gz",
5+
"patch_strip": 1,
6+
"patches": {
7+
"module_dot_bazel_version.patch": "sha256-R2bO/OhPjdsLeiel0TDbDha+jzQ6e4dK1vrwo0VJMg0="
8+
}
9+
}

modules/score_communication/metadata.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
"github:eclipse-score/communication"
1414
],
1515
"versions": [
16+
"0.1.4",
1617
"0.1.3",
1718
"0.1.2",
1819
"0.1.1",

0 commit comments

Comments
 (0)