diff --git a/.github/scripts/build_universal_macos.sh b/.github/scripts/build_universal_macos.sh index d07c395cd6..432a275d6d 100755 --- a/.github/scripts/build_universal_macos.sh +++ b/.github/scripts/build_universal_macos.sh @@ -12,6 +12,7 @@ cmake -B build -G Ninja \ -D CMAKE_BUILD_TYPE=${NVIM_BUILD_TYPE} \ -D CMAKE_OSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET} \ -D CMAKE_OSX_ARCHITECTURES=arm64\;x86_64 \ + -D ENABLE_LIBINTL=OFF \ -D CMAKE_FIND_FRAMEWORK=NEVER cmake --build build # Make sure we build everything for M1 as well diff --git a/CMakeLists.txt b/CMakeLists.txt index aa9ae8b875..15e3f34edd 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -101,6 +101,7 @@ if (MINGW) else() option(ENABLE_LTO "enable link time optimization" ON) endif() +option(ENABLE_LIBINTL "enable libintl" ON) message(STATUS "CMAKE_INSTALL_PREFIX=${CMAKE_INSTALL_PREFIX}") diff --git a/src/nvim/CMakeLists.txt b/src/nvim/CMakeLists.txt index 069ef8a8ef..75c9821a2c 100755 --- a/src/nvim/CMakeLists.txt +++ b/src/nvim/CMakeLists.txt @@ -32,11 +32,13 @@ target_link_libraries(main_lib INTERFACE treesitter unibilium) -# Libintl (not Intl) selects our FindLibintl.cmake script. #8464 -find_package(Libintl REQUIRED) -target_include_directories(main_lib SYSTEM BEFORE INTERFACE ${LIBINTL_INCLUDE_DIR}) -if (LIBINTL_LIBRARY) - target_link_libraries(main_lib INTERFACE ${LIBINTL_LIBRARY}) +if(ENABLE_LIBINTL) + # Libintl (not Intl) selects our FindLibintl.cmake script. #8464 + find_package(Libintl REQUIRED) + target_include_directories(main_lib SYSTEM BEFORE INTERFACE ${LIBINTL_INCLUDE_DIR}) + if (LIBINTL_LIBRARY) + target_link_libraries(main_lib INTERFACE ${LIBINTL_LIBRARY}) + endif() endif() # The unit test lib requires LuaJIT; it will be skipped if LuaJIT is missing.