Skip to content

Commit 5d28ede

Browse files
authored
deps: follow openkal 0.7.0 (#6)
* deps: follow openkal 0.7.0 规范新增 `openkal.random`(mcpplibs/openkal#8),版本升到 0.7.0。 ⚠️ CI 有一道版本同步门,而它的诊断说明了为什么必须一起改: this is openkal 0.7.0 and this implementation is written against openkal 0.6.0. Nothing is wrong with either; they are not in step. ⭐ 本包**不提供** `openkal.random`,而那不是偏离 —— 6.1 条规定实现提供一个 接口是全有或全无,不提供的接口作为链接期定义缺席。这里跟随的只是规范版本, 不是接口集合。 * release: 0.1.5 The branch carried 0.1.4, which is the version on `main` and the version already in the index. Following openkal 0.7.0 changes what this package declares, and on two of these repositories it also adds an interface, so the content behind that number is no longer the content published under it. openkal takes a minor bump for a new interface and an implementation following it takes a patch bump --- the shape of 0.5.2 → 0.6.0 with 0.5.2 → 0.5.3 beneath it. * fix(ci): one specification in the graph, and follow the branch under test Two failures, both quiet until this change made them loud. The example asked for openkal 0.6.0 while the package it links asks for 0.7.0, so both were resolved and the engine fell back to mangling one copy's module names to let them coexist: Downloading mcpplibs.openkal v0.6.0 Downloading mcpplibs.openkal v0.7.0 Mangled openkal.abort v0.6.0 ↔ v0.7.0 → …__v0_7_0__mcpp (cross-major fallback) Mangling stages the sources under `target/.mangled/` and, by design, leaves headers where they are. This package's sources reach `sbi.h` as a quoted include beside them, which the staged copy has no path to: src/time.cpp:44:10: fatal error: 'sbi.h' file not found Naming one specification removes the fallback and the example builds against what the package is written for. The engine gap it exposed is real and is being fixed separately; nothing here depends on that. `OPENKAL_BRANCH` was `feat/openkal-closure`, a branch merged long before, so every run since had been cloning a stale specification and reporting on it. It now follows the branch under test where one of that name exists, and says which it used.
1 parent 47fd4a4 commit 5d28ede

3 files changed

Lines changed: 17 additions & 6 deletions

File tree

.github/workflows/ci.yml

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,12 @@ jobs:
1717
XLINGS_NON_INTERACTIVE: '1'
1818
# The branch of the specification this backend is verified against. It
1919
# moves with this one; when both are on `main` this becomes `main`.
20-
OPENKAL_BRANCH: feat/openkal-closure
20+
# The specification is taken from the branch of the same name where
21+
# one exists, so a change spanning both repositories is tested as a
22+
# whole. It was a fixed branch name until 2026-08-25 --- one merged
23+
# long before, so every run since had been cloning a stale tree and
24+
# reporting on it.
25+
OPENKAL_BRANCH: ${{ github.head_ref || github.ref_name }}
2126
steps:
2227
- uses: actions/checkout@v4
2328

@@ -122,8 +127,14 @@ jobs:
122127
- name: The conformance suite runs on the machine with no operating system
123128
run: |
124129
set -euo pipefail
125-
git clone --quiet --depth 1 -b "$OPENKAL_BRANCH" \
126-
https://github.com/mcpplibs/openkal "$RUNNER_TEMP/spec"
130+
git clone --quiet https://github.com/mcpplibs/openkal "$RUNNER_TEMP/spec"
131+
if git -C "$RUNNER_TEMP/spec" rev-parse --verify --quiet \
132+
"origin/$OPENKAL_BRANCH" > /dev/null; then
133+
git -C "$RUNNER_TEMP/spec" checkout --quiet "origin/$OPENKAL_BRANCH"
134+
echo "the specification is at $OPENKAL_BRANCH"
135+
else
136+
echo "the specification has no $OPENKAL_BRANCH; its default branch is used"
137+
fi
127138
Q=$(ls -d "$HOME"/.mcpp/registry/data/xpkgs/xim-x-qemu-riscv/*/bin/qemu-system-riscv64 | head -1)
128139
export OPENKAL_CONFORMANCE_RUNNER="$Q -machine virt -nographic -no-reboot -bios default -kernel"
129140
export OPENKAL_CONFORMANCE_IMPL_FEATURES=standalone

examples/hello/mcpp.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,5 +13,5 @@ runner = ["qemu-system-riscv64", "-machine", "virt", "-nographic",
1313
"-no-reboot", "-bios", "default", "-kernel"]
1414

1515
[dependencies]
16-
openkal = "0.6.0"
16+
openkal = "0.7.0"
1717
openkal-opensbi = { path = "../.." }

mcpp.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
[package]
1515
namespace = "mcpplibs"
1616
name = "openkal-opensbi"
17-
version = "0.1.4"
17+
version = "0.1.5"
1818
description = "An implementation of openkal on the RISC-V Supervisor Binary Interface, portable across every machine whose firmware provides one"
1919
license = "Apache-2.0"
2020

@@ -33,7 +33,7 @@ repo = "https://github.com/mcpplibs/openkal-opensbi"
3333
# The contract, not an implementation of it. Declaring it turns a version
3434
# mismatch into a resolution-time message rather than a link-time one.
3535
[dependencies]
36-
openkal = "0.6.0"
36+
openkal = "0.7.0"
3737

3838
# ⭐ WHAT RECEIVES CONTROL, WHICH IS A STATEMENT ABOUT THE PROGRAM.
3939
#

0 commit comments

Comments
 (0)