This commit is contained in:
parent
8603182caf
commit
40e094f7eb
2 changed files with 10 additions and 6 deletions
10
project.cpp
10
project.cpp
|
|
@ -137,9 +137,13 @@ extern "C" Configuration CrafterBuildProject(std::span<const std::string_view> a
|
|||
// libmsquic.so.2 is built in crafter-build's external cache, and the
|
||||
// RUNPATH pointing there only exists on the build machine — the first
|
||||
// deploy to a real host died in the loader (exit 127) because of it.
|
||||
// $ORIGIN makes the loader also look next to the binary itself, and CI
|
||||
// ships the .so alongside it into /srv/catcrafts-app.
|
||||
cfg.linkFlags.push_back("-Wl,-rpath,$ORIGIN");
|
||||
// CI ships the .so alongside the binary into /srv/catcrafts-app, and
|
||||
// this rpath makes the loader look there. The path is spelled out
|
||||
// rather than $ORIGIN: the flag passes through a shell on its way to
|
||||
// the linker, where $ORIGIN expands to empty — leaving a bare -rpath
|
||||
// that swallows the next input file (libCatcrafts.Shared.a) and fails
|
||||
// the link with every Shared symbol undefined.
|
||||
cfg.linkFlags.push_back("-Wl,-rpath,/srv/catcrafts-app");
|
||||
|
||||
ApplyReleaseTrimming(cfg);
|
||||
return cfg;
|
||||
|
|
|
|||
Loading…
Reference in a new issue