From aa90d521de12a398d495ea3c7e8a4ac13485c436 Mon Sep 17 00:00:00 2001 From: dundargoc Date: Sat, 16 Dec 2023 14:54:41 +0100 Subject: [PATCH] build: fix universal mac builds Cmake 3.28+ will fail if two projects download the same file to prevent scheduling problems. This can be circumvented by downloading luajit to a unique location for each target. This is theoretically non-optimal since we need to download the same file three times for universal builds, but universal builds are rare and the convenience of this method outweighs setting up the dependencies optimally. This fixes the currently broken release workflow for mac. Closes https://github.com/neovim/neovim/issues/26526. (cherry picked from commit d5c656c7d06ab0d6347b4fd75f7736844dd12147) --- cmake.deps/cmake/BuildLuajit.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmake.deps/cmake/BuildLuajit.cmake b/cmake.deps/cmake/BuildLuajit.cmake index 5276b1133f..c5c0bdbac1 100644 --- a/cmake.deps/cmake/BuildLuajit.cmake +++ b/cmake.deps/cmake/BuildLuajit.cmake @@ -19,7 +19,7 @@ function(BuildLuajit) URL ${LUAJIT_URL} URL_HASH SHA256=${LUAJIT_SHA256} DOWNLOAD_NO_PROGRESS TRUE - DOWNLOAD_DIR ${DEPS_DOWNLOAD_DIR}/luajit + DOWNLOAD_DIR ${DEPS_DOWNLOAD_DIR}/${_luajit_TARGET} CONFIGURE_COMMAND "${_luajit_CONFIGURE_COMMAND}" BUILD_IN_SOURCE 1 BUILD_COMMAND "${_luajit_BUILD_COMMAND}"