Hi there,
I’m trying to setup my dev setup to build the Cesium Unity in order to have proper platform files for the Vision OS for Unity. My goal would be to contribute based on this WIP PR WIP Added Vision Pro build support by handzlikchris · Pull Request #502 · CesiumGS/cesium-unity · GitHub
About my setup:
- macOS 15.5
- Cesium Unity 1.16 (clean, no changes to repo)
- Unity 2022.3.62f1
I followed the step at cesium-unity/Documentation~/developer-setup.md at main · CesiumGS/cesium-unity · GitHub
- Setting up the development environment
- reinterop-reinterop-guide
- build-for-the-editor
The first compilation fails:
cmake -B build -S . -DCMAKE_BUILD_TYPE=Debug
-- The CXX compiler identification is AppleClang 17.0.0.17000013
-- The C compiler identification is AppleClang 17.0.0.17000013
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
CMake Error at extern/tidy-html5/CMakeLists.txt:20 (cmake_minimum_required):
Compatibility with CMake < 3.5 has been removed from CMake.
Update the VERSION argument <min> value. Or, use the <min>...<max> syntax
to tell CMake that the project requires at least <min> but has been updated
to work with policies introduced by <max> or earlier.
Or, add -DCMAKE_POLICY_VERSION_MINIMUM=3.5 to try configuring anyway.
-- Configuring incomplete, errors occurred!
Workaround by updating tidy-html5/CMakeLists.txt. Now fails to build asyncplusplus:
make -B build -S . -DCMAKE_BUILD_TYPE=Debug
-> TIDY_SO_VERSION = 59. This is an ODD (development) release.
-- *** Debug Logging is NOT enabled.
-- *** Only building static library STATIC, version 5.9.14, date 2021.08.17
-- VCPKG_TRIPLET arm64-osx-unity
-- VCPKG_TARGET_TRIPLET
-- VCPKG_OVERLAY_PORTS /Users/augmentit/gits/cesium-test/Packages/com.cesium.unity/native~/vcpkg/ports;/Users/augmentit/gits/cesium-test/Packages/com.cesium.unity/native~/extern/cesium-native/extern/vcpkg/ports
-- VCPKG_OVERLAY_TRIPLETS /Users/augmentit/gits/cesium-test/Packages/com.cesium.unity/native~/vcpkg/triplets
-- EZVCPKG v0.1 starting up
Website: https://github.com/jherico/ezvcpkg
-- EZVCPKG_BASEDIR envrionment variable not found and basedir not set, using default /Users/augmentit/.ezvcpkg
-- EZVCPKG initializing
commit: 2024.11.16
repository: https://github.com/microsoft/vcpkg.git
local dir: /Users/augmentit/.ezvcpkg/2024.11.16
-- EZVCPKG Bootstrapping
-- Found Git: /opt/homebrew/bin/git (found version "2.44.0")
-- EZVCPKG Cloning repository
-- EZVCPKG Checking out commit 2024.11.16
-- EZVCPKG Bootstrapping vcpkg binary
-- EZVCPKG vcpkg bootstrap command: /Users/augmentit/.ezvcpkg/2024.11.16/bootstrap-vcpkg.sh
-- EZVCPKG vcpkg working dir: /Users/augmentit/.ezvcpkg/2024.11.16
-- EZVCPKG Building/Verifying package asyncplusplus using triplet arm64-osx-unity
CMake Error at extern/cesium-native/cmake/ezvcpkg/ezvcpkg.cmake:83 (message):
EZVCPKG failed with error 1
Call Stack (most recent call first):
extern/cesium-native/cmake/ezvcpkg/ezvcpkg.cmake:194 (EZVCPKG_CHECK_RESULTS)
extern/cesium-native/cmake/ezvcpkg/ezvcpkg.cmake:286 (EZVCPKG_BUILD)
extern/cesium-native/cmake/ezvcpkg/ezvcpkg.cmake:300 (EZVCPKG_FETCH_IMPL)
extern/cesium-native/CMakeLists.txt:103 (ezvcpkg_fetch)
Log file (/Users/augmentit/.ezvcpkg/2024.11.16/buildtrees/asyncplusplus/config-arm64-osx-unity-out.log)
[1/2] "/opt/homebrew/bin/cmake" -E chdir ".." "/opt/homebrew/bin/cmake" "/Users/augmentit/.ezvcpkg/2024.11.16/buildtrees/asyncplusplus/src/989edd9fba-8ad1c3cc1a.clean" "-G" "Ninja" "-DCMAKE_BUILD_TYPE=Release" "-DCMAKE_INSTALL_PREFIX=/Users/augmentit/.ezvcpkg/2024.11.16/packages/asyncplusplus_arm64-osx-unity" "-DFETCHCONTENT_FULLY_DISCONNECTED=ON" "-DCMAKE_MAKE_PROGRAM=/Users/augmentit/.ezvcpkg/2024.11.16/downloads/tools/ninja/1.10.2-osx/ninja" "-DCMAKE_SYSTEM_NAME=Darwin" "-DBUILD_SHARED_LIBS=OFF" "-DVCPKG_CHAINLOAD_TOOLCHAIN_FILE=/Users/augmentit/.ezvcpkg/2024.11.16/scripts/toolchains/osx.cmake" "-DVCPKG_TARGET_TRIPLET=arm64-osx-unity" "-DVCPKG_SET_CHARSET_FLAG=ON" "-DVCPKG_PLATFORM_TOOLSET=external" "-DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON" "-DCMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY=ON" "-DCMAKE_FIND_PACKAGE_NO_SYSTEM_PACKAGE_REGISTRY=ON" "-DCMAKE_INSTALL_SYSTEM_RUNTIME_LIBS_SKIP=TRUE" "-DCMAKE_VERBOSE_MAKEFILE=ON" "-DVCPKG_APPLOCAL_DEPS=OFF" "-DCMAKE_TOOLCHAIN_FILE=/Users/augmentit/.ezvcpkg/2024.11.16/scripts/buildsystems/vcpkg.cmake" "-DCMAKE_ERROR_ON_ABSOLUTE_INSTALL_DESTINATION=ON" "-DVCPKG_CXX_FLAGS=" "-DVCPKG_CXX_FLAGS_RELEASE=" "-DVCPKG_CXX_FLAGS_DEBUG=" "-DVCPKG_C_FLAGS=" "-DVCPKG_C_FLAGS_RELEASE=" "-DVCPKG_C_FLAGS_DEBUG=" "-DVCPKG_CRT_LINKAGE=dynamic" "-DVCPKG_LINKER_FLAGS=" "-DVCPKG_LINKER_FLAGS_RELEASE=" "-DVCPKG_LINKER_FLAGS_DEBUG=" "-DVCPKG_TARGET_ARCHITECTURE=arm64" "-DCMAKE_INSTALL_LIBDIR:STRING=lib" "-DCMAKE_INSTALL_BINDIR:STRING=bin" "-D_VCPKG_ROOT_DIR=/Users/augmentit/.ezvcpkg/2024.11.16" "-D_VCPKG_INSTALLED_DIR=/Users/augmentit/.ezvcpkg/2024.11.16/installed" "-DVCPKG_MANIFEST_INSTALL=OFF" "-DCMAKE_OSX_DEPLOYMENT_TARGET=10.15" "-DCMAKE_OSX_ARCHITECTURES=arm64"
FAILED: ../CMakeCache.txt
"/opt/homebrew/bin/cmake" -E chdir ".." "/opt/homebrew/bin/cmake" "/Users/augmentit/.ezvcpkg/2024.11.16/buildtrees/asyncplusplus/src/989edd9fba-8ad1c3cc1a.clean" "-G" "Ninja" "-DCMAKE_BUILD_TYPE=Release" "-DCMAKE_INSTALL_PREFIX=/Users/augmentit/.ezvcpkg/2024.11.16/packages/asyncplusplus_arm64-osx-unity" "-DFETCHCONTENT_FULLY_DISCONNECTED=ON" "-DCMAKE_MAKE_PROGRAM=/Users/augmentit/.ezvcpkg/2024.11.16/downloads/tools/ninja/1.10.2-osx/ninja" "-DCMAKE_SYSTEM_NAME=Darwin" "-DBUILD_SHARED_LIBS=OFF" "-DVCPKG_CHAINLOAD_TOOLCHAIN_FILE=/Users/augmentit/.ezvcpkg/2024.11.16/scripts/toolchains/osx.cmake" "-DVCPKG_TARGET_TRIPLET=arm64-osx-unity" "-DVCPKG_SET_CHARSET_FLAG=ON" "-DVCPKG_PLATFORM_TOOLSET=external" "-DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON" "-DCMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY=ON" "-DCMAKE_FIND_PACKAGE_NO_SYSTEM_PACKAGE_REGISTRY=ON" "-DCMAKE_INSTALL_SYSTEM_RUNTIME_LIBS_SKIP=TRUE" "-DCMAKE_VERBOSE_MAKEFILE=ON" "-DVCPKG_APPLOCAL_DEPS=OFF" "-DCMAKE_TOOLCHAIN_FILE=/Users/augmentit/.ezvcpkg/2024.11.16/scripts/buildsystems/vcpkg.cmake" "-DCMAKE_ERROR_ON_ABSOLUTE_INSTALL_DESTINATION=ON" "-DVCPKG_CXX_FLAGS=" "-DVCPKG_CXX_FLAGS_RELEASE=" "-DVCPKG_CXX_FLAGS_DEBUG=" "-DVCPKG_C_FLAGS=" "-DVCPKG_C_FLAGS_RELEASE=" "-DVCPKG_C_FLAGS_DEBUG=" "-DVCPKG_CRT_LINKAGE=dynamic" "-DVCPKG_LINKER_FLAGS=" "-DVCPKG_LINKER_FLAGS_RELEASE=" "-DVCPKG_LINKER_FLAGS_DEBUG=" "-DVCPKG_TARGET_ARCHITECTURE=arm64" "-DCMAKE_INSTALL_LIBDIR:STRING=lib" "-DCMAKE_INSTALL_BINDIR:STRING=bin" "-D_VCPKG_ROOT_DIR=/Users/augmentit/.ezvcpkg/2024.11.16" "-D_VCPKG_INSTALLED_DIR=/Users/augmentit/.ezvcpkg/2024.11.16/installed" "-DVCPKG_MANIFEST_INSTALL=OFF" "-DCMAKE_OSX_DEPLOYMENT_TARGET=10.15" "-DCMAKE_OSX_ARCHITECTURES=arm64"
CMake Error at CMakeLists.txt:21 (cmake_minimum_required):
Compatibility with CMake < 3.5 has been removed from CMake.
Update the VERSION argument <min> value. Or, use the <min>...<max> syntax
to tell CMake that the project requires at least <min> but has been updated
to work with policies introduced by <max> or earlier.
Or, add -DCMAKE_POLICY_VERSION_MINIMUM=3.5 to try configuring anyway.
-- Configuring incomplete, errors occurred!
[2/2] "/opt/homebrew/bin/cmake" -E chdir "../../arm64-osx-unity-dbg" "/opt/homebrew/bin/cmake" "/Users/augmentit/.ezvcpkg/2024.11.16/buildtrees/asyncplusplus/src/989edd9fba-8ad1c3cc1a.clean" "-G" "Ninja" "-DCMAKE_BUILD_TYPE=Debug" "-DCMAKE_INSTALL_PREFIX=/Users/augmentit/.ezvcpkg/2024.11.16/packages/asyncplusplus_arm64-osx-unity/debug" "-DFETCHCONTENT_FULLY_DISCONNECTED=ON" "-DCMAKE_MAKE_PROGRAM=/Users/augmentit/.ezvcpkg/2024.11.16/downloads/tools/ninja/1.10.2-osx/ninja" "-DCMAKE_SYSTEM_NAME=Darwin" "-DBUILD_SHARED_LIBS=OFF" "-DVCPKG_CHAINLOAD_TOOLCHAIN_FILE=/Users/augmentit/.ezvcpkg/2024.11.16/scripts/toolchains/osx.cmake" "-DVCPKG_TARGET_TRIPLET=arm64-osx-unity" "-DVCPKG_SET_CHARSET_FLAG=ON" "-DVCPKG_PLATFORM_TOOLSET=external" "-DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON" "-DCMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY=ON" "-DCMAKE_FIND_PACKAGE_NO_SYSTEM_PACKAGE_REGISTRY=ON" "-DCMAKE_INSTALL_SYSTEM_RUNTIME_LIBS_SKIP=TRUE" "-DCMAKE_VERBOSE_MAKEFILE=ON" "-DVCPKG_APPLOCAL_DEPS=OFF" "-DCMAKE_TOOLCHAIN_FILE=/Users/augmentit/.ezvcpkg/2024.11.16/scripts/buildsystems/vcpkg.cmake" "-DCMAKE_ERROR_ON_ABSOLUTE_INSTALL_DESTINATION=ON" "-DVCPKG_CXX_FLAGS=" "-DVCPKG_CXX_FLAGS_RELEASE=" "-DVCPKG_CXX_FLAGS_DEBUG=" "-DVCPKG_C_FLAGS=" "-DVCPKG_C_FLAGS_RELEASE=" "-DVCPKG_C_FLAGS_DEBUG=" "-DVCPKG_CRT_LINKAGE=dynamic" "-DVCPKG_LINKER_FLAGS=" "-DVCPKG_LINKER_FLAGS_RELEASE=" "-DVCPKG_LINKER_FLAGS_DEBUG=" "-DVCPKG_TARGET_ARCHITECTURE=arm64" "-DCMAKE_INSTALL_LIBDIR:STRING=lib" "-DCMAKE_INSTALL_BINDIR:STRING=bin" "-D_VCPKG_ROOT_DIR=/Users/augmentit/.ezvcpkg/2024.11.16" "-D_VCPKG_INSTALLED_DIR=/Users/augmentit/.ezvcpkg/2024.11.16/installed" "-DVCPKG_MANIFEST_INSTALL=OFF" "-DCMAKE_OSX_DEPLOYMENT_TARGET=10.15" "-DCMAKE_OSX_ARCHITECTURES=arm64"
FAILED: ../../arm64-osx-unity-dbg/CMakeCache.txt
"/opt/homebrew/bin/cmake" -E chdir "../../arm64-osx-unity-dbg" "/opt/homebrew/bin/cmake" "/Users/augmentit/.ezvcpkg/2024.11.16/buildtrees/asyncplusplus/src/989edd9fba-8ad1c3cc1a.clean" "-G" "Ninja" "-DCMAKE_BUILD_TYPE=Debug" "-DCMAKE_INSTALL_PREFIX=/Users/augmentit/.ezvcpkg/2024.11.16/packages/asyncplusplus_arm64-osx-unity/debug" "-DFETCHCONTENT_FULLY_DISCONNECTED=ON" "-DCMAKE_MAKE_PROGRAM=/Users/augmentit/.ezvcpkg/2024.11.16/downloads/tools/ninja/1.10.2-osx/ninja" "-DCMAKE_SYSTEM_NAME=Darwin" "-DBUILD_SHARED_LIBS=OFF" "-DVCPKG_CHAINLOAD_TOOLCHAIN_FILE=/Users/augmentit/.ezvcpkg/2024.11.16/scripts/toolchains/osx.cmake" "-DVCPKG_TARGET_TRIPLET=arm64-osx-unity" "-DVCPKG_SET_CHARSET_FLAG=ON" "-DVCPKG_PLATFORM_TOOLSET=external" "-DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON" "-DCMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY=ON" "-DCMAKE_FIND_PACKAGE_NO_SYSTEM_PACKAGE_REGISTRY=ON" "-DCMAKE_INSTALL_SYSTEM_RUNTIME_LIBS_SKIP=TRUE" "-DCMAKE_VERBOSE_MAKEFILE=ON" "-DVCPKG_APPLOCAL_DEPS=OFF" "-DCMAKE_TOOLCHAIN_FILE=/Users/augmentit/.ezvcpkg/2024.11.16/scripts/buildsystems/vcpkg.cmake" "-DCMAKE_ERROR_ON_ABSOLUTE_INSTALL_DESTINATION=ON" "-DVCPKG_CXX_FLAGS=" "-DVCPKG_CXX_FLAGS_RELEASE=" "-DVCPKG_CXX_FLAGS_DEBUG=" "-DVCPKG_C_FLAGS=" "-DVCPKG_C_FLAGS_RELEASE=" "-DVCPKG_C_FLAGS_DEBUG=" "-DVCPKG_CRT_LINKAGE=dynamic" "-DVCPKG_LINKER_FLAGS=" "-DVCPKG_LINKER_FLAGS_RELEASE=" "-DVCPKG_LINKER_FLAGS_DEBUG=" "-DVCPKG_TARGET_ARCHITECTURE=arm64" "-DCMAKE_INSTALL_LIBDIR:STRING=lib" "-DCMAKE_INSTALL_BINDIR:STRING=bin" "-D_VCPKG_ROOT_DIR=/Users/augmentit/.ezvcpkg/2024.11.16" "-D_VCPKG_INSTALLED_DIR=/Users/augmentit/.ezvcpkg/2024.11.16/installed" "-DVCPKG_MANIFEST_INSTALL=OFF" "-DCMAKE_OSX_DEPLOYMENT_TARGET=10.15" "-DCMAKE_OSX_ARCHITECTURES=arm64"
CMake Error at CMakeLists.txt:21 (cmake_minimum_required):
Compatibility with CMake < 3.5 has been removed from CMake.
Update the VERSION argument <min> value. Or, use the <min>...<max> syntax
to tell CMake that the project requires at least <min> but has been updated
to work with policies introduced by <max> or earlier.
Or, add -DCMAKE_POLICY_VERSION_MINIMUM=3.5 to try configuring anyway.
-- Configuring incomplete, errors occurred!
ninja: build stopped: subcommand failed.
I did try to use the following command without result.
cmake -B build -S . -DCMAKE_BUILD_TYPE=Debug -DCMAKE_POLICY_VERSION_MINIMUM=4.0
I also tried to change version manually, but seems the file is always overwritten when using the Cesium make command.
I don’t have much experience with CMake, so please be kind if I missed something obvious. Any help would be very much appreciated.
Thanks for reading
Cheers