Merge pull request #153775 from thiagokokada/fix-clojure-lsp-build-on-macos

clojure-lsp: fix build on macOS
This commit is contained in:
Thiago Kenji Okada 2022-01-06 20:28:35 -03:00 committed by GitHub
commit 017328f71d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -17,10 +17,14 @@ buildGraalvmNativeImage rec {
};
# https://github.com/clojure-lsp/clojure-lsp/blob/2021.11.02-15.24.47/graalvm/native-unix-compile.sh#L18-L27
DTLV_LIB_EXTRACT_DIR = "/tmp";
# Needs to be inject on `nativeImageBuildArgs` inside shell environment,
# otherwise we can't expand to the value set in `mktemp -d` call
preBuild = ''
export DTLV_LIB_EXTRACT_DIR="$(mktemp -d)"
nativeImageBuildArgs+=("-H:CLibraryPath=$DTLV_LIB_EXTRACT_DIR")
'';
extraNativeImageBuildArgs = [
"-H:CLibraryPath=${DTLV_LIB_EXTRACT_DIR}"
"--no-fallback"
"--native-image-info"
];