From 21884ed7c37bb530e9899e18752c8fd5c4218863 Mon Sep 17 00:00:00 2001 From: Martijn Visser Date: Tue, 27 Jan 2026 11:17:37 +0100 Subject: [PATCH] Fix bundling and rpath docs for lbrary API The rpath is only automatically set to at-bundle when using the CLI: https://github.com/JuliaLang/JuliaC.jl/blob/ed13d9ece8db9bb29cdf5230c76a8f1de11c3ecd/src/JuliaC.jl#L173-L179 For the library API this wouldn't make sense since bundling happens after linking, so at linking time we don't know yet if the user wants to bundle. --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index db6c620..c5df3bf 100644 --- a/README.md +++ b/README.md @@ -85,7 +85,7 @@ img = ImageRecipe( link = LinkRecipe( image_recipe = img, outname = "build/app_test_exe", - rpath = nothing, # set automatically when bundling + rpath = "@bundle", # set only when bundling ) bun = BundleRecipe( @@ -100,7 +100,7 @@ bundle_products(bun) ### Bundling and rpath -When `--bundle` (or `BundleRecipe.output_dir`) is set, JuliaC: +When `--bundle` (or `BundleRecipe.output_dir` and `LinkRecipe.rpath == "@bundle"`) is set, JuliaC: - Places the executable in `/bin` and libraries in `/lib` and `/lib/julia` (Windows: everything under `/bin`). - Copies required artifacts alongside the bundle. - Links your output with a relative rpath so the executable finds sibling libs (Unix uses `@loader_path/../lib` or `$ORIGIN/../lib`).