Issues with compiling c++ code with CMake

I’ve been messing around with Cesium-Unity repo locally I’ve had it working fine for a few days but I had to switch gears the other day, so I moved to another branch without the cesium plugin. When I got back to my environment I walked through the developer setup again but kept running into an issue when compiling the c++ code.

The error I got is:

...\com.cesium.unity\native~\Runtime\src\UnityPrepareRendererResources.cpp(15,10):
error C1083: Cannot open include file: 'CesiumGltf/ExtensionModelExtFeatureMetadata.h':
No such file or directory [...\com.cesium.unity\native~\build\Runtime\CesiumForUnityNative-Runtime.vcxproj]

I have tried re cloning the repo, updating the submodules, running dotnet publish Reinterop~ -o . again and opening and closing Unity a bunch of times… I’m kinda at a loss not sure what broke with me switching branches to one without the submodule and then switching back to the one with it, but since then I have not successfully got cesium-unity working on my project.

1 Like

Hi @joshuaWhite,

Sorry about the confusion. We’re in the process of reorganizing Cesium Native right now, so some classes got deleted and stuff has been moved around. You’re welcome to delete any references CesiumGltf/ExtensionModelExtFeatureMetadata.h and CesiumGltf/ExtensionMeshPrimitiveExtFeatureMetadata.h, since they no longer exist in Cesium Native.

Let us know if you run into any further compilation errors!

Awesome that was the issue thank you for the help.

So quick follow up issue I’m now trying to build to android with cesium-unity repo in the packages and I’m getting an error in the build.log here is the full log.

CMake Deprecation Warning at extern/tidy-html5/CMakeLists.txt:20 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


CMake Warning (dev) at extern/tidy-html5/CMakeLists.txt:26 (project):
  Policy CMP0048 is not set: project() command manages VERSION variables.
  Run "cmake --help-policy CMP0048" for policy details.  Use the cmake_policy
  command to set the policy and suppress this warning.

  The following variable(s) would be set to empty:

    PROJECT_VERSION
    PROJECT_VERSION_MAJOR
    PROJECT_VERSION_MINOR
    PROJECT_VERSION_PATCH
This warning is for project developers.  Use -Wno-dev to suppress it.

-> TIDY_SO_VERSION = 59. This is an ODD (development) release.
-- *** Debug Logging is NOT enabled.
-- *** Building support for runtime configuration files.
-- *** Only building static library STATIC, version 5.9.14, date 2021.08.17
CMake Deprecation Warning at extern/cesium-native/extern/KTX-Software/cmake/cputypetest.cmake:4 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.
Call Stack (most recent call first):
  extern/cesium-native/extern/KTX-Software/CMakeLists.txt:23 (include)


-- Could NOT find Vulkan (missing: Vulkan_LIBRARY) (found version "1.2.158")
-- Vulkan SDK not found -> skipping mkvk target (this is harmless; only needed when re-generating of vulkan headers and dfdutils is required)
--   AVX2 backend    - OFF
--   SSE4.1 backend  - OFF
--   SSE2 backend    - OFF
--   NEON backend    -  ON
--   NONE backend    - OFF
--   NATIVE backend  - OFF
--   Decompressor    - OFF
--   Diagnostics     - OFF
--   Unit tests      - OFF
-- Could NOT find OpenGL (missing: OPENGL_opengl_LIBRARY OPENGL_glx_LIBRARY OPENGL_INCLUDE_DIR) 
-- Could NOT find PNG (missing: PNG_LIBRARY PNG_PNG_INCLUDE_DIR) 
-- Could NOT find JPEG (missing: JPEG_LIBRARY JPEG_INCLUDE_DIR) 
TIFF is disabled when statically linking.
-- Could NOT find GIF (missing: GIF_LIBRARY GIF_INCLUDE_DIR) 
-- Performing Test WEBP_HAVE_FLAG_SSE41
-- Performing Test WEBP_HAVE_FLAG_SSE41 - Failed
-- Performing Test WEBP_HAVE_FLAG_SSE41
-- Performing Test WEBP_HAVE_FLAG_SSE41 - Failed
-- Performing Test HAS_COMPILE_FLAG
-- Performing Test HAS_COMPILE_FLAG - Success
-- Performing Test WEBP_HAVE_FLAG_SSE2
-- Performing Test WEBP_HAVE_FLAG_SSE2 - Failed
-- Performing Test WEBP_HAVE_FLAG_SSE2
-- Performing Test WEBP_HAVE_FLAG_SSE2 - Failed
-- Performing Test HAS_COMPILE_FLAG
-- Performing Test HAS_COMPILE_FLAG - Success
-- Performing Test WEBP_HAVE_FLAG_MIPS32
-- Performing Test WEBP_HAVE_FLAG_MIPS32 - Failed
-- Performing Test WEBP_HAVE_FLAG_MIPS32
-- Performing Test WEBP_HAVE_FLAG_MIPS32 - Failed
-- Performing Test WEBP_HAVE_FLAG_MIPS_DSP_R2
-- Performing Test WEBP_HAVE_FLAG_MIPS_DSP_R2 - Failed
-- Performing Test WEBP_HAVE_FLAG_MIPS_DSP_R2
-- Performing Test WEBP_HAVE_FLAG_MIPS_DSP_R2 - Failed
-- Performing Test HAS_COMPILE_FLAG
-- Performing Test HAS_COMPILE_FLAG - Success
-- Performing Test WEBP_HAVE_FLAG_NEON
-- Performing Test WEBP_HAVE_FLAG_NEON - Success
-- Performing Test WEBP_HAVE_FLAG_MSA
-- Performing Test WEBP_HAVE_FLAG_MSA - Failed
-- Performing Test WEBP_HAVE_FLAG_MSA
-- Performing Test WEBP_HAVE_FLAG_MSA - Failed
-- Performing Test HAS_COMPILE_FLAG
-- Performing Test HAS_COMPILE_FLAG - Success
CMake Deprecation Warning at extern/cesium-native/extern/uriparser/CMakeLists.txt:37 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


-- ===========================================================================
-- 
-- Configuration
--   Build type ............. RelWithDebInfo
--   Shared libraries ....... OFF
--   Compiler flags
--     C .................... -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fexceptions  -fvisibility=hidden
--     C++ .................. -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fexceptions -frtti -stdlib=libc++  -fvisibility=hidden
--   Linker flags
--     Executable ........... -Wl,--build-id=sha1 -Wl,--no-rosegment -Wl,--fatal-warnings -Qunused-arguments -Wl,--no-undefined  -Wl,--gc-sections
--     Module ............... -Wl,--build-id=sha1 -Wl,--no-rosegment -Wl,--fatal-warnings -Qunused-arguments -Wl,--no-undefined
--     Shared ............... -Wl,--build-id=sha1 -Wl,--no-rosegment -Wl,--fatal-warnings -Qunused-arguments -Wl,--no-undefined
--   Paths
--     Prefix ............... D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/Plugins/Android/arm64
--     qhelpgenerator ....... 
-- 
--   Features
--     Code for char * ...... ON
--     Code for wchar_t * ... ON
--     Tools ................ OFF
--     Test suite ........... OFF
--     Documentation ........ OFF
-- 
-- Continue with
--   make
--   make test
--   sudo make install
-- 
-- ===========================================================================
CMake Warning (dev) at extern/cesium-native/extern/draco/CMakeLists.txt:39 (include):
  Policy CMP0148 is not set: The FindPythonInterp and FindPythonLibs modules
  are removed.  Run "cmake --help-policy CMP0148" for policy details.  Use
  the cmake_policy command to set the policy and suppress this warning.

This warning is for project developers.  Use -Wno-dev to suppress it.

CMake Deprecation Warning at extern/cesium-native/extern/meshoptimizer/CMakeLists.txt:1 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


CMake Deprecation Warning at extern/cesium-native/extern/glm/CMakeLists.txt:1 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


CMake Deprecation Warning at extern/cesium-native/extern/glm/CMakeLists.txt:2 (cmake_policy):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


CMake Deprecation Warning at extern/cesium-native/extern/asyncplusplus/CMakeLists.txt:21 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


-- Build spdlog: 1.10.0
-- Build type: RelWithDebInfo
-- Project 'expected_lite', package 'expected-lite' version: '0.6.2'
-- Using CMake version 3.28.3
-- ZLIB_HEADER_VERSION: 1.3.0
-- ZLIBNG_HEADER_VERSION: 2.1.6
-- Arch detected: 'aarch64-none-linux-android21'
-- Basearch of 'aarch64-none-linux-android21' has been detected as: 'arm'
-- Using CMake toolchain: extern/android-toolchain.cmake
CMake Warning (dev) at C:/Program Files/CMake/share/cmake-3.28/Modules/CMakeDependentOption.cmake:89 (message):
  Policy CMP0127 is not set: cmake_dependent_option() supports full Condition
  Syntax.  Run "cmake --help-policy CMP0127" for policy details.  Use the
  cmake_policy command to set the policy and suppress this warning.
Call Stack (most recent call first):
  build-Android-arm64/extern/cesium-native/extern/zlib-ng-src/CMakeLists.txt:105 (cmake_dependent_option)
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Architecture-specific source files: arch/arm/arm_features.c;arch/arm/crc32_acle.c;arch/arm/insert_string_acle.c;arch/arm/adler32_neon.c;arch/arm/chunkset_neon.c;arch/arm/compare256_neon.c;arch/arm/slide_hash_neon.c;arch/arm/slide_hash_armv6.c
-- The following features have been enabled:

 * CMAKE_BUILD_TYPE, Build type: RelWithDebInfo (selected)
 * ACLE_CRC, Support ACLE optimized CRC hash generation, using "-march=armv8-a+crc"
 * NEON_ADLER32, Support NEON instructions in adler32, using "-march=armv8-a+simd"
 * NEON_SLIDEHASH, Support NEON instructions in slide_hash, using "-march=armv8-a+simd"
 * ARMV6, Support ARMv6 SIMD instructions in slide_hash, using ""
 * WITH_GZFILEOP, Compile with support for gzFile related functions
 * ZLIB_ENABLE_TESTS, Build test binaries
 * ZLIBNG_ENABLE_TESTS, Test zlib-ng specific API
 * WITH_SANITIZER, Enable sanitizer support
 * WITH_OPTIM, Build with optimisation
 * WITH_NEW_STRATEGIES, Use new strategies
 * WITH_ACLE, Build with ACLE
 * WITH_NEON, Build with NEON intrinsics
 * WITH_ARMV6, Build with ARMv6 SIMD

-- The following OPTIONAL packages have been found:

 * Git
 * ZLIB

-- The following REQUIRED packages have been found:

 * Bash
 * Threads

-- The following features have been disabled:

 * ZLIB_SYMBOL_PREFIX, Publicly exported symbols DO NOT have a custom prefix
 * ZLIB_COMPAT, Compile with zlib compatible API
 * WITH_GTEST, Build gtest_zlib
 * WITH_FUZZERS, Build test/fuzz
 * WITH_BENCHMARKS, Build test/benchmarks
 * WITH_BENCHMARK_APPS, Build application benchmarks
 * WITH_NATIVE_INSTRUCTIONS, Instruct the compiler to use the full instruction set on this host (gcc/clang -march=native)
 * WITH_MAINTAINER_WARNINGS, Build with project maintainer warnings
 * WITH_CODE_COVERAGE, Enable code coverage reporting
 * WITH_INFLATE_STRICT, Build with strict inflate distance checking
 * WITH_INFLATE_ALLOW_INVALID_DIST, Build with zero fill for inflate invalid distances
 * INSTALL_UTILS, Copy minigzip and minideflate during install

-- The following OPTIONAL packages have not been found:

 * Vulkan
 * OpenGL
 * PNG
 * JPEG
 * GIF

-- Could NOT find Doxygen (missing: DOXYGEN_EXECUTABLE) 
-- Configuring done (20.4s)
CMake Warning in extern/cesium-native/extern/draco/CMakeLists.txt:
  The object file directory

    D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/draco/CMakeFiles/draco_compression_attributes_dec.dir/

  has 177 characters.  The maximum full path to an object file is 250
  characters (see CMAKE_OBJECT_PATH_MAX).  Object file

    src/draco/compression/attributes/sequential_attribute_decoders_controller.cc.o

  cannot be safely placed under this directory.  The build may not work
  correctly.


CMake Warning in extern/cesium-native/extern/draco/CMakeLists.txt:
  The object file directory

    D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/draco/CMakeFiles/draco_compression_attributes_enc.dir/

  has 177 characters.  The maximum full path to an object file is 250
  characters (see CMAKE_OBJECT_PATH_MAX).  Object file

    src/draco/compression/attributes/sequential_integer_attribute_encoder.cc.o

  cannot be safely placed under this directory.  The build may not work
  correctly.


CMake Warning in extern/cesium-native/extern/draco/CMakeLists.txt:
  The object file directory

    D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/draco/CMakeFiles/draco_compression_attributes_pred_schemes_enc.dir/

  has 190 characters.  The maximum full path to an object file is 250
  characters (see CMAKE_OBJECT_PATH_MAX).  Object file

    4903a2f1d67bacb7cbad22462a10a95f/prediction_scheme_encoder_factory.cc.o

  cannot be safely placed under this directory.  The build may not work
  correctly.


-- Generating done (4.6s)
-- Build files have been written to: D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64

 
uild[  0%] Built target sqlite3
[  0%] Built target libjpeg-turbo
[  0%] Built target cpufeatures
[  0%] Built target Async++
[  0%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_compression_point_cloud_dec.dir/src/draco/compression/point_cloud/point_cloud_decoder.cc.o
[  0%] Built target sharpyuv
[  1%] Built target tinyxml2
[  1%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_compression_point_cloud_dec.dir/src/draco/compression/point_cloud/point_cloud_kd_tree_decoder.cc.o
[  2%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_compression_point_cloud_dec.dir/src/draco/compression/point_cloud/point_cloud_sequential_decoder.cc.o
[  2%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_compression_attributes_pred_schemes_enc.dir/4903a2f1d67bacb7cbad22462a10a95f/prediction_scheme_encoder_factory.cc.o
[  3%] Built target uriparser
[  3%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_point_cloud.dir/src/draco/point_cloud/point_cloud.cc.o
[  3%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_points_dec.dir/src/draco/compression/point_cloud/algorithms/dynamic_integer_points_kd_tree_decoder.cc.o
[  3%] Built target webputilsdecode
[  6%] Built target webputils
[  7%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_points_enc.dir/src/draco/compression/point_cloud/algorithms/dynamic_integer_points_kd_tree_encoder.cc.o
[  7%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_animation.dir/src/draco/animation/keyframe_animation.cc.o
[  7%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_animation_dec.dir/src/draco/animation/keyframe_animation_decoder.cc.o
[  7%] Built target draco_compression_decode
[  7%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_point_cloud.dir/src/draco/point_cloud/point_cloud_builder.cc.o
[  9%] Built target spdlog
[ 10%] Built target draco_compression_bit_coders
[ 10%] Built target draco_attributes
[ 10%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_points_dec.dir/src/draco/compression/point_cloud/algorithms/float_points_tree_decoder.cc.o
[ 10%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_points_enc.dir/src/draco/compression/point_cloud/algorithms/float_points_tree_encoder.cc.o
[ 10%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_animation_enc.dir/src/draco/animation/keyframe_animation_encoder.cc.o
[ 13%] Built target webpdspdecode
[ 14%] Built target webpdecode
[ 15%] Built target draco_core
[ 15%] Building C object extern/cesium-native/extern/zlib-ng/CMakeFiles/zlib.dir/arch/arm/slide_hash_armv6.c.o
[ 15%] Building C object extern/cesium-native/extern/zlib-ng/CMakeFiles/zlib.dir/gzlib.c.o
[ 15%] Building C object extern/cesium-native/extern/zlib-ng/CMakeFiles/zlib.dir/gzread.c.o
[ 18%] Built target ktx_read
[ 21%] Built target webpdsp
[ 23%] Built target webpencode
[ 26%] Built target s2geometry
[ 26%] Built target draco_compression_entropy
[ 26%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_io.dir/src/draco/io/file_reader_factory.cc.o
[ 26%] Building C object extern/cesium-native/extern/zlib-ng/CMakeFiles/zlib.dir/gzwrite.c.o
[ 27%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_io.dir/src/draco/io/file_utils.cc.o
[ 28%] Built target draco_compression_attributes_enc
[ 30%] Built target draco_compression_attributes_dec
[ 30%] Built target draco_compression_mesh_enc
[ 30%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_io.dir/src/draco/io/file_writer_factory.cc.o
[ 30%] Built target draco_compression_encode
[ 30%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_compression_point_cloud_enc.dir/src/draco/compression/point_cloud/point_cloud_encoder.cc.o
[ 30%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_compression_point_cloud_enc.dir/src/draco/compression/point_cloud/point_cloud_kd_tree_encoder.cc.o
[ 31%] Built target draco_compression_mesh_dec
[ 31%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_io.dir/src/draco/io/file_writer_utils.cc.o
[ 31%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_mesh.dir/src/draco/mesh/corner_table.cc.o
[ 31%] Built target draco_metadata_enc
[ 31%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_compression_point_cloud_enc.dir/src/draco/compression/point_cloud/point_cloud_sequential_encoder.cc.o
D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/zlib-ng-src/arch/arm/slide_hash_armv6.c:13:16: error: unknown type name 'uint16x2_t'; did you mean 'uint16_t'?
    Z_REGISTER uint16x2_t v;
               ^~~~~~~~~~
               uint16_t
D:/UnityHub/2022.3.16f1/Editor/Data/PlaybackEngines/AndroidPlayer/NDK/toolchains/llvm/prebuilt/windows-x86_64/bin/../sysroot/usr/include\stdint.h:62:23: note: 'uint16_t' declared here
typedef __uint16_t    uint16_t;
                      ^
D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/zlib-ng-src/arch/arm/slide_hash_armv6.c:14:5: error: unknown type name 'uint16x2_t'; did you mean 'uint16_t'?
    uint16x2_t p0, p1, p2, p3;
    ^~~~~~~~~~
    uint16_t
D:/UnityHub/2022.3.16f1/Editor/Data/PlaybackEngines/AndroidPlayer/NDK/toolchains/llvm/prebuilt/windows-x86_64/bin/../sysroot/usr/include\stdint.h:62:23: note: 'uint16_t' declared here
typedef __uint16_t    uint16_t;
                      ^
D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/zlib-ng-src/arch/arm/slide_hash_armv6.c:23:24: error: use of undeclared identifier 'uint16x2_t'
    n = size / (sizeof(uint16x2_t) * 4);
                       ^
D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/zlib-ng-src/arch/arm/slide_hash_armv6.c:25:23: error: unknown type name 'uint16x2_t'; did you mean 'uint16_t'?
        p0 = *((const uint16x2_t *)(table));
                      ^~~~~~~~~~
                      uint16_t
D:/UnityHub/2022.3.16f1/Editor/Data/PlaybackEngines/AndroidPlayer/NDK/toolchains/llvm/prebuilt/windows-x86_64/bin/../sysroot/usr/include\stdint.h:62:23: note: 'uint16_t' declared here
typedef __uint16_t    uint16_t;
                      ^
D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/zlib-ng-src/arch/arm/slide_hash_armv6.c:26:23: error: unknown type name 'uint16x2_t'; did you mean 'uint16_t'?
        p1 = *((const uint16x2_t *)(table+2));
                      ^~~~~~~~~~
                      uint16_t
D:/UnityHub/2022.3.16f1/Editor/Data/PlaybackEngines/AndroidPlayer/NDK/toolchains/llvm/prebuilt/windows-x86_64/bin/../sysroot/usr/include\stdint.h:62:23: note: 'uint16_t' declared here
typedef __uint16_t    uint16_t;
                      ^
D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/zlib-ng-src/arch/arm/slide_hash_armv6.c:27:23: error: unknown type name 'uint16x2_t'; did you mean 'uint16_t'?
        p2 = *((const uint16x2_t *)(table+4));
                      ^~~~~~~~~~
                      uint16_t
D:/UnityHub/2022.3.16f1/Editor/Data/PlaybackEngines/AndroidPlayer/NDK/toolchains/llvm/prebuilt/windows-x86_64/bin/../sysroot/usr/include\stdint.h:62:23: note: 'uint16_t' declared here
typedef __uint16_t    uint16_t;
                      ^
D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/zlib-ng-src/arch/arm/slide_hash_armv6.c:28:23: error: unknown type name 'uint16x2_t'; did you mean 'uint16_t'?
        p3 = *((const uint16x2_t *)(table+6));
                      ^~~~~~~~~~
                      uint16_t
D:/UnityHub/2022.3.16f1/Editor/Data/PlaybackEngines/AndroidPlayer/NDK/toolchains/llvm/prebuilt/windows-x86_64/bin/../sysroot/usr/include\stdint.h:62:23: note: 'uint16_t' declared here
typedef __uint16_t    uint16_t;
                      ^
D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/zlib-ng-src/arch/arm/slide_hash_armv6.c:29:14: warning: implicit declaration of function '__uqsub16' is invalid in C99 [-Wimplicit-function-declaration]
        p0 = __uqsub16(p0, v);
             ^
D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/zlib-ng-src/arch/arm/slide_hash_armv6.c:33:24: error: expected expression
        *((uint16x2_t *)(table)) = p0;
                       ^
D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/zlib-ng-src/arch/arm/slide_hash_armv6.c:33:12: error: use of undeclared identifier 'uint16x2_t'
        *((uint16x2_t *)(table)) = p0;
           ^
D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/zlib-ng-src/arch/arm/slide_hash_armv6.c:34:24: error: expected expression
        *((uint16x2_t *)(table+2)) = p1;
                       ^
D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/zlib-ng-src/arch/arm/slide_hash_armv6.c:34:12: error: use of undeclared identifier 'uint16x2_t'
        *((uint16x2_t *)(table+2)) = p1;
           ^
D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/zlib-ng-src/arch/arm/slide_hash_armv6.c:35:24: error: expected expression
        *((uint16x2_t *)(table+4)) = p2;
                       ^
D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/zlib-ng-src/arch/arm/slide_hash_armv6.c:35:12: error: use of undeclared identifier 'uint16x2_t'
        *((uint16x2_t *)(table+4)) = p2;
           ^
D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/zlib-ng-src/arch/arm/slide_hash_armv6.c:36:24: error: expected expression
        *((uint16x2_t *)(table+6)) = p3;
                       ^
D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/zlib-ng-src/arch/arm/slide_hash_armv6.c:36:12: error: use of undeclared identifier 'uint16x2_t'
        *((uint16x2_t *)(table+6)) = p3;
           ^
1 warning and 15 errors generated.
make[2]: *** [extern/cesium-native/extern/zlib-ng/CMakeFiles/zlib.dir/build.make:552: extern/cesium-native/extern/zlib-ng/CMakeFiles/zlib.dir/arch/arm/slide_hash_armv6.c.o] Error 1
make[2]: *** Waiting for unfinished jobs....
[ 31%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_io.dir/src/draco/io/mesh_io.cc.o
make[1]: *** [CMakeFiles/Makefile2:2559: extern/cesium-native/extern/zlib-ng/CMakeFiles/zlib.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 31%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_mesh.dir/src/draco/mesh/mesh.cc.o
[ 31%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_io.dir/src/draco/io/obj_decoder.cc.o
[ 31%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_metadata_dec.dir/src/draco/metadata/metadata_decoder.cc.o
[ 31%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_mesh.dir/src/draco/mesh/mesh_are_equivalent.cc.o
[ 31%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_mesh.dir/src/draco/mesh/mesh_attribute_corner_table.cc.o
[ 31%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_io.dir/src/draco/io/parser_utils.cc.o
[ 31%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_io.dir/src/draco/io/ply_decoder.cc.o
[ 31%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_io.dir/src/draco/io/obj_encoder.cc.o
[ 31%] Built target draco_animation_dec
[ 31%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_mesh.dir/src/draco/mesh/mesh_cleanup.cc.o
[ 31%] Built target draco_animation_enc
[ 32%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_io.dir/src/draco/io/point_cloud_io.cc.o
[ 32%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_io.dir/src/draco/io/ply_encoder.cc.o
[ 32%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_io.dir/src/draco/io/ply_reader.cc.o
[ 32%] Built target draco_animation
[ 32%] Built target draco_metadata_dec
[ 32%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_mesh.dir/src/draco/mesh/mesh_misc_functions.cc.o
[ 32%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_mesh.dir/src/draco/mesh/mesh_stripifier.cc.o
[ 34%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_mesh.dir/src/draco/mesh/triangle_soup_mesh_builder.cc.o
[ 34%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_io.dir/src/draco/io/stdio_file_writer.cc.o
[ 34%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_io.dir/src/draco/io/stdio_file_reader.cc.o
[ 34%] Built target draco_compression_point_cloud_dec
[ 34%] Built target draco_compression_point_cloud_enc
[ 34%] Built target draco_compression_attributes_pred_schemes_enc
[ 34%] Built target draco_point_cloud
[ 34%] Built target draco_mesh
[ 34%] Built target draco_points_dec
[ 34%] Built target draco_points_enc
[ 34%] Built target draco_io
make: *** [Makefile:156: all] Error 2

k
: **
k
: **

The build completes but when running the build on the quest headset the cesium map does not load and I spam errors in my console like so.

"NotImplementedException: The native implementation is missing so UpdateCredits cannot be invoked. This may be caused by a missing call to CreateImplementation in one of your constructors, or it may be that the entire native implementation shared library i"

I’m guessing this is related to the issues I’m having.

Ok so to try and fix the app building issues I rebased my local changes onto the latest on main for cesium-unity and then I ran the git submodule update --init --recursive command just to make sure I get any submodule changes. Then I re did dotnet publish Reinterop~ -o . opened Unity to get the c# code compiled, and lastly I ran these commands to compile the c++ code with CMake.

cmake -B build -S . -DCMAKE_BUILD_TYPE=RelWithDebInfo
cmake --build build -j14 --target install --config RelWithDebInfo

I’m now getting these errors on the compiling:

C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: The command "setlocal [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: "C:\Program Files\CMake\bin\cmake.exe" -DBUILD_TYPE=RelWithDebInfo -P cmake_install.cmake [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: if %errorlevel% neq 0 goto :cmEnd [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: :cmEnd [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: endlocal & call :cmErrorLevel %errorlevel% & goto :cmDone [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: :cmErrorLevel [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: exit /b %1 [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: :cmDone [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: if %errorlevel% neq 0 goto :VCEnd [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: :VCEnd" exited with code 1. [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]

and a close and re-open of Unity is still showing that the code hasn’t compiled correctly…

Hey @joshuaWhite,

Can I trouble you to clean your extern folder and re-download all the submodules? And then try again. We’ve been trying to sort out the cesium-native changes, and ultimately reverted the ones that changed our submodules. I hope a clean build / reinstall of the libraries can solve your issue.

Just deleted my extern folder and redid

git submodule update --init --recursive

It re populated the folder and then after going through the developer setup steps again. I was still met with my latest errors “error MSB3073” from Visual Studios trying to run the cmake.exe

Not sure if anything else on my side is messed up. My cesium-unity branch is based on the current main of cesium-unity and the native submodule points to the commit 09c1eb76 - Merge pull request #798 from CesiumGS/upgrade-to-zlib-ng on cesium-native should I have the native module point to latest on main? or an earlier commit?

Hi @joshuaWhite,

Yeah, I recommend updating to the latest commit on main in cesium-native. We still have to update cesium-unity for last night’s changes in cesium-native. :grimacing: Apologies for the inconvenience!

Just pointed to latest on cesium-native and rebuilt everything still same errors error MSB3073

C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: The command "setlocal [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: "C:\Program Files\CMake\bin\cmake.exe" -DBUILD_TYPE=RelWithDebInfo -P cmake_install.cmake [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: if %errorlevel% neq 0 goto :cmEnd [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: :cmEnd [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: endlocal & call :cmErrorLevel %errorlevel% & goto :cmDone [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: :cmErrorLevel [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: exit /b %1 [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: :cmDone [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: if %errorlevel% neq 0 goto :VCEnd [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(166,5): error MSB3073: :VCEnd" exited with code 1. [D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build\install.vcxproj]

I tend to see these errors when I try building while Unity itself is open. In other words, I have to close Unity before I do cmake --build build -j14 --target install --config RelWithDebInfo.

Does that make a difference?

1 Like

Yup that was it… man do I feel dumb now. Thank you so much for your help.

1 Like

Sorry about all the bugging I got it working in editor again. Latest cesium-native commit and latest cesium-unity commit though while building my app still getting issues.

make[2]: *** No rule to make target 'extern/cesium-native/extern/draco/CMakeFiles/draco_compression_attributes_pred_schemes_enc.dir/4903a2f1d67bacb7cbad22462a10a95f/prediction_scheme_encoder_factory.cc.o', needed by 'extern/cesium-native/extern/draco/libdraco.a'.  Stop.
make[1]: *** [CMakeFiles/Makefile2:2330: extern/cesium-native/extern/draco/CMakeFiles/draco_static.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 56%] Linking CXX static library libCesiumGeometry.a
[ 56%] Linking CXX static library libCesiumAsync.a
[ 56%] Built target CesiumGeometry
[ 56%] Built target CesiumAsync
[ 57%] Linking CXX static library libCesiumJsonReader.a
[ 57%] Built target CesiumJsonReader
[ 57%] Linking CXX static library libCesiumGltf.a
[ 57%] Built target CesiumGltf
[ 57%] Linking CXX static library libktx_read.a
[ 57%] Built target ktx_read
make: *** [Makefile:156: all] Error 2

Everything seems to be working fine in editor just when I build nothing shows up. The log above is a snippet from the cesium build.log from my latest test.

Tried building again today, pulled latest from cesium-native just incase that fixed the issues with building I was having last week. But I’m still running into an issue making the android build of my app with my custom cesium-unity in the project.

Here is the error that pops up in the Editor while it is building:

An error occurred while building CesiumForUnityNative. See D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build-Android-arm64\build.log for details. The command-line was:
cmake --build "D:\Github\Wooorld-Quest-Google-Submodule\Packages\com.cesium.unity\native~\build-Android-arm64" --config RelWithDebInfo --parallel 25 --target install
UnityEngine.Debug:LogError (object)
CesiumForUnity.CompileCesiumForUnityNative:RunAndLog (System.Diagnostics.ProcessStartInfo,System.IO.StreamWriter,string) (at ./Packages/com.cesium.unity/Editor/CompileCesiumForUnityNative.cs:512)
CesiumForUnity.CompileCesiumForUnityNative:BuildNativeLibrary (CesiumForUnity.CompileCesiumForUnityNative/LibraryToBuild) (at ./Packages/com.cesium.unity/Editor/CompileCesiumForUnityNative.cs:478)
CesiumForUnity.CompileCesiumForUnityNative:OnPostBuildPlayerScriptDLLs (UnityEditor.Build.Reporting.BuildReport) (at ./Packages/com.cesium.unity/Editor/CompileCesiumForUnityNative.cs:210)
UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)

Here is the build.log file:

CMake Deprecation Warning at extern/tidy-html5/CMakeLists.txt:20 (cmake_minimum_required):
-- *** Debug Logging is NOT enabled.
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


CMake Warning (dev) at extern/tidy-html5/CMakeLists.txt:26 (project):
  Policy CMP0048 is not set: project() command manages VERSION variables.
  Run "cmake --help-policy CMP0048" for policy details.  Use the cmake_policy
  command to set the policy and suppress this warning.

  The following variable(s) would be set to empty:

    PROJECT_VERSION
    PROJECT_VERSION_MAJOR
    PROJECT_VERSION_MINOR
    PROJECT_VERSION_PATCH
This warning is for project developers.  Use -Wno-dev to suppress it.

-> TIDY_SO_VERSION = 59. This is an ODD (development) release.
-- *** Building support for runtime configuration files.
-- *** Only building static library STATIC, version 5.9.14, date 2021.08.17
CMake Deprecation Warning at extern/cesium-native/extern/KTX-Software/cmake/cputypetest.cmake:4 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.
Call Stack (most recent call first):
  extern/cesium-native/extern/KTX-Software/CMakeLists.txt:23 (include)


-- Could NOT find Vulkan (missing: Vulkan_LIBRARY) (found version "1.2.158")
-- Vulkan SDK not found -> skipping mkvk target (this is harmless; only needed when re-generating of vulkan headers and dfdutils is required)
--   AVX2 backend    - OFF
--   SSE4.1 backend  - OFF
--   SSE2 backend    - OFF
--   NEON backend    -  ON
--   NONE backend    - OFF
--   NATIVE backend  - OFF
--   Decompressor    - OFF
--   Diagnostics     - OFF
--   Unit tests      - OFF
-- Could NOT find OpenGL (missing: OPENGL_opengl_LIBRARY OPENGL_glx_LIBRARY OPENGL_INCLUDE_DIR) 
-- Could NOT find PNG (missing: PNG_LIBRARY PNG_PNG_INCLUDE_DIR) 
TIFF is disabled when statically linking.
                                                                  -- Could NOT find GIF (missing: GIF_LIBRARY GIF_INCLUDE_DIR) 
-- Performing Test WEBP_HAVE_FLAG_SSE41
-- Performing Test WEBP_HAVE_FLAG_SSE41 - Failed
-- Performing Test WEBP_HAVE_FLAG_SSE41
-- Performing Test WEBP_HAVE_FLAG_SSE41 - Failed
-- Performing Test HAS_COMPILE_FLAG
-- Performing Test HAS_COMPILE_FLAG - Success
-- Performing Test WEBP_HAVE_FLAG_SSE2
-- Performing Test WEBP_HAVE_FLAG_SSE2 - Failed
-- Performing Test WEBP_HAVE_FLAG_SSE2
-- Performing Test WEBP_HAVE_FLAG_SSE2 - Failed
-- Performing Test HAS_COMPILE_FLAG
-- Performing Test HAS_COMPILE_FLAG - Success
-- Performing Test WEBP_HAVE_FLAG_MIPS32
-- Performing Test WEBP_HAVE_FLAG_MIPS32 - Failed
-- Performing Test WEBP_HAVE_FLAG_MIPS32
-- Performing Test WEBP_HAVE_FLAG_MIPS32 - Failed
-- Performing Test WEBP_HAVE_FLAG_MIPS_DSP_R2
-- Performing Test WEBP_HAVE_FLAG_MIPS_DSP_R2 - Failed
-- Performing Test WEBP_HAVE_FLAG_MIPS_DSP_R2
-- Performing Test WEBP_HAVE_FLAG_MIPS_DSP_R2 - Failed
-- Performing Test HAS_COMPILE_FLAG
-- Performing Test HAS_COMPILE_FLAG - Success
-- Performing Test WEBP_HAVE_FLAG_NEON
-- Performing Test WEBP_HAVE_FLAG_NEON - Success
-- Performing Test WEBP_HAVE_FLAG_MSA
-- Performing Test WEBP_HAVE_FLAG_MSA - Failed
-- Performing Test WEBP_HAVE_FLAG_MSA
-- Performing Test WEBP_HAVE_FLAG_MSA - Failed
-- Performing Test HAS_COMPILE_FLAG
-- Performing Test HAS_COMPILE_FLAG - Success
CMake Deprecation Warning at extern/cesium-native/extern/uriparser/CMakeLists.txt:37 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


-- ===========================================================================
-- 
-- Configuration
--   Build type ............. RelWithDebInfo
--   Shared libraries ....... OFF
--   Compiler flags
--     C .................... -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fexceptions  -fvisibility=hidden
--     C++ .................. -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fexceptions -frtti -stdlib=libc++  -fvisibility=hidden
--   Linker flags
--     Executable ........... -Wl,--build-id=sha1 -Wl,--no-rosegment -Wl,--fatal-warnings -Qunused-arguments -Wl,--no-undefined  -Wl,--gc-sections
--     Module ............... -Wl,--build-id=sha1 -Wl,--no-rosegment -Wl,--fatal-warnings -Qunused-arguments -Wl,--no-undefined
--     Shared ............... -Wl,--build-id=sha1 -Wl,--no-rosegment -Wl,--fatal-warnings -Qunused-arguments -Wl,--no-undefined
--   Paths
--     Prefix ............... D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/Plugins/Android/arm64
--     qhelpgenerator ....... 
-- 
--   Features
--     Code for char * ...... ON
--     Code for wchar_t * ... ON
--     Tools ................ OFF
--     Test suite ........... OFF
--     Documentation ........ OFF
-- 
-- Continue with
--   make
--   make test
--   sudo make install
-- 
-- ===========================================================================
CMake Warning (dev) at extern/cesium-native/extern/draco/CMakeLists.txt:39 (include):
  Policy CMP0148 is not set: The FindPythonInterp and FindPythonLibs modules
  are removed.  Run "cmake --help-policy CMP0148" for policy details.  Use
  the cmake_policy command to set the policy and suppress this warning.

This warning is for project developers.  Use -Wno-dev to suppress it.

CMake Deprecation Warning at extern/cesium-native/extern/meshoptimizer/CMakeLists.txt:1 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


CMake Deprecation Warning at extern/cesium-native/extern/glm/CMakeLists.txt:1 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


CMake Deprecation Warning at extern/cesium-native/extern/glm/CMakeLists.txt:2 (cmake_policy):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


CMake Deprecation Warning at extern/cesium-native/extern/asyncplusplus/CMakeLists.txt:21 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


-- Build spdlog: 1.10.0
-- Build type: RelWithDebInfo
-- Project 'expected_lite', package 'expected-lite' version: '0.6.2'
CMake Deprecation Warning at build-Android-arm64/extern/cesium-native/extern/zlib-src/CMakeLists.txt:1 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


CMake Warning (dev) at build-Android-arm64/extern/cesium-native/extern/zlib-src/CMakeLists.txt:4 (project):
  Policy CMP0048 is not set: project() command manages VERSION variables.
  Run "cmake --help-policy CMP0048" for policy details.  Use the cmake_policy
  command to set the policy and suppress this warning.

  The following variable(s) would be set to empty:

    PROJECT_VERSION
    PROJECT_VERSION_MAJOR
    PROJECT_VERSION_MINOR
    PROJECT_VERSION_PATCH
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Renaming
--     D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/zlib-src/zconf.h
-- to 'zconf.h.included' because this file is included with zlib
-- but CMake generates it automatically in the build directory.
-- Could NOT find Doxygen (missing: DOXYGEN_EXECUTABLE) 
-- Configuring done (22.4s)
CMake Warning in extern/cesium-native/extern/draco/CMakeLists.txt:
  The object file directory

    D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/draco/CMakeFiles/draco_compression_attributes_dec.dir/

  has 177 characters.  The maximum full path to an object file is 250
  characters (see CMAKE_OBJECT_PATH_MAX).  Object file

    src/draco/compression/attributes/sequential_attribute_decoders_controller.cc.o

  cannot be safely placed under this directory.  The build may not work
  correctly.


CMake Warning in extern/cesium-native/extern/draco/CMakeLists.txt:
  The object file directory

    D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/draco/CMakeFiles/draco_compression_attributes_enc.dir/

  has 177 characters.  The maximum full path to an object file is 250
  characters (see CMAKE_OBJECT_PATH_MAX).  Object file

    src/draco/compression/attributes/sequential_integer_attribute_encoder.cc.o

  cannot be safely placed under this directory.  The build may not work
  correctly.


CMake Warning in extern/cesium-native/extern/draco/CMakeLists.txt:
  The object file directory

    D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/draco/CMakeFiles/draco_compression_attributes_pred_schemes_enc.dir/

  has 190 characters.  The maximum full path to an object file is 250
  characters (see CMAKE_OBJECT_PATH_MAX).  Object file

    4903a2f1d67bacb7cbad22462a10a95f/prediction_scheme_encoder_factory.cc.o

  cannot be safely placed under this directory.  The build may not work
  correctly.


-- Generating done (6.4s)
-- Build files have been written to: D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64

 
uild[  1%] Built target libjpeg-turbo
[  1%] Built target csprng
[  1%] Built target tinyxml2
[  1%] Built target modp_b64
[  1%] Built target Async++
[  1%] Building CXX object extern/cesium-native/extern/draco/CMakeFiles/draco_compression_attributes_pred_schemes_enc.dir/4903a2f1d67bacb7cbad22462a10a95f/prediction_scheme_encoder_factory.cc.o
[  1%] Built target sqlite3
[  2%] Built target cpufeatures
[  2%] Built target draco_animation_enc
[  2%] Built target draco_compression_decode
[  2%] Built target draco_metadata_enc
[  2%] Built target draco_animation
[  3%] Built target webputilsdecode
[  3%] Built target draco_metadata_dec
[  5%] Built target draco_compression_point_cloud_dec
[  5%] Built target draco_points_enc
[  6%] Built target webpdecode
[  7%] Built target draco_attributes
[  9%] Built target webputils
[ 10%] Built target spdlog
[ 11%] Built target draco_compression_entropy
[ 11%] Built target draco_points_dec
[ 13%] Built target sharpyuv
[ 14%] Built target draco_point_cloud
[ 15%] Built target webpdspdecode
[ 15%] Built target webpdecoder
[ 15%] Built target draco_animation_dec
[ 15%] Built target draco_compression_point_cloud_enc
[ 15%] Built target draco_compression_mesh_dec
[ 15%] Built target draco_compression_encode
[ 15%] Built target draco_metadata
[ 18%] Built target zlibstatic
[ 21%] Built target meshoptimizer
[ 21%] Built target draco_compression_attributes_dec
[ 23%] Built target uriparser
[ 25%] Built target draco_compression_attributes_enc
[ 28%] Built target webpdsp
[ 30%] Built target draco_compression_bit_coders
[ 31%] Built target draco_core
[ 32%] Built target draco_mesh
[ 32%] Built target draco_compression_mesh_enc
[ 34%] Built target s2geometry
[ 38%] Built target tidy-static
[ 39%] Built target draco_io
[ 43%] Built target webpencode
[ 44%] Built target CesiumUtility
[ 44%] Built target webp
[ 48%] Built target ktx_read
[ 48%] Built target Cesium3DTiles
[ 51%] Built target CesiumJsonReader
[ 52%] Built target CesiumAsync
[ 52%] Building CXX object extern/cesium-native/Cesium3DTilesReader/CMakeFiles/Cesium3DTilesReader.dir/generated/src/GeneratedJsonHandlers.cpp.o
[ 52%] Building CXX object extern/cesium-native/Cesium3DTilesReader/CMakeFiles/Cesium3DTilesReader.dir/generated/src/registerExtensions.cpp.o
[ 52%] Building CXX object extern/cesium-native/CesiumIonClient/CMakeFiles/CesiumIonClient.dir/src/Connection.cpp.o
[ 52%] Building CXX object extern/cesium-native/CesiumIonClient/CMakeFiles/CesiumIonClient.dir/src/Response.cpp.o
[ 52%] Building CXX object extern/cesium-native/Cesium3DTilesReader/CMakeFiles/Cesium3DTilesReader.dir/src/SubtreeFileReader.cpp.o
[ 52%] Building CXX object extern/cesium-native/CesiumIonClient/CMakeFiles/CesiumIonClient.dir/src/fillWithRandomBytes.cpp.o
[ 52%] Building CXX object extern/cesium-native/CesiumIonClient/CMakeFiles/CesiumIonClient.dir/src/parseLinkHeader.cpp.o
[ 55%] Built target CesiumGeometry
[ 55%] Building CXX object extern/cesium-native/CesiumGeospatial/CMakeFiles/CesiumGeospatial.dir/src/BoundingRegion.cpp.o
[ 55%] Building CXX object extern/cesium-native/CesiumGeospatial/CMakeFiles/CesiumGeospatial.dir/src/BoundingRegionBuilder.cpp.o
[ 56%] Building CXX object extern/cesium-native/CesiumGeospatial/CMakeFiles/CesiumGeospatial.dir/src/BoundingRegionWithLooseFittingHeights.cpp.o
[ 56%] Building CXX object extern/cesium-native/CesiumGeospatial/CMakeFiles/CesiumGeospatial.dir/src/CartographicPolygon.cpp.o
[ 56%] Building CXX object extern/cesium-native/CesiumGeospatial/CMakeFiles/CesiumGeospatial.dir/src/Ellipsoid.cpp.o
[ 56%] Building CXX object extern/cesium-native/CesiumGeospatial/CMakeFiles/CesiumGeospatial.dir/src/EllipsoidTangentPlane.cpp.o
[ 56%] Building CXX object extern/cesium-native/CesiumGeospatial/CMakeFiles/CesiumGeospatial.dir/src/GeographicProjection.cpp.o
[ 56%] Building CXX object extern/cesium-native/CesiumGeospatial/CMakeFiles/CesiumGeospatial.dir/src/GlobeAnchor.cpp.o
[ 56%] Building CXX object extern/cesium-native/CesiumGeospatial/CMakeFiles/CesiumGeospatial.dir/src/GlobeRectangle.cpp.o
[ 56%] Building CXX object extern/cesium-native/CesiumGeospatial/CMakeFiles/CesiumGeospatial.dir/src/GlobeTransforms.cpp.o
[ 56%] Building CXX object extern/cesium-native/CesiumGeospatial/CMakeFiles/CesiumGeospatial.dir/src/HilbertOrder.cpp.o
[ 56%] Building CXX object extern/cesium-native/CesiumGeospatial/CMakeFiles/CesiumGeospatial.dir/src/LocalHorizontalCoordinateSystem.cpp.o
[ 57%] Building CXX object extern/cesium-native/CesiumGeospatial/CMakeFiles/CesiumGeospatial.dir/src/Projection.cpp.o
[ 57%] Building CXX object extern/cesium-native/CesiumGeospatial/CMakeFiles/CesiumGeospatial.dir/src/S2CellBoundingVolume.cpp.o
[ 57%] Building CXX object extern/cesium-native/CesiumGeospatial/CMakeFiles/CesiumGeospatial.dir/src/S2CellID.cpp.o
[ 57%] Building CXX object extern/cesium-native/CesiumGeospatial/CMakeFiles/CesiumGeospatial.dir/src/SimplePlanarEllipsoidCurve.cpp.o
[ 57%] Building CXX object extern/cesium-native/CesiumGltf/CMakeFiles/CesiumGltf.dir/src/Accessor.cpp.o
[ 57%] Building CXX object extern/cesium-native/CesiumGltf/CMakeFiles/CesiumGltf.dir/src/AccessorUtility.cpp.o
[ 59%] Building CXX object extern/cesium-native/CesiumGltf/CMakeFiles/CesiumGltf.dir/src/FeatureIdTextureView.cpp.o
[ 59%] Building CXX object extern/cesium-native/CesiumGeospatial/CMakeFiles/CesiumGeospatial.dir/src/WebMercatorProjection.cpp.o
[ 59%] Building CXX object extern/cesium-native/CesiumGltf/CMakeFiles/CesiumGltf.dir/src/KhrTextureTransform.cpp.o
[ 59%] Building CXX object extern/cesium-native/CesiumGeospatial/CMakeFiles/CesiumGeospatial.dir/src/calcQuadtreeMaxGeometricError.cpp.o
[ 59%] Building CXX object extern/cesium-native/CesiumGltf/CMakeFiles/CesiumGltf.dir/src/Model.cpp.o
[ 59%] Building CXX object extern/cesium-native/CesiumGltf/CMakeFiles/CesiumGltf.dir/src/PropertyAttributePropertyView.cpp.o
[ 59%] Building CXX object extern/cesium-native/CesiumGltf/CMakeFiles/CesiumGltf.dir/src/PropertyAttributeView.cpp.o
[ 59%] Building CXX object extern/cesium-native/CesiumGltf/CMakeFiles/CesiumGltf.dir/src/PropertyTableView.cpp.o
[ 59%] Building CXX object extern/cesium-native/CesiumGltf/CMakeFiles/CesiumGltf.dir/src/PropertyTexturePropertyView.cpp.o
[ 59%] Building CXX object extern/cesium-native/CesiumGltf/CMakeFiles/CesiumGltf.dir/src/PropertyTextureView.cpp.o
[ 59%] Building CXX object extern/cesium-native/CesiumGltf/CMakeFiles/CesiumGltf.dir/src/SamplerUtility.cpp.o
[ 59%] Built target draco_compression_attributes_pred_schemes_enc
[ 59%] Linking CXX static library libCesiumGeospatial.a
[ 59%] Built target CesiumGeospatial
make[2]: *** No rule to make target 'extern/cesium-native/extern/draco/CMakeFiles/draco_compression_attributes_pred_schemes_enc.dir/4903a2f1d67bacb7cbad22462a10a95f/prediction_scheme_encoder_factory.cc.o', needed by 'extern/cesium-native/extern/draco/libdraco.a'.  Stop.
make[1]: *** [CMakeFiles/Makefile2:2330: extern/cesium-native/extern/draco/CMakeFiles/draco_static.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 59%] Linking CXX static library libCesiumGltf.a
[ 60%] Built target CesiumGltf
[ 60%] Linking CXX static library libCesiumIonClient.a
[ 60%] Built target CesiumIonClient
[ 60%] Linking CXX static library libCesium3DTilesReader.a
[ 60%] Built target Cesium3DTilesReader
make: *** [Makefile:156: all] Error 2

Seems like I’m getting closer and closer to a successful build. At 60% now according to the build log but still wondering if there is something I’m missing to get a successful build.

Hi @joshuaWhite,

Sorry that you’re still having trouble! Can you share what your Build Settings look like? We can try to replicate your setup and see if we successfully build.

@joshuaWhite To followup on your error log, it looks like you’re having a MAX_PATH error.

CMake Warning in extern/cesium-native/extern/draco/CMakeLists.txt:
  The object file directory

    D:/Github/Wooorld-Quest-Google-Submodule/Packages/com.cesium.unity/native~/build-Android-arm64/extern/cesium-native/extern/draco/CMakeFiles/draco_compression_attributes_dec.dir/

  has 177 characters.  The maximum full path to an object file is 250
  characters (see CMAKE_OBJECT_PATH_MAX).  Object file

    src/draco/compression/attributes/sequential_attribute_decoders_controller.cc.o

  cannot be safely placed under this directory.  The build may not work
  correctly.

Can you check that you have long paths enabled on Windows? If you do, then you may need to shorten the name of your project, or move it to the D:/ drive directly, in order to shorten the path name.

Sorry for the late reply, and thank you so much for this message it led me to figuring out that in Windows 10 Pro the “group policy” overrides the registry. I had already followed the dev guide and enabled long paths but my group policy hadn’t been changed which was overriding it. Once I changed my group policy and restarted my PC I was able to finally successfully build. Thank you so much for all of your help. I did run into another small hiccup with building a package but I was able to eventually figure that out as well, thanks to another post on the forum.

1 Like