eb-local.rpath¶
- module eb-local.rpath src/rpath.zig[source][autodoc]¶
RPATH wrappers for compilers that have no build environment module.
eb-local devfalls back to them when the loaded compiler family has no buildenv installed, so a program still records the library directory of every module it links against, as EasyBuild’s own wrappers do, instead of linking without run paths and needing LD_LIBRARY_PATH.
Error sets¶
Functions¶
- pub fn cacheHome(a: Allocator, env: *const std.process.Environ.Map) Error![]const u8[source][autodoc]¶
The effective user cache directory: absolute
$XDG_CACHE_HOME, or absolute$HOME/.cachewhen XDG_CACHE_HOME is unset or empty.
- pub fn directory(a: Allocator, env: *const std.process.Environ.Map, found: []const []const u8) Error![]const u8[source][autodoc]¶
The directory for the wrappers of
found: below the user’s cache directory, named by the names it holds and the script it writes.
- pub fn present(a: Allocator, path: []const u8) Allocator.Error![]const []const u8[source][autodoc]¶
The wrapped names on
path, innamesorder.
- pub fn unwrapped(a: Allocator, path: []const u8, among: []const []const u8) Allocator.Error![]const []const u8[source][autodoc]¶
The names among
amongthat no wrapper covers onpath: the first of each name is neither one of eb-local’s wrappers nor one of EasyBuild’s, which it writes asrpath_wrappers/NAME_wrapper/NAME.
Constants¶
- pub const names = ...[source][autodoc]¶
The commands wrapped when they are on PATH: compiler drivers, then linkers. MPI wrappers call these by name, so they are covered too.
- pub const self_linking = ...[source][autodoc]¶
The compilers that find their linker themselves, so a wrapped
ldon PATH never sees their links, and the linker of theirs that EasyBuild’s GCC build environment does not wrap. A program they link has run paths only when they are wrapped themselves.
- pub const marker = ".eb-local-rpath"[source][autodoc]¶
A directory holding this file is skipped when a wrapper looks for the command it stands in for, so wrappers never call each other.
- pub const script = ...[source][autodoc]¶
One script for every name: it runs the next command of its own name on PATH. An empty entry is the current directory, including the one a trailing colon names, as execvp searches. When that command links, it adds a run path for each absolute library directory named with -L or by the absolute path of an existing
lib*.sofile, and for a compiler driver for each LIBRARY_PATH entry, which EESSI’s modules set and the driver passes to the linker; system and compatibility-layer directories are left out, as the loader finds those itself, and so are stub directories (stubs/lib64of a CUDA toolkit): a stub is for the link only, and one on the run path is loaded in place of the driver’s library. Other.sonames are commonly runtime-loaded plugins, not link inputs that create a DT_NEEDED entry, so they are not inferred here. The arguments of a response file, @FILE, count as arguments of the command: Meson and CMake put a long link line in one. –disable-new-dtags writes RPATH rather than RUNPATH, so LD_LIBRARY_PATH cannot override it, as in EasyBuild.