Skip to content

Commit 9cf7503

Browse files
committed
bugfix: set CLAUDE_PROJECT_DIR and CLAUDE_PLUGIN_ROOT for AOT training
AOT recording failed because MainJvmScope requires these environment variables to initialize handlers during AotTraining.
1 parent 80f0a94 commit 9cf7503

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

client/build-jlink.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -300,6 +300,8 @@ generate_startup_archives() {
300300
# Uses a single AotTraining class that exercises all handlers in one JVM invocation,
301301
# replacing 20 separate JVM launches (~19s -> ~1s).
302302
log "Recording AOT training data..."
303+
# Set environment variables required by MainJvmScope so handlers can initialize.
304+
CLAUDE_PROJECT_DIR="${PROJECT_DIR%/*}" CLAUDE_PLUGIN_ROOT="${PROJECT_DIR%/*}/plugin" \
303305
"$java_bin" \
304306
-XX:AOTMode=record \
305307
-XX:AOTConfiguration="$aot_config" \

0 commit comments

Comments
 (0)