Skip to content

Commit f2dd634

Browse files
committed
graphics check: read the member's program from its product directory at the workspace root
mcpp 2026.9.29.1+ builds a workspace at its root and places a member's programs in bin/<package name>/ of the workspace's build directory; the member's own directory holds no build.
1 parent 6c377ce commit f2dd634

1 file changed

Lines changed: 9 additions & 5 deletions

File tree

‎tests/check_graphics_install_side_effects.sh‎

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -81,11 +81,15 @@ describe() {
8181
# which is the failure that would actually invalidate the comparison.
8282
build_and_describe() {
8383
( cd "$PROJ" && "$MCPP" test ) > "$1" 2>&1 || true
84-
local bin
85-
bin=$(find "$PROJ/target" -type f -path '*/bin/*' -perm -u+x 2>/dev/null \
86-
| head -1)
84+
# mcpp 2026.9.29.1+ builds a workspace at its root: a member's programs
85+
# are in `bin/<package name>/` of the workspace's build directory, and
86+
# the member's own directory holds no build.
87+
local pkg bin
88+
pkg=$(sed -n 's/^name *= *"\(.*\)".*/\1/p' "$PROJ/mcpp.toml" | head -1)
89+
bin=$(find "$ROOT/target" -type f -path "*/bin/$pkg/*" ! -name '*.so*' \
90+
-perm -u+x 2>/dev/null | head -1)
8791
[[ -n "$bin" ]] || {
88-
echo "no artifact produced under $PROJ/target:" >&2
92+
echo "no artifact produced under $ROOT/target/*/*/bin/$pkg:" >&2
8993
tail -25 "$1" >&2; return 1; }
9094
describe "$bin"
9195
}
@@ -161,7 +165,7 @@ this check installs into.
161165
162166
Installing the graphics stack into one home and measuring artifacts from
163167
another compares two unrelated things, and the comparison passes for any
164-
mcpp. Clean the member's target/ (or use a checkout that has none) so the
168+
mcpp. Clean the workspace's target/ (or use a checkout that has none) so the
165169
build actually resolves through MCPP_HOME.
166170
MSG
167171
exit 1 ;;

0 commit comments

Comments
 (0)