File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -77,9 +77,15 @@ def _build_env(session: nox.Session) -> Path:
7777 env = {"CONDA_PREFIX" : str (env_dir )}
7878 env .update (_darwin_sdk_env ())
7979 if platform .system () == "Darwin" :
80- # Also pass an explicit rpath so delocate-wheel can bundle deps even
81- # when meson would otherwise embed a @loader_path-relative path.
80+ # Pass an explicit rpath so delocate-wheel can bundle deps even when
81+ # meson would otherwise embed a @loader_path-relative path.
8282 env ["LDFLAGS" ] = (env .get ("LDFLAGS" , "" ) + f" -Wl,-rpath,{ lib_dir } " ).strip ()
83+ # conda-forge's ld64_osx-64 linker may be invoked from the micromamba
84+ # pkgs cache path (hard-linked), so @loader_path/../lib/libtapi.dylib
85+ # resolves against the cache dir rather than the installed env. Set a
86+ # fallback so dyld finds libtapi.dylib in the env's lib/ dir instead.
87+ existing = os .environ .get ("DYLD_FALLBACK_LIBRARY_PATH" , "" )
88+ env ["DYLD_FALLBACK_LIBRARY_PATH" ] = f"{ lib_dir } :{ existing } " .strip (":" )
8389 session .env .update (env )
8490
8591
You can’t perform that action at this time.
0 commit comments