aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Clason <c.clason@uni-graz.at>2022-09-28 11:06:11 +0200
committerGitHub <noreply@github.com>2022-09-28 11:06:11 +0200
commiteb4844b5ed9bcf8c434a93b9f9def4fe81557f37 (patch)
tree737f038c7809a8e20133ade80b3d8248f6f65334
parentd7358118aa57ec636ef6f84c6ac96f26d8bed32c (diff)
downloadrneovim-eb4844b5ed9bcf8c434a93b9f9def4fe81557f37.tar.gz
rneovim-eb4844b5ed9bcf8c434a93b9f9def4fe81557f37.tar.bz2
rneovim-eb4844b5ed9bcf8c434a93b9f9def4fe81557f37.zip
build(macos): restore and test universal build (#20383)
Build tree-sitter parsers for arm64 as well as x86 Check that all created binaries contain both architectures
-rw-r--r--.github/workflows/release.yml5
-rw-r--r--cmake.deps/cmake/BuildTreesitterParsers.cmake2
2 files changed, 7 insertions, 0 deletions
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index 5e0ea5e5f4..5fc40a2471 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -113,6 +113,11 @@ jobs:
DEPS_CMAKE_FLAGS="$OSX_FLAGS"
make DESTDIR="$GITHUB_WORKSPACE/build/release/nvim-macos" install
cd "$GITHUB_WORKSPACE/build/"
+ # Make sure we build everything for M1 as well
+ for macho in bin/* lib/nvim/parser/*.so
+ do
+ lipo -info "$macho" | grep -q arm64 || exit 1
+ done
cpack -C "$NVIM_BUILD_TYPE"
- uses: actions/upload-artifact@v3
with:
diff --git a/cmake.deps/cmake/BuildTreesitterParsers.cmake b/cmake.deps/cmake/BuildTreesitterParsers.cmake
index 25d2fd21a3..e08792f62a 100644
--- a/cmake.deps/cmake/BuildTreesitterParsers.cmake
+++ b/cmake.deps/cmake/BuildTreesitterParsers.cmake
@@ -4,6 +4,8 @@ function(BuildTSParser LANG TS_URL TS_SHA256 TS_CMAKE_FILE)
PREFIX ${DEPS_BUILD_DIR}
URL ${TREESITTER_C_URL}
DOWNLOAD_DIR ${DEPS_DOWNLOAD_DIR}/${NAME}
+ CMAKE_CACHE_ARGS
+ -DCMAKE_OSX_ARCHITECTURES:STRING=${CMAKE_OSX_ARCHITECTURES}
DOWNLOAD_COMMAND ${CMAKE_COMMAND}
-DPREFIX=${DEPS_BUILD_DIR}
-DDOWNLOAD_DIR=${DEPS_DOWNLOAD_DIR}/${NAME}