Repository navigation
julia: Julia actions on Linux x86_64 run on the source-built libjulia-internal (part of #13965) - #14192
Merged
Conversation
…-internal (part of #13965) julia/private/runtime registers source_toolchain ahead of @julia_toolchains. It wraps the downloaded Julia 1.13.4 toolchain in a tree whose lib/julia/libjulia-internal is the source-built library, with julia and libjulia copied so $ORIGIN resolves inside the tree. A stock flag keeps the runtime rules on the downloaded release. JuliaPrecompile, JuliaSysimage and JuliaLink now run that tree's julia and link against its libraries. The registration is a dev dependency until the julia_src archives move to dx_pins. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Xut2hvrtsUC3euEfXchJYt
This was referenced Nov 20, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Linked Issue
Part of #13965
Changes
julia/private/runtime/defs.bzl: newjulia_source_toolchainrule. It takes the downloaded Julia toolchain and builds a tree wherelib/julia/libjulia-internal.so.<version>is the source-built library. Thelibjulia-internal.soand.so.<major>.<minor>names link to it.bin/*andlib/libjulia.so*are copied, so the loader's$ORIGINstays inside the tree. Every other file is a symlink. The rule returns the stockToolchainInfowithjulia,all_files,link_files,sysimageandmake_variable_infoswapped for the tree's files.julia/private/runtime/BUILD.bazel: adds astockbool flag with asource_runtimeconfig_setting, plussource_juliaandsource_toolchain(Linux x86_64 exec and target, pinned to the runtime Julia version). The runtime transition setsstock, sojulia_runtime_files,julia_shipped_libsand the toolchain itself resolve the downloaded release instead of themselves.MODULE.bazel: registers//julia/private/runtime:source_toolchainahead of@julia_toolchains//:all. It isdev_dependency = Trueuntil thejulia_srcarchives move todx_pinsandjulia/private/runtimeships inmodule_srcs.libjulia_internal_test: new casethe_registered_toolchain_runs_on_the_built_library. It resolvesjuliathroughcurrent_julia_toolchainand checks that the loaded libjulia-internal is the tree's copy, that it differs from the shipped library, and that it exports the source-built symbol set.On linux_x86_64,
aquerynow showsJuliaPrecompile,JuliaSysimageandJuliaLinkfor//julia/tests/fixtures/hello/...runningjulia/private/runtime/source_julia/bin/julia, with--sysimagetaken from the same tree.Verification
Tested:
//julia/private/runtime:libjulia_internal_test,//julia/private/runtime:libjulia_internal_test_upstream,//julia/private/runtime:julia_src_version_test,//julia/tests:alland//julia/tests/fixtures/hello:all, excepthello_standalone_output_test{,_upstream}. All 13 tests passed locally on linux_x86_64.tools/dx check --applyon the four touched files: no findings.Not run:
hello_standalone_output_test(its JuliaSysimage build OOMs small hosts),determinism_check, nested-Bazel and consumer tests. Consumers are unaffected, because the registration is a dev dependency.MODULE.bazelis a review path, so this PR needs a second-sessionReview:comment.Generated by Claude Code