T-386 (cavekit-engine-update R4b): render/goanna/modules/JihadEngine.jsm (resource://gre/modules/) holds the engine modules the components import (LightweightThemeManager, AddonManager, PermissionsUtils) and the about:addons markup the Personas pane decorates (ids, row anonids and classes, the view controller, the URLs). jihadPersonas.js and jihadBundledAddons.js go through it; check-engine-api.py reads its SURFACE block (one list, not two) and fails a component importing an engine module around it (check 4b); its mozconfig search is one level down (a recursive glob had walked the objdirs for over an hour). test/jihad-engine-shim-test.js passes; device (Enyo): about:addons shows Personas and Uninstall, the Personas view lists the 14 and Default look in use. T-387 (R6), two of three: build/install-components.sh installs every render/goanna/components/*.manifest (now files, not heredocs) with the files it names and the shim, for the device bundle and the desktop dist alike (the bundle is identical: same files, same registrations); push-engine-update.sh derives the engine's loose files from the branch's diff and the objdir's install records (build/engine/engine-loose-files.py): videocontrols.xml, AddonManager.jsm, amContentHandler.js and amInstallTrigger.js now go with XPIProvider.jsm (they did not before), verified on the device. build-goanna.sh stops on a failed mach step (a failed configure had been hidden by an && list). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01J67ZH8aYy8uzhgZDZ6Nvx9
29 lines
1.5 KiB
Bash
Executable File
29 lines
1.5 KiB
Bash
Executable File
#!/bin/sh
|
|
# Copyright 2026 NotAlexNoyle. MPL-2.0.
|
|
# install-components.sh DEST REPO — cavekit-engine-update.md R6 (T-387): Jihad's own XPCOM
|
|
# components into an engine dist, the one script both the device bundle (make-device-bundle.sh)
|
|
# and the desktop dist (build/desktop/build-goanna.sh) use. Every render/goanna/components/*.manifest
|
|
# is copied with the JS files its "component" lines name and registered from DEST/chrome.manifest
|
|
# (idempotent); the engine shim the components import goes to DEST/modules/JihadEngine.jsm. A
|
|
# manifest naming a file that is not there fails the build, not the device.
|
|
set -eu
|
|
DEST="${1:?usage: install-components.sh DEST REPO}"
|
|
SRC="${2:?usage: install-components.sh DEST REPO}/render/goanna"
|
|
mkdir -p "$DEST/components" "$DEST/modules"
|
|
touch "$DEST/chrome.manifest"
|
|
n=0
|
|
for m in "$SRC"/components/*.manifest; do
|
|
[ -f "$m" ] || continue
|
|
name=$(basename "$m")
|
|
for js in $(awk '$1 == "component" { print $3 }' "$m" | sort -u); do
|
|
[ -s "$SRC/components/$js" ] || { echo "ERROR: $name names components/$js, which is missing" >&2; exit 1; }
|
|
cp -L "$SRC/components/$js" "$DEST/components/$js"
|
|
done
|
|
cp -L "$m" "$DEST/components/$name"
|
|
grep -q "^manifest components/$name\$" "$DEST/chrome.manifest" || echo "manifest components/$name" >> "$DEST/chrome.manifest"
|
|
n=$((n + 1))
|
|
done
|
|
[ "$n" -gt 0 ] || { echo "ERROR: no component manifests in $SRC/components" >&2; exit 1; }
|
|
cp -L "$SRC/modules/JihadEngine.jsm" "$DEST/modules/JihadEngine.jsm"
|
|
echo " components: $n manifests registered, modules/JihadEngine.jsm"
|