From a1b2dc0f73243a65cb21d4b5188729e2eae46e9d Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Fri, 5 Jun 2026 12:53:07 -0500 Subject: [PATCH 01/56] Rearchitect vcpkg port for official submission Add a clean vcpkg-oriented CMake and overlay-port path so the SDK can be consumed through vcpkg across the supported platform set. This keeps vendored dependency builds available by default while enabling vcpkg-provided sqlite, zlib, nlohmann-json, and curl when the vcpkg toolchain is active. Files changed: CMake install/config support, overlay port metadata, vcpkg consumer tests, examples/docs, Obj-C/Swift wrapper source selection, and vcpkg test workflow. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- .gitattributes | 6 + .github/workflows/test-vcpkg.yml | 111 + .gitignore | 3 + CMakeLists.txt | 236 +- cmake/MSTelemetryConfig.cmake.in | 25 + docs/building-with-vcpkg.md | 195 +- examples/c/SampleC-Guest/CMakeLists.txt | 27 +- examples/cmake/MSTelemetrySample.cmake | 50 + examples/cpp/EventSender/CMakeLists.txt | 27 +- examples/cpp/MacProxy/CMakeLists.txt | 27 +- examples/cpp/SampleCpp/CMakeLists.txt | 33 +- examples/cpp/SampleCppMini/CMakeLists.txt | 29 +- examples/cpp/SampleCppMini/main.cpp | 4 +- examples/objc/cocoa-app/CMakeLists.txt | 24 +- examples/swift/SamplePackage/Package.swift | 5 +- .../SwiftWrapperApp.xcodeproj/project.pbxproj | 849 +-- lib/CMakeLists.txt | 282 +- .../app/src/main/cpp/CMakeLists.txt | 2 +- tests/functests/CMakeLists.txt | 2 +- tests/unittests/CMakeLists.txt | 2 +- tests/vcpkg/CMakeLists.txt | 19 + tests/vcpkg/README.md | 111 + tests/vcpkg/main.cpp | 81 + tests/vcpkg/test-vcpkg-android.sh | 99 + tests/vcpkg/test-vcpkg-ios.sh | 161 + tests/vcpkg/test-vcpkg-linux.sh | 58 + tests/vcpkg/test-vcpkg-macos.sh | 63 + tests/vcpkg/test-vcpkg-windows.ps1 | 141 + tests/vcpkg/vcpkg.json | 8 + tools/ports/mstelemetry/CONTROL | 4 - tools/ports/mstelemetry/TODO.md | 9 - tools/ports/mstelemetry/get_repo_name.sh | 6 - tools/ports/mstelemetry/portfile.cmake | 128 +- .../ports/mstelemetry/response_file_linux.txt | 6 - tools/ports/mstelemetry/response_file_mac.txt | 6 - tools/ports/mstelemetry/usage | 4 + tools/ports/mstelemetry/v142-build.patch | 5701 ----------------- tools/ports/mstelemetry/vcpkg.json | 29 + tools/vcpkg | 2 +- wrappers/obj-c/ODWLogger.mm | 34 +- wrappers/swift/Package.swift | 40 +- .../swift/Sources/OneDSSwift/Logger.swift | 4 +- zlib/CMakeLists.txt | 2 +- 43 files changed, 2064 insertions(+), 6591 deletions(-) create mode 100644 .github/workflows/test-vcpkg.yml create mode 100644 cmake/MSTelemetryConfig.cmake.in create mode 100644 examples/cmake/MSTelemetrySample.cmake create mode 100644 tests/vcpkg/CMakeLists.txt create mode 100644 tests/vcpkg/README.md create mode 100644 tests/vcpkg/main.cpp create mode 100755 tests/vcpkg/test-vcpkg-android.sh create mode 100755 tests/vcpkg/test-vcpkg-ios.sh create mode 100755 tests/vcpkg/test-vcpkg-linux.sh create mode 100755 tests/vcpkg/test-vcpkg-macos.sh create mode 100644 tests/vcpkg/test-vcpkg-windows.ps1 create mode 100644 tests/vcpkg/vcpkg.json delete mode 100644 tools/ports/mstelemetry/CONTROL delete mode 100644 tools/ports/mstelemetry/TODO.md delete mode 100755 tools/ports/mstelemetry/get_repo_name.sh delete mode 100644 tools/ports/mstelemetry/response_file_linux.txt delete mode 100644 tools/ports/mstelemetry/response_file_mac.txt create mode 100644 tools/ports/mstelemetry/usage delete mode 100644 tools/ports/mstelemetry/v142-build.patch create mode 100644 tools/ports/mstelemetry/vcpkg.json diff --git a/.gitattributes b/.gitattributes index 8fc60d592..429fefd5c 100644 --- a/.gitattributes +++ b/.gitattributes @@ -87,6 +87,12 @@ GNUmakefile text *.xml text *.cfg text +## Exclude vcpkg port and test scaffolding from GitHub tarballs. +## This avoids a chicken-and-egg problem: the portfile contains a SHA512 +## of the tarball, so changes to the portfile must not change the tarball. +tools/ports/ export-ignore +tests/vcpkg/ export-ignore + ## Self-reference =) .gitignore text .gitattributes text diff --git a/.github/workflows/test-vcpkg.yml b/.github/workflows/test-vcpkg.yml new file mode 100644 index 000000000..a9a25f6e1 --- /dev/null +++ b/.github/workflows/test-vcpkg.yml @@ -0,0 +1,111 @@ +name: Vcpkg port tests + +on: + push: + branches: + - master + - main + - dev + - dev/* + - release/* + - buildme/* + + pull_request: + branches: + - master + - main + - dev + + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: ${{ github.event_name == 'pull_request' }} + +jobs: + windows: + runs-on: windows-latest + name: Windows (x64-windows-static) + steps: + - uses: actions/checkout@v4 + + - name: Bootstrap vcpkg + run: | + git clone https://github.com/microsoft/vcpkg.git ${{ runner.temp }}\vcpkg + & "${{ runner.temp }}\vcpkg\bootstrap-vcpkg.bat" -disableMetrics + shell: pwsh + + - name: Run vcpkg port test + run: .\tests\vcpkg\test-vcpkg-windows.ps1 -VcpkgRoot "${{ runner.temp }}\vcpkg" + shell: pwsh + + linux: + runs-on: ubuntu-latest + name: Linux (x64-linux) + steps: + - uses: actions/checkout@v4 + + - name: Bootstrap vcpkg + run: | + git clone https://github.com/microsoft/vcpkg.git "${{ runner.temp }}/vcpkg" + "${{ runner.temp }}/vcpkg/bootstrap-vcpkg.sh" -disableMetrics + + - name: Run vcpkg port test + env: + VCPKG_ROOT: ${{ runner.temp }}/vcpkg + run: | + chmod +x tests/vcpkg/test-vcpkg-linux.sh + ./tests/vcpkg/test-vcpkg-linux.sh + + macos: + runs-on: macos-latest + name: macOS (native) + steps: + - uses: actions/checkout@v4 + + - name: Bootstrap vcpkg + run: | + git clone https://github.com/microsoft/vcpkg.git "${{ runner.temp }}/vcpkg" + "${{ runner.temp }}/vcpkg/bootstrap-vcpkg.sh" -disableMetrics + + - name: Run vcpkg port test + env: + VCPKG_ROOT: ${{ runner.temp }}/vcpkg + run: | + chmod +x tests/vcpkg/test-vcpkg-macos.sh + ./tests/vcpkg/test-vcpkg-macos.sh + + ios: + runs-on: macos-latest + name: iOS (arm64-ios cross-compile) + steps: + - uses: actions/checkout@v4 + + - name: Bootstrap vcpkg + run: | + git clone https://github.com/microsoft/vcpkg.git "${{ runner.temp }}/vcpkg" + "${{ runner.temp }}/vcpkg/bootstrap-vcpkg.sh" -disableMetrics + + - name: Run vcpkg port test (device) + env: + VCPKG_ROOT: ${{ runner.temp }}/vcpkg + run: | + chmod +x tests/vcpkg/test-vcpkg-ios.sh + ./tests/vcpkg/test-vcpkg-ios.sh + + android: + runs-on: ubuntu-latest + name: Android (arm64-v8a cross-compile) + steps: + - uses: actions/checkout@v4 + + - name: Bootstrap vcpkg + run: | + git clone https://github.com/microsoft/vcpkg.git "${{ runner.temp }}/vcpkg" + "${{ runner.temp }}/vcpkg/bootstrap-vcpkg.sh" -disableMetrics + + - name: Run vcpkg port test + env: + VCPKG_ROOT: ${{ runner.temp }}/vcpkg + run: | + chmod +x tests/vcpkg/test-vcpkg-android.sh + ./tests/vcpkg/test-vcpkg-android.sh arm64-v8a diff --git a/.gitignore b/.gitignore index 515445ff7..af5733868 100644 --- a/.gitignore +++ b/.gitignore @@ -405,3 +405,6 @@ build/.cmake/api/v1/query/client-vscode/query.json #Test files generated locally. *.ses + +# vcpkg test build directories +tests/vcpkg/build-*/ diff --git a/CMakeLists.txt b/CMakeLists.txt index e9d1fdabe..ba010e0ef 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,14 +1,15 @@ -cmake_minimum_required(VERSION 3.1.0) +cmake_minimum_required(VERSION 3.5) project(MSTelemetry LANGUAGES C CXX) -# Set installation prefix for macOS and Linux -if(UNIX AND NOT DEFINED CMAKE_INSTALL_PREFIX) - set(CMAKE_INSTALL_PREFIX "/usr/local" CACHE PATH "Installation directory prefix" FORCE) +################################################################################################ +# Vcpkg dependency mode: detect early so it can guard platform-specific flag logic +################################################################################################ +if(DEFINED VCPKG_TOOLCHAIN OR DEFINED VCPKG_TARGET_TRIPLET) + option(MATSDK_USE_VCPKG_DEPS "Use vcpkg-provided dependencies via find_package()" ON) +else() + option(MATSDK_USE_VCPKG_DEPS "Use vcpkg-provided dependencies via find_package()" OFF) endif() - -set(INSTALL_BIN_DIR "${CMAKE_INSTALL_PREFIX}/bin" CACHE PATH "Installation directory for executables") -set(INSTALL_LIB_DIR "${CMAKE_INSTALL_PREFIX}/lib" CACHE PATH "Installation directory for libraries") -set(INSTALL_INC_DIR "${CMAKE_INSTALL_PREFIX}/include" CACHE PATH "Installation directory for headers") +message(STATUS "MATSDK_USE_VCPKG_DEPS: ${MATSDK_USE_VCPKG_DEPS}") # Begin Uncomment for i386 build #set(CMAKE_SYSTEM_PROCESSOR i386) @@ -24,6 +25,14 @@ if (NOT TARGET_ARCH) endif() # Enable ARC for obj-c on Apple +# Initialize platform options before conditional blocks (needed for config templates) +if(NOT DEFINED BUILD_IOS) + set(BUILD_IOS OFF) +endif() +if(NOT APPLE AND NOT DEFINED BUILD_APPLE_HTTP) + set(BUILD_APPLE_HTTP OFF) +endif() + if(APPLE) message(STATUS "BUILD_IOS: ${BUILD_IOS}") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fobjc-arc") @@ -35,75 +44,86 @@ if(APPLE) set(FORCE_RESET_OSX_DEPLOYMENT_TARGET ${FORCE_RESET_DEPLOYMENT_TARGET}) endif() - if(BUILD_IOS) - set(TARGET_ARCH "APPLE") - set(IOS True) - set(APPLE True) + # When building via vcpkg, the toolchain file handles architecture, sysroot, + # deployment target, and platform flags. Skip manual flag configuration. + if(NOT MATSDK_USE_VCPKG_DEPS) + if(BUILD_IOS) + set(TARGET_ARCH "APPLE") + set(IOS True) + set(APPLE True) + + if(FORCE_RESET_OSX_DEPLOYMENT_TARGET) + set(CMAKE_OSX_DEPLOYMENT_TARGET "" CACHE STRING "Force unset of the deployment target for iOS" FORCE) + if (${IOS_PLAT} STREQUAL "iphonesimulator") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mios-simulator-version-min=${IOS_DEPLOYMENT_TARGET}") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -mios-simulator-version-min=${IOS_DEPLOYMENT_TARGET}") + else() + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -miphoneos-version-min=${IOS_DEPLOYMENT_TARGET}") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -miphoneos-version-min=${IOS_DEPLOYMENT_TARGET}") + endif() + endif() - if(FORCE_RESET_OSX_DEPLOYMENT_TARGET) - set(CMAKE_OSX_DEPLOYMENT_TARGET "" CACHE STRING "Force unset of the deployment target for iOS" FORCE) - if (${IOS_PLAT} STREQUAL "iphonesimulator") - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mios-simulator-version-min=${IOS_DEPLOYMENT_TARGET}") - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -mios-simulator-version-min=${IOS_DEPLOYMENT_TARGET}") + if((${IOS_PLAT} STREQUAL "iphoneos") OR (${IOS_PLAT} STREQUAL "iphonesimulator") OR (${IOS_PLAT} STREQUAL "xros") OR (${IOS_PLAT} STREQUAL "xrsimulator")) + set(IOS_PLATFORM "${IOS_PLAT}") else() - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -miphoneos-version-min=${IOS_DEPLOYMENT_TARGET}") - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -miphoneos-version-min=${IOS_DEPLOYMENT_TARGET}") + message(FATAL_ERROR "Unrecognized iOS platform '${IOS_PLAT}'") endif() - endif() - if((${IOS_PLAT} STREQUAL "iphoneos") OR (${IOS_PLAT} STREQUAL "iphonesimulator") OR (${IOS_PLAT} STREQUAL "xros") OR (${IOS_PLAT} STREQUAL "xrsimulator")) - set(IOS_PLATFORM "${IOS_PLAT}") - else() - message(FATAL_ERROR "Unrecognized iOS platform '${IOS_PLAT}'") - endif() + if(${IOS_ARCH} STREQUAL "x86_64") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -arch x86_64") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -arch x86_64") + set(CMAKE_SYSTEM_PROCESSOR x86_64) + elseif(${IOS_ARCH} STREQUAL "arm64") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -arch arm64") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -arch arm64") + set(CMAKE_SYSTEM_PROCESSOR arm64) + elseif(${IOS_ARCH} STREQUAL "arm64e") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -arch arm64e") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -arch arm64e") + set(CMAKE_SYSTEM_PROCESSOR arm64e) + else() + message(FATAL_ERROR "Unrecognized iOS architecture '${IOS_ARCH}'") + endif() - if(${IOS_ARCH} STREQUAL "x86_64") - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -arch x86_64") - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -arch x86_64") - set(CMAKE_SYSTEM_PROCESSOR x86_64) - elseif(${IOS_ARCH} STREQUAL "arm64") - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -arch arm64") - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -arch arm64") - set(CMAKE_SYSTEM_PROCESSOR arm64) - elseif(${IOS_ARCH} STREQUAL "arm64e") - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -arch arm64e") - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -arch arm64e") - set(CMAKE_SYSTEM_PROCESSOR arm64e) + execute_process(COMMAND xcodebuild -version -sdk ${IOS_PLATFORM} ONLY_ACTIVE_ARCH=NO Path + OUTPUT_VARIABLE CMAKE_OSX_SYSROOT + ERROR_QUIET + OUTPUT_STRIP_TRAILING_WHITESPACE) + message(STATUS "CMAKE_OSX_SYSROOT ${CMAKE_OSX_SYSROOT}") + message(STATUS "ARCHITECTURE: ${CMAKE_SYSTEM_PROCESSOR}") + message(STATUS "PLATFORM: ${IOS_PLATFORM}") else() - message(FATAL_ERROR "Unrecognized iOS architecture '${IOS_ARCH}'") + if("${MAC_ARCH}" STREQUAL "x86_64") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -arch x86_64") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -arch x86_64") + set(CMAKE_SYSTEM_PROCESSOR x86_64) + set(TARGET_ARCH ${CMAKE_SYSTEM_PROCESSOR}) + set(CMAKE_OSX_ARCHITECTURES ${MAC_ARCH}) + set(APPLE True) + elseif("${MAC_ARCH}" STREQUAL "arm64") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -arch arm64") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -arch arm64") + set(CMAKE_SYSTEM_PROCESSOR arm64) + set(TARGET_ARCH ${CMAKE_SYSTEM_PROCESSOR}) + set(CMAKE_OSX_ARCHITECTURES ${MAC_ARCH}) + set(APPLE True) + else() + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -arch x86_64 -arch arm64") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -arch x86_64 -arch arm64") + endif() + message(STATUS "MAC_ARCH: ${MAC_ARCH}") endif() - - execute_process(COMMAND xcodebuild -version -sdk ${IOS_PLATFORM} ONLY_ACTIVE_ARCH=NO Path - OUTPUT_VARIABLE CMAKE_OSX_SYSROOT - ERROR_QUIET - OUTPUT_STRIP_TRAILING_WHITESPACE) - message(STATUS "CMAKE_OSX_SYSROOT ${CMAKE_OSX_SYSROOT}") - message(STATUS "ARCHITECTURE: ${CMAKE_SYSTEM_PROCESSOR}") - message(STATUS "PLATFORM: ${IOS_PLATFORM}") else() - if(${MAC_ARCH} STREQUAL "x86_64") - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -arch x86_64") - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -arch x86_64") - set(CMAKE_SYSTEM_PROCESSOR x86_64) - set(TARGET_ARCH ${CMAKE_SYSTEM_PROCESSOR}) - set(CMAKE_OSX_ARCHITECTURES ${MAC_ARCH}) - set(APPLE True) - elseif(${MAC_ARCH} STREQUAL "arm64") - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -arch arm64") - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -arch arm64") - set(CMAKE_SYSTEM_PROCESSOR arm64) - set(TARGET_ARCH ${CMAKE_SYSTEM_PROCESSOR}) - set(CMAKE_OSX_ARCHITECTURES ${MAC_ARCH}) - set(APPLE True) - else() - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -arch x86_64 -arch arm64") - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -arch x86_64 -arch arm64") + # vcpkg mode: just set internal flags from what the toolchain provides + if(BUILD_IOS OR CMAKE_SYSTEM_NAME STREQUAL "iOS") + set(BUILD_IOS ON) + set(TARGET_ARCH "APPLE") + set(IOS True) endif() - message(STATUS "MAC_ARCH: ${MAC_ARCH}") + message(STATUS "vcpkg toolchain managing architecture and platform flags") endif() endif() -message(STATUS "CMAKE_SYSTEM_INFO_FILE: ${CMAKE_SYSTEM_INFO_FILE}") message(STATUS "CMAKE_SYSTEM_NAME: ${CMAKE_SYSTEM_NAME}") message(STATUS "CMAKE_SYSTEM_PROCESSOR: ${CMAKE_SYSTEM_PROCESSOR}") message(STATUS "CMAKE_SYSTEM: ${CMAKE_SYSTEM}") @@ -114,14 +134,22 @@ message(STATUS "CMAKE_CXX_COMPILER_ID: ${CMAKE_CXX_COMPILER_ID}") include(tools/ParseOsRelease.cmake) +# When building via vcpkg, let the toolchain manage compiler flags. +# Only apply project-specific flags for non-vcpkg (legacy) builds. +if(NOT MATSDK_USE_VCPKG_DEPS) + if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "MSVC") set(WARN_FLAGS "/W4 /WX") elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") # -Wno-unknown-warning-option is Clang-only, omitted here set(WARN_FLAGS "-Wall -Werror -Wextra -Wno-unused-parameter -Wno-unused-but-set-variable") + # -Wno-reorder is C++-only; added to CXX_FLAGS below (suppresses member-init-order warnings in submodule code) + set(CXX_EXTRA_WARN_FLAGS "-Wno-reorder") else() # Clang / AppleClang set(WARN_FLAGS "-Wall -Werror -Wextra -Wno-unused-parameter -Wno-unknown-warning-option -Wno-unused-but-set-variable") + # -Wno-reorder is C++-only; added to CXX_FLAGS below (suppresses member-init-order warnings in submodule code) + set(CXX_EXTRA_WARN_FLAGS "-Wno-reorder") endif() if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") @@ -149,13 +177,13 @@ if (NOT CMAKE_BUILD_TYPE STREQUAL "Debug") #TODO: -fno-rtti message(STATUS "Building Release ...") set(CMAKE_C_FLAGS "$ENV{CFLAGS} ${CMAKE_C_FLAGS} -std=c11 ${REL_FLAGS}") - set(CMAKE_CXX_FLAGS "$ENV{CXXFLAGS} ${CMAKE_CXX_FLAGS} -std=c++11 ${REL_FLAGS}") + set(CMAKE_CXX_FLAGS "$ENV{CXXFLAGS} ${CMAKE_CXX_FLAGS} -std=c++11 ${REL_FLAGS} ${CXX_EXTRA_WARN_FLAGS}") else() set(USE_TCMALLOC 1) message(STATUS "Building Debug ...") include(tools/FindTcmalloc.cmake) set(CMAKE_C_FLAGS "$ENV{CFLAGS} ${CMAKE_C_FLAGS} -std=c11 ${DBG_FLAGS}") - set(CMAKE_CXX_FLAGS "$ENV{CXXFLAGS} ${CMAKE_CXX_FLAGS} -std=c++11 ${DBG_FLAGS}") + set(CMAKE_CXX_FLAGS "$ENV{CXXFLAGS} ${CMAKE_CXX_FLAGS} -std=c++11 ${DBG_FLAGS} ${CXX_EXTRA_WARN_FLAGS}") endif() #Remove /Zi for Win32 debug compiler issue @@ -180,7 +208,11 @@ elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "MSVC") # using Visual Studio C++ endif() +endif() # NOT MATSDK_USE_VCPKG_DEPS (compiler flags) + include(tools/Utils.cmake) +include(GNUInstallDirs) +include(CMakePackageConfigHelpers) if (NOT DEFAULT_PAL_IMPLEMENTATION) if(MSVC) @@ -212,7 +244,7 @@ if(USE_ONEDS_SECURE_MEM_FUNCTIONS) add_definitions(-DUSE_ONEDS_SECURE_MEM_FUNCTIONS) endif() -if(PAL_IMPLEMENTATION STREQUAL "WIN32") +if(PAL_IMPLEMENTATION STREQUAL "WIN32" AND NOT MATSDK_USE_VCPKG_DEPS) add_definitions(-DZLIB_WINAPI) endif() @@ -244,26 +276,7 @@ endif() message(STATUS "SDK version: ${SDK_VERSION_PREFIX}-${MATSDK_BUILD_VERSION}") ################################################################################################ -# HTTP stack section -################################################################################################ - -# Only use custom curl if compiling with CPP11 PAL -if (PAL_IMPLEMENTATION STREQUAL "CPP11") - - if(NOT BUILD_IOS) - include(FindCURL) - find_package(CURL REQUIRED) - if (NOT CURL_FOUND) - message (FATAL_ERROR "libcurl not found! Have you installed deps?") - endif (NOT CURL_FOUND) - include_directories(CURL_INCLUDE_DIRS) - set(CMAKE_REQUIRED_LIBRARIES "${CURL_LIBRARIES}") - list(APPEND LIBS "${CURL_LIBRARIES}") - endif() -endif() - -################################################################################################ -# User options +# User options (must be before HTTP stack section for BUILD_APPLE_HTTP) ################################################################################################ option(BUILD_HEADERS "Build API headers" YES) option(BUILD_LIBRARY "Build library" YES) @@ -288,6 +301,45 @@ if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin") option(BUILD_APPLE_HTTP "Build Apple HTTP client" YES) endif() +if(BUILD_APPLE_HTTP) + add_definitions(-DAPPLE_HTTP=1) +endif() + +################################################################################################ +# HTTP stack section +################################################################################################ + +# Only use custom curl if compiling with CPP11 PAL +set(MATSDK_NEEDS_CURL OFF) +if(PAL_IMPLEMENTATION STREQUAL "CPP11" + AND NOT BUILD_IOS + AND NOT CMAKE_SYSTEM_NAME STREQUAL "Android" + AND NOT BUILD_APPLE_HTTP) + set(MATSDK_NEEDS_CURL ON) + find_package(CURL REQUIRED) + if(MATSDK_USE_VCPKG_DEPS) + list(APPEND LIBS CURL::libcurl) + else() + include_directories(CURL_INCLUDE_DIRS) + set(CMAKE_REQUIRED_LIBRARIES "${CURL_LIBRARIES}") + list(APPEND LIBS "${CURL_LIBRARIES}") + endif() +endif() + +################################################################################################ +# Dependency resolution (vcpkg mode vs vendored) +################################################################################################ +if(MATSDK_USE_VCPKG_DEPS) + find_package(unofficial-sqlite3 CONFIG REQUIRED) + find_package(ZLIB REQUIRED) + find_package(nlohmann_json CONFIG REQUIRED) + message(STATUS "Using vcpkg-provided sqlite3, zlib, nlohmann-json") +else() + # Include repo root to allow includes of vendored sqlite, zlib, and nlohmann + include_directories(${CMAKE_SOURCE_DIR}) + message(STATUS "Using vendored sqlite3, zlib, nlohmann-json") +endif() + if(BUILD_UNIT_TESTS OR BUILD_FUNC_TESTS) message(STATUS "Adding gtest") add_library(gtest STATIC IMPORTED GLOBAL) @@ -295,10 +347,6 @@ if(BUILD_UNIT_TESTS OR BUILD_FUNC_TESTS) add_library(gmock STATIC IMPORTED GLOBAL) endif() -if(BUILD_APPLE_HTTP) - add_definitions(-DAPPLE_HTTP=1) -endif() - # Bond Lite subdirectories include_directories(bondlite/include) @@ -309,10 +357,6 @@ include_directories(lib/pal) # enable_testing() # add_subdirectory(bondlite/tests) #endif() - -# Include repo root to allow includes of sqlite, zlib, and nlohmann -include_directories(${CMAKE_SOURCE_DIR}) - if(BUILD_HEADERS) add_subdirectory(lib/include) endif() diff --git a/cmake/MSTelemetryConfig.cmake.in b/cmake/MSTelemetryConfig.cmake.in new file mode 100644 index 000000000..0ad3351e9 --- /dev/null +++ b/cmake/MSTelemetryConfig.cmake.in @@ -0,0 +1,25 @@ +@PACKAGE_INIT@ + +include(CMakeFindDependencyMacro) + +# Re-find dependencies that consumers need +find_dependency(unofficial-sqlite3 CONFIG) +find_dependency(ZLIB) +find_dependency(nlohmann_json CONFIG) + +# Curl is needed on Linux (not Windows/iOS/Android/macOS-with-Apple-HTTP). +# We capture the build-time decision as a boolean rather than re-deriving +# it, because the macOS BUILD_APPLE_HTTP edge case can't be inferred from +# CMAKE_SYSTEM_NAME alone. +if(@MATSDK_NEEDS_CURL@) + find_dependency(CURL) +endif() + +# Pthreads are needed on Linux and Android (POSIX threading) +if(CMAKE_SYSTEM_NAME STREQUAL "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "Android") + find_dependency(Threads) +endif() + +include("${CMAKE_CURRENT_LIST_DIR}/MSTelemetryTargets.cmake") + +check_required_components(MSTelemetry) diff --git a/docs/building-with-vcpkg.md b/docs/building-with-vcpkg.md index 6312fa18d..83fe5d14b 100644 --- a/docs/building-with-vcpkg.md +++ b/docs/building-with-vcpkg.md @@ -1,10 +1,12 @@ # Building 1DS C++ SDK with vcpkg -vcpkg is a Microsoft cross-platform open source C++ package manager. Onboarding instructions for Windows, Linux and Mac OS X [available here](https://docs.microsoft.com/en-us/cpp/build/vcpkg). This document assumes that the customer build system is already configured to use vcpkg. 1DS C++ SDK maintainers provide a build recipe, `mstelemetry` port or CONTROL file for vcpkg. Mainline vcpkg repo is refreshed to point to latest stable open source release of 1DS C++ SDK. Public build of SDK does not include private submodules. However, local port / CONTROL file included in 1DS C++ SDK git repo allows to build SDK with additional Microsoft-proprietary private submodules. +[vcpkg](https://vcpkg.io/) is a Microsoft cross-platform open source C++ package manager. Onboarding instructions for Windows, Linux and Mac OS X [available here](https://docs.microsoft.com/en-us/cpp/build/vcpkg). This document assumes that the customer build system is already configured to use vcpkg ([getting started guide](https://learn.microsoft.com/en-us/vcpkg/get_started/overview)). 1DS C++ SDK maintainers provide a build recipe, `mstelemetry` port or CONTROL file for vcpkg. The mainline vcpkg repo is refreshed to point to latest stable open source release of 1DS C++ SDK. -## Installing open source mstelemetry package +## Quick Start -The following command can be used to install the public open source release: +### Installing from the vcpkg registry + +Once a new port has been accepted into the official vcpkg registry, install with: ```console vcpkg install mstelemetry @@ -12,83 +14,184 @@ vcpkg install mstelemetry That's it! The package should be compiled for the current OS. -See instructions below to build the SDK with additional Microsoft-proprietary modules. - -## Windows build with submodules +### Installing from the overlay port (development / pre-release) -`cmd.exe` command line prompt commands: +Before the port is published, or to test local changes, use the overlay port +shipped in this repository: ```console -git clone --recurse-submodules https://github.com/microsoft/cpp_client_telemetry +git clone https://github.com/microsoft/cpp_client_telemetry cd cpp_client_telemetry -vcpkg install --head --overlay-ports=%CD%\tools\ports mstelemetry +vcpkg install --overlay-ports=tools/ports mstelemetry ``` -## POSIX (Linux and Mac) build with submodules +### Using in your CMake project -Shell commands: +After installing, add the SDK to your CMake project: -```console -git clone --recurse-submodules https://github.com/microsoft/cpp_client_telemetry -cd cpp_client_telemetry -vcpkg install --head --overlay-ports=`pwd`/tools/ports mstelemetry +```cmake +find_package(MSTelemetry CONFIG REQUIRED) +target_link_libraries(your_target PRIVATE MSTelemetry::mat) ``` -## Using response files to specify dependencies +If you use vcpkg manifest mode (recommended), add `mstelemetry` to your +project's `vcpkg.json`: -vcpkg allows to consolidate parameters passed to vcpkg in a response file. All 3rd party dependencies needed for 1DS SDK can be described and installed via response file. +```json +{ + "dependencies": ["mstelemetry"] +} +``` -Example for Mac: +## Platform-Specific Instructions -```console -vcpkg install @tools/ports/mstelemetry/response_file_mac.txt +### Windows + +```powershell +vcpkg install mstelemetry --triplet=x64-windows-static ``` -Example for Linux: +### Linux -```console -vcpkg install @tools/ports/mstelemetry/response_file_linux.txt +```bash +vcpkg install mstelemetry --triplet=x64-linux ``` -vcpkg build log files are created in `${VCPKG_INSTALL_DIR}/buildtrees/mstelemetry/build-[err|out].log` . Review the logs in case if you encounter package installation failures. +### macOS -## Using triplets +```bash +# Apple Silicon +vcpkg install mstelemetry --triplet=arm64-osx -In order to enable custom build flags - vcpkg triplets and custom environment variables may be used. Please see [triplets instruction here](https://vcpkg.readthedocs.io/en/latest/users/triplets/). Response file for a custom build, e.g. `response_file_linux_PRODUCTNAME.txt` may specify a custom triplet. For example, custom triplet controls if the library is built as static or dynamic. Default triplets may also be overridden with [custom triplets](https://vcpkg.readthedocs.io/en/latest/examples/overlay-triplets-linux-dynamic/#overlay-triplets-example). Custom triplets specific to various products must be maintained by product teams. Product teams may optionally decide to integrate their triplets in the mainline 1DS C++ SDK repo as-needed. +# Intel +vcpkg install mstelemetry --triplet=x64-osx +``` -## Build with vcpkg dependencies +### iOS (cross-compile) -This section needs to be updated with more detailed info. Default `CMakeLists.txt` in top-level directory utilize the following dependencies: +```bash +vcpkg install mstelemetry --triplet=arm64-ios +``` -- OS-provided `sqlite3` library. -- OS-provided `zlib` library. -- SDK-provided snapshot of `nlohmann-json` header-only library. +### iOS Simulator -It is possible to adjust the build system to use vcpkg-installed dependencies instead. +vcpkg ships a built-in community triplet for the iOS Simulator: -### nlohmann-json +```bash +vcpkg install mstelemetry --triplet=arm64-ios-simulator +``` -The package `nlohmann-json` provides CMake targets: +See the [vcpkg triplet documentation](https://learn.microsoft.com/en-us/vcpkg/users/triplets) +for details on creating your own custom triplets for other platforms. -```console - find_package(nlohmann_json CONFIG REQUIRED) - target_link_libraries(main PRIVATE nlohmann_json nlohmann_json::nlohmann_json) +### Android (cross-compile) + +Requires the Android NDK (`ANDROID_NDK_HOME` must be set): + +```bash +vcpkg install mstelemetry --triplet=arm64-android ``` -### sqlite3 +Supported triplets: `arm64-android`, `arm-neon-android`, `x64-android`, +`x86-android`. + +## Dependencies + +The vcpkg port automatically resolves the following dependencies: -The package `sqlite3` provides CMake targets: +| Dependency | vcpkg Package | CMake Target | Platforms | +| -------------- | --------------- | --------------------------------- | ------------------ | +| SQLite3 | `sqlite3` | `unofficial::sqlite3::sqlite3` | All | +| zlib | `zlib` | `ZLIB::ZLIB` | All | +| nlohmann JSON | `nlohmann-json` | `nlohmann_json::nlohmann_json` | All | +| libcurl | `curl[ssl]` | `CURL::libcurl` | Non-Windows, non-Apple, non-Android | + +Windows, macOS/iOS, and Android use platform-native HTTP clients (WinInet, +NSURLSession, and HttpClient_Android respectively), so curl is not required +on those platforms. + +## Optional: SIMD-Optimized zlib with zlib-ng + +The vcpkg port depends on stock `zlib` by default. If you want SIMD-optimized +compression (Intel PCLMULQDQ/AVX2, ARM NEON, etc.), you can transparently +replace zlib with [zlib-ng](https://github.com/zlib-ng/zlib-ng) in +compatibility mode. No changes to the port or SDK code are needed. + +**Add one line to your vcpkg triplet file** (e.g., `x64-windows-static.cmake`): + +```cmake +set(ZLIB_COMPAT ON) +``` + +Then install `zlib-ng` instead of `zlib`: ```console - find_package(unofficial-sqlite3 CONFIG REQUIRED) - target_link_libraries(main PRIVATE unofficial::sqlite3::sqlite3) +vcpkg install zlib-ng mstelemetry --triplet=x64-windows-static ``` -### zlib +With `ZLIB_COMPAT=ON`, zlib-ng installs as a drop-in replacement — it provides +the same `zlib.h` header, the same function names (`deflate`, `inflate`, +`crc32`), and the same `ZLIB::ZLIB` CMake target. All packages that depend on +`zlib` (including `mstelemetry` and any other libraries like `onnxruntime`) +will automatically use the optimized zlib-ng build. -The package zlib is compatible with built-in CMake targets: +> **Important:** All libraries in the same binary should link against the same +> zlib. When using `ZLIB_COMPAT=ON`, ensure all dependencies resolve to +> zlib-ng rather than mixing stock zlib and zlib-ng. -```console - find_package(ZLIB REQUIRED) - target_link_libraries(main PRIVATE ZLIB::ZLIB) +## How It Works: MATSDK_USE_VCPKG_DEPS + +When the SDK detects it is being built via vcpkg (by checking for +`VCPKG_TOOLCHAIN` or `VCPKG_TARGET_TRIPLET`), it automatically sets +`MATSDK_USE_VCPKG_DEPS=ON`. This switches dependency resolution from +vendored sources to vcpkg-provided packages via `find_package()`. + +You can also set this explicitly for custom CMake workflows: + +```bash +cmake -DMATSDK_USE_VCPKG_DEPS=ON \ + -DCMAKE_TOOLCHAIN_FILE=$VCPKG_ROOT/scripts/buildsystems/vcpkg.cmake \ + .. +``` + +## Troubleshooting + +vcpkg build log files are created in +`${VCPKG_INSTALL_DIR}/buildtrees/mstelemetry/`. Review the following logs +if you encounter package installation failures: + +| File | Contents | +| ---- | -------- | +| `build-out.log` | Build stdout (compiler output) | +| `build-err.log` | Build stderr (compiler errors/warnings) | +| `config-*.log` | CMake configure output | + +You can also pass `--debug` to `vcpkg install` for verbose diagnostics. + +## Testing the Port + +Integration tests are provided in `tests/vcpkg/`. Each script builds the +port from the overlay, compiles a test consumer, and runs runtime checks: + +```bash +# Windows (from Developer Command Prompt) +.\tests\vcpkg\test-vcpkg-windows.ps1 -VcpkgRoot C:\path\to\vcpkg + +# Linux +./tests/vcpkg/test-vcpkg-linux.sh + +# macOS +./tests/vcpkg/test-vcpkg-macos.sh + +# iOS (cross-compile — verifies binary is produced) +./tests/vcpkg/test-vcpkg-ios.sh + +# iOS Simulator (builds and runs on simulator) +./tests/vcpkg/test-vcpkg-ios.sh --simulator + +# Android (cross-compile — verifies binary is produced) +./tests/vcpkg/test-vcpkg-android.sh ``` + +See [tests/vcpkg/README.md](../tests/vcpkg/README.md) for prerequisites and +detailed usage. diff --git a/examples/c/SampleC-Guest/CMakeLists.txt b/examples/c/SampleC-Guest/CMakeLists.txt index d5932af4e..2d4a4e368 100644 --- a/examples/c/SampleC-Guest/CMakeLists.txt +++ b/examples/c/SampleC-Guest/CMakeLists.txt @@ -1,46 +1,27 @@ -cmake_minimum_required(VERSION 3.1.0) +cmake_minimum_required(VERSION 3.5) project(SampleC-Guest) # Uncomment for building i386 binary on x86_64 system #set(CMAKE_SYSTEM_PROCESSOR i386) -# For ARM / Raspberry Pi 3 cross-compile -# set(MATSDK_LIB /usr/local/lib/armv7l-linux-gnu) - -# Point example to SDK dirs for x86_64 Desktop -if(EXISTS "/usr/local/lib/libmat.a") -# Use local libmat.a -set(MATSDK_LIB /usr/local/lib/) -else() -# Use architecture-specific libmat.a -set(MATSDK_LIB /usr/local/lib/${CMAKE_SYSTEM_PROCESSOR}-linux-gnu) -endif() +include(${CMAKE_CURRENT_LIST_DIR}/../../cmake/MSTelemetrySample.cmake) set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -ggdb -gdwarf-2 -std=c11") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O0 -ggdb -gdwarf-2 -std=c++11") find_package (Threads) -set(MATSDK_INCLUDE /usr/local/include/mat) - # 1DS SDK to include dirs -include_directories( . ${MATSDK_INCLUDE} ) +include_directories(. ${MATSDK_SAMPLE_INCLUDE_DIRS}) # Link main.cpp to executable add_executable(SampleC-Guest main.cpp demo.c) source_group(" " REGULAR_EXPRESSION "") -# Prefer linking to more recent local sqlite3 -if(EXISTS "/usr/local/lib/libsqlite3.a") -set (SQLITE3_LIB "/usr/local/lib/libsqlite3.a") -else() -set (SQLITE3_LIB "sqlite3") -endif() - set (PLATFORM_LIBS "") # Add flags for obtaining system UUID via IOKit if (CMAKE_SYSTEM_NAME STREQUAL "Darwin") set (PLATFORM_LIBS "-framework CoreFoundation -framework IOKit") endif() -target_link_libraries(SampleC-Guest ${MATSDK_LIB}/libmat.a curl z ${CMAKE_THREAD_LIBS_INIT} ${SQLITE3_LIB} ${PLATFORM_LIBS} dl) +target_link_libraries(SampleC-Guest ${MATSDK_LIBRARY} curl z ${CMAKE_THREAD_LIBS_INIT} ${MATSDK_SQLITE3_LIB} ${MATSDK_SAMPLE_PLATFORM_LIBS} ${PLATFORM_LIBS} dl) diff --git a/examples/cmake/MSTelemetrySample.cmake b/examples/cmake/MSTelemetrySample.cmake new file mode 100644 index 000000000..c2dab5ece --- /dev/null +++ b/examples/cmake/MSTelemetrySample.cmake @@ -0,0 +1,50 @@ +set(_MATSDK_DEFAULT_INSTALL_DIR "/usr/local") +if(NOT "$ENV{MATSDK_INSTALL_DIR}" STREQUAL "") + set(_MATSDK_DEFAULT_INSTALL_DIR "$ENV{MATSDK_INSTALL_DIR}") +endif() + +set(MATSDK_INSTALL_DIR "${_MATSDK_DEFAULT_INSTALL_DIR}" CACHE PATH "MSTelemetry install prefix") +set(MATSDK_INCLUDE_DIR "${MATSDK_INSTALL_DIR}/include/mat" CACHE PATH "MSTelemetry public headers") +set(MATSDK_LIB_DIR "${MATSDK_INSTALL_DIR}/lib" CACHE PATH "MSTelemetry library directory") + +if(NOT EXISTS "${MATSDK_LIB_DIR}/libmat.a" + AND NOT EXISTS "${MATSDK_LIB_DIR}/libmat.dylib" + AND NOT EXISTS "${MATSDK_LIB_DIR}/libmat.so" + AND (EXISTS "${MATSDK_LIB_DIR}/${CMAKE_SYSTEM_PROCESSOR}-linux-gnu/libmat.a" + OR EXISTS "${MATSDK_LIB_DIR}/${CMAKE_SYSTEM_PROCESSOR}-linux-gnu/libmat.so")) + set(MATSDK_LIB_DIR "${MATSDK_LIB_DIR}/${CMAKE_SYSTEM_PROCESSOR}-linux-gnu" CACHE PATH "MSTelemetry library directory" FORCE) +endif() + +find_library(MATSDK_LIBRARY NAMES mat HINTS "${MATSDK_LIB_DIR}" NO_DEFAULT_PATH) +if(NOT MATSDK_LIBRARY) + message(FATAL_ERROR "Could not find libmat under ${MATSDK_LIB_DIR}. Set MATSDK_INSTALL_DIR or MATSDK_LIB_DIR.") +endif() + +if(NOT EXISTS "${MATSDK_INCLUDE_DIR}") + message(FATAL_ERROR "Could not find mat headers under ${MATSDK_INCLUDE_DIR}. Set MATSDK_INSTALL_DIR or MATSDK_INCLUDE_DIR.") +endif() + +set(MATSDK_SAMPLE_INCLUDE_DIRS "${MATSDK_INCLUDE_DIR}") + +set(MATSDK_SAMPLE_PLATFORM_LIBS "") +if(APPLE) + list(APPEND MATSDK_SAMPLE_PLATFORM_LIBS + "-framework CoreFoundation" + "-framework Foundation" + "-framework CFNetwork" + "-framework Network" + "-framework SystemConfiguration" + ) + if(CMAKE_SYSTEM_NAME STREQUAL "iOS") + list(APPEND MATSDK_SAMPLE_PLATFORM_LIBS "-framework UIKit") + else() + list(APPEND MATSDK_SAMPLE_PLATFORM_LIBS "-framework IOKit") + endif() +endif() + +find_library(MATSDK_SQLITE3_LIB NAMES sqlite3 HINTS "${MATSDK_INSTALL_DIR}/lib" NO_DEFAULT_PATH) +if(NOT MATSDK_SQLITE3_LIB) + set(MATSDK_SQLITE3_LIB sqlite3) +endif() + +mark_as_advanced(MATSDK_INSTALL_DIR MATSDK_INCLUDE_DIR MATSDK_LIB_DIR MATSDK_LIBRARY MATSDK_SQLITE3_LIB) diff --git a/examples/cpp/EventSender/CMakeLists.txt b/examples/cpp/EventSender/CMakeLists.txt index 67a1a3ae6..615b96ffe 100644 --- a/examples/cpp/EventSender/CMakeLists.txt +++ b/examples/cpp/EventSender/CMakeLists.txt @@ -1,42 +1,23 @@ -cmake_minimum_required(VERSION 3.1.0) +cmake_minimum_required(VERSION 3.5) project(EventSender) # Uncomment for building i386 binary on x86_64 system #set(CMAKE_SYSTEM_PROCESSOR i386) -# For ARM / Raspberry Pi 3 cross-compile -# set(MAT_SDK_LIB /usr/local/lib/armv7l-linux-gnu) - -# Point example to SDK dirs for x86_64 Desktop -if(EXISTS "/usr/local/lib/libmat.a") -# Use local libmat.a -set(MAT_SDK_LIB /usr/local/lib/) -else() -# Use architecture-specific libmat.a -set(MAT_SDK_LIB /usr/local/lib/${CMAKE_SYSTEM_PROCESSOR}-linux-gnu) -endif() +include(${CMAKE_CURRENT_LIST_DIR}/../../cmake/MSTelemetrySample.cmake) set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -ggdb -gdwarf-2 -std=c11") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O0 -ggdb -gdwarf-2 -std=c++11") find_package (Threads) -set(MAT_SDK_INCLUDE /usr/local/include/mat) - # 1DS SDK to include dirs -include_directories( . ${MAT_SDK_INCLUDE} ) +include_directories(. ${MATSDK_SAMPLE_INCLUDE_DIRS}) # Link main.cpp to executable add_executable(EventSender EventSender.cpp) source_group(" " REGULAR_EXPRESSION "") -# Prefer linking to more recent local sqlite3 -if(EXISTS "/usr/local/lib/libsqlite3.a") -set (SQLITE3_LIB "/usr/local/lib/libsqlite3.a") -else() -set (SQLITE3_LIB "sqlite3") -endif() - set (PLATFORM_LIBS "") # Add flags for obtaining system UUID via IOKit if (CMAKE_SYSTEM_NAME STREQUAL "Darwin") @@ -46,4 +27,4 @@ endif() #tcmalloc turned off by default #target_link_libraries(EventSender ${MAT_SDK_LIB}/libmat.a curl z ${CMAKE_THREAD_LIBS_INIT} ${SQLITE3_LIB} dl tcmalloc) -target_link_libraries(EventSender ${MAT_SDK_LIB}/libmat.a curl z ${CMAKE_THREAD_LIBS_INIT} ${SQLITE3_LIB} ${PLATFORM_LIBS} dl) +target_link_libraries(EventSender ${MATSDK_LIBRARY} curl z ${CMAKE_THREAD_LIBS_INIT} ${MATSDK_SQLITE3_LIB} ${MATSDK_SAMPLE_PLATFORM_LIBS} ${PLATFORM_LIBS} dl) diff --git a/examples/cpp/MacProxy/CMakeLists.txt b/examples/cpp/MacProxy/CMakeLists.txt index 89d4cb233..93f090fae 100644 --- a/examples/cpp/MacProxy/CMakeLists.txt +++ b/examples/cpp/MacProxy/CMakeLists.txt @@ -1,42 +1,23 @@ -cmake_minimum_required(VERSION 3.1.0) +cmake_minimum_required(VERSION 3.5) project(MacProxy) # Uncomment for building i386 binary on x86_64 system #set(CMAKE_SYSTEM_PROCESSOR i386) -# For ARM / Raspberry Pi 3 cross-compile -# set(MAT_SDK_LIB /usr/local/lib/armv7l-linux-gnu) - -# Point example to SDK dirs for x86_64 Desktop -if(EXISTS "/usr/local/lib/libmat.a") -# Use local libmat.a -set(MAT_SDK_LIB /usr/local/lib/) -else() -# Use architecture-specific libmat.a -set(MAT_SDK_LIB /usr/local/lib/${CMAKE_SYSTEM_PROCESSOR}-linux-gnu) -endif() +include(${CMAKE_CURRENT_LIST_DIR}/../../cmake/MSTelemetrySample.cmake) set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -ggdb -gdwarf-2 -std=c11") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O0 -ggdb -gdwarf-2 -std=c++11") find_package (Threads) -set(MAT_SDK_INCLUDE /usr/local/include/mat) - # 1DS SDK to include dirs -include_directories( . ${MAT_SDK_INCLUDE} ) +include_directories(. ${MATSDK_SAMPLE_INCLUDE_DIRS}) # Link main.cpp to executable add_executable(MacProxy main.cpp HttpEventListener.cpp) source_group(" " REGULAR_EXPRESSION "") -# Prefer linking to more recent local sqlite3 -if(EXISTS "/usr/local/lib/libsqlite3.a") -set (SQLITE3_LIB "/usr/local/lib/libsqlite3.a") -else() -set (SQLITE3_LIB "sqlite3") -endif() - set (PLATFORM_LIBS "") # Add flags for obtaining system UUID via IOKit if (CMAKE_SYSTEM_NAME STREQUAL "Darwin") @@ -48,4 +29,4 @@ if (CMAKE_SYSTEM_PROCESSOR STREQUAL "armv7l") set (PLATFORM_LIBS "atomic") endif() -target_link_libraries(MacProxy ${MAT_SDK_LIB}/libmat.a curl z ${CMAKE_THREAD_LIBS_INIT} ${SQLITE3_LIB} ${PLATFORM_LIBS} dl) +target_link_libraries(MacProxy ${MATSDK_LIBRARY} curl z ${CMAKE_THREAD_LIBS_INIT} ${MATSDK_SQLITE3_LIB} ${MATSDK_SAMPLE_PLATFORM_LIBS} ${PLATFORM_LIBS} dl) diff --git a/examples/cpp/SampleCpp/CMakeLists.txt b/examples/cpp/SampleCpp/CMakeLists.txt index b377d0ab2..b1bf8e419 100644 --- a/examples/cpp/SampleCpp/CMakeLists.txt +++ b/examples/cpp/SampleCpp/CMakeLists.txt @@ -1,46 +1,23 @@ -cmake_minimum_required(VERSION 3.1.0) +cmake_minimum_required(VERSION 3.5) project(SampleCpp) # Uncomment for building i386 binary on x86_64 system #set(CMAKE_SYSTEM_PROCESSOR i386) -if (NOT TARGET_ARCH) - set(TARGET_ARCH ${CMAKE_SYSTEM_PROCESSOR}) -endif() - -# For ARM / Raspberry Pi 3 cross-compile -# set(MAT_SDK_LIB /usr/local/lib/armv7l-linux-gnu) - -# Search for static lib first -find_path(MAT_SDK_LIB_PATH NAMES libmat.a PATHS /usr/lib /usr/local/lib /usr/local/lib/${TARGET_ARCH}-linux-gnu) -if (CMAKE_SYSTEM_NAME STREQUAL "Darwin") - # Search for .dylib on Mac OS X - find_path(MAT_SDK_DYLIB_PATH NAMES libmat.dylib PATHS /usr/lib /usr/local/lib) -endif() -find_library(LIBMAT NAMES libmat.a libmat.dylib HINTS ${MAT_SDK_LIB_PATH} ${MAT_SDK_DYLIB_PATH}) +include(${CMAKE_CURRENT_LIST_DIR}/../../cmake/MSTelemetrySample.cmake) set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -ggdb -gdwarf-2 -std=c11") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O0 -ggdb -gdwarf-2 -std=c++11") find_package (Threads) -set(MAT_SDK_INCLUDE /usr/local/include/mat) - # 1DS SDK to include dirs -include_directories( . ${MAT_SDK_INCLUDE} ) +include_directories(. ${MATSDK_SAMPLE_INCLUDE_DIRS}) # Link main.cpp to executable add_executable(SampleCpp main.cpp DebugCallback.cpp demo.c) source_group(" " REGULAR_EXPRESSION "") -# NOTE: modify this sample if necessary to use vcpkg-provided sqlite library -# Prefer linking to more recent local sqlite3 -if(EXISTS "/usr/local/lib/libsqlite3.a") -set (SQLITE3_LIB "/usr/local/lib/libsqlite3.a") -else() -set (SQLITE3_LIB "sqlite3") -endif() - set (PLATFORM_LIBS "") # Add flags for obtaining system UUID via IOKit if (CMAKE_SYSTEM_NAME STREQUAL "Darwin") @@ -55,5 +32,5 @@ endif() #tcmalloc turned off by default #target_link_libraries(SampleCpp ${MAT_SDK_LIB}/libmat.a curl z ${CMAKE_THREAD_LIBS_INIT} ${SQLITE3_LIB} dl tcmalloc) -# TODO: use add_library to allow linking against ${LIBMAT_STATIC} -target_link_libraries(SampleCpp ${LIBMAT} curl z ${CMAKE_THREAD_LIBS_INIT} ${SQLITE3_LIB} ${PLATFORM_LIBS} dl) +# TODO: use add_library to allow linking against a proper exported SDK target +target_link_libraries(SampleCpp ${MATSDK_LIBRARY} curl z ${CMAKE_THREAD_LIBS_INIT} ${MATSDK_SQLITE3_LIB} ${MATSDK_SAMPLE_PLATFORM_LIBS} ${PLATFORM_LIBS} dl) diff --git a/examples/cpp/SampleCppMini/CMakeLists.txt b/examples/cpp/SampleCppMini/CMakeLists.txt index af0fbf873..665237000 100644 --- a/examples/cpp/SampleCppMini/CMakeLists.txt +++ b/examples/cpp/SampleCppMini/CMakeLists.txt @@ -1,42 +1,23 @@ -cmake_minimum_required(VERSION 3.1.0) +cmake_minimum_required(VERSION 3.5) project(SampleCppMini) # Uncomment for building i386 binary on x86_64 system #set(CMAKE_SYSTEM_PROCESSOR i386) -# For ARM / Raspberry Pi 3 cross-compile -# set(MAT_SDK_LIB /usr/local/lib/armv7l-linux-gnu) - -# Point example to SDK dirs for x86_64 Desktop -if(EXISTS "/usr/local/lib/libmat.a") -# Use local libmat.a -set(MAT_SDK_LIB /usr/local/lib/) -else() -# Use architecture-specific libmat.a -set(MAT_SDK_LIB /usr/local/lib/${CMAKE_SYSTEM_PROCESSOR}-linux-gnu) -endif() +include(${CMAKE_CURRENT_LIST_DIR}/../../cmake/MSTelemetrySample.cmake) set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -ggdb -gdwarf-2 -std=c11") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O0 -ggdb -gdwarf-2 -std=c++11") find_package (Threads) -set(MAT_SDK_INCLUDE /usr/local/include/aria) - # 1DS SDK to include dirs -include_directories( . ${MAT_SDK_INCLUDE} ) +include_directories(. ${MATSDK_SAMPLE_INCLUDE_DIRS}) # Link main.cpp to executable -add_executable(SampleCppMini main.cpp DebugCallback.cpp demo.c) +add_executable(SampleCppMini main.cpp demo.c) source_group(" " REGULAR_EXPRESSION "") -# Prefer linking to more recent local sqlite3 -if(EXISTS "/usr/local/lib/libsqlite3.a") -set (SQLITE3_LIB "/usr/local/lib/libsqlite3.a") -else() -set (SQLITE3_LIB "sqlite3") -endif() - set (PLATFORM_LIBS "") # Add flags for obtaining system UUID via IOKit if (CMAKE_SYSTEM_NAME STREQUAL "Darwin") @@ -46,4 +27,4 @@ endif() #tcmalloc turned off by default #target_link_libraries(SampleCppMini ${MAT_SDK_LIB}/libmat.a curl z ${CMAKE_THREAD_LIBS_INIT} ${SQLITE3_LIB} dl tcmalloc) -target_link_libraries(SampleCppMini ${MAT_SDK_LIB}/libmat.a curl z ${CMAKE_THREAD_LIBS_INIT} ${SQLITE3_LIB} ${PLATFORM_LIBS} dl) +target_link_libraries(SampleCppMini ${MATSDK_LIBRARY} curl z ${CMAKE_THREAD_LIBS_INIT} ${MATSDK_SQLITE3_LIB} ${MATSDK_SAMPLE_PLATFORM_LIBS} ${PLATFORM_LIBS} dl) diff --git a/examples/cpp/SampleCppMini/main.cpp b/examples/cpp/SampleCppMini/main.cpp index 5214ebc22..9a94146ce 100644 --- a/examples/cpp/SampleCppMini/main.cpp +++ b/examples/cpp/SampleCppMini/main.cpp @@ -56,8 +56,10 @@ void test_cpp_api(const char * token, int ticketType, const char *ticket) // Log detailed event with various properties EventProperties detailed_event("MyApp.detailed_event", { +#ifdef _MSC_VER // Log compiler version { "_MSC_VER", _MSC_VER }, +#endif // Pii-typed fields { "piiKind.None", EventProperty("field_value", PiiKind_None) }, { "piiKind.DistinguishedName", EventProperty("/CN=Jack Frost,OU=PIE,DC=REDMOND,DC=COM", PiiKind_DistinguishedName) }, @@ -75,7 +77,7 @@ void test_cpp_api(const char * token, int ticketType, const char *ticket) // Various typed key-values { "strKey1", "hello1" }, { "strKey2", "hello2" }, - { "int64Key", 1L }, + { "int64Key", 1LL }, { "dblKey", 3.14 }, { "boolKey", false }, { "guidKey0", GUID_t("00000000-0000-0000-0000-000000000000") }, diff --git a/examples/objc/cocoa-app/CMakeLists.txt b/examples/objc/cocoa-app/CMakeLists.txt index 4d5456a83..1ee932715 100644 --- a/examples/objc/cocoa-app/CMakeLists.txt +++ b/examples/objc/cocoa-app/CMakeLists.txt @@ -1,31 +1,15 @@ -cmake_minimum_required(VERSION 2.8.8) +cmake_minimum_required(VERSION 3.5) project(foo) -# Point example to SDK dirs for x86_64 Desktop -if(EXISTS "/usr/local/lib/libmat.a") -# Use local libmat.a -set(MATSDK_LIB /usr/local/lib/) -else() -# Use architecture-specific libmat.a -set(MATSDK_LIB /usr/local/lib/${CMAKE_SYSTEM_PROCESSOR}-linux-gnu) -endif() +include(${CMAKE_CURRENT_LIST_DIR}/../../cmake/MSTelemetrySample.cmake) set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -ggdb -gdwarf-2 -std=c11") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O0 -ggdb -gdwarf-2 -std=c++11") find_package (Threads) -set(MATSDK_INCLUDE /usr/local/include/mat) - # 1DS SDK to include dirs -include_directories( . ${MATSDK_INCLUDE} ) - -# Prefer linking to more recent local sqlite3 -if(EXISTS "/usr/local/lib/libsqlite3.a") -set (SQLITE3_LIB "/usr/local/lib/libsqlite3.a") -else() -set (SQLITE3_LIB "sqlite3") -endif() +include_directories(. ${MATSDK_SAMPLE_INCLUDE_DIRS}) set (PLATFORM_LIBS "") # Add flags for obtaining system UUID via IOKit @@ -57,4 +41,4 @@ set_target_properties( ${CMAKE_CURRENT_LIST_DIR}/plist.in ) -target_link_libraries(foo ${MATSDK_LIB}/libmat.a curl z ${CMAKE_THREAD_LIBS_INIT} ${SQLITE3_LIB} ${PLATFORM_LIBS} dl) +target_link_libraries(foo ${MATSDK_LIBRARY} curl z ${CMAKE_THREAD_LIBS_INIT} ${MATSDK_SQLITE3_LIB} ${MATSDK_SAMPLE_PLATFORM_LIBS} ${PLATFORM_LIBS} dl) diff --git a/examples/swift/SamplePackage/Package.swift b/examples/swift/SamplePackage/Package.swift index eb32822c2..66930e19b 100644 --- a/examples/swift/SamplePackage/Package.swift +++ b/examples/swift/SamplePackage/Package.swift @@ -2,6 +2,9 @@ // The swift-tools-version declares the minimum version of Swift required to build this package. import PackageDescription +import Foundation + +let matsdkInstallDir = ProcessInfo.processInfo.environment["MATSDK_INSTALL_DIR"] ?? "/usr/local" let package = Package( name: "SamplePackage", @@ -26,7 +29,7 @@ let package = Package( .unsafeFlags(["-Xcc", "-I../../../wrappers/swift/Modules/"]), ], linkerSettings: [ - .unsafeFlags(["-L/usr/local/lib"]), + .unsafeFlags(["-L\(matsdkInstallDir)/lib"]), // Libs to be linked. .linkedLibrary("mat"), .linkedLibrary("sqlite3"), diff --git a/examples/swift/SampleXcodeApp/SwiftWrapperApp.xcodeproj/project.pbxproj b/examples/swift/SampleXcodeApp/SwiftWrapperApp.xcodeproj/project.pbxproj index 50111aaf0..4000bc664 100644 --- a/examples/swift/SampleXcodeApp/SwiftWrapperApp.xcodeproj/project.pbxproj +++ b/examples/swift/SampleXcodeApp/SwiftWrapperApp.xcodeproj/project.pbxproj @@ -1,423 +1,426 @@ -// !$*UTF8*$! -{ - archiveVersion = 1; - classes = { - }; - objectVersion = 56; - objects = { - -/* Begin PBXBuildFile section */ - 2711D2652A45438A000712BD /* SwiftWrapperExampleApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2711D2642A45438A000712BD /* SwiftWrapperExampleApp.swift */; }; - 2711D2672A45438A000712BD /* ContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2711D2662A45438A000712BD /* ContentView.swift */; }; - 2711D26D2A45438C000712BD /* Preview Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 2711D26C2A45438C000712BD /* Preview Assets.xcassets */; }; - A34744202A4642300039D419 /* OneDSSwift in Frameworks */ = {isa = PBXBuildFile; productRef = A347441F2A4642300039D419 /* OneDSSwift */; }; - A34744242A4643B20039D419 /* libmat.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A34744232A4643B20039D419 /* libmat.a */; }; - A34744262A4643FE0039D419 /* libsqlite3.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A34744252A4643FE0039D419 /* libsqlite3.a */; }; - A34744282A46440F0039D419 /* SystemConfiguration.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A34744272A46440F0039D419 /* SystemConfiguration.framework */; }; - A347442A2A46441A0039D419 /* Network.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A34744292A46441A0039D419 /* Network.framework */; }; - A347442C2A46442C0039D419 /* libz.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = A347442B2A46442C0039D419 /* libz.tbd */; }; -/* End PBXBuildFile section */ - -/* Begin PBXFileReference section */ - 2711D2612A45438A000712BD /* SwiftWrapperApp.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = SwiftWrapperApp.app; sourceTree = BUILT_PRODUCTS_DIR; }; - 2711D2642A45438A000712BD /* SwiftWrapperExampleApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SwiftWrapperExampleApp.swift; sourceTree = ""; }; - 2711D2662A45438A000712BD /* ContentView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentView.swift; sourceTree = ""; }; - 2711D26A2A45438C000712BD /* SwiftWrapperApp.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = SwiftWrapperApp.entitlements; sourceTree = ""; }; - 2711D26C2A45438C000712BD /* Preview Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = "Preview Assets.xcassets"; sourceTree = ""; }; - 2711D2732A45452E000712BD /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist; path = Info.plist; sourceTree = ""; }; - 277E76FF2A45FE4D004A3A8F /* swift */ = {isa = PBXFileReference; lastKnownFileType = wrapper; name = swift; path = ../../../wrappers/swift; sourceTree = ""; }; - A34744232A4643B20039D419 /* libmat.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libmat.a; path = /usr/local/lib/libmat.a; sourceTree = ""; }; - A34744252A4643FE0039D419 /* libsqlite3.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libsqlite3.a; path = /usr/local/lib/libsqlite3.a; sourceTree = ""; }; - A34744272A46440F0039D419 /* SystemConfiguration.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SystemConfiguration.framework; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk/System/Library/Frameworks/SystemConfiguration.framework; sourceTree = DEVELOPER_DIR; }; - A34744292A46441A0039D419 /* Network.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Network.framework; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk/System/Library/Frameworks/Network.framework; sourceTree = DEVELOPER_DIR; }; - A347442B2A46442C0039D419 /* libz.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libz.tbd; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk/usr/lib/libz.tbd; sourceTree = DEVELOPER_DIR; }; -/* End PBXFileReference section */ - -/* Begin PBXFrameworksBuildPhase section */ - 2711D25E2A45438A000712BD /* Frameworks */ = { - isa = PBXFrameworksBuildPhase; - buildActionMask = 2147483647; - files = ( - A347442C2A46442C0039D419 /* libz.tbd in Frameworks */, - A347442A2A46441A0039D419 /* Network.framework in Frameworks */, - A34744282A46440F0039D419 /* SystemConfiguration.framework in Frameworks */, - A34744202A4642300039D419 /* OneDSSwift in Frameworks */, - A34744242A4643B20039D419 /* libmat.a in Frameworks */, - A34744262A4643FE0039D419 /* libsqlite3.a in Frameworks */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXFrameworksBuildPhase section */ - -/* Begin PBXGroup section */ - 2711D2582A45438A000712BD = { - isa = PBXGroup; - children = ( - 277E76FE2A45FE4D004A3A8F /* Packages */, - 2711D2632A45438A000712BD /* SwiftWrapperApp */, - 2711D2622A45438A000712BD /* Products */, - A347441E2A4642300039D419 /* Frameworks */, - ); - sourceTree = ""; - }; - 2711D2622A45438A000712BD /* Products */ = { - isa = PBXGroup; - children = ( - 2711D2612A45438A000712BD /* SwiftWrapperApp.app */, - ); - name = Products; - sourceTree = ""; - }; - 2711D2632A45438A000712BD /* SwiftWrapperApp */ = { - isa = PBXGroup; - children = ( - 2711D2732A45452E000712BD /* Info.plist */, - 2711D2642A45438A000712BD /* SwiftWrapperExampleApp.swift */, - 2711D2662A45438A000712BD /* ContentView.swift */, - 2711D26A2A45438C000712BD /* SwiftWrapperApp.entitlements */, - 2711D26B2A45438C000712BD /* Preview Content */, - ); - path = SwiftWrapperApp; - sourceTree = ""; - }; - 2711D26B2A45438C000712BD /* Preview Content */ = { - isa = PBXGroup; - children = ( - 2711D26C2A45438C000712BD /* Preview Assets.xcassets */, - ); - path = "Preview Content"; - sourceTree = ""; - }; - 277E76FE2A45FE4D004A3A8F /* Packages */ = { - isa = PBXGroup; - children = ( - 277E76FF2A45FE4D004A3A8F /* swift */, - ); - name = Packages; - sourceTree = ""; - }; - A347441E2A4642300039D419 /* Frameworks */ = { - isa = PBXGroup; - children = ( - A347442B2A46442C0039D419 /* libz.tbd */, - A34744292A46441A0039D419 /* Network.framework */, - A34744272A46440F0039D419 /* SystemConfiguration.framework */, - A34744252A4643FE0039D419 /* libsqlite3.a */, - A34744232A4643B20039D419 /* libmat.a */, - ); - name = Frameworks; - sourceTree = ""; - }; -/* End PBXGroup section */ - -/* Begin PBXNativeTarget section */ - 2711D2602A45438A000712BD /* SwiftWrapperApp */ = { - isa = PBXNativeTarget; - buildConfigurationList = 2711D2702A45438C000712BD /* Build configuration list for PBXNativeTarget "SwiftWrapperApp" */; - buildPhases = ( - 2711D25D2A45438A000712BD /* Sources */, - 2711D25E2A45438A000712BD /* Frameworks */, - 2711D25F2A45438A000712BD /* Resources */, - ); - buildRules = ( - ); - dependencies = ( - 277E77012A460B83004A3A8F /* PBXTargetDependency */, - ); - name = SwiftWrapperApp; - packageProductDependencies = ( - A347441F2A4642300039D419 /* OneDSSwift */, - ); - productName = SwiftWrapperApp; - productReference = 2711D2612A45438A000712BD /* SwiftWrapperApp.app */; - productType = "com.apple.product-type.application"; - }; -/* End PBXNativeTarget section */ - -/* Begin PBXProject section */ - 2711D2592A45438A000712BD /* Project object */ = { - isa = PBXProject; - attributes = { - BuildIndependentTargetsInParallel = 1; - LastSwiftUpdateCheck = 1430; - LastUpgradeCheck = 1430; - TargetAttributes = { - 2711D2602A45438A000712BD = { - CreatedOnToolsVersion = 14.3; - }; - }; - }; - buildConfigurationList = 2711D25C2A45438A000712BD /* Build configuration list for PBXProject "SwiftWrapperApp" */; - compatibilityVersion = "Xcode 14.0"; - developmentRegion = en; - hasScannedForEncodings = 0; - knownRegions = ( - en, - Base, - ); - mainGroup = 2711D2582A45438A000712BD; - productRefGroup = 2711D2622A45438A000712BD /* Products */; - projectDirPath = ""; - projectRoot = ""; - targets = ( - 2711D2602A45438A000712BD /* SwiftWrapperApp */, - ); - }; -/* End PBXProject section */ - -/* Begin PBXResourcesBuildPhase section */ - 2711D25F2A45438A000712BD /* Resources */ = { - isa = PBXResourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - 2711D26D2A45438C000712BD /* Preview Assets.xcassets in Resources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXResourcesBuildPhase section */ - -/* Begin PBXSourcesBuildPhase section */ - 2711D25D2A45438A000712BD /* Sources */ = { - isa = PBXSourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - 2711D2672A45438A000712BD /* ContentView.swift in Sources */, - 2711D2652A45438A000712BD /* SwiftWrapperExampleApp.swift in Sources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXSourcesBuildPhase section */ - -/* Begin PBXTargetDependency section */ - 277E77012A460B83004A3A8F /* PBXTargetDependency */ = { - isa = PBXTargetDependency; - productRef = 277E77002A460B83004A3A8F /* OneDSSwift */; - }; -/* End PBXTargetDependency section */ - -/* Begin XCBuildConfiguration section */ - 2711D26E2A45438C000712BD /* Debug */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_ENABLE_OBJC_WEAK = YES; - CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_COMMA = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INFINITE_RECURSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; - CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; - CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; - CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; - CLANG_WARN_STRICT_PROTOTYPES = YES; - CLANG_WARN_SUSPICIOUS_MOVE = YES; - CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - COPY_PHASE_STRIP = NO; - DEBUG_INFORMATION_FORMAT = dwarf; - ENABLE_STRICT_OBJC_MSGSEND = YES; - ENABLE_TESTABILITY = YES; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_DYNAMIC_NO_PIC = NO; - GCC_NO_COMMON_BLOCKS = YES; - GCC_OPTIMIZATION_LEVEL = 0; - GCC_PREPROCESSOR_DEFINITIONS = ( - "DEBUG=1", - "$(inherited)", - ); - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; - MTL_FAST_MATH = YES; - ONLY_ACTIVE_ARCH = YES; - SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; - SWIFT_INCLUDE_PATHS = ""; - "SWIFT_INCLUDE_PATHS[arch=*]" = ../../../wrappers/swift/Modules/; - SWIFT_OPTIMIZATION_LEVEL = "-Onone"; - }; - name = Debug; - }; - 2711D26F2A45438C000712BD /* Release */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_ENABLE_OBJC_WEAK = YES; - CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_COMMA = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INFINITE_RECURSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; - CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; - CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; - CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; - CLANG_WARN_STRICT_PROTOTYPES = YES; - CLANG_WARN_SUSPICIOUS_MOVE = YES; - CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - COPY_PHASE_STRIP = NO; - DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; - ENABLE_NS_ASSERTIONS = NO; - ENABLE_STRICT_OBJC_MSGSEND = YES; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_NO_COMMON_BLOCKS = YES; - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - MTL_ENABLE_DEBUG_INFO = NO; - MTL_FAST_MATH = YES; - SWIFT_COMPILATION_MODE = wholemodule; - SWIFT_INCLUDE_PATHS = ""; - SWIFT_OPTIMIZATION_LEVEL = "-O"; - }; - name = Release; - }; - 2711D2712A45438C000712BD /* Debug */ = { - isa = XCBuildConfiguration; - buildSettings = { - ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; - CODE_SIGN_ENTITLEMENTS = SwiftWrapperApp/SwiftWrapperApp.entitlements; - CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 1; - DEVELOPMENT_ASSET_PATHS = "\"SwiftWrapperApp/Preview Content\""; - ENABLE_PREVIEWS = YES; - GENERATE_INFOPLIST_FILE = YES; - INFOPLIST_FILE = SwiftWrapperApp/Info.plist; - "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphoneos*]" = YES; - "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphonesimulator*]" = YES; - "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphoneos*]" = YES; - "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphonesimulator*]" = YES; - "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphoneos*]" = YES; - "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphonesimulator*]" = YES; - "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphoneos*]" = UIStatusBarStyleDefault; - "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphonesimulator*]" = UIStatusBarStyleDefault; - INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; - INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; - IPHONEOS_DEPLOYMENT_TARGET = 16.4; - LD_RUNPATH_SEARCH_PATHS = "@executable_path/Frameworks"; - "LD_RUNPATH_SEARCH_PATHS[arch=*]" = /usr/local/lib/; - "LD_RUNPATH_SEARCH_PATHS[sdk=macosx*]" = "@executable_path/../Frameworks"; - LIBRARY_SEARCH_PATHS = /usr/local/lib; - MACOSX_DEPLOYMENT_TARGET = 13.3; - MARKETING_VERSION = 1.0; - PRODUCT_BUNDLE_IDENTIFIER = OneDSSwift.SwiftWrapperApp; - PRODUCT_NAME = "$(TARGET_NAME)"; - SDKROOT = auto; - SUPPORTED_PLATFORMS = "iphoneos iphonesimulator macosx"; - SWIFT_EMIT_LOC_STRINGS = YES; - SWIFT_VERSION = 5.0; - TARGETED_DEVICE_FAMILY = "1,2"; - }; - name = Debug; - }; - 2711D2722A45438C000712BD /* Release */ = { - isa = XCBuildConfiguration; - buildSettings = { - ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; - CODE_SIGN_ENTITLEMENTS = SwiftWrapperApp/SwiftWrapperApp.entitlements; - CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 1; - DEVELOPMENT_ASSET_PATHS = "\"SwiftWrapperApp/Preview Content\""; - ENABLE_PREVIEWS = YES; - GENERATE_INFOPLIST_FILE = YES; - INFOPLIST_FILE = SwiftWrapperApp/Info.plist; - "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphoneos*]" = YES; - "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphonesimulator*]" = YES; - "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphoneos*]" = YES; - "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphonesimulator*]" = YES; - "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphoneos*]" = YES; - "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphonesimulator*]" = YES; - "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphoneos*]" = UIStatusBarStyleDefault; - "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphonesimulator*]" = UIStatusBarStyleDefault; - INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; - INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; - IPHONEOS_DEPLOYMENT_TARGET = 16.4; - LD_RUNPATH_SEARCH_PATHS = "@executable_path/Frameworks"; - "LD_RUNPATH_SEARCH_PATHS[sdk=macosx*]" = "@executable_path/../Frameworks"; - LIBRARY_SEARCH_PATHS = /usr/local/lib; - MACOSX_DEPLOYMENT_TARGET = 13.3; - MARKETING_VERSION = 1.0; - PRODUCT_BUNDLE_IDENTIFIER = OneDSSwift.SwiftWrapperApp; - PRODUCT_NAME = "$(TARGET_NAME)"; - SDKROOT = auto; - SUPPORTED_PLATFORMS = "iphoneos iphonesimulator macosx"; - SWIFT_EMIT_LOC_STRINGS = YES; - SWIFT_VERSION = 5.0; - TARGETED_DEVICE_FAMILY = "1,2"; - }; - name = Release; - }; -/* End XCBuildConfiguration section */ - -/* Begin XCConfigurationList section */ - 2711D25C2A45438A000712BD /* Build configuration list for PBXProject "SwiftWrapperApp" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - 2711D26E2A45438C000712BD /* Debug */, - 2711D26F2A45438C000712BD /* Release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; - 2711D2702A45438C000712BD /* Build configuration list for PBXNativeTarget "SwiftWrapperApp" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - 2711D2712A45438C000712BD /* Debug */, - 2711D2722A45438C000712BD /* Release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; -/* End XCConfigurationList section */ - -/* Begin XCSwiftPackageProductDependency section */ - 277E77002A460B83004A3A8F /* OneDSSwift */ = { - isa = XCSwiftPackageProductDependency; - productName = OneDSSwift; - }; - A347441F2A4642300039D419 /* OneDSSwift */ = { - isa = XCSwiftPackageProductDependency; - productName = OneDSSwift; - }; -/* End XCSwiftPackageProductDependency section */ - }; - rootObject = 2711D2592A45438A000712BD /* Project object */; -} +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 56; + objects = { + +/* Begin PBXBuildFile section */ + 2711D2652A45438A000712BD /* SwiftWrapperExampleApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2711D2642A45438A000712BD /* SwiftWrapperExampleApp.swift */; }; + 2711D2672A45438A000712BD /* ContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2711D2662A45438A000712BD /* ContentView.swift */; }; + 2711D26D2A45438C000712BD /* Preview Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 2711D26C2A45438C000712BD /* Preview Assets.xcassets */; }; + A34744202A4642300039D419 /* OneDSSwift in Frameworks */ = {isa = PBXBuildFile; productRef = A347441F2A4642300039D419 /* OneDSSwift */; }; + A34744242A4643B20039D419 /* libmat.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A34744232A4643B20039D419 /* libmat.a */; }; + A34744262A4643FE0039D419 /* libsqlite3.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = A34744252A4643FE0039D419 /* libsqlite3.tbd */; }; + A34744282A46440F0039D419 /* SystemConfiguration.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A34744272A46440F0039D419 /* SystemConfiguration.framework */; }; + A347442A2A46441A0039D419 /* Network.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A34744292A46441A0039D419 /* Network.framework */; }; + A347442C2A46442C0039D419 /* libz.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = A347442B2A46442C0039D419 /* libz.tbd */; }; +/* End PBXBuildFile section */ + +/* Begin PBXFileReference section */ + 2711D2612A45438A000712BD /* SwiftWrapperApp.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = SwiftWrapperApp.app; sourceTree = BUILT_PRODUCTS_DIR; }; + 2711D2642A45438A000712BD /* SwiftWrapperExampleApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SwiftWrapperExampleApp.swift; sourceTree = ""; }; + 2711D2662A45438A000712BD /* ContentView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentView.swift; sourceTree = ""; }; + 2711D26A2A45438C000712BD /* SwiftWrapperApp.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = SwiftWrapperApp.entitlements; sourceTree = ""; }; + 2711D26C2A45438C000712BD /* Preview Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = "Preview Assets.xcassets"; sourceTree = ""; }; + 2711D2732A45452E000712BD /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist; path = Info.plist; sourceTree = ""; }; + 277E76FF2A45FE4D004A3A8F /* swift */ = {isa = PBXFileReference; lastKnownFileType = wrapper; name = swift; path = ../../../wrappers/swift; sourceTree = ""; }; + A34744232A4643B20039D419 /* libmat.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libmat.a; path = "$(MATSDK_INSTALL_DIR)/lib/libmat.a"; sourceTree = ""; }; + A34744252A4643FE0039D419 /* libsqlite3.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libsqlite3.tbd; path = usr/lib/libsqlite3.tbd; sourceTree = SDKROOT; }; + A34744272A46440F0039D419 /* SystemConfiguration.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SystemConfiguration.framework; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk/System/Library/Frameworks/SystemConfiguration.framework; sourceTree = DEVELOPER_DIR; }; + A34744292A46441A0039D419 /* Network.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Network.framework; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk/System/Library/Frameworks/Network.framework; sourceTree = DEVELOPER_DIR; }; + A347442B2A46442C0039D419 /* libz.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libz.tbd; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk/usr/lib/libz.tbd; sourceTree = DEVELOPER_DIR; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 2711D25E2A45438A000712BD /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + A347442C2A46442C0039D419 /* libz.tbd in Frameworks */, + A347442A2A46441A0039D419 /* Network.framework in Frameworks */, + A34744282A46440F0039D419 /* SystemConfiguration.framework in Frameworks */, + A34744202A4642300039D419 /* OneDSSwift in Frameworks */, + A34744242A4643B20039D419 /* libmat.a in Frameworks */, + A34744262A4643FE0039D419 /* libsqlite3.tbd in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 2711D2582A45438A000712BD = { + isa = PBXGroup; + children = ( + 277E76FE2A45FE4D004A3A8F /* Packages */, + 2711D2632A45438A000712BD /* SwiftWrapperApp */, + 2711D2622A45438A000712BD /* Products */, + A347441E2A4642300039D419 /* Frameworks */, + ); + sourceTree = ""; + }; + 2711D2622A45438A000712BD /* Products */ = { + isa = PBXGroup; + children = ( + 2711D2612A45438A000712BD /* SwiftWrapperApp.app */, + ); + name = Products; + sourceTree = ""; + }; + 2711D2632A45438A000712BD /* SwiftWrapperApp */ = { + isa = PBXGroup; + children = ( + 2711D2732A45452E000712BD /* Info.plist */, + 2711D2642A45438A000712BD /* SwiftWrapperExampleApp.swift */, + 2711D2662A45438A000712BD /* ContentView.swift */, + 2711D26A2A45438C000712BD /* SwiftWrapperApp.entitlements */, + 2711D26B2A45438C000712BD /* Preview Content */, + ); + path = SwiftWrapperApp; + sourceTree = ""; + }; + 2711D26B2A45438C000712BD /* Preview Content */ = { + isa = PBXGroup; + children = ( + 2711D26C2A45438C000712BD /* Preview Assets.xcassets */, + ); + path = "Preview Content"; + sourceTree = ""; + }; + 277E76FE2A45FE4D004A3A8F /* Packages */ = { + isa = PBXGroup; + children = ( + 277E76FF2A45FE4D004A3A8F /* swift */, + ); + name = Packages; + sourceTree = ""; + }; + A347441E2A4642300039D419 /* Frameworks */ = { + isa = PBXGroup; + children = ( + A347442B2A46442C0039D419 /* libz.tbd */, + A34744292A46441A0039D419 /* Network.framework */, + A34744272A46440F0039D419 /* SystemConfiguration.framework */, + A34744252A4643FE0039D419 /* libsqlite3.tbd */, + A34744232A4643B20039D419 /* libmat.a */, + ); + name = Frameworks; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + 2711D2602A45438A000712BD /* SwiftWrapperApp */ = { + isa = PBXNativeTarget; + buildConfigurationList = 2711D2702A45438C000712BD /* Build configuration list for PBXNativeTarget "SwiftWrapperApp" */; + buildPhases = ( + 2711D25D2A45438A000712BD /* Sources */, + 2711D25E2A45438A000712BD /* Frameworks */, + 2711D25F2A45438A000712BD /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + 277E77012A460B83004A3A8F /* PBXTargetDependency */, + ); + name = SwiftWrapperApp; + packageProductDependencies = ( + A347441F2A4642300039D419 /* OneDSSwift */, + ); + productName = SwiftWrapperApp; + productReference = 2711D2612A45438A000712BD /* SwiftWrapperApp.app */; + productType = "com.apple.product-type.application"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 2711D2592A45438A000712BD /* Project object */ = { + isa = PBXProject; + attributes = { + BuildIndependentTargetsInParallel = 1; + LastSwiftUpdateCheck = 1430; + LastUpgradeCheck = 1430; + TargetAttributes = { + 2711D2602A45438A000712BD = { + CreatedOnToolsVersion = 14.3; + }; + }; + }; + buildConfigurationList = 2711D25C2A45438A000712BD /* Build configuration list for PBXProject "SwiftWrapperApp" */; + compatibilityVersion = "Xcode 14.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = 2711D2582A45438A000712BD; + productRefGroup = 2711D2622A45438A000712BD /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 2711D2602A45438A000712BD /* SwiftWrapperApp */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 2711D25F2A45438A000712BD /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 2711D26D2A45438C000712BD /* Preview Assets.xcassets in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 2711D25D2A45438A000712BD /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 2711D2672A45438A000712BD /* ContentView.swift in Sources */, + 2711D2652A45438A000712BD /* SwiftWrapperExampleApp.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + 277E77012A460B83004A3A8F /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + productRef = 277E77002A460B83004A3A8F /* OneDSSwift */; + }; +/* End PBXTargetDependency section */ + +/* Begin XCBuildConfiguration section */ + 2711D26E2A45438C000712BD /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; + MTL_FAST_MATH = YES; + ONLY_ACTIVE_ARCH = YES; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_INCLUDE_PATHS = ""; + "SWIFT_INCLUDE_PATHS[arch=*]" = ../../../wrappers/swift/Modules/; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + 2711D26F2A45438C000712BD /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + SWIFT_COMPILATION_MODE = wholemodule; + SWIFT_INCLUDE_PATHS = ""; + SWIFT_OPTIMIZATION_LEVEL = "-O"; + }; + name = Release; + }; + 2711D2712A45438C000712BD /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; + CODE_SIGN_ENTITLEMENTS = SwiftWrapperApp/SwiftWrapperApp.entitlements; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_ASSET_PATHS = "\"SwiftWrapperApp/Preview Content\""; + ENABLE_PREVIEWS = YES; + GENERATE_INFOPLIST_FILE = YES; + INFOPLIST_FILE = SwiftWrapperApp/Info.plist; + "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphoneos*]" = YES; + "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphonesimulator*]" = YES; + "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphoneos*]" = YES; + "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphonesimulator*]" = YES; + "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphoneos*]" = YES; + "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphonesimulator*]" = YES; + "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphoneos*]" = UIStatusBarStyleDefault; + "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphonesimulator*]" = UIStatusBarStyleDefault; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + IPHONEOS_DEPLOYMENT_TARGET = 16.4; + LD_RUNPATH_SEARCH_PATHS = "@executable_path/Frameworks"; + "LD_RUNPATH_SEARCH_PATHS[arch=*]" = "$(MATSDK_INSTALL_DIR)/lib"; + LIBRARY_SEARCH_PATHS = "$(MATSDK_INSTALL_DIR)/lib"; + MATSDK_INSTALL_DIR = /usr/local; + "LD_RUNPATH_SEARCH_PATHS[sdk=macosx*]" = "@executable_path/../Frameworks"; + MACOSX_DEPLOYMENT_TARGET = 13.3; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = OneDSSwift.SwiftWrapperApp; + PRODUCT_NAME = "$(TARGET_NAME)"; + SDKROOT = auto; + SUPPORTED_PLATFORMS = "iphoneos iphonesimulator macosx"; + SWIFT_EMIT_LOC_STRINGS = YES; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + 2711D2722A45438C000712BD /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; + CODE_SIGN_ENTITLEMENTS = SwiftWrapperApp/SwiftWrapperApp.entitlements; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_ASSET_PATHS = "\"SwiftWrapperApp/Preview Content\""; + ENABLE_PREVIEWS = YES; + GENERATE_INFOPLIST_FILE = YES; + INFOPLIST_FILE = SwiftWrapperApp/Info.plist; + "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphoneos*]" = YES; + "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphonesimulator*]" = YES; + "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphoneos*]" = YES; + "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphonesimulator*]" = YES; + "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphoneos*]" = YES; + "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphonesimulator*]" = YES; + "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphoneos*]" = UIStatusBarStyleDefault; + "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphonesimulator*]" = UIStatusBarStyleDefault; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + IPHONEOS_DEPLOYMENT_TARGET = 16.4; + LD_RUNPATH_SEARCH_PATHS = "@executable_path/Frameworks"; + "LD_RUNPATH_SEARCH_PATHS[arch=*]" = "$(MATSDK_INSTALL_DIR)/lib"; + "LD_RUNPATH_SEARCH_PATHS[sdk=macosx*]" = "@executable_path/../Frameworks"; + LIBRARY_SEARCH_PATHS = "$(MATSDK_INSTALL_DIR)/lib"; + MACOSX_DEPLOYMENT_TARGET = 13.3; + MATSDK_INSTALL_DIR = /usr/local; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = OneDSSwift.SwiftWrapperApp; + PRODUCT_NAME = "$(TARGET_NAME)"; + SDKROOT = auto; + SUPPORTED_PLATFORMS = "iphoneos iphonesimulator macosx"; + SWIFT_EMIT_LOC_STRINGS = YES; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 2711D25C2A45438A000712BD /* Build configuration list for PBXProject "SwiftWrapperApp" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 2711D26E2A45438C000712BD /* Debug */, + 2711D26F2A45438C000712BD /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 2711D2702A45438C000712BD /* Build configuration list for PBXNativeTarget "SwiftWrapperApp" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 2711D2712A45438C000712BD /* Debug */, + 2711D2722A45438C000712BD /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + +/* Begin XCSwiftPackageProductDependency section */ + 277E77002A460B83004A3A8F /* OneDSSwift */ = { + isa = XCSwiftPackageProductDependency; + productName = OneDSSwift; + }; + A347441F2A4642300039D419 /* OneDSSwift */ = { + isa = XCSwiftPackageProductDependency; + productName = OneDSSwift; + }; +/* End XCSwiftPackageProductDependency section */ + }; + rootObject = 2711D2592A45438A000712BD /* Project object */; +} diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt index 7321a6de5..9058cf362 100644 --- a/lib/CMakeLists.txt +++ b/lib/CMakeLists.txt @@ -1,7 +1,15 @@ # Honor visibility properties for all target types cmake_policy(SET CMP0063 NEW) -include_directories( . ${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_SOURCE_DIR}/include/public ${CMAKE_CURRENT_SOURCE_DIR}/include/mat ${CMAKE_CURRENT_SOURCE_DIR}/pal ${CMAKE_CURRENT_SOURCE_DIR}/utils ${CMAKE_CURRENT_SOURCE_DIR}/modules/exp ${CMAKE_CURRENT_SOURCE_DIR}/modules/dataviewer ${CMAKE_CURRENT_SOURCE_DIR}/modules/privacyguard ${CMAKE_CURRENT_SOURCE_DIR}/modules/liveeventinspector ${CMAKE_CURRENT_SOURCE_DIR}/modules/cds ${CMAKE_CURRENT_SOURCE_DIR}/modules/signals ${CMAKE_CURRENT_SOURCE_DIR}/modules/sanitizer /usr/local/include ) +# Legacy (non-target) include paths that apply globally within this directory and +# are used by build.sh / MSBuild / standalone CMake workflows. They do NOT propagate +# to downstream consumers via find_package() (see target_include_directories below). +include_directories( . ${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_SOURCE_DIR}/include/public ${CMAKE_CURRENT_SOURCE_DIR}/include/mat ${CMAKE_CURRENT_SOURCE_DIR}/pal ${CMAKE_CURRENT_SOURCE_DIR}/utils ${CMAKE_CURRENT_SOURCE_DIR}/modules/exp ${CMAKE_CURRENT_SOURCE_DIR}/modules/dataviewer ${CMAKE_CURRENT_SOURCE_DIR}/modules/privacyguard ${CMAKE_CURRENT_SOURCE_DIR}/modules/liveeventinspector ${CMAKE_CURRENT_SOURCE_DIR}/modules/cds ${CMAKE_CURRENT_SOURCE_DIR}/modules/signals ${CMAKE_CURRENT_SOURCE_DIR}/modules/sanitizer ) + +# Legacy builds may need system-installed deps from /usr/local/include +if(NOT MATSDK_USE_VCPKG_DEPS) + include_directories(/usr/local/include) +endif() set(SRCS decorators/BaseDecorator.cpp packager/BondSplicer.cpp @@ -135,6 +143,9 @@ if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/modules/sanitizer/" AND BUILD_SANITIZER) endif() endif() +set(MATSDK_OBJC_PRIVACYGUARD_AVAILABLE OFF) +set(MATSDK_OBJC_SANITIZER_AVAILABLE OFF) + if(PAL_IMPLEMENTATION STREQUAL "CPP11") if(APPLE) list(APPEND SRCS @@ -172,11 +183,18 @@ if(PAL_IMPLEMENTATION STREQUAL "CPP11") pal/posix/NetworkInformationImpl.mm ) else() - list(APPEND SRCS - http/HttpClient_Curl.cpp - http/HttpClient_Curl.hpp - pal/posix/NetworkInformationImpl.cpp - ) + list(APPEND SRCS pal/posix/NetworkInformationImpl.cpp) + if(CMAKE_SYSTEM_NAME STREQUAL "Android") + list(APPEND SRCS + http/HttpClient_Android.cpp + http/HttpClient_Android.hpp + ) + else() + list(APPEND SRCS + http/HttpClient_Curl.cpp + http/HttpClient_Curl.hpp + ) + endif() endif() if(APPLE AND BUILD_OBJC_WRAPPER) message(STATUS "Include ObjC Wrappers") @@ -186,6 +204,9 @@ if(PAL_IMPLEMENTATION STREQUAL "CPP11") ../wrappers/obj-c/ODWEventProperties.mm ../wrappers/obj-c/ODWLogConfiguration.mm ../wrappers/obj-c/ODWSemanticContext.mm + ../wrappers/obj-c/ODWCommonDataContext.mm + ../wrappers/obj-c/ODWPrivacyGuardInitConfig.mm + ../wrappers/obj-c/ODWSanitizerInitConfig.mm ) if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/modules/dataviewer/") list(APPEND SRCS @@ -193,15 +214,14 @@ if(PAL_IMPLEMENTATION STREQUAL "CPP11") ) endif() if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/modules/privacyguard/" AND BUILD_PRIVACYGUARD) - list(APPEND SRCS - ../wrappers/obj-c/ODWCommonDataContext.mm - ../wrappers/obj-c/ODWPrivacyGuard.mm - ../wrappers/obj-c/ODWPrivacyGuardInitConfig.mm + set(MATSDK_OBJC_PRIVACYGUARD_AVAILABLE ON) + list(APPEND SRCS + ../wrappers/obj-c/ODWPrivacyGuard.mm ) endif() if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/modules/sanitizer/" AND BUILD_SANITIZER) + set(MATSDK_OBJC_SANITIZER_AVAILABLE ON) list(APPEND SRCS - ../wrappers/obj-c/ODWSanitizerInitConfig.mm ../wrappers/obj-c/ODWSanitizer.mm ) endif() @@ -230,8 +250,10 @@ if(PAL_IMPLEMENTATION STREQUAL "CPP11") elseif(PAL_IMPLEMENTATION STREQUAL "WIN32") # Win32 Desktop for now. # TODO: define a separate PAL for Win10 cmake build -include_directories( ${CMAKE_CURRENT_SOURCE_DIR}/../zlib ${CMAKE_CURRENT_SOURCE_DIR}/../sqlite) -add_definitions(-D_UNICODE -DUNICODE -DZLIB_WINAPI -DWIN32 -DMATSDK_PLATFORM_WINDOWS=1 -DMATSDK_SHARED_LIB=1 -D_UTC_SDK -DUSE_BOND -D_WINDOWS -D_USRDLL -DWINVER=_WIN32_WINNT_WIN7) +if(NOT MATSDK_USE_VCPKG_DEPS) + include_directories( ${CMAKE_CURRENT_SOURCE_DIR}/../zlib ${CMAKE_CURRENT_SOURCE_DIR}/../sqlite) +endif() +add_definitions(-D_UNICODE -DUNICODE -DWIN32 -DMATSDK_PLATFORM_WINDOWS=1 -DMATSDK_SHARED_LIB=1 -D_UTC_SDK -DUSE_BOND -D_WINDOWS -D_USRDLL -DWINVER=_WIN32_WINNT_WIN7) remove_definitions(-D_MBCS) list(APPEND SRCS http/HttpClient_WinInet.cpp @@ -267,71 +289,203 @@ endif() create_source_files_groups_per_folder(${SRCS}) -# MinGW does not require pthread -if (CMAKE_SYSTEM_NAME STREQUAL "Linux") +# Linux and Android require pthreads +if(CMAKE_SYSTEM_NAME STREQUAL "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "Android") find_package(Threads REQUIRED) - if(THREADS_HAVE_PTHREAD_ARG) - target_compile_options(mat PUBLIC "-pthread") - endif() endif() -if(BUILD_SHARED_LIBS STREQUAL "ON") +################################################################################################ +# Build the library +################################################################################################ +if(BUILD_SHARED_LIBS) message(STATUS "Building shared SDK library") - - # include(FindCURL) - # find_package(CURL REQUIRED) - # set(CMAKE_REQUIRED_LIBRARIES "${CURL_LIBRARIES}") - - # find_package(sqlite3 REQUIRED) - add_library(mat SHARED ${SRCS}) +else() + message(STATUS "Building static SDK library") + add_library(mat STATIC ${SRCS}) +endif() - # Add flags for obtaining system UUID via IOKit - if (CMAKE_SYSTEM_NAME STREQUAL "Darwin") - set(CMAKE_SHARED_LINKER_FLAGS - "-framework CoreFoundation -framework IOKit -framework Foundation" - ) +# Target-based include paths for vcpkg / install workflow. +# PUBLIC propagates to consumers; PRIVATE is SDK-internal only. +# BUILD_INTERFACE is used during the SDK build; INSTALL_INTERFACE is used +# by consumers after cmake --install. +target_include_directories(mat + PUBLIC + $ + $ + PRIVATE + ${CMAKE_CURRENT_SOURCE_DIR} + ${CMAKE_CURRENT_SOURCE_DIR}/include + ${CMAKE_CURRENT_SOURCE_DIR}/pal + ${CMAKE_CURRENT_SOURCE_DIR}/utils +) + +if(APPLE AND BUILD_OBJC_WRAPPER) + if(MATSDK_OBJC_PRIVACYGUARD_AVAILABLE) + target_compile_definitions(mat PRIVATE MATSDK_OBJC_PRIVACYGUARD_AVAILABLE=1) + else() + target_compile_definitions(mat PRIVATE MATSDK_OBJC_PRIVACYGUARD_AVAILABLE=0) endif() - # - # TODO: allow adding "${Tcmalloc_LIBRARIES}" to target_link_libraries for memory leak debugging - # - if (BUILD_STATIC_SQLITE STREQUAL "ON") - # Build dynamic library, but prefer statically linking sqlite3 and zlib - add_library(sqlite3 STATIC IMPORTED GLOBAL) - add_library(z STATIC IMPORTED GLOBAL) - target_link_libraries(mat PRIVATE sqlite3 PUBLIC z ${LIBS} "${CMAKE_THREAD_LIBS_INIT}" "${CMAKE_DL_LIBS}" "${CMAKE_REQUIRED_LIBRARIES}") + if(MATSDK_OBJC_SANITIZER_AVAILABLE) + target_compile_definitions(mat PRIVATE MATSDK_OBJC_SANITIZER_AVAILABLE=1) else() - # Prefer shared libraries for sqlite3 and zlib - add_library(sqlite3 SHARED IMPORTED GLOBAL) - add_library(z SHARED IMPORTED GLOBAL) - target_link_libraries(mat PUBLIC sqlite3 PUBLIC z ${LIBS} "${CMAKE_THREAD_LIBS_INIT}" "${CMAKE_DL_LIBS}" "${CMAKE_REQUIRED_LIBRARIES}") + target_compile_definitions(mat PRIVATE MATSDK_OBJC_SANITIZER_AVAILABLE=0) endif() +endif() - # target_link_libraries(mat PUBLIC libsqlite3 libcurl.a libz.a libssl.a libcrypto.a "${SQLITE_LIBRARY}" "${CMAKE_THREAD_LIBS_INIT}" "${CMAKE_DL_LIBS}" ) - install(TARGETS mat EXPORT mat LIBRARY DESTINATION ${INSTALL_LIB_DIR}) +################################################################################################ +# Link dependencies +################################################################################################ +if(MATSDK_USE_VCPKG_DEPS) + # vcpkg mode: all deps resolved via find_package() in root CMakeLists.txt + target_link_libraries(mat + PRIVATE + unofficial::sqlite3::sqlite3 + ZLIB::ZLIB + nlohmann_json::nlohmann_json + ${LIBS} + ) else() - message(STATUS "Building static SDK library") - add_library(mat STATIC ${SRCS}) - if(LINK_STATIC_DEPENDS) - if(PAL_IMPLEMENTATION STREQUAL "WIN32") - target_link_libraries(mat ${LIBS} "${CMAKE_THREAD_LIBS_INIT}" "${CMAKE_DL_LIBS}" ) + # Legacy mode: use vendored or system-installed deps + if(CMAKE_SYSTEM_NAME STREQUAL "Android") + # Android NDK has no system sqlite3 or zlib — build from bundled source. + add_library(sqlite3_bundled STATIC "${CMAKE_CURRENT_SOURCE_DIR}/../sqlite/sqlite3.c") + target_include_directories(sqlite3_bundled PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}/../sqlite") + set_target_properties(sqlite3_bundled PROPERTIES POSITION_INDEPENDENT_CODE ON) + # Guard bundled sqlite3 against toolchain or environment flags that imply finite-math-only (uses INFINITY macro). + # Also suppress warnings treated as errors in vendored code. + target_compile_options(sqlite3_bundled PRIVATE -fno-finite-math-only -Wno-unused-function) + + # Build zlib from bundled source, excluding Intel SIMD files (crc_folding.c, + # fill_window_sse.c, x86.c) that require SSE4.2/PCLMULQDQ and cannot compile + # on ARM. simd_stub.c provides the necessary stubs instead. + add_library(zlib_bundled STATIC + "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/adler32.c" + "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/compress.c" + "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/crc32.c" + "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/deflate.c" + "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/gzclose.c" + "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/gzlib.c" + "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/gzread.c" + "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/gzwrite.c" + "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/infback.c" + "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/inffast.c" + "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/inflate.c" + "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/inftrees.c" + "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/trees.c" + "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/uncompr.c" + "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/zutil.c" + "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/simd_stub.c" + ) + target_include_directories(zlib_bundled PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}/../zlib") + set_target_properties(zlib_bundled PROPERTIES POSITION_INDEPENDENT_CODE ON) + # Bundled zlib 1.2.11 uses K&R-style function definitions and POSIX functions + # (close/read/write) without explicit includes; suppress warnings from + # vendored code we don't modify. + target_compile_options(zlib_bundled PRIVATE + -Wno-strict-prototypes -Wno-deprecated-non-prototype -Wno-implicit-function-declaration) + + target_link_libraries(mat PRIVATE sqlite3_bundled zlib_bundled ${LIBS}) + elseif(PAL_IMPLEMENTATION STREQUAL "WIN32") + # Windows legacy: vendored sqlite/zlib headers are included via + # include_directories in the PAL section above; link only ${LIBS} + # (e.g. CURL if needed — sqlite/zlib come from .vcxproj references). + target_link_libraries(mat PRIVATE ${LIBS}) + else() + # Linux/macOS legacy: link system-installed sqlite3 and zlib + if(EXISTS "/usr/local/lib/libsqlite3.a") + set(MATSDK_SQLITE3_LIB "/usr/local/lib/libsqlite3.a") + elseif(EXISTS "/usr/local/opt/sqlite/lib/libsqlite3.a") + set(MATSDK_SQLITE3_LIB "/usr/local/opt/sqlite/lib/libsqlite3.a") + elseif(EXISTS "/opt/homebrew/opt/sqlite/lib/libsqlite3.a") + set(MATSDK_SQLITE3_LIB "/opt/homebrew/opt/sqlite/lib/libsqlite3.a") else() - add_library(sqlite3 STATIC IMPORTED GLOBAL) - find_library(SQLITE3_STATIC_LIB NAMES libsqlite3.a - PATHS /usr/local/lib /usr/local/opt/sqlite/lib /opt/homebrew/opt/sqlite/lib - NO_DEFAULT_PATH) - if(SQLITE3_STATIC_LIB) - set_target_properties(sqlite3 PROPERTIES IMPORTED_LOCATION ${SQLITE3_STATIC_LIB}) - endif() - add_library(z STATIC IMPORTED GLOBAL) - # - # TODO: allow adding "${Tcmalloc_LIBRARIES}" to target_link_libraries for memory leak debugging - # - target_link_libraries(mat PRIVATE libsqlite3.a PUBLIC libz.a ${LIBS} "${CMAKE_THREAD_LIBS_INIT}" "${CMAKE_DL_LIBS}" ) + set(MATSDK_SQLITE3_LIB "sqlite3") endif() + + find_package(ZLIB REQUIRED) + target_include_directories(mat PRIVATE ${ZLIB_INCLUDE_DIRS}) + target_link_libraries(mat PRIVATE ${MATSDK_SQLITE3_LIB} ZLIB::ZLIB ${LIBS}) + endif() +endif() + +# Platform-specific link dependencies +if(CMAKE_SYSTEM_NAME STREQUAL "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "Android") + target_link_libraries(mat PUBLIC "${CMAKE_THREAD_LIBS_INIT}" "${CMAKE_DL_LIBS}") + if(THREADS_HAVE_PTHREAD_ARG) + target_compile_options(mat PUBLIC "-pthread") + endif() + if(CMAKE_SYSTEM_NAME STREQUAL "Android") + target_link_libraries(mat PUBLIC log) + endif() +elseif(PAL_IMPLEMENTATION STREQUAL "WIN32") + target_link_libraries(mat PUBLIC wininet crypt32 ws2_32) +elseif(APPLE) + target_link_libraries(mat PUBLIC + "-framework CoreFoundation" + "-framework Foundation" + "-framework CFNetwork" + "-framework Network" + "-framework SystemConfiguration" + ) + if(BUILD_IOS OR CMAKE_SYSTEM_NAME STREQUAL "iOS") + target_link_libraries(mat PUBLIC "-framework UIKit") + else() + target_link_libraries(mat PUBLIC "-framework IOKit") endif() - install(TARGETS mat EXPORT mat ARCHIVE DESTINATION ${INSTALL_LIB_DIR}) endif() -message(STATUS "Library will be installed to ${INSTALL_LIB_DIR}") +################################################################################################ +# Installation +################################################################################################ +# The CMake package config / export workflow is used by vcpkg and any CMake-based +# consumer that does find_package(MSTelemetry). Legacy (non-vcpkg) builds install +# via install.sh or MSBuild output directories and don't need this. +if(MATSDK_USE_VCPKG_DEPS) + install(TARGETS mat + EXPORT MSTelemetryTargets + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} + ) + + message(STATUS "Library will be installed to ${CMAKE_INSTALL_LIBDIR}") + + # Generate and install CMake package config files + install(EXPORT MSTelemetryTargets + FILE MSTelemetryTargets.cmake + NAMESPACE MSTelemetry:: + DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/MSTelemetry + ) + + configure_package_config_file( + "${CMAKE_CURRENT_SOURCE_DIR}/../cmake/MSTelemetryConfig.cmake.in" + "${CMAKE_CURRENT_BINARY_DIR}/MSTelemetryConfig.cmake" + INSTALL_DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/MSTelemetry + ) + + if(NOT DEFINED MATSDK_BUILD_VERSION OR MATSDK_BUILD_VERSION STREQUAL "") + message(FATAL_ERROR "MATSDK_BUILD_VERSION is not set. Cannot generate package version file.") + endif() + + write_basic_package_version_file( + "${CMAKE_CURRENT_BINARY_DIR}/MSTelemetryConfigVersion.cmake" + VERSION ${MATSDK_BUILD_VERSION} + COMPATIBILITY AnyNewerVersion + ) + + install(FILES + "${CMAKE_CURRENT_BINARY_DIR}/MSTelemetryConfig.cmake" + "${CMAKE_CURRENT_BINARY_DIR}/MSTelemetryConfigVersion.cmake" + DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/MSTelemetry + ) +else() + # Legacy install: just put the library and headers in standard locations + install(TARGETS mat + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} + ) + message(STATUS "Library will be installed to ${CMAKE_INSTALL_LIBDIR}") +endif() diff --git a/lib/android_build/app/src/main/cpp/CMakeLists.txt b/lib/android_build/app/src/main/cpp/CMakeLists.txt index 94c5f4b41..1ee7d8662 100644 --- a/lib/android_build/app/src/main/cpp/CMakeLists.txt +++ b/lib/android_build/app/src/main/cpp/CMakeLists.txt @@ -3,7 +3,7 @@ # Sets the minimum version of CMake required to build the native library. -cmake_minimum_required(VERSION 3.4.1) +cmake_minimum_required(VERSION 3.5) set(CMAKE_CXX_STANDARD 14) set(CMAKE_CXX_STANDARD_REQUIRED ON) diff --git a/tests/functests/CMakeLists.txt b/tests/functests/CMakeLists.txt index 323a8e2f9..d3eac21fe 100644 --- a/tests/functests/CMakeLists.txt +++ b/tests/functests/CMakeLists.txt @@ -124,7 +124,7 @@ else() ${LIBGTEST} ${LIBGMOCK} mat - ${ZLIB_LIBRARIES} + ZLIB::ZLIB ${SQLITE3_LIB} ${PLATFORM_LIBS} dl) diff --git a/tests/unittests/CMakeLists.txt b/tests/unittests/CMakeLists.txt index 8b52a5fb3..5ca5b8e77 100644 --- a/tests/unittests/CMakeLists.txt +++ b/tests/unittests/CMakeLists.txt @@ -189,7 +189,7 @@ else() ${LIBGTEST} ${LIBGMOCK} mat - ${ZLIB_LIBRARIES} + ZLIB::ZLIB ${SQLITE3_LIB} ${PLATFORM_LIBS} dl) diff --git a/tests/vcpkg/CMakeLists.txt b/tests/vcpkg/CMakeLists.txt new file mode 100644 index 000000000..42636fa16 --- /dev/null +++ b/tests/vcpkg/CMakeLists.txt @@ -0,0 +1,19 @@ +cmake_minimum_required(VERSION 3.15) +project(mstelemetry_vcpkg_test LANGUAGES CXX) + +set(CMAKE_CXX_STANDARD 14) +set(CMAKE_CXX_STANDARD_REQUIRED ON) +set(CMAKE_CXX_EXTENSIONS OFF) + +# Match vcpkg static triplet CRT linkage +if(MSVC AND VCPKG_TARGET_TRIPLET MATCHES "-static$") + set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreaded$<$:Debug>") +endif() + +find_package(MSTelemetry CONFIG REQUIRED) + +add_executable(vcpkg_test main.cpp) +target_link_libraries(vcpkg_test PRIVATE MSTelemetry::mat) + +enable_testing() +add_test(NAME vcpkg_integration_test COMMAND vcpkg_test) diff --git a/tests/vcpkg/README.md b/tests/vcpkg/README.md new file mode 100644 index 000000000..d9ffcba72 --- /dev/null +++ b/tests/vcpkg/README.md @@ -0,0 +1,111 @@ +# Vcpkg Port Integration Tests + +End-to-end tests that verify the `mstelemetry` vcpkg port can be installed, found via `find_package(MSTelemetry CONFIG)`, linked, and executed on all supported platforms. + +## Prerequisites + +1. **vcpkg** — [Install and bootstrap](https://vcpkg.io/en/getting-started): + ```bash + git clone https://github.com/microsoft/vcpkg ~/vcpkg + ~/vcpkg/bootstrap-vcpkg.sh # Linux/macOS + ``` + ```powershell + git clone https://github.com/microsoft/vcpkg C:\vcpkg + .\vcpkg\bootstrap-vcpkg.bat # Windows + ``` +2. **Set `VCPKG_ROOT`**: + ```bash + export VCPKG_ROOT=~/vcpkg # Linux/macOS (add to ~/.bashrc) + ``` + ```powershell + $env:VCPKG_ROOT = "$HOME\vcpkg" # Windows (or set system env var) + ``` +3. **Platform tools** — see per-platform sections below. + +## Running Tests + +All scripts are run from the repo root. + +### Windows + +**Requires:** Visual Studio 2019+ with C++ workload, cmake + +Best run from a **VS Developer Command Prompt** (ensures the same compiler version as vcpkg uses): +```powershell +.\tests\vcpkg\test-vcpkg-windows.ps1 -VcpkgRoot C:\path\to\vcpkg +``` + +> **Note:** Visual Studio's `vcvarsall.bat` overrides the `VCPKG_ROOT` environment variable. +> Always pass `-VcpkgRoot` explicitly to point at your vcpkg installation. + +Optional: specify a different triplet (default auto-detects host architecture): +```powershell +.\tests\vcpkg\test-vcpkg-windows.ps1 -VcpkgRoot C:\path\to\vcpkg -Triplet x64-windows +``` + +### Linux + +**Requires:** gcc/g++, cmake, pkg-config + +```bash +./tests/vcpkg/test-vcpkg-linux.sh +``` + +### macOS + +**Requires:** Xcode command line tools, cmake + +```bash +./tests/vcpkg/test-vcpkg-macos.sh +``` + +### iOS + +**Requires:** macOS with Xcode + iOS SDK, cmake + +**Device build** (cross-compile only — verifies the binary is produced): +```bash +./tests/vcpkg/test-vcpkg-ios.sh +``` + +**Simulator build** (builds and runs on iOS Simulator): +```bash +./tests/vcpkg/test-vcpkg-ios.sh --simulator +``` + +The simulator mode uses the built-in vcpkg community triplet `arm64-ios-simulator` that targets the `iphonesimulator` SDK, then executes the binary via `xcrun simctl spawn`. + +### Android (cross-compile) + +**Requires:** Android NDK, cmake, VCPKG_ROOT set + +```bash +# Default: arm64-v8a +./tests/vcpkg/test-vcpkg-android.sh + +# Other ABIs: +./tests/vcpkg/test-vcpkg-android.sh armeabi-v7a +./tests/vcpkg/test-vcpkg-android.sh x86_64 +``` + +Set `ANDROID_NDK_HOME` if the script can't find your NDK automatically. Cross-compiled binary can be tested on device via `adb push`/`adb shell`. + +## What Gets Tested + +Each script runs 3 steps: + +1. **Configure** — CMake configures a minimal consumer project with the vcpkg toolchain. Dependencies (including the `mstelemetry` overlay port) are installed automatically. +2. **Build** — The consumer links against `MSTelemetry::mat` +3. **Run** — The test binary exercises `LogManager`, `EventProperties`, and verifies all symbols resolve + +## Troubleshooting + +| Problem | Fix | +|---------|-----| +| `VCPKG_ROOT is not set` | Set the environment variable to your vcpkg installation | +| vcvarsall overrides `VCPKG_ROOT` | Pass `-VcpkgRoot C:\path\to\vcpkg` explicitly on Windows | +| `RuntimeLibrary mismatch` (Windows) | Run from a VS Developer Command Prompt matching vcpkg's compiler | +| Dependency build fails | Check vcpkg logs in `build-*/consumer/vcpkg-manifest-install.log` | +| iOS SDK not found | Install Xcode and run `xcode-select --install` | +| Android NDK not found | Set `ANDROID_NDK_HOME` to your NDK path (e.g., `$ANDROID_HOME/ndk/26.x.x`) | +| First run is slow | Dependencies (sqlite3, zlib, nlohmann-json, curl) are built on first run | diff --git a/tests/vcpkg/main.cpp b/tests/vcpkg/main.cpp new file mode 100644 index 000000000..6a5e3bbc6 --- /dev/null +++ b/tests/vcpkg/main.cpp @@ -0,0 +1,81 @@ +// Vcpkg integration test for mstelemetry +// Verifies that find_package(MSTelemetry) works and core APIs are callable + +#include +#include +#include +#include + +#include "LogManager.hpp" + +LOGMANAGER_INSTANCE + +using namespace MAT; + +static int test_count = 0; +static int pass_count = 0; + +static void check(bool cond, const char* name) +{ + test_count++; + if (cond) { + pass_count++; + printf(" [PASS] %s\n", name); + } else { + printf(" [FAIL] %s\n", name); + } +} + +int main() +{ + printf("=== MSTelemetry vcpkg integration test ===\n"); + + // ---- Core API tests ---- + printf("\n-- Core API --\n"); + + // 1. Verify headers compile and link + check(true, "Headers found and compiled successfully"); + + // 2. LogManager configuration + auto& config = LogManager::GetLogConfiguration(); + check(true, "LogManager::GetLogConfiguration() callable"); + + // 3. EventProperties with multiple types + { + EventProperties props("TestEvent"); + props.SetProperty("strProp", "value"); + props.SetProperty("intProp", (int64_t)42); + props.SetProperty("dblProp", 3.14); + props.SetProperty("boolProp", true); + check(props.GetName() == "TestEvent", "Event name matches"); + check(true, "SetProperty for string, int, double, bool"); + } + + // 4. Multiple event types + { + std::vector names = {"App.Started", "App.PageView", "App.Error"}; + for (const auto& name : names) { + EventProperties ep(name); + ep.SetProperty("timestamp", (int64_t)1234567890); + } + check(true, "Created multiple event types"); + } + + // 5. PII annotations + { + EventProperties props("PiiTest"); + props.SetProperty("userId", "user@example.com", PiiKind_Identity); + props.SetProperty("ip", "127.0.0.1", PiiKind_IPv4Address); + check(true, "PII-annotated properties compile and link"); + } + + // 6. Event priority + { + EventProperties props("PriorityTest"); + props.SetPriority(EventPriority_High); + check(true, "SetPriority compiles and links"); + } + + printf("\n=== Results: %d/%d passed ===\n", pass_count, test_count); + return (pass_count == test_count) ? 0 : 1; +} diff --git a/tests/vcpkg/test-vcpkg-android.sh b/tests/vcpkg/test-vcpkg-android.sh new file mode 100755 index 000000000..6d57c232c --- /dev/null +++ b/tests/vcpkg/test-vcpkg-android.sh @@ -0,0 +1,99 @@ +#!/bin/bash +# Test script: Verify mstelemetry vcpkg port for Android (cross-compile only) +# Usage: ./tests/vcpkg/test-vcpkg-android.sh [ABI] +# ABI: arm64-v8a (default), armeabi-v7a, x86_64, x86 +# Prerequisites: VCPKG_ROOT set, ANDROID_NDK_HOME set, cmake +set -e + +SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" +REPO_ROOT="$(cd "${SCRIPT_DIR}/../.." && pwd)" +OVERLAY_PORTS="${REPO_ROOT}/tools/ports" + +# Android ABI (default: arm64-v8a) +ANDROID_ABI="${1:-arm64-v8a}" + +# Map ABI to vcpkg triplet +case "${ANDROID_ABI}" in + arm64-v8a) TRIPLET="arm64-android" ;; + armeabi-v7a) TRIPLET="arm-neon-android" ;; + x86_64) TRIPLET="x64-android" ;; + x86) TRIPLET="x86-android" ;; + *) + echo "ERROR: Unsupported ABI '${ANDROID_ABI}'. Use: arm64-v8a, armeabi-v7a, x86_64, x86" + exit 1 + ;; +esac + +BUILD_DIR="${SCRIPT_DIR}/build-android-${ANDROID_ABI}" + +echo "=== MSTelemetry vcpkg port test (Android cross-compile) ===" +echo "Repository root: ${REPO_ROOT}" +echo "ABI: ${ANDROID_ABI}" +echo "Triplet: ${TRIPLET}" + +# Check prerequisites +if [ -z "${VCPKG_ROOT}" ]; then + echo "ERROR: VCPKG_ROOT is not set. Please set it to your vcpkg installation directory." + exit 1 +fi + +VCPKG_TOOLCHAIN="${VCPKG_ROOT}/scripts/buildsystems/vcpkg.cmake" +if [ ! -f "${VCPKG_TOOLCHAIN}" ]; then + echo "ERROR: vcpkg toolchain not found at ${VCPKG_TOOLCHAIN}" + exit 1 +fi + +# Find NDK +if [ -z "${ANDROID_NDK_HOME}" ]; then + # Try common locations + if [ -n "${ANDROID_HOME}" ] && [ -d "${ANDROID_HOME}/ndk" ]; then + ANDROID_NDK_HOME=$(ls -d "${ANDROID_HOME}/ndk/"* 2>/dev/null | sort -t. -k1,1n -k2,2n -k3,3n | tail -1) + elif [ -n "${ANDROID_SDK_ROOT}" ] && [ -d "${ANDROID_SDK_ROOT}/ndk" ]; then + ANDROID_NDK_HOME=$(ls -d "${ANDROID_SDK_ROOT}/ndk/"* 2>/dev/null | sort -t. -k1,1n -k2,2n -k3,3n | tail -1) + fi +fi + +if [ -z "${ANDROID_NDK_HOME}" ] || [ ! -d "${ANDROID_NDK_HOME}" ]; then + echo "ERROR: Android NDK not found. Set ANDROID_NDK_HOME to your NDK path." + echo " e.g., export ANDROID_NDK_HOME=\$ANDROID_HOME/ndk/26.1.10909125" + exit 1 +fi +echo "NDK: ${ANDROID_NDK_HOME}" + +# Clean previous build +rm -rf "${BUILD_DIR}" +mkdir -p "${BUILD_DIR}" + +echo "" +echo "--- Step 1: Configure (vcpkg installs deps automatically) ---" +cmake -S "${SCRIPT_DIR}" -B "${BUILD_DIR}/consumer" \ + -DCMAKE_TOOLCHAIN_FILE="${VCPKG_TOOLCHAIN}" \ + -DVCPKG_TARGET_TRIPLET="${TRIPLET}" \ + -DVCPKG_OVERLAY_PORTS="${OVERLAY_PORTS}" \ + -DVCPKG_CHAINLOAD_TOOLCHAIN_FILE="${ANDROID_NDK_HOME}/build/cmake/android.toolchain.cmake" \ + -DANDROID_ABI="${ANDROID_ABI}" \ + -DANDROID_PLATFORM=android-24 \ + -DCMAKE_BUILD_TYPE=Release + +echo "" +echo "--- Step 2: Build test consumer for Android ---" +cmake --build "${BUILD_DIR}/consumer" --config Release + +echo "" +echo "--- Step 3: Verify output ---" +BINARY=$(find "${BUILD_DIR}/consumer" -name "vcpkg_test" -type f 2>/dev/null | head -1) +if [ -n "${BINARY}" ]; then + echo "[PASS] Android binary produced: ${BINARY}" + file "${BINARY}" + echo "" + echo "NOTE: Cross-compiled binary cannot be executed on the host." + echo " Deploy to device or emulator via adb for runtime verification:" + echo " adb push ${BINARY} /data/local/tmp/" + echo " adb shell /data/local/tmp/vcpkg_test" +else + echo "[FAIL] Android binary not found" + exit 1 +fi + +echo "" +echo "=== Android vcpkg port cross-compile test PASSED ===" diff --git a/tests/vcpkg/test-vcpkg-ios.sh b/tests/vcpkg/test-vcpkg-ios.sh new file mode 100755 index 000000000..49133d418 --- /dev/null +++ b/tests/vcpkg/test-vcpkg-ios.sh @@ -0,0 +1,161 @@ +#!/bin/bash +# Test script: Verify mstelemetry vcpkg port for iOS +# Usage: ./tests/vcpkg/test-vcpkg-ios.sh [--simulator] +# Prerequisites: VCPKG_ROOT set, macOS with Xcode + iOS SDK, cmake +# +# By default builds for arm64-ios (device). With --simulator, builds for +# the iOS Simulator and runs the binary via xcrun simctl. +set -e + +SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" +REPO_ROOT="$(cd "${SCRIPT_DIR}/../.." && pwd)" +OVERLAY_PORTS="${REPO_ROOT}/tools/ports" +USE_SIMULATOR=false + +for arg in "$@"; do + case "$arg" in + --simulator) USE_SIMULATOR=true ;; + *) echo "Unknown option: $arg"; exit 1 ;; + esac +done + +if [ "${USE_SIMULATOR}" = true ]; then + TRIPLET="arm64-ios-simulator" + BUILD_DIR="${SCRIPT_DIR}/build-iossim" + APPLE_SDK="iphonesimulator" + echo "=== MSTelemetry vcpkg port test (iOS Simulator) ===" +else + TRIPLET="arm64-ios" + BUILD_DIR="${SCRIPT_DIR}/build-ios" + APPLE_SDK="iphoneos" + echo "=== MSTelemetry vcpkg port test (iOS device cross-compile) ===" +fi + +echo "Repository root: ${REPO_ROOT}" + +# Check prerequisites +if [ -z "${VCPKG_ROOT}" ]; then + echo "ERROR: VCPKG_ROOT is not set. Please set it to your vcpkg installation directory." + exit 1 +fi + +if [ "$(uname)" != "Darwin" ]; then + echo "ERROR: iOS builds require macOS with Xcode installed." + exit 1 +fi + +HAS_ARM64_HARDWARE="$(sysctl -n hw.optional.arm64 2>/dev/null || echo 0)" +if [ "${USE_SIMULATOR}" = true ] && [ "$(uname -m)" != "arm64" ] && [ "${HAS_ARM64_HARDWARE}" != "1" ]; then + echo "ERROR: --simulator builds arm64-ios-simulator and requires an Apple Silicon macOS host." + echo " Use the default device cross-compile mode on Intel macOS." + exit 1 +fi + +if ! command -v python3 &> /dev/null; then + echo "ERROR: python3 is required for simulator device detection but was not found." + exit 1 +fi + +# Verify Xcode SDK +if [ "${USE_SIMULATOR}" = true ]; then + xcrun --sdk iphonesimulator --show-sdk-path > /dev/null 2>&1 || { + echo "ERROR: iOS Simulator SDK not found. Install Xcode and iOS Simulator runtime." + exit 1 + } +else + xcrun --sdk iphoneos --show-sdk-path > /dev/null 2>&1 || { + echo "ERROR: iOS SDK not found. Install Xcode and iOS SDK." + exit 1 + } +fi + +VCPKG_TOOLCHAIN="${VCPKG_ROOT}/scripts/buildsystems/vcpkg.cmake" +if [ ! -f "${VCPKG_TOOLCHAIN}" ]; then + echo "ERROR: vcpkg toolchain not found at ${VCPKG_TOOLCHAIN}" + exit 1 +fi + +echo "Triplet: ${TRIPLET}" +echo "Apple SDK: ${APPLE_SDK}" + +# Clean previous build +rm -rf "${BUILD_DIR}" +mkdir -p "${BUILD_DIR}" + +echo "" +echo "--- Step 1: Configure (vcpkg installs deps automatically) ---" +cmake -S "${SCRIPT_DIR}" -B "${BUILD_DIR}/consumer" \ + -DCMAKE_TOOLCHAIN_FILE="${VCPKG_TOOLCHAIN}" \ + -DVCPKG_TARGET_TRIPLET="${TRIPLET}" \ + -DVCPKG_OVERLAY_PORTS="${OVERLAY_PORTS}" \ + -DCMAKE_BUILD_TYPE=Release \ + -DCMAKE_SYSTEM_NAME=iOS \ + -DCMAKE_OSX_SYSROOT="${APPLE_SDK}" \ + -DCMAKE_OSX_ARCHITECTURES=arm64 \ + -DCMAKE_OSX_DEPLOYMENT_TARGET=12.0 + +echo "" +echo "--- Step 2: Build test consumer for iOS ---" +cmake --build "${BUILD_DIR}/consumer" --config Release + +echo "" +echo "--- Step 3: Verify output ---" +BINARY=$(find "${BUILD_DIR}/consumer" -name "vcpkg_test" -type f 2>/dev/null | head -1) +if [ -z "${BINARY}" ]; then + echo "[FAIL] iOS binary not found" + exit 1 +fi + +echo "[PASS] iOS binary produced: ${BINARY}" +file "${BINARY}" + +if [ "${USE_SIMULATOR}" = true ]; then + echo "" + echo "--- Step 4: Run on iOS Simulator ---" + + # Find an available iPhone simulator + DEVICE_UDID=$(xcrun simctl list devices available -j \ + | python3 -c " +import sys, json +data = json.load(sys.stdin)['devices'] +for runtime, devices in data.items(): + if 'iOS' not in runtime: + continue + for d in devices: + if d.get('isAvailable') and 'iPhone' in d.get('name', ''): + print(d['udid']) + sys.exit(0) +print('') +") + + if [ -z "${DEVICE_UDID}" ]; then + echo "ERROR: No available iPhone simulator found." + echo "Create one in Xcode's Devices and Simulators window, or use:" + echo " xcrun simctl list devicetypes" + echo " xcrun simctl list runtimes" + echo " xcrun simctl create " + exit 1 + fi + + echo "Using simulator: ${DEVICE_UDID}" + + # Boot the simulator (ignore error if already booted) + xcrun simctl boot "${DEVICE_UDID}" 2>/dev/null || true + + # Run the test binary on the simulator + echo "Executing vcpkg_test on simulator..." + if xcrun simctl spawn "${DEVICE_UDID}" "${BINARY}"; then + echo "[PASS] iOS Simulator execution succeeded" + else + EXIT_CODE=$? + echo "[FAIL] iOS Simulator execution failed with exit code ${EXIT_CODE}" + exit ${EXIT_CODE} + fi +else + echo "" + echo "NOTE: Device binary cannot run on macOS host." + echo " Use --simulator to build and run on the iOS Simulator." +fi + +echo "" +echo "=== iOS vcpkg port test PASSED ===" diff --git a/tests/vcpkg/test-vcpkg-linux.sh b/tests/vcpkg/test-vcpkg-linux.sh new file mode 100755 index 000000000..205430ffa --- /dev/null +++ b/tests/vcpkg/test-vcpkg-linux.sh @@ -0,0 +1,58 @@ +#!/bin/bash +# Test script: Verify mstelemetry vcpkg port on Linux +# Usage: ./tests/vcpkg/test-vcpkg-linux.sh +# Prerequisites: VCPKG_ROOT set, gcc/g++, cmake +set -e + +SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" +REPO_ROOT="$(cd "${SCRIPT_DIR}/../.." && pwd)" +BUILD_DIR="${SCRIPT_DIR}/build-linux" +OVERLAY_PORTS="${REPO_ROOT}/tools/ports" + +echo "=== MSTelemetry vcpkg port test (Linux) ===" +echo "Repository root: ${REPO_ROOT}" + +# Check prerequisites +if [ -z "${VCPKG_ROOT}" ]; then + echo "ERROR: VCPKG_ROOT is not set. Please set it to your vcpkg installation directory." + exit 1 +fi + +VCPKG_TOOLCHAIN="${VCPKG_ROOT}/scripts/buildsystems/vcpkg.cmake" +if [ ! -f "${VCPKG_TOOLCHAIN}" ]; then + echo "ERROR: vcpkg toolchain not found at ${VCPKG_TOOLCHAIN}" + exit 1 +fi + +LINUX_ARCH="$(uname -m)" +if [ "${LINUX_ARCH}" = "aarch64" ]; then + TRIPLET="arm64-linux" +else + TRIPLET="x64-linux" +fi + +echo "Architecture: ${LINUX_ARCH}" +echo "Triplet: ${TRIPLET}" + +# Clean previous build +rm -rf "${BUILD_DIR}" +mkdir -p "${BUILD_DIR}" + +echo "" +echo "--- Step 1: Configure (vcpkg installs deps automatically) ---" +cmake -S "${SCRIPT_DIR}" -B "${BUILD_DIR}/consumer" \ + -DCMAKE_TOOLCHAIN_FILE="${VCPKG_TOOLCHAIN}" \ + -DVCPKG_TARGET_TRIPLET="${TRIPLET}" \ + -DVCPKG_OVERLAY_PORTS="${OVERLAY_PORTS}" \ + -DCMAKE_BUILD_TYPE=Release + +echo "" +echo "--- Step 2: Build test consumer ---" +cmake --build "${BUILD_DIR}/consumer" --config Release + +echo "" +echo "--- Step 3: Run test ---" +"${BUILD_DIR}/consumer/vcpkg_test" + +echo "" +echo "=== Linux vcpkg port test PASSED ===" diff --git a/tests/vcpkg/test-vcpkg-macos.sh b/tests/vcpkg/test-vcpkg-macos.sh new file mode 100755 index 000000000..8d9c83e9a --- /dev/null +++ b/tests/vcpkg/test-vcpkg-macos.sh @@ -0,0 +1,63 @@ +#!/bin/bash +# Test script: Verify mstelemetry vcpkg port on macOS +# Usage: ./tests/vcpkg/test-vcpkg-macos.sh +# Prerequisites: VCPKG_ROOT set, Xcode command line tools, cmake +set -e + +SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" +REPO_ROOT="$(cd "${SCRIPT_DIR}/../.." && pwd)" +BUILD_DIR="${SCRIPT_DIR}/build-macos" +OVERLAY_PORTS="${REPO_ROOT}/tools/ports" + +echo "=== MSTelemetry vcpkg port test (macOS) ===" +echo "Repository root: ${REPO_ROOT}" + +# Check prerequisites +if [ -z "${VCPKG_ROOT}" ]; then + echo "ERROR: VCPKG_ROOT is not set. Please set it to your vcpkg installation directory." + exit 1 +fi + +if [ "$(uname)" != "Darwin" ]; then + echo "ERROR: This script must be run on macOS." + exit 1 +fi + +VCPKG_TOOLCHAIN="${VCPKG_ROOT}/scripts/buildsystems/vcpkg.cmake" +if [ ! -f "${VCPKG_TOOLCHAIN}" ]; then + echo "ERROR: vcpkg toolchain not found at ${VCPKG_TOOLCHAIN}" + exit 1 +fi +MAC_ARCH="$(uname -m)" + +if [ "${MAC_ARCH}" = "arm64" ]; then + TRIPLET="arm64-osx" +else + TRIPLET="x64-osx" +fi + +echo "Architecture: ${MAC_ARCH}" +echo "Triplet: ${TRIPLET}" + +# Clean previous build +rm -rf "${BUILD_DIR}" +mkdir -p "${BUILD_DIR}" + +echo "" +echo "--- Step 1: Configure (vcpkg installs deps automatically) ---" +cmake -S "${SCRIPT_DIR}" -B "${BUILD_DIR}/consumer" \ + -DCMAKE_TOOLCHAIN_FILE="${VCPKG_TOOLCHAIN}" \ + -DVCPKG_TARGET_TRIPLET="${TRIPLET}" \ + -DVCPKG_OVERLAY_PORTS="${OVERLAY_PORTS}" \ + -DCMAKE_BUILD_TYPE=Release + +echo "" +echo "--- Step 2: Build test consumer ---" +cmake --build "${BUILD_DIR}/consumer" --config Release + +echo "" +echo "--- Step 3: Run test ---" +"${BUILD_DIR}/consumer/vcpkg_test" + +echo "" +echo "=== macOS vcpkg port test PASSED ===" diff --git a/tests/vcpkg/test-vcpkg-windows.ps1 b/tests/vcpkg/test-vcpkg-windows.ps1 new file mode 100644 index 000000000..a919495dd --- /dev/null +++ b/tests/vcpkg/test-vcpkg-windows.ps1 @@ -0,0 +1,141 @@ +# Test script: Verify mstelemetry vcpkg port on Windows +# Usage: Run from a VS Developer Command Prompt, or the script will find VS automatically. +# .\tests\vcpkg\test-vcpkg-windows.ps1 +# .\tests\vcpkg\test-vcpkg-windows.ps1 -Triplet x64-windows +param( + [string]$VcpkgRoot = "", + [string]$Triplet = "" +) + +$ErrorActionPreference = "Stop" + +$ScriptDir = Split-Path -Parent $MyInvocation.MyCommand.Path +$RepoRoot = (Resolve-Path (Join-Path $ScriptDir "..\..")).Path +$BuildDir = Join-Path $ScriptDir "build-windows" +$OverlayPorts = Join-Path $RepoRoot "tools\ports" + +Write-Host "=== MSTelemetry vcpkg port test (Windows) ===" -ForegroundColor Cyan + +# Resolve vcpkg root: parameter > VCPKG_ROOT env var > error +if ([string]::IsNullOrEmpty($VcpkgRoot)) { + $VcpkgRoot = $env:VCPKG_ROOT +} +if ([string]::IsNullOrEmpty($VcpkgRoot)) { + Write-Error "VCPKG_ROOT is not set. Pass -VcpkgRoot or set the VCPKG_ROOT environment variable." + exit 1 +} + +$VcpkgToolchain = Join-Path $VcpkgRoot "scripts\buildsystems\vcpkg.cmake" +if (-not (Test-Path $VcpkgToolchain)) { + Write-Error "vcpkg toolchain not found at $VcpkgToolchain" + exit 1 +} + +# PROCESSOR_ARCHITEW6432 reports the native arch even under x64 emulation on ARM64 +$NativeArch = if ($env:PROCESSOR_ARCHITEW6432) { $env:PROCESSOR_ARCHITEW6432 } else { $env:PROCESSOR_ARCHITECTURE } + +# Auto-detect triplet from host architecture if not specified +if ([string]::IsNullOrEmpty($Triplet)) { + if ($NativeArch -eq "ARM64") { + $Triplet = "arm64-windows-static" + } else { + $Triplet = "x64-windows-static" + } +} + +# Map triplet to vcvarsall architecture +$VcvarsArch = switch -Regex ($Triplet) { + "^arm64-" { if ($NativeArch -eq "ARM64") { "arm64" } else { "amd64_arm64" } } + "^x86-" { "x86" } + default { "x64" } +} + +Write-Host "Repository root: $RepoRoot" +Write-Host "vcpkg root: $VcpkgRoot" +Write-Host "Triplet: $Triplet" + +# Clean previous build +if (Test-Path $BuildDir) { + Remove-Item -Recurse -Force $BuildDir +} +New-Item -ItemType Directory -Path $BuildDir -Force | Out-Null + +# Build cmake args as an array (avoids backtick continuation issues) +$ConsumerBuild = Join-Path $BuildDir "consumer" +$CmakeArgs = @( + "-S", $ScriptDir, + "-B", $ConsumerBuild, + "-DCMAKE_TOOLCHAIN_FILE=$VcpkgToolchain", + "-DVCPKG_TARGET_TRIPLET=$Triplet", + "-DVCPKG_OVERLAY_PORTS=$OverlayPorts", + "-DCMAKE_BUILD_TYPE=Release" +) + +# Detect whether cl.exe is on PATH (i.e., running from VS Developer Command Prompt) +$clExe = Get-Command cl.exe -ErrorAction SilentlyContinue +if (-not $clExe) { + Write-Host "cl.exe not on PATH. Finding VS with vswhere..." + $vswherePath = "C:\Program Files (x86)\Microsoft Visual Studio\Installer\vswhere.exe" + if (-not (Test-Path $vswherePath)) { + $vswherePath = (Get-Command vswhere.exe -ErrorAction SilentlyContinue).Source + } + if (-not $vswherePath) { + Write-Error "vswhere.exe not found. Install Visual Studio or run from a VS Developer Command Prompt." + exit 1 + } + $vsInstall = & $vswherePath -latest -property installationPath + if (-not $vsInstall) { + Write-Error "Visual Studio not found. Run from a VS Developer Command Prompt." + exit 1 + } + $vcvarsall = Join-Path $vsInstall "VC\Auxiliary\Build\vcvarsall.bat" + Write-Host "Initializing VS environment from: $vcvarsall" + + # Build and run everything from a temporary batch file so each argument remains quoted. + $quoteCmdArg = { + param([string]$Value) + '"' + $Value.Replace('"', '""') + '"' + } + $configureArgs = @($CmakeArgs + @("-G", "NMake Makefiles")) | ForEach-Object { & $quoteCmdArg $_ } + $buildArgs = @("--build", $ConsumerBuild, "--config", "Release") | ForEach-Object { & $quoteCmdArg $_ } + $batchFile = Join-Path $BuildDir "run-vcpkg-test.cmd" + @( + "@echo off", + "call $(& $quoteCmdArg $vcvarsall) $VcvarsArch", + "if errorlevel 1 exit /b %errorlevel%", + "cmake $($configureArgs -join ' ')", + "if errorlevel 1 exit /b %errorlevel%", + "cmake $($buildArgs -join ' ')" + ) | Set-Content -LiteralPath $batchFile -Encoding ASCII + cmd /d /s /c "`"$batchFile`"" + if ($LASTEXITCODE -ne 0) { Write-Error "Build failed"; exit 1 } +} else { + Write-Host "Using cl.exe from: $($clExe.Source)" + + Write-Host "" + Write-Host "--- Step 1: Configure (vcpkg installs deps automatically) ---" -ForegroundColor Yellow + cmake @CmakeArgs -G "NMake Makefiles" + if ($LASTEXITCODE -ne 0) { Write-Error "CMake configure failed"; exit 1 } + + Write-Host "" + Write-Host "--- Step 2: Build test consumer ---" -ForegroundColor Yellow + cmake --build $ConsumerBuild --config Release + if ($LASTEXITCODE -ne 0) { Write-Error "Build failed"; exit 1 } +} + +Write-Host "" +Write-Host "--- Step 3: Run test ---" -ForegroundColor Yellow +$TestExe = Get-ChildItem -Path $ConsumerBuild -Recurse -Filter "vcpkg_test.exe" | Select-Object -First 1 +if ($null -eq $TestExe) { + Write-Error "Test executable not found" + exit 1 +} + +& $TestExe.FullName +if ($LASTEXITCODE -ne 0) { + Write-Error "Test execution failed" + exit 1 +} + +Write-Host "" +Write-Host "=== Windows vcpkg port test PASSED ===" -ForegroundColor Green diff --git a/tests/vcpkg/vcpkg.json b/tests/vcpkg/vcpkg.json new file mode 100644 index 000000000..ae83db603 --- /dev/null +++ b/tests/vcpkg/vcpkg.json @@ -0,0 +1,8 @@ +{ + "name": "mstelemetry-vcpkg-test", + "version-string": "0.0.1", + "description": "Integration test for mstelemetry vcpkg port", + "dependencies": [ + "mstelemetry" + ] +} diff --git a/tools/ports/mstelemetry/CONTROL b/tools/ports/mstelemetry/CONTROL deleted file mode 100644 index 54f2489b6..000000000 --- a/tools/ports/mstelemetry/CONTROL +++ /dev/null @@ -1,4 +0,0 @@ -Source: mstelemetry -Version: 3.4.999 -Homepage: https://github.com/microsoft/cpp_client_telemetry -Description: Microsoft C/C++ Client Telemetry Library (1DS C++ SDK) diff --git a/tools/ports/mstelemetry/TODO.md b/tools/ports/mstelemetry/TODO.md deleted file mode 100644 index 36ddfd11a..000000000 --- a/tools/ports/mstelemetry/TODO.md +++ /dev/null @@ -1,9 +0,0 @@ -# TODO - -- Consider adding the following line to portfile.cmake - -``` -Build-Depends: curl[ssl], nlohmann-json, sqlite3 -``` - -- Consider using Google Test and Google Benchmark from vcpkg diff --git a/tools/ports/mstelemetry/get_repo_name.sh b/tools/ports/mstelemetry/get_repo_name.sh deleted file mode 100755 index e98b382ba..000000000 --- a/tools/ports/mstelemetry/get_repo_name.sh +++ /dev/null @@ -1,6 +0,0 @@ -#!/bin/bash -set -e -DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" -pushd $DIR/../../ > /dev/null -basename -s .git `git config --get remote.origin.url` -popd > /dev/null diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index 7a9fba689..648506b40 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,83 +1,53 @@ -include(vcpkg_common_functions) - -message("CMAKE_CURRENT_SOURCE_DIR=${CMAKE_CURRENT_SOURCE_DIR}") -message("CMAKE_MODULE_PATH=${CMAKE_MODULE_PATH}") -message("CMAKE_CURRENT_LIST_DIR=${CMAKE_CURRENT_LIST_DIR}") - -if (UNIX) - execute_process(COMMAND "${CMAKE_CURRENT_LIST_DIR}/get_repo_name.sh" OUTPUT_VARIABLE REPO_NAME ERROR_QUIET) -else() - # execute_process(COMMAND git config --get remote.origin.url OUTPUT_VARIABLE REPO_URL ERROR_QUIET) - # message("REPO_URL=${REPO_URL}") - # string(REPLACE "/" ";" REPO_URL_LIST ${REPO_URL}) - # message(REPO_URL_LIST "list = ${REPO_URL_LIST}") - # list(LENGTH ${REPO_URL_LIST} LAST_ITEM) - # list(GET ${REPO_URL_LIST} ${LAST_ITEM} REPO_NAME) +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO microsoft/cpp_client_telemetry + REF dc53d660024772cd6fd858f7897ff124c2330c28 + SHA512 a8c70f4cc1a3f4dc88a0c5ed3bf2992bad7e85f1cf75238f1a608bc726f9c5317c8a549aeb2174022cf79bbe77a14940f687cc7cdbcbdeb5afd1b2db3944e174 + HEAD_REF main +) + +# Determine if Apple HTTP should be used (no curl needed). +# Note: BUILD_APPLE_HTTP must remain ON for macOS/iOS — the vcpkg.json +# curl dependency is excluded on these platforms. +set(MATSDK_BUILD_APPLE_HTTP OFF) +if(VCPKG_TARGET_IS_OSX OR VCPKG_TARGET_IS_IOS) + set(MATSDK_BUILD_APPLE_HTTP ON) endif() -message("REPO_NAME=${REPO_NAME}") - -if (DEFINED REPO_NAME) - # Use local snapshot since we already cloned the code - get_filename_component(SOURCE_PATH "${CMAKE_CURRENT_LIST_DIR}/../../../" ABSOLUTE) - message("Using local source snapshot from ${SOURCE_PATH}") -else() - # Fetch from GitHub main - message("Fetching source code from GitHub...") - if (UNIX) - vcpkg_from_github( - OUT_SOURCE_PATH SOURCE_PATH - REPO microsoft/cpp_client_telemetry - HEAD_REF main - ) - else() - vcpkg_from_github( - OUT_SOURCE_PATH SOURCE_PATH - REPO microsoft/cpp_client_telemetry - REF 4f60dd3bca305c2c0dd5ec2ed7b91d36b4de6dcf - SHA512 9778df5aa65d95fe1d41739753495d29b3149676e98ac2e802a103604553f4f2b43bc2eb089c2e13dc695f70279287ea79ec6e2926fad03befe8a671f91d36fb - HEAD_REF main - PATCHES ${CMAKE_CURRENT_LIST_DIR}/v142-build.patch - ) - endif() +# iOS build options +set(MATSDK_BUILD_IOS OFF) +if(VCPKG_TARGET_IS_IOS) + set(MATSDK_BUILD_IOS ON) endif() -# TODO: it will be slightly cleaner to perform pure CMake or Ninja build, by describing all possible variable options -# as separate triplets. Since we have a fairly non-trivial build logic in build.sh script - we use it as-is for now. -# build.sh itself should check if we are building under vcpkg and avoid installing deps that are coming from vcpkg. -if (UNIX) - vcpkg_execute_build_process( - COMMAND ${SOURCE_PATH}/build.sh noroot - WORKING_DIRECTORY ${SOURCE_PATH}/ - LOGNAME build - ) - - vcpkg_execute_build_process( - COMMAND ${SOURCE_PATH}/install.sh ${CURRENT_PACKAGES_DIR} - WORKING_DIRECTORY ${SOURCE_PATH}/ - LOGNAME install - ) - - file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright) -else() - vcpkg_check_linkage(ONLY_STATIC_LIBRARY) - - vcpkg_install_msbuild( - SOURCE_PATH ${SOURCE_PATH} - PROJECT_SUBPATH Solutions/MSTelemetrySDK.sln - LICENSE_SUBPATH LICENSE - RELEASE_CONFIGURATION Release - DEBUG_CONFIGURATION Debug - OPTIONS /p:MATSDK_SHARED_LIB=1 - PLATFORM ${VCPKG_TARGET_ARCHITECTURE} - PLATFORM_TOOLSET v142 - TARGET sqlite:Rebuild,win32-lib:Rebuild - USE_VCPKG_INTEGRATION - ) - - file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/bin" "${CURRENT_PACKAGES_DIR}/debug/bin") - file(COPY "${SOURCE_PATH}/lib/include/public" DESTINATION "${CURRENT_PACKAGES_DIR}") - file(RENAME "${CURRENT_PACKAGES_DIR}/public" "${CURRENT_PACKAGES_DIR}/include") - file(COPY "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}") - file(WRITE "${CURRENT_PACKAGES_DIR}/share/${PORT}/copyright" "Refer to LICENSE file") -endif() +vcpkg_cmake_configure( + SOURCE_PATH "${SOURCE_PATH}" + OPTIONS + -DMATSDK_USE_VCPKG_DEPS=ON + -DBUILD_HEADERS=ON + -DBUILD_LIBRARY=ON + -DBUILD_TEST_TOOL=OFF + -DBUILD_UNIT_TESTS=OFF + -DBUILD_FUNC_TESTS=OFF + -DBUILD_JNI_WRAPPER=OFF + -DBUILD_OBJC_WRAPPER=OFF + -DBUILD_SWIFT_WRAPPER=OFF + -DBUILD_PACKAGE=OFF + -DBUILD_VERSION=${VERSION} + -DBUILD_APPLE_HTTP=${MATSDK_BUILD_APPLE_HTTP} + -DBUILD_IOS=${MATSDK_BUILD_IOS} +) + +vcpkg_cmake_install() + +vcpkg_cmake_config_fixup(PACKAGE_NAME MSTelemetry CONFIG_PATH lib/cmake/MSTelemetry) + +# Remove duplicate headers and empty dirs +file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include") +file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share") + +# Install usage instructions +file(INSTALL "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}") + +# Install license +vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE") diff --git a/tools/ports/mstelemetry/response_file_linux.txt b/tools/ports/mstelemetry/response_file_linux.txt deleted file mode 100644 index ee7642068..000000000 --- a/tools/ports/mstelemetry/response_file_linux.txt +++ /dev/null @@ -1,6 +0,0 @@ ---head ---overlay-ports=tools/ports -mstelemetry -sqlite3 -zlib -nlohmann-json diff --git a/tools/ports/mstelemetry/response_file_mac.txt b/tools/ports/mstelemetry/response_file_mac.txt deleted file mode 100644 index ee7642068..000000000 --- a/tools/ports/mstelemetry/response_file_mac.txt +++ /dev/null @@ -1,6 +0,0 @@ ---head ---overlay-ports=tools/ports -mstelemetry -sqlite3 -zlib -nlohmann-json diff --git a/tools/ports/mstelemetry/usage b/tools/ports/mstelemetry/usage new file mode 100644 index 000000000..4c94e773f --- /dev/null +++ b/tools/ports/mstelemetry/usage @@ -0,0 +1,4 @@ +mstelemetry provides CMake targets: + + find_package(MSTelemetry CONFIG REQUIRED) + target_link_libraries(main PRIVATE MSTelemetry::mat) diff --git a/tools/ports/mstelemetry/v142-build.patch b/tools/ports/mstelemetry/v142-build.patch deleted file mode 100644 index 814418819..000000000 --- a/tools/ports/mstelemetry/v142-build.patch +++ /dev/null @@ -1,5701 +0,0 @@ -diff --git a/Solutions/MSTelemetrySDK.sln b/Solutions/MSTelemetrySDK.sln -index 904f20a9..a6bc3ece 100644 ---- a/Solutions/MSTelemetrySDK.sln -+++ b/Solutions/MSTelemetrySDK.sln -@@ -1,6 +1,6 @@ - Microsoft Visual Studio Solution File, Format Version 12.00 --# Visual Studio 15 --VisualStudioVersion = 15.0.28307.645 -+# Visual Studio Version 16 -+VisualStudioVersion = 16.0.31105.61 - MinimumVisualStudioVersion = 10.0.40219.1 - Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "sqlite", "..\sqlite\sqlite.vcxproj", "{2EBC7B3C-2AF1-442C-9285-CAB39BBB8C00}" - EndProject -@@ -38,39 +38,6 @@ EndProject - Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "managed", "..\lib\shared\Shared.vcxitems", "{EF859326-2A11-481C-AE8C-03D754F1C412}" - EndProject - Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "include", "include", "{553836FF-B1FD-4B70-AC81-AEC7752F9284}" -- ProjectSection(SolutionItems) = preProject -- ..\lib\include\public\AggregatedMetric.hpp = ..\lib\include\public\AggregatedMetric.hpp -- ..\lib\include\public\CommonFields.h = ..\lib\include\public\CommonFields.h -- ..\lib\include\public\CsProtocol_types.hpp = ..\lib\include\public\CsProtocol_types.hpp -- ..\lib\include\public\ctmacros.hpp = ..\lib\include\public\ctmacros.hpp -- ..\lib\include\public\DebugEvents.hpp = ..\lib\include\public\DebugEvents.hpp -- ..\lib\include\public\Enums.hpp = ..\lib\include\public\Enums.hpp -- ..\lib\include\public\EventProperties.hpp = ..\lib\include\public\EventProperties.hpp -- ..\lib\include\public\EventProperty.hpp = ..\lib\include\public\EventProperty.hpp -- ..\lib\include\public\IAFDClient.hpp = ..\lib\include\public\IAFDClient.hpp -- ..\lib\include\public\ICdsFactory.hpp = ..\lib\include\public\ICdsFactory.hpp -- ..\lib\include\public\IDataInspector.hpp = ..\lib\include\public\IDataInspector.hpp -- ..\lib\include\public\IDataViewer.hpp = ..\lib\include\public\IDataViewer.hpp -- ..\lib\include\public\IDataViewerCollection.hpp = ..\lib\include\public\IDataViewerCollection.hpp -- ..\lib\include\public\IDecorator.hpp = ..\lib\include\public\IDecorator.hpp -- ..\lib\include\public\IECSClient.hpp = ..\lib\include\public\IECSClient.hpp -- ..\lib\include\public\IEventFilter.hpp = ..\lib\include\public\IEventFilter.hpp -- ..\lib\include\public\IEventFilterCollection.hpp = ..\lib\include\public\IEventFilterCollection.hpp -- ..\lib\include\public\IHttpClient.hpp = ..\lib\include\public\IHttpClient.hpp -- ..\lib\include\public\ILogConfiguration.hpp = ..\lib\include\public\ILogConfiguration.hpp -- ..\lib\include\public\ILogger.hpp = ..\lib\include\public\ILogger.hpp -- ..\lib\include\public\ILogManager.hpp = ..\lib\include\public\ILogManager.hpp -- ..\lib\include\public\IModule.hpp = ..\lib\include\public\IModule.hpp -- ..\lib\include\public\IOfflineStorage.hpp = ..\lib\include\public\IOfflineStorage.hpp -- ..\lib\include\public\ISemanticContext.hpp = ..\lib\include\public\ISemanticContext.hpp -- ..\lib\include\public\ITaskDispatcher.hpp = ..\lib\include\public\ITaskDispatcher.hpp -- ..\lib\include\public\LogManager.hpp = ..\lib\include\public\LogManager.hpp -- ..\lib\include\public\LogSessionData.hpp = ..\lib\include\public\LogSessionData.hpp -- ..\lib\include\public\mat.h = ..\lib\include\public\mat.h -- ..\lib\include\public\PayloadDecoder.hpp = ..\lib\include\public\PayloadDecoder.hpp -- ..\lib\include\public\Version.hpp = ..\lib\include\public\Version.hpp -- ..\lib\include\public\Version.hpp.template = ..\lib\include\public\Version.hpp.template -- EndProjectSection - EndProject - Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "win32-lib", "win32-lib\win32-lib.vcxproj", "{1DC6B38A-B390-34CE-907F-4958807A3D42}" - EndProject -@@ -164,42 +131,19 @@ Global - GlobalSection(SharedMSBuildProjectFiles) = preSolution - ..\lib\pal\universal\universal.vcxitems*{10e9165b-49d1-4d1c-8248-334b9905b9cc}*SharedItemsImports = 9 - ..\lib\pal\desktop\desktop.vcxitems*{10e9165b-49d1-4d1c-8248-334b9905b9cd}*SharedItemsImports = 9 -- ..\lib\modules\azmon\azmon.vcxitems*{1dc6b38a-b390-34ce-907f-4958807a3d42}*SharedItemsImports = 4 -- ..\lib\modules\cds\cds.vcxitems*{1dc6b38a-b390-34ce-907f-4958807a3d42}*SharedItemsImports = 4 -- ..\lib\modules\dataviewer\dataviewer.vcxitems*{1dc6b38a-b390-34ce-907f-4958807a3d42}*SharedItemsImports = 4 -- ..\lib\modules\exp\exp.vcxitems*{1dc6b38a-b390-34ce-907f-4958807a3d42}*SharedItemsImports = 4 -- ..\lib\modules\filter\filter.vcxitems*{1dc6b38a-b390-34ce-907f-4958807a3d42}*SharedItemsImports = 4 -- ..\lib\modules\privacyguard\privacyguard.vcxitems*{1dc6b38a-b390-34ce-907f-4958807a3d42}*SharedItemsImports = 4 - ..\lib\pal\desktop\desktop.vcxitems*{1dc6b38a-b390-34ce-907f-4958807a3d42}*SharedItemsImports = 4 - Clienttelemetry\Clienttelemetry.vcxitems*{1dc6b38a-b390-34ce-907f-4958807a3d42}*SharedItemsImports = 4 - ..\lib\pal\desktop\desktop.vcxitems*{1dc6b38a-b390-34ce-907f-4958807a3d43}*SharedItemsImports = 4 - Clienttelemetry\Clienttelemetry.vcxitems*{1dc6b38a-b390-34ce-907f-4958807a3d43}*SharedItemsImports = 4 - ..\lib\modules\dataviewer\dataviewer.vcxitems*{20ad4f2b-3f98-4baf-8144-e1e7682a7927}*SharedItemsImports = 9 -- ..\lib\modules\azmon\azmon.vcxitems*{216a8e97-21f7-4bef-9e52-7f772c177c32}*SharedItemsImports = 4 -- ..\lib\modules\cds\cds.vcxitems*{216a8e97-21f7-4bef-9e52-7f772c177c32}*SharedItemsImports = 4 -- ..\lib\modules\dataviewer\dataviewer.vcxitems*{216a8e97-21f7-4bef-9e52-7f772c177c32}*SharedItemsImports = 4 -- ..\lib\modules\exp\exp.vcxitems*{216a8e97-21f7-4bef-9e52-7f772c177c32}*SharedItemsImports = 4 -- ..\lib\modules\filter\filter.vcxitems*{216a8e97-21f7-4bef-9e52-7f772c177c32}*SharedItemsImports = 4 -- ..\lib\modules\privacyguard\privacyguard.vcxitems*{216a8e97-21f7-4bef-9e52-7f772c177c32}*SharedItemsImports = 4 - ..\lib\pal\desktop\desktop.vcxitems*{216a8e97-21f7-4bef-9e52-7f772c177c32}*SharedItemsImports = 4 - Clienttelemetry\Clienttelemetry.vcxitems*{216a8e97-21f7-4bef-9e52-7f772c177c32}*SharedItemsImports = 4 - ..\lib\pal\desktop\desktop.vcxitems*{216a8e97-21f7-4bef-9e52-7f772c177c33}*SharedItemsImports = 4 - Clienttelemetry\Clienttelemetry.vcxitems*{216a8e97-21f7-4bef-9e52-7f772c177c33}*SharedItemsImports = 4 - ..\lib\modules\exp\exp.vcxitems*{2bfafe9a-45b0-4c02-841e-03e47fd2e340}*SharedItemsImports = 9 -- ..\lib\modules\azmon\azmon.vcxitems*{434c594f-cde0-3690-ac0a-9ed854b74092}*SharedItemsImports = 4 -- ..\lib\modules\cds\cds.vcxitems*{434c594f-cde0-3690-ac0a-9ed854b74092}*SharedItemsImports = 4 -- ..\lib\modules\dataviewer\dataviewer.vcxitems*{434c594f-cde0-3690-ac0a-9ed854b74092}*SharedItemsImports = 4 -- ..\lib\modules\filter\filter.vcxitems*{434c594f-cde0-3690-ac0a-9ed854b74092}*SharedItemsImports = 4 -- ..\lib\modules\privacyguard\privacyguard.vcxitems*{434c594f-cde0-3690-ac0a-9ed854b74092}*SharedItemsImports = 4 - ..\lib\pal\desktop\desktop.vcxitems*{434c594f-cde0-3690-ac0a-9ed854b74092}*SharedItemsImports = 4 - Clienttelemetry\Clienttelemetry.vcxitems*{434c594f-cde0-3690-ac0a-9ed854b74092}*SharedItemsImports = 4 - Clienttelemetry\Clienttelemetry.vcxitems*{45d41acc-2c3c-43d2-bc10-02aa73ffc7c7}*SharedItemsImports = 9 -- ..\lib\modules\azmon\azmon.vcxitems*{49077dbf-e363-4d2d-8334-636569a771b6}*SharedItemsImports = 4 -- ..\lib\modules\cds\cds.vcxitems*{49077dbf-e363-4d2d-8334-636569a771b6}*SharedItemsImports = 4 -- ..\lib\modules\dataviewer\dataviewer.vcxitems*{49077dbf-e363-4d2d-8334-636569a771b6}*SharedItemsImports = 4 -- ..\lib\modules\exp\exp.vcxitems*{49077dbf-e363-4d2d-8334-636569a771b6}*SharedItemsImports = 4 -- ..\lib\modules\filter\filter.vcxitems*{49077dbf-e363-4d2d-8334-636569a771b6}*SharedItemsImports = 4 -- ..\lib\modules\privacyguard\privacyguard.vcxitems*{49077dbf-e363-4d2d-8334-636569a771b6}*SharedItemsImports = 4 - ..\lib\pal\universal\universal.vcxitems*{49077dbf-e363-4d2d-8334-636569a771b6}*SharedItemsImports = 4 - ..\lib\shared\Shared.vcxitems*{49077dbf-e363-4d2d-8334-636569a771b6}*SharedItemsImports = 4 - Clienttelemetry\Clienttelemetry.vcxitems*{49077dbf-e363-4d2d-8334-636569a771b6}*SharedItemsImports = 4 -@@ -213,25 +157,14 @@ Global - Clienttelemetry\Clienttelemetry.vcxitems*{57a81ed9-5603-471f-afee-9656da74178d}*SharedItemsImports = 4 - ..\lib\decoder\decoder.vcxitems*{65b6880e-fc36-443d-a7a5-0e6cda6523ac}*SharedItemsImports = 9 - ..\lib\modules\azmon\azmon.vcxitems*{6dc5ab1d-3d64-4c52-8d8e-d9a8b0c16f14}*SharedItemsImports = 9 -- ..\lib\modules\azmon\azmon.vcxitems*{7a75748d-5d6b-48a5-83cb-f5f439133d59}*SharedItemsImports = 4 -- ..\lib\modules\cds\cds.vcxitems*{7a75748d-5d6b-48a5-83cb-f5f439133d59}*SharedItemsImports = 4 -- ..\lib\modules\dataviewer\dataviewer.vcxitems*{7a75748d-5d6b-48a5-83cb-f5f439133d59}*SharedItemsImports = 4 -- ..\lib\modules\exp\exp.vcxitems*{7a75748d-5d6b-48a5-83cb-f5f439133d59}*SharedItemsImports = 4 -- ..\lib\modules\filter\filter.vcxitems*{7a75748d-5d6b-48a5-83cb-f5f439133d59}*SharedItemsImports = 4 -- ..\lib\modules\privacyguard\privacyguard.vcxitems*{7a75748d-5d6b-48a5-83cb-f5f439133d59}*SharedItemsImports = 4 - ..\lib\pal\universal\universal.vcxitems*{7a75748d-5d6b-48a5-83cb-f5f439133d59}*SharedItemsImports = 4 - Clienttelemetry\Clienttelemetry.vcxitems*{7a75748d-5d6b-48a5-83cb-f5f439133d59}*SharedItemsImports = 4 -- ..\lib\modules\cds\cds.vcxitems*{e1f6ca48-3bbf-4378-8d1e-6bbf4869db5b}*SharedItemsImports = 9 -- ..\lib\modules\cds\cds.vcxitems*{fe79fb3a-b3ef-38df-b7a4-11277db72b39}*SharedItemsImports = 4 - ..\lib\modules\filter\filter.vcxitems*{d74e42ec-c6ee-4944-b92a-eb711be002a9}*SharedItemsImports = 9 - ..\lib\shared\Shared.vcxitems*{dc91621e-a203-42df-8e03-3a23dd0602b1}*SharedItemsImports = 4 -+ ..\lib\modules\cds\cds.vcxitems*{e1f6ca48-3bbf-4378-8d1e-6bbf4869db5b}*SharedItemsImports = 9 - ..\lib\modules\privacyguard\privacyguard.vcxitems*{e1f6ca48-3bbf-4378-8d1e-6bbf4869db5b}*SharedItemsImports = 9 - ..\lib\shared\Shared.vcxitems*{ef859326-2a11-481c-ae8c-03d754f1c412}*SharedItemsImports = 9 - ..\lib\decoder\decoder.vcxitems*{fe79fb3a-b3ef-38df-b7a4-11277db72b39}*SharedItemsImports = 4 -- ..\lib\modules\azmon\azmon.vcxitems*{fe79fb3a-b3ef-38df-b7a4-11277db72b39}*SharedItemsImports = 4 -- ..\lib\modules\dataviewer\dataviewer.vcxitems*{fe79fb3a-b3ef-38df-b7a4-11277db72b39}*SharedItemsImports = 4 -- ..\lib\modules\filter\filter.vcxitems*{fe79fb3a-b3ef-38df-b7a4-11277db72b39}*SharedItemsImports = 4 -- ..\lib\modules\privacyguard\privacyguard.vcxitems*{fe79fb3a-b3ef-38df-b7a4-11277db72b39}*SharedItemsImports = 4 - ..\lib\pal\desktop\desktop.vcxitems*{fe79fb3a-b3ef-38df-b7a4-11277db72b39}*SharedItemsImports = 4 - Clienttelemetry\Clienttelemetry.vcxitems*{fe79fb3a-b3ef-38df-b7a4-11277db72b39}*SharedItemsImports = 4 - EndGlobalSection -diff --git a/Solutions/net40/net40.vcxproj b/Solutions/net40/net40.vcxproj -index 12444a52..ef11fb6c 100644 ---- a/Solutions/net40/net40.vcxproj -+++ b/Solutions/net40/net40.vcxproj -@@ -27,6 +27,7 @@ - net40 - true - true -+ 10.0 - - - -@@ -35,6 +36,7 @@ - false - Unicode - false -+ v142 - - - DynamicLibrary -@@ -42,6 +44,7 @@ - true - Unicode - false -+ v142 - - - DynamicLibrary -@@ -49,6 +52,7 @@ - Unicode - false - false -+ v142 - - - DynamicLibrary -@@ -56,6 +60,7 @@ - false - Unicode - false -+ v142 - - - -diff --git a/Solutions/win10-cs/win10-cs.vcxproj b/Solutions/win10-cs/win10-cs.vcxproj -index 147ae1e4..0a7a0ea7 100644 ---- a/Solutions/win10-cs/win10-cs.vcxproj -+++ b/Solutions/win10-cs/win10-cs.vcxproj -@@ -47,6 +47,7 @@ - 8.2 - 10.0.10240.0 - true -+ 10.0 - - - TRUE -@@ -55,38 +56,46 @@ - - DynamicLibrary - true -+ v142 - - - DynamicLibrary - true -+ v142 - - - DynamicLibrary - true -+ v142 - - - DynamicLibrary - true -+ v142 - - - DynamicLibrary - false - true -+ v142 - - - DynamicLibrary - false - true -+ v142 - - - DynamicLibrary - false - true -+ v142 - - - DynamicLibrary - false - true -+ v142 - - - -diff --git a/Solutions/win10-lib/win10-lib.vcxproj b/Solutions/win10-lib/win10-lib.vcxproj -index 30bcf573..a38778d7 100644 ---- a/Solutions/win10-lib/win10-lib.vcxproj -+++ b/Solutions/win10-lib/win10-lib.vcxproj -@@ -48,43 +48,52 @@ - 10.0 - win10-lib - true -+ 10.0 - - - - StaticLibrary - true -+ v142 - - - StaticLibrary - true -+ v142 - - - StaticLibrary - true -+ v142 - - - StaticLibrary - true -+ v142 - - - StaticLibrary - false - true -+ v142 - - - StaticLibrary - false - true -+ v142 - - - StaticLibrary - false - true -+ v142 - - - StaticLibrary - false - true -+ v142 - - - -@@ -95,7 +104,7 @@ - - - -- -+ - - - -diff --git a/Solutions/win32-dll/win32-dll.vcxproj b/Solutions/win32-dll/win32-dll.vcxproj -index 4ae04059..5df3dd01 100644 ---- a/Solutions/win32-dll/win32-dll.vcxproj -+++ b/Solutions/win32-dll/win32-dll.vcxproj -@@ -44,6 +44,7 @@ - ClientTelemetry - win32-dll - true -+ 10.0 - - - TRUE -@@ -57,36 +58,42 @@ - true - Unicode - false -+ v142 - - - DynamicLibrary - false - false - Unicode -+ v142 - - - DynamicLibrary - true - Unicode - false -+ v142 - - - DynamicLibrary - true - Unicode - false -+ v142 - - - DynamicLibrary - false - false - Unicode -+ v142 - - - DynamicLibrary - false - false - Unicode -+ v142 - - - -diff --git a/Solutions/win32-lib/win32-lib.vcxproj b/Solutions/win32-lib/win32-lib.vcxproj -index c1d9667a..6880136b 100644 ---- a/Solutions/win32-lib/win32-lib.vcxproj -+++ b/Solutions/win32-lib/win32-lib.vcxproj -@@ -57,6 +57,7 @@ - ClientTelemetry - win32-lib - true -+ 10.0 - - - OACR -@@ -67,48 +68,56 @@ - true - Unicode - false -+ v142 - - - StaticLibrary - true - Unicode - false -+ v142 - - - StaticLibrary - false - false - Unicode -+ v142 - - - StaticLibrary - false - false - Unicode -+ v142 - - - StaticLibrary - true - Unicode - false -+ v142 - - - StaticLibrary - true - Unicode - false -+ v142 - - - StaticLibrary - true - Unicode - false -+ v142 - - - StaticLibrary - true - Unicode - false -+ v142 - - - StaticLibrary -@@ -116,24 +125,28 @@ - false - Unicode - win-x64_vs2015-crtdynamic-release -+ v142 - - - StaticLibrary - false - false - Unicode -+ v142 - - - StaticLibrary - false - false - Unicode -+ v142 - - - StaticLibrary - false - false - Unicode -+ v142 - - - -diff --git a/Solutions/win32-mini-dll/win32-mini-dll.vcxproj b/Solutions/win32-mini-dll/win32-mini-dll.vcxproj -index 97892580..b8c5eeef 100644 ---- a/Solutions/win32-mini-dll/win32-mini-dll.vcxproj -+++ b/Solutions/win32-mini-dll/win32-mini-dll.vcxproj -@@ -44,6 +44,7 @@ - ClientTelemetry - win32-mini-dll - true -+ 10.0 - - - OACR -@@ -54,36 +55,42 @@ - true - Unicode - false -+ v142 - - - DynamicLibrary - false - false - Unicode -+ v142 - - - DynamicLibrary - true - Unicode - false -+ v142 - - - DynamicLibrary - true - Unicode - false -+ v142 - - - DynamicLibrary - false - false - Unicode -+ v142 - - - DynamicLibrary - false - false - Unicode -+ v142 - - - -diff --git a/Solutions/win32-mini-lib/win32-mini-lib.vcxproj b/Solutions/win32-mini-lib/win32-mini-lib.vcxproj -index edc2828f..6da2528e 100644 ---- a/Solutions/win32-mini-lib/win32-mini-lib.vcxproj -+++ b/Solutions/win32-mini-lib/win32-mini-lib.vcxproj -@@ -57,6 +57,7 @@ - ClientTelemetry - win32-mini-lib - true -+ 10.0 - - - OACR -@@ -67,72 +68,84 @@ - true - Unicode - false -+ v142 - - - StaticLibrary - true - Unicode - false -+ v142 - - - StaticLibrary - false - false - Unicode -+ v142 - - - StaticLibrary - false - false - Unicode -+ v142 - - - StaticLibrary - true - Unicode - false -+ v142 - - - StaticLibrary - true - Unicode - false -+ v142 - - - StaticLibrary - true - Unicode - false -+ v142 - - - StaticLibrary - true - Unicode - false -+ v142 - - - StaticLibrary - false - false - Unicode -+ v142 - - - StaticLibrary - false - false - Unicode -+ v142 - - - StaticLibrary - false - false - Unicode -+ v142 - - - StaticLibrary - false - false - Unicode -+ v142 - - - -diff --git a/examples/c/SampleC/SampleC.vcxproj b/examples/c/SampleC/SampleC.vcxproj -index a4901f2b..9dbc8ca4 100644 ---- a/examples/c/SampleC/SampleC.vcxproj -+++ b/examples/c/SampleC/SampleC.vcxproj -@@ -20,12 +20,14 @@ - Application - true - Unicode -+ v142 - - - Application - false - true - Unicode -+ v142 - - - -diff --git a/examples/cpp/EventSender/EventSender.vcxproj b/examples/cpp/EventSender/EventSender.vcxproj -index b55221e1..ed4d921a 100644 ---- a/examples/cpp/EventSender/EventSender.vcxproj -+++ b/examples/cpp/EventSender/EventSender.vcxproj -@@ -24,29 +24,34 @@ - {7DBFBA1F-520D-4C93-A33E-DD92FD4F9222} - Win32Proj - EventSender -+ 10.0 - - - - Application - true - Unicode -+ v142 - - - Application - false - true - Unicode -+ v142 - - - Application - true - Unicode -+ v142 - - - Application - false - true - Unicode -+ v142 - - - -diff --git a/examples/cpp/EventSender/EventSender.vcxproj.filters b/examples/cpp/EventSender/EventSender.vcxproj.filters -index f5b9ccda..edd3c98f 100644 ---- a/examples/cpp/EventSender/EventSender.vcxproj.filters -+++ b/examples/cpp/EventSender/EventSender.vcxproj.filters -@@ -1,117 +1,22 @@ -- -- -- -- -- {4FC737F1-C7A5-4376-A066-2A32D752A2FF} -- cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx -- -- -- {93995380-89BD-4b04-88EB-625FBE52EBFB} -- h;hh;hpp;hxx;hm;inl;inc;ipp;xsd -- -- -- {67DA6AB6-F800-4c08-8B7A-83BB121AAD01} -- rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms -- -- -- -- -- Source Files -- -- -- -- -- -- Header Files -- -- -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -- Header Files -- -- -+ -+ -+ -+ -+ {4FC737F1-C7A5-4376-A066-2A32D752A2FF} -+ cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx -+ -+ -+ {93995380-89BD-4b04-88EB-625FBE52EBFB} -+ h;hh;hpp;hxx;hm;inl;inc;ipp;xsd -+ -+ -+ {67DA6AB6-F800-4c08-8B7A-83BB121AAD01} -+ rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms -+ -+ -+ -+ -+ Source Files -+ -+ - -\ No newline at end of file -diff --git a/examples/cpp/SampleCpp/SampleCpp.vcxproj b/examples/cpp/SampleCpp/SampleCpp.vcxproj -index f8154a7e..ab8b5fb6 100644 ---- a/examples/cpp/SampleCpp/SampleCpp.vcxproj -+++ b/examples/cpp/SampleCpp/SampleCpp.vcxproj -@@ -79,124 +79,124 @@ - {86AC752C-5687-4377-841E-943D9BEEF360} - Win32Proj - SampleCpp -- 10.0.17134.0 -+ 10.0 - true - - - - Application - true -- v141 -+ v142 - Unicode - - - Application - true -- v141 -+ v142 - Unicode - - - Application - true -- v141 -+ v142 - Unicode - - - Application - false -- v141 -+ v142 - true - Unicode - - - Application - false -- v141 -+ v142 - true - Unicode - - - Application - false -- v141 -+ v142 - true - Unicode - - - Application - true -- v141 -+ v142 - Unicode - - - Application - true -- v141 -+ v142 - Unicode - - - Application - true -- v141 -+ v142 - Unicode - - - Application - true -- v141 -+ v142 - Unicode - - - Application - true -- v141 -+ v142 - Unicode - - - Application - true -- v141 -+ v142 - Unicode - - - Application - false -- v141 -+ v142 - true - Unicode - - - Application - false -- v141 -+ v142 - true - Unicode - - - Application - false -- v141 -+ v142 - true - Unicode - - - Application - false -- v141 -+ v142 - true - Unicode - - - Application - false -- v141 -+ v142 - true - Unicode - - - Application - false -- v141 -+ v142 - true - Unicode - -diff --git a/examples/cpp/SampleCppLogManagers/SampleCppLogManagers.vcxproj b/examples/cpp/SampleCppLogManagers/SampleCppLogManagers.vcxproj -index be49c0cf..1466a4d8 100644 ---- a/examples/cpp/SampleCppLogManagers/SampleCppLogManagers.vcxproj -+++ b/examples/cpp/SampleCppLogManagers/SampleCppLogManagers.vcxproj -@@ -1,200 +1,200 @@ -- -- -- -- -- Debug -- Win32 -- -- -- Release -- Win32 -- -- -- Debug -- x64 -- -- -- Release -- x64 -- -- -- -- 15.0 -- {77053F92-F003-4D1C-A489-1DEB7CFEA4EC} -- Win32Proj -- SampleCppLogManagers -- 10.0.17134.0 -- -- -- -- Application -- true -- v141 -- Unicode -- -- -- Application -- false -- v141 -- true -- Unicode -- -- -- Application -- true -- v141 -- Unicode -- -- -- Application -- false -- v141 -- true -- Unicode -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- true -- $(VC_IncludePath);$(WindowsSDK_IncludePath);$(SolutionDir)\..\lib\include\public;$(SolutionDir)\..\lib\pal\ -- $(ProjectDir) -- $(Configuration)\ -- $(LibraryPath) -- -- -- true -- $(ProjectDir) -- $(VC_IncludePath);$(WindowsSDK_IncludePath);$(SolutionDir)\..\lib\include\public;$(SolutionDir)\..\lib\pal\ -- $(LibraryPath) -- -- -- false -- $(VC_IncludePath);$(WindowsSDK_IncludePath);$(SolutionDir)\..\lib\include\public -- -- -- false -- $(VC_IncludePath);$(WindowsSDK_IncludePath);$(SolutionDir)\..\lib\include\public -- -- -- -- NotUsing -- Level3 -- Disabled -- true -- WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions) -- true -- pch.h -- -- -- Console -- true -- -- -- $(MSBuildProjectDirectory)\deploy-dll.cmd $(Configuration) $(Platform) $(OutDir) -- -- -- Deploy DLLs -- -- -- -- -- NotUsing -- Level3 -- Disabled -- true -- _DEBUG;_CONSOLE;%(PreprocessorDefinitions) -- true -- pch.h -- -- -- Console -- true -- -- -- $(MSBuildProjectDirectory)\deploy-dll.cmd $(Configuration) $(Platform) $(OutDir) -- -- -- Deploy DLLs -- -- -- -- -- NotUsing -- Level3 -- MaxSpeed -- true -- true -- true -- WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions) -- true -- pch.h -- -- -- Console -- true -- true -- true -- -- -- $(MSBuildProjectDirectory)\deploy-dll.cmd $(Configuration) $(Platform) $(OutDir) -- -- -- Deploy DLLs -- -- -- -- -- NotUsing -- Level3 -- MaxSpeed -- true -- true -- true -- NDEBUG;_CONSOLE;%(PreprocessorDefinitions) -- true -- pch.h -- -- -- Console -- true -- true -- true -- -- -- $(MSBuildProjectDirectory)\deploy-dll.cmd $(Configuration) $(Platform) $(OutDir) -- -- -- Deploy DLLs -- -- -- -- -- -- -- -- {216a8e97-21f7-4bef-9e52-7f772c177c32} -- -- -- -- -- -- -- -- -- -+ -+ -+ -+ -+ Debug -+ Win32 -+ -+ -+ Release -+ Win32 -+ -+ -+ Debug -+ x64 -+ -+ -+ Release -+ x64 -+ -+ -+ -+ 15.0 -+ {77053F92-F003-4D1C-A489-1DEB7CFEA4EC} -+ Win32Proj -+ SampleCppLogManagers -+ 10.0 -+ -+ -+ -+ Application -+ true -+ v142 -+ Unicode -+ -+ -+ Application -+ false -+ v142 -+ true -+ Unicode -+ -+ -+ Application -+ true -+ v142 -+ Unicode -+ -+ -+ Application -+ false -+ v142 -+ true -+ Unicode -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ true -+ $(VC_IncludePath);$(WindowsSDK_IncludePath);$(SolutionDir)\..\lib\include\public;$(SolutionDir)\..\lib\pal\ -+ $(ProjectDir) -+ $(Configuration)\ -+ $(LibraryPath) -+ -+ -+ true -+ $(ProjectDir) -+ $(VC_IncludePath);$(WindowsSDK_IncludePath);$(SolutionDir)\..\lib\include\public;$(SolutionDir)\..\lib\pal\ -+ $(LibraryPath) -+ -+ -+ false -+ $(VC_IncludePath);$(WindowsSDK_IncludePath);$(SolutionDir)\..\lib\include\public -+ -+ -+ false -+ $(VC_IncludePath);$(WindowsSDK_IncludePath);$(SolutionDir)\..\lib\include\public -+ -+ -+ -+ NotUsing -+ Level3 -+ Disabled -+ true -+ WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions) -+ true -+ pch.h -+ -+ -+ Console -+ true -+ -+ -+ $(MSBuildProjectDirectory)\deploy-dll.cmd $(Configuration) $(Platform) $(OutDir) -+ -+ -+ Deploy DLLs -+ -+ -+ -+ -+ NotUsing -+ Level3 -+ Disabled -+ true -+ _DEBUG;_CONSOLE;%(PreprocessorDefinitions) -+ true -+ pch.h -+ -+ -+ Console -+ true -+ -+ -+ $(MSBuildProjectDirectory)\deploy-dll.cmd $(Configuration) $(Platform) $(OutDir) -+ -+ -+ Deploy DLLs -+ -+ -+ -+ -+ NotUsing -+ Level3 -+ MaxSpeed -+ true -+ true -+ true -+ WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions) -+ true -+ pch.h -+ -+ -+ Console -+ true -+ true -+ true -+ -+ -+ $(MSBuildProjectDirectory)\deploy-dll.cmd $(Configuration) $(Platform) $(OutDir) -+ -+ -+ Deploy DLLs -+ -+ -+ -+ -+ NotUsing -+ Level3 -+ MaxSpeed -+ true -+ true -+ true -+ NDEBUG;_CONSOLE;%(PreprocessorDefinitions) -+ true -+ pch.h -+ -+ -+ Console -+ true -+ true -+ true -+ -+ -+ $(MSBuildProjectDirectory)\deploy-dll.cmd $(Configuration) $(Platform) $(OutDir) -+ -+ -+ Deploy DLLs -+ -+ -+ -+ -+ -+ -+ -+ {216a8e97-21f7-4bef-9e52-7f772c177c32} -+ -+ -+ -+ -+ -+ -+ -+ -+ - -\ No newline at end of file -diff --git a/examples/cpp/SampleCppMini/SampleCppMini.vcxproj b/examples/cpp/SampleCppMini/SampleCppMini.vcxproj -index a2891ace..e232a2e4 100644 ---- a/examples/cpp/SampleCppMini/SampleCppMini.vcxproj -+++ b/examples/cpp/SampleCppMini/SampleCppMini.vcxproj -@@ -79,35 +79,35 @@ - {86AC752C-5687-4377-841E-943D9BEEF361} - Win32Proj - SampleCppMini -- 10.0.17763.0 -+ 10.0 - true - - - - Application - true -- v141 -+ v142 - Unicode - Static - - - Application - true -- v141 -+ v142 - Unicode - Static - - - Application - true -- v141 -+ v142 - Unicode - Static - - - Application - false -- v141 -+ v142 - true - Unicode - Static -@@ -115,7 +115,7 @@ - - Application - false -- v141 -+ v142 - true - Unicode - Static -@@ -123,7 +123,7 @@ - - Application - false -- v141 -+ v142 - true - Unicode - Static -@@ -131,49 +131,49 @@ - - Application - true -- v141 -+ v142 - Unicode - Static - - - Application - true -- v141 -+ v142 - Unicode - Static - - - Application - true -- v141 -+ v142 - Unicode - Static - - - Application - true -- v141 -+ v142 - Unicode - Static - - - Application - true -- v141 -+ v142 - Unicode - Static - - - Application - true -- v141 -+ v142 - Unicode - Static - - - Application - false -- v141 -+ v142 - true - Unicode - Static -@@ -181,7 +181,7 @@ - - Application - false -- v141 -+ v142 - true - Unicode - Static -@@ -189,7 +189,7 @@ - - Application - false -- v141 -+ v142 - true - Unicode - Static -@@ -197,7 +197,7 @@ - - Application - false -- v141 -+ v142 - true - Unicode - Static -@@ -205,7 +205,7 @@ - - Application - false -- v141 -+ v142 - true - Unicode - Static -@@ -213,7 +213,7 @@ - - Application - false -- v141 -+ v142 - true - Unicode - Static -diff --git a/examples/cpp/SampleCppUWP/SampleCppUWP.vcxproj b/examples/cpp/SampleCppUWP/SampleCppUWP.vcxproj -index efe13147..23635fa5 100644 ---- a/examples/cpp/SampleCppUWP/SampleCppUWP.vcxproj -+++ b/examples/cpp/SampleCppUWP/SampleCppUWP.vcxproj -@@ -8,7 +8,7 @@ - true - Windows Store - 8.2 -- 10.0.17763.0 -+ 10.0 - 10.0.17763.0 - SampleCppUWP - -@@ -50,46 +50,46 @@ - - Application - true -- v141 -+ v142 - - - Application - true -- v141 -+ v142 - - - Application - true -- v141 -+ v142 - - - Application - true -- v141 -+ v142 - - - Application - false - true -- v141 -+ v142 - - - Application - false - true -- v141 -+ v142 - - - Application - false - true -- v141 -+ v142 - - - Application - false - true -- v141 -+ v142 - - - -diff --git a/googletest/googlemock/msvc/2015/gmock.vcxproj b/googletest/googlemock/msvc/2015/gmock.vcxproj -index 7b06da3a..612de047 100644 ---- a/googletest/googlemock/msvc/2015/gmock.vcxproj -+++ b/googletest/googlemock/msvc/2015/gmock.vcxproj -@@ -1,215 +1,215 @@ -- -- -- -- -- Debug -- ARM64 -- -- -- Debug -- Win32 -- -- -- Debug -- x64 -- -- -- Release -- ARM64 -- -- -- Release -- Win32 -- -- -- Release -- x64 -- -- -- -- {34681F0D-CE45-415D-B5F2-5C662DFE3BD5} -- gmock -- Win32Proj -- 10.0.17134.0 -- true -- -- -- -- StaticLibrary -- Unicode -- false -- v141 -- -- -- StaticLibrary -- Unicode -- false -- v141 -- -- -- StaticLibrary -- Unicode -- false -- v141 -- -- -- StaticLibrary -- Unicode -- v141 -- -- -- StaticLibrary -- Unicode -- v141 -- -- -- StaticLibrary -- Unicode -- v141 -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- <_ProjectFileVersion>10.0.30319.1 -- -- -- $(SolutionDir)$(Platform)\$(Configuration)\ -- $(Platform)\$(Configuration)\ -- -- -- $(SolutionDir)$(Platform)\$(Configuration)\ -- $(Platform)\$(Configuration)\ -- -- -- -- Disabled -- ..\..\include;..\..;%(AdditionalIncludeDirectories) -- _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions) -- true -- EnableFastChecks -- MultiThreadedDebugDLL -- -- -- Level3 -- ProgramDatabase -- -- -- false -- -- -- -- -- Disabled -- ..\..\include;..\..;%(AdditionalIncludeDirectories) -- _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions) -- EnableFastChecks -- MultiThreadedDebugDLL -- -- -- Level3 -- ProgramDatabase -- -- -- false -- -- -- -- -- Disabled -- ..\..\include;..\..;%(AdditionalIncludeDirectories) -- _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions) -- EnableFastChecks -- MultiThreadedDebugDLL -- -- -- Level3 -- ProgramDatabase -- -- -- false -- -- -- -- -- ..\..\include;..\..;%(AdditionalIncludeDirectories) -- _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions) -- MultiThreadedDLL -- -- -- Level3 -- ProgramDatabase -- -- -- false -- -- -- -- -- ..\..\include;..\..;%(AdditionalIncludeDirectories) -- _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions) -- MultiThreadedDLL -- -- -- Level3 -- ProgramDatabase -- -- -- false -- -- -- -- -- ..\..\include;..\..;%(AdditionalIncludeDirectories) -- _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions) -- MultiThreadedDLL -- -- -- Level3 -- ProgramDatabase -- -- -- false -- -- -- -- -- -- $(GTestDir);%(AdditionalIncludeDirectories) -- $(GTestDir);%(AdditionalIncludeDirectories) -- $(GTestDir);%(AdditionalIncludeDirectories) -- $(GTestDir);%(AdditionalIncludeDirectories) -- $(GTestDir);%(AdditionalIncludeDirectories) -- $(GTestDir);%(AdditionalIncludeDirectories) -- -- -- -- -- -- -+ -+ -+ -+ -+ Debug -+ ARM64 -+ -+ -+ Debug -+ Win32 -+ -+ -+ Debug -+ x64 -+ -+ -+ Release -+ ARM64 -+ -+ -+ Release -+ Win32 -+ -+ -+ Release -+ x64 -+ -+ -+ -+ {34681F0D-CE45-415D-B5F2-5C662DFE3BD5} -+ gmock -+ Win32Proj -+ 10.0 -+ true -+ -+ -+ -+ StaticLibrary -+ Unicode -+ false -+ v142 -+ -+ -+ StaticLibrary -+ Unicode -+ false -+ v142 -+ -+ -+ StaticLibrary -+ Unicode -+ false -+ v142 -+ -+ -+ StaticLibrary -+ Unicode -+ v142 -+ -+ -+ StaticLibrary -+ Unicode -+ v142 -+ -+ -+ StaticLibrary -+ Unicode -+ v142 -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ <_ProjectFileVersion>10.0.30319.1 -+ -+ -+ $(SolutionDir)$(Platform)\$(Configuration)\ -+ $(Platform)\$(Configuration)\ -+ -+ -+ $(SolutionDir)$(Platform)\$(Configuration)\ -+ $(Platform)\$(Configuration)\ -+ -+ -+ -+ Disabled -+ ..\..\include;..\..;%(AdditionalIncludeDirectories) -+ _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions) -+ true -+ EnableFastChecks -+ MultiThreadedDebugDLL -+ -+ -+ Level3 -+ ProgramDatabase -+ -+ -+ false -+ -+ -+ -+ -+ Disabled -+ ..\..\include;..\..;%(AdditionalIncludeDirectories) -+ _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions) -+ EnableFastChecks -+ MultiThreadedDebugDLL -+ -+ -+ Level3 -+ ProgramDatabase -+ -+ -+ false -+ -+ -+ -+ -+ Disabled -+ ..\..\include;..\..;%(AdditionalIncludeDirectories) -+ _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions) -+ EnableFastChecks -+ MultiThreadedDebugDLL -+ -+ -+ Level3 -+ ProgramDatabase -+ -+ -+ false -+ -+ -+ -+ -+ ..\..\include;..\..;%(AdditionalIncludeDirectories) -+ _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions) -+ MultiThreadedDLL -+ -+ -+ Level3 -+ ProgramDatabase -+ -+ -+ false -+ -+ -+ -+ -+ ..\..\include;..\..;%(AdditionalIncludeDirectories) -+ _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions) -+ MultiThreadedDLL -+ -+ -+ Level3 -+ ProgramDatabase -+ -+ -+ false -+ -+ -+ -+ -+ ..\..\include;..\..;%(AdditionalIncludeDirectories) -+ _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions) -+ MultiThreadedDLL -+ -+ -+ Level3 -+ ProgramDatabase -+ -+ -+ false -+ -+ -+ -+ -+ -+ $(GTestDir);%(AdditionalIncludeDirectories) -+ $(GTestDir);%(AdditionalIncludeDirectories) -+ $(GTestDir);%(AdditionalIncludeDirectories) -+ $(GTestDir);%(AdditionalIncludeDirectories) -+ $(GTestDir);%(AdditionalIncludeDirectories) -+ $(GTestDir);%(AdditionalIncludeDirectories) -+ -+ -+ -+ -+ -+ - -\ No newline at end of file -diff --git a/googletest/googletest/msvc/gtest.vcxproj b/googletest/googletest/msvc/gtest.vcxproj -index 6495fbdc..9548a5d5 100644 ---- a/googletest/googletest/msvc/gtest.vcxproj -+++ b/googletest/googletest/msvc/gtest.vcxproj -@@ -1,218 +1,218 @@ -- -- -- -- -- Debug -- ARM64 -- -- -- Debug -- Win32 -- -- -- Debug -- x64 -- -- -- Release -- ARM64 -- -- -- Release -- Win32 -- -- -- Release -- x64 -- -- -- -- {C8F6C172-56F2-4E76-B5FA-C3B423B31BE7} -- Win32Proj -- 10.0.17134.0 -- true -- -- -- -- StaticLibrary -- v141 -- Unicode -- -- -- StaticLibrary -- v141 -- Unicode -- -- -- StaticLibrary -- v141 -- Unicode -- -- -- StaticLibrary -- v141 -- Unicode -- -- -- StaticLibrary -- v141 -- Unicode -- -- -- StaticLibrary -- v141 -- Unicode -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- <_ProjectFileVersion>14.0.25431.1 -- -- -- MinimumRecommendedRules.ruleset -- -- -- -- -- MinimumRecommendedRules.ruleset -- -- -- -- -- MinimumRecommendedRules.ruleset -- -- -- -- -- MinimumRecommendedRules.ruleset -- -- -- -- -- MinimumRecommendedRules.ruleset -- -- -- -- -- MinimumRecommendedRules.ruleset -- -- -- -- -- -- Disabled -- _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions) -- true -- EnableFastChecks -- MultiThreadedDebugDLL -- -- Level3 -- EditAndContinue -- -- -- $(OutDir)gtestd.lib -- -- -- -- -- Disabled -- _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions) -- EnableFastChecks -- MultiThreadedDebugDLL -- -- -- Level3 -- ProgramDatabase -- -- -- $(OutDir)gtestd.lib -- -- -- -- -- Disabled -- _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions) -- EnableFastChecks -- MultiThreadedDebugDLL -- -- -- Level3 -- ProgramDatabase -- -- -- $(OutDir)gtestd.lib -- -- -- -- -- _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions) -- MultiThreadedDLL -- -- Level3 -- ProgramDatabase -- -- -- $(OutDir)gtest.lib -- -- -- -- -- _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions) -- MultiThreadedDLL -- -- -- Level3 -- ProgramDatabase -- -- -- $(OutDir)gtest.lib -- -- -- -- -- _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions) -- MultiThreadedDLL -- -- -- Level3 -- ProgramDatabase -- -- -- $(OutDir)gtest.lib -- -- -- -- -- ..;..\include;%(AdditionalIncludeDirectories) -- ..;..\include;%(AdditionalIncludeDirectories) -- ..;..\include;%(AdditionalIncludeDirectories) -- ..;..\include;%(AdditionalIncludeDirectories) -- ..;..\include;%(AdditionalIncludeDirectories) -- ..;..\include;%(AdditionalIncludeDirectories) -- -- -- -- -- -- -+ -+ -+ -+ -+ Debug -+ ARM64 -+ -+ -+ Debug -+ Win32 -+ -+ -+ Debug -+ x64 -+ -+ -+ Release -+ ARM64 -+ -+ -+ Release -+ Win32 -+ -+ -+ Release -+ x64 -+ -+ -+ -+ {C8F6C172-56F2-4E76-B5FA-C3B423B31BE7} -+ Win32Proj -+ 10.0 -+ true -+ -+ -+ -+ StaticLibrary -+ v142 -+ Unicode -+ -+ -+ StaticLibrary -+ v142 -+ Unicode -+ -+ -+ StaticLibrary -+ v142 -+ Unicode -+ -+ -+ StaticLibrary -+ v142 -+ Unicode -+ -+ -+ StaticLibrary -+ v142 -+ Unicode -+ -+ -+ StaticLibrary -+ v142 -+ Unicode -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ <_ProjectFileVersion>14.0.25431.1 -+ -+ -+ MinimumRecommendedRules.ruleset -+ -+ -+ -+ -+ MinimumRecommendedRules.ruleset -+ -+ -+ -+ -+ MinimumRecommendedRules.ruleset -+ -+ -+ -+ -+ MinimumRecommendedRules.ruleset -+ -+ -+ -+ -+ MinimumRecommendedRules.ruleset -+ -+ -+ -+ -+ MinimumRecommendedRules.ruleset -+ -+ -+ -+ -+ -+ Disabled -+ _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions) -+ true -+ EnableFastChecks -+ MultiThreadedDebugDLL -+ -+ Level3 -+ EditAndContinue -+ -+ -+ $(OutDir)gtestd.lib -+ -+ -+ -+ -+ Disabled -+ _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions) -+ EnableFastChecks -+ MultiThreadedDebugDLL -+ -+ -+ Level3 -+ ProgramDatabase -+ -+ -+ $(OutDir)gtestd.lib -+ -+ -+ -+ -+ Disabled -+ _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions) -+ EnableFastChecks -+ MultiThreadedDebugDLL -+ -+ -+ Level3 -+ ProgramDatabase -+ -+ -+ $(OutDir)gtestd.lib -+ -+ -+ -+ -+ _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions) -+ MultiThreadedDLL -+ -+ Level3 -+ ProgramDatabase -+ -+ -+ $(OutDir)gtest.lib -+ -+ -+ -+ -+ _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions) -+ MultiThreadedDLL -+ -+ -+ Level3 -+ ProgramDatabase -+ -+ -+ $(OutDir)gtest.lib -+ -+ -+ -+ -+ _SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions) -+ MultiThreadedDLL -+ -+ -+ Level3 -+ ProgramDatabase -+ -+ -+ $(OutDir)gtest.lib -+ -+ -+ -+ -+ ..;..\include;%(AdditionalIncludeDirectories) -+ ..;..\include;%(AdditionalIncludeDirectories) -+ ..;..\include;%(AdditionalIncludeDirectories) -+ ..;..\include;%(AdditionalIncludeDirectories) -+ ..;..\include;%(AdditionalIncludeDirectories) -+ ..;..\include;%(AdditionalIncludeDirectories) -+ -+ -+ -+ -+ -+ - -\ No newline at end of file -diff --git a/sqliteUWP/sqlite-uwp.vcxproj b/sqliteUWP/sqlite-uwp.vcxproj -index 69c042ea..dea6ffff 100644 ---- a/sqliteUWP/sqlite-uwp.vcxproj -+++ b/sqliteUWP/sqlite-uwp.vcxproj -@@ -1,316 +1,316 @@ -- -- -- -- -- Debug -- ARM -- -- -- Debug -- ARM64 -- -- -- Debug -- Win32 -- -- -- Debug -- x64 -- -- -- Release -- ARM -- -- -- Release -- ARM64 -- -- -- Release -- Win32 -- -- -- Release -- x64 -- -- -- -- {6883a688-89f5-424a-9bfa-50d42f691b29} -- en-US -- 14.0 -- 10.0.17134.0 -- 10.0.10240.0 -- -- -- -- StaticLibrary -- true -- v141 -- true -- -- -- StaticLibrary -- true -- v141 -- true -- -- -- StaticLibrary -- true -- v141 -- true -- -- -- StaticLibrary -- true -- v141 -- true -- -- -- StaticLibrary -- false -- true -- v141 -- -- -- StaticLibrary -- false -- true -- v141 -- -- -- StaticLibrary -- false -- true -- v141 -- -- -- StaticLibrary -- false -- true -- v141 -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- false -- $(SolutionDir)$(Platform)\$(Configuration)\$(MSBuildProjectName)\ -- $(Platform)\$(Configuration)\ -- -- -- false -- $(SolutionDir)$(Platform)\$(Configuration)\$(MSBuildProjectName)\ -- $(Platform)\$(Configuration)\ -- -- -- false -- -- -- false -- -- -- false -- -- -- false -- -- -- false -- -- -- false -- -- -- -- NotUsing -- false -- true -- SQLITE_DEFAULT_AUTOVACUUM=1;SQLITE_OS_WINRT;_LIB;_UNICODE;UNICODE;%(PreprocessorDefinitions) -- -- $(OutDir)$(TargetName).pdb -- Default -- false -- -- -- Console -- false -- false -- -- -- false -- true -- -- -- -- -- NotUsing -- false -- true -- SQLITE_DEFAULT_AUTOVACUUM=1;SQLITE_OS_WINRT;_LIB;_UNICODE;UNICODE;%(PreprocessorDefinitions) -- -- MinSpace -- $(OutDir)$(TargetName).pdb -- false -- -- -- Console -- false -- false -- -- -- true -- false -- -- -- -- -- NotUsing -- false -- true -- SQLITE_DEFAULT_AUTOVACUUM=1;SQLITE_OS_WINRT;_LIB;_ARM_WINAPI_PARTITION_DESKTOP_SDK_AVAILABLE=1;%(ClCompile.PreprocessorDefinitions) -- -- $(OutDir)$(TargetName).pdb -- Default -- false -- -- -- Console -- false -- false -- -- -- false -- true -- -- -- -- -- NotUsing -- false -- true -- SQLITE_DEFAULT_AUTOVACUUM=1;SQLITE_OS_WINRT;_LIB;_ARM_WINAPI_PARTITION_DESKTOP_SDK_AVAILABLE=1;%(ClCompile.PreprocessorDefinitions) -- -- MinSpace -- $(OutDir)$(TargetName).pdb -- false -- -- -- Console -- false -- false -- -- -- true -- false -- -- -- -- -- NotUsing -- false -- true -- SQLITE_DEFAULT_AUTOVACUUM=1;SQLITE_OS_WINRT;_LIB;_UNICODE;UNICODE;%(PreprocessorDefinitions) -- -- $(OutDir)$(TargetName).pdb -- Default -- false -- -- -- Console -- false -- false -- -- -- false -- true -- -- -- -- -- NotUsing -- false -- true -- SQLITE_DEFAULT_AUTOVACUUM=1;SQLITE_OS_WINRT;_LIB;_UNICODE;UNICODE;%(PreprocessorDefinitions) -- -- MinSpace -- $(OutDir)$(TargetName).pdb -- false -- -- -- Console -- false -- false -- -- -- true -- false -- -- -- -- -- false -- NotUsing -- _UNICODE;UNICODE;SQLITE_OS_WINRT;%(PreprocessorDefinitions) -- false -- -- -- false -- true -- -- -- -- -- false -- NotUsing -- _UNICODE;UNICODE;SQLITE_OS_WINRT;%(PreprocessorDefinitions) -- false -- -- -- true -- false -- -- -- -- -- -- -- -- -- false -- false -- -- -- -- -- -- -+ -+ -+ -+ -+ Debug -+ ARM -+ -+ -+ Debug -+ ARM64 -+ -+ -+ Debug -+ Win32 -+ -+ -+ Debug -+ x64 -+ -+ -+ Release -+ ARM -+ -+ -+ Release -+ ARM64 -+ -+ -+ Release -+ Win32 -+ -+ -+ Release -+ x64 -+ -+ -+ -+ {6883a688-89f5-424a-9bfa-50d42f691b29} -+ en-US -+ 14.0 -+ 10.0 -+ 10.0.10240.0 -+ -+ -+ -+ StaticLibrary -+ true -+ v142 -+ true -+ -+ -+ StaticLibrary -+ true -+ v142 -+ true -+ -+ -+ StaticLibrary -+ true -+ v142 -+ true -+ -+ -+ StaticLibrary -+ true -+ v142 -+ true -+ -+ -+ StaticLibrary -+ false -+ true -+ v142 -+ -+ -+ StaticLibrary -+ false -+ true -+ v142 -+ -+ -+ StaticLibrary -+ false -+ true -+ v142 -+ -+ -+ StaticLibrary -+ false -+ true -+ v142 -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ false -+ $(SolutionDir)$(Platform)\$(Configuration)\$(MSBuildProjectName)\ -+ $(Platform)\$(Configuration)\ -+ -+ -+ false -+ $(SolutionDir)$(Platform)\$(Configuration)\$(MSBuildProjectName)\ -+ $(Platform)\$(Configuration)\ -+ -+ -+ false -+ -+ -+ false -+ -+ -+ false -+ -+ -+ false -+ -+ -+ false -+ -+ -+ false -+ -+ -+ -+ NotUsing -+ false -+ true -+ SQLITE_DEFAULT_AUTOVACUUM=1;SQLITE_OS_WINRT;_LIB;_UNICODE;UNICODE;%(PreprocessorDefinitions) -+ -+ $(OutDir)$(TargetName).pdb -+ Default -+ false -+ -+ -+ Console -+ false -+ false -+ -+ -+ false -+ true -+ -+ -+ -+ -+ NotUsing -+ false -+ true -+ SQLITE_DEFAULT_AUTOVACUUM=1;SQLITE_OS_WINRT;_LIB;_UNICODE;UNICODE;%(PreprocessorDefinitions) -+ -+ MinSpace -+ $(OutDir)$(TargetName).pdb -+ false -+ -+ -+ Console -+ false -+ false -+ -+ -+ true -+ false -+ -+ -+ -+ -+ NotUsing -+ false -+ true -+ SQLITE_DEFAULT_AUTOVACUUM=1;SQLITE_OS_WINRT;_LIB;_ARM_WINAPI_PARTITION_DESKTOP_SDK_AVAILABLE=1;%(ClCompile.PreprocessorDefinitions) -+ -+ $(OutDir)$(TargetName).pdb -+ Default -+ false -+ -+ -+ Console -+ false -+ false -+ -+ -+ false -+ true -+ -+ -+ -+ -+ NotUsing -+ false -+ true -+ SQLITE_DEFAULT_AUTOVACUUM=1;SQLITE_OS_WINRT;_LIB;_ARM_WINAPI_PARTITION_DESKTOP_SDK_AVAILABLE=1;%(ClCompile.PreprocessorDefinitions) -+ -+ MinSpace -+ $(OutDir)$(TargetName).pdb -+ false -+ -+ -+ Console -+ false -+ false -+ -+ -+ true -+ false -+ -+ -+ -+ -+ NotUsing -+ false -+ true -+ SQLITE_DEFAULT_AUTOVACUUM=1;SQLITE_OS_WINRT;_LIB;_UNICODE;UNICODE;%(PreprocessorDefinitions) -+ -+ $(OutDir)$(TargetName).pdb -+ Default -+ false -+ -+ -+ Console -+ false -+ false -+ -+ -+ false -+ true -+ -+ -+ -+ -+ NotUsing -+ false -+ true -+ SQLITE_DEFAULT_AUTOVACUUM=1;SQLITE_OS_WINRT;_LIB;_UNICODE;UNICODE;%(PreprocessorDefinitions) -+ -+ MinSpace -+ $(OutDir)$(TargetName).pdb -+ false -+ -+ -+ Console -+ false -+ false -+ -+ -+ true -+ false -+ -+ -+ -+ -+ false -+ NotUsing -+ _UNICODE;UNICODE;SQLITE_OS_WINRT;%(PreprocessorDefinitions) -+ false -+ -+ -+ false -+ true -+ -+ -+ -+ -+ false -+ NotUsing -+ _UNICODE;UNICODE;SQLITE_OS_WINRT;%(PreprocessorDefinitions) -+ false -+ -+ -+ true -+ false -+ -+ -+ -+ -+ -+ -+ -+ -+ false -+ false -+ -+ -+ -+ -+ -+ - -\ No newline at end of file -diff --git a/tests/functests/FuncTests.vcxproj b/tests/functests/FuncTests.vcxproj -index 08e24b00..868a148a 100644 ---- a/tests/functests/FuncTests.vcxproj -+++ b/tests/functests/FuncTests.vcxproj -@@ -45,7 +45,7 @@ - - - {FE79FB3A-B3EF-38DF-B7A4-11277DB72B39} -- 10.0.17134.0 -+ 10.0 - Win32Proj - Win32 - FuncTests -@@ -56,37 +56,37 @@ - Application - false - Unicode -- v141 -+ v142 - - - Application - false - Unicode -- v141 -+ v142 - - - Application - false - Unicode -- v141 -+ v142 - - - Application - false - Unicode -- v141 -+ v142 - - - Application - false - Unicode -- v141 -+ v142 - - - Application - false - Unicode -- v141 -+ v142 - - - -@@ -449,15 +449,15 @@ - - - -- -+ - - - - - -- -+ - - - - -- -+ -\ No newline at end of file -diff --git a/tests/functests/FuncTests.vcxproj.filters b/tests/functests/FuncTests.vcxproj.filters -index 71dbe545..eedf3eab 100644 ---- a/tests/functests/FuncTests.vcxproj.filters -+++ b/tests/functests/FuncTests.vcxproj.filters -@@ -14,13 +14,8 @@ - - - -- -- -- -- - - -- - - - -diff --git a/tests/unittests/UnitTests.vcxproj b/tests/unittests/UnitTests.vcxproj -index 31506e77..0bff4a9f 100644 ---- a/tests/unittests/UnitTests.vcxproj -+++ b/tests/unittests/UnitTests.vcxproj -@@ -45,7 +45,7 @@ - - - {434C594F-CDE0-3690-AC0A-9ED854B74092} -- 10.0.17134.0 -+ 10.0 - Win32Proj - Win32 - UnitTests -@@ -56,37 +56,37 @@ - Application - false - Unicode -- v141 -+ v142 - - - Application - false - Unicode -- v141 -+ v142 - - - Application - false - Unicode -- v141 -+ v142 - - - Application - false - Unicode -- v141 -+ v142 - - - Application - false - Unicode -- v141 -+ v142 - - - Application - false - Unicode -- v141 -+ v142 - - - -diff --git a/tests/unittests/UnitTests.vcxproj.filters b/tests/unittests/UnitTests.vcxproj.filters -index a6c9b1e0..be1ba644 100644 ---- a/tests/unittests/UnitTests.vcxproj.filters -+++ b/tests/unittests/UnitTests.vcxproj.filters -@@ -7,7 +7,6 @@ - - - -- - - - -@@ -53,11 +52,6 @@ - - - -- -- -- -- -- - - - -diff --git a/zlib/contrib/vstudio/vc14/zlibvc.vcxproj b/zlib/contrib/vstudio/vc14/zlibvc.vcxproj -index 5ff55579..77518e48 100644 ---- a/zlib/contrib/vstudio/vc14/zlibvc.vcxproj -+++ b/zlib/contrib/vstudio/vc14/zlibvc.vcxproj -@@ -1,1218 +1,1215 @@ -- -- -- -- -- Debug.vc14x.MT-sqlite -- ARM -- -- -- Debug.vc14x.MT-sqlite -- ARM64 -- -- -- Debug.vc14x.MT-sqlite -- Win32 -- -- -- Debug.vc14x.MT-sqlite -- x64 -- -- -- Debug -- ARM -- -- -- Debug -- ARM64 -- -- -- Debug -- Win32 -- -- -- Debug -- x64 -- -- -- Release.vc14x.MT-sqlite -- ARM -- -- -- Release.vc14x.MT-sqlite -- ARM64 -- -- -- Release.vc14x.MT-sqlite -- Win32 -- -- -- Release.vc14x.MT-sqlite -- x64 -- -- -- Release -- ARM -- -- -- Release -- ARM64 -- -- -- Release -- Win32 -- -- -- Release -- x64 -- -- -- -- {8FD826F8-3739-44E6-8CC8-997122E53B8D} -- zlib -- 10.0.17134.0 -- true -- -- -- -- StaticLibrary -- false -- false -- Unicode -- v141 -- -- -- StaticLibrary -- false -- false -- Unicode -- v141 -- -- -- true -- StaticLibrary -- false -- false -- Unicode -- v141 -- -- -- true -- StaticLibrary -- false -- false -- Unicode -- v141 -- -- -- true -- StaticLibrary -- false -- false -- Unicode -- v141 -- -- -- true -- StaticLibrary -- false -- false -- Unicode -- v141 -- -- -- StaticLibrary -- false -- Unicode -- v141 -- -- -- StaticLibrary -- false -- Unicode -- v141 -- -- -- true -- StaticLibrary -- false -- Unicode -- v141 -- -- -- true -- StaticLibrary -- false -- Unicode -- v141 -- -- -- true -- StaticLibrary -- false -- Unicode -- v141 -- -- -- true -- StaticLibrary -- false -- Unicode -- v141 -- -- -- StaticLibrary -- false -- false -- Unicode -- v141 -- -- -- StaticLibrary -- false -- false -- Unicode -- v141 -- -- -- StaticLibrary -- false -- Unicode -- v141 -- -- -- StaticLibrary -- false -- Unicode -- v141 -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- $(VC_IncludePath);$(WindowsSDK_IncludePath) -- -- -- $(VC_IncludePath);$(WindowsSDK_IncludePath) -- -- -- $(VC_IncludePath);$(WindowsSDK_IncludePath);%(AdditionalIncludeDirectories) -- -- -- $(VC_IncludePath);$(WindowsSDK_IncludePath);%(AdditionalIncludeDirectories) -- -- -- $(VC_IncludePath);$(WindowsSDK_IncludePath);%(AdditionalIncludeDirectories) -- -- -- $(VC_IncludePath);$(WindowsSDK_IncludePath);%(AdditionalIncludeDirectories) -- -- -- -- -- -- -- $(VC_IncludePath);$(WindowsSDK_IncludePath) -- -- -- $(VC_IncludePath);$(WindowsSDK_IncludePath) -- -- -- $(VC_IncludePath);$(WindowsSDK_IncludePath) -- -- -- $(VC_IncludePath);$(WindowsSDK_IncludePath) -- -- -- $(VC_IncludePath);$(WindowsSDK_IncludePath) -- -- -- $(VC_IncludePath);$(WindowsSDK_IncludePath) -- -- -- false -- $(VC_IncludePath);$(WindowsSDK_IncludePath) -- -- -- false -- $(VC_IncludePath);$(WindowsSDK_IncludePath) -- -- -- -- -- false -- $(VC_IncludePath);$(WindowsSDK_IncludePath) -- -- -- false -- $(VC_IncludePath);$(WindowsSDK_IncludePath) -- -- -- -- _DEBUG;%(PreprocessorDefinitions) -- true -- true -- Win32 -- $(OutDir)zlibvc.tlb -- -- -- Disabled -- ..\..\..;..\..\masmx86;%(AdditionalIncludeDirectories) -- WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -- -- -- MultiThreadedDebugDLL -- true -- $(IntDir)zlibvc.pch -- $(IntDir) -- $(IntDir) -- $(OutDir)$(TargetName).pdb -- false -- Level3 -- true -- ProgramDatabase -- StreamingSIMDExtensions -- Guard -- -- -- _DEBUG;%(PreprocessorDefinitions) -- 0x040c -- -- -- /MACHINE:I386 %(AdditionalOptions) -- ..\..\masmx86\match686.obj;..\..\masmx86\inffas32.obj;%(AdditionalDependencies) -- $(OutDir)zlib.lib -- true -- .\zlibvc.def -- true -- $(OutDir)zlib.pdb -- true -- $(OutDir)zlib.lib.map -- Windows -- false -- -- -- $(OutDir)zlib.lib -- -- -+ -+ -+ -+ -+ Debug.vc14x.MT-sqlite -+ ARM -+ -+ -+ Debug.vc14x.MT-sqlite -+ ARM64 -+ -+ -+ Debug.vc14x.MT-sqlite -+ Win32 -+ -+ -+ Debug.vc14x.MT-sqlite -+ x64 -+ -+ -+ Debug -+ ARM -+ -+ -+ Debug -+ ARM64 -+ -+ -+ Debug -+ Win32 -+ -+ -+ Debug -+ x64 -+ -+ -+ Release.vc14x.MT-sqlite -+ ARM -+ -+ -+ Release.vc14x.MT-sqlite -+ ARM64 -+ -+ -+ Release.vc14x.MT-sqlite -+ Win32 -+ -+ -+ Release.vc14x.MT-sqlite -+ x64 -+ -+ -+ Release -+ ARM -+ -+ -+ Release -+ ARM64 -+ -+ -+ Release -+ Win32 -+ -+ -+ Release -+ x64 -+ -+ -+ -+ {8FD826F8-3739-44E6-8CC8-997122E53B8D} -+ zlib -+ 10.0 -+ true -+ -+ -+ -+ StaticLibrary -+ false -+ false -+ Unicode -+ v142 -+ -+ -+ StaticLibrary -+ false -+ false -+ Unicode -+ v142 -+ -+ -+ true -+ StaticLibrary -+ false -+ false -+ Unicode -+ v142 -+ -+ -+ true -+ StaticLibrary -+ false -+ false -+ Unicode -+ v142 -+ -+ -+ true -+ StaticLibrary -+ false -+ false -+ Unicode -+ v142 -+ -+ -+ true -+ StaticLibrary -+ false -+ false -+ Unicode -+ v142 -+ -+ -+ StaticLibrary -+ false -+ Unicode -+ v142 -+ -+ -+ StaticLibrary -+ false -+ Unicode -+ v142 -+ -+ -+ true -+ StaticLibrary -+ false -+ Unicode -+ v142 -+ -+ -+ true -+ StaticLibrary -+ false -+ Unicode -+ v142 -+ -+ -+ true -+ StaticLibrary -+ false -+ Unicode -+ v142 -+ -+ -+ true -+ StaticLibrary -+ false -+ Unicode -+ v142 -+ -+ -+ StaticLibrary -+ false -+ false -+ Unicode -+ v142 -+ -+ -+ StaticLibrary -+ false -+ false -+ Unicode -+ v142 -+ -+ -+ StaticLibrary -+ false -+ Unicode -+ v142 -+ -+ -+ StaticLibrary -+ false -+ Unicode -+ v142 -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ $(VC_IncludePath);$(WindowsSDK_IncludePath) -+ -+ -+ $(VC_IncludePath);$(WindowsSDK_IncludePath) -+ -+ -+ $(VC_IncludePath);$(WindowsSDK_IncludePath);%(AdditionalIncludeDirectories) -+ -+ -+ $(VC_IncludePath);$(WindowsSDK_IncludePath);%(AdditionalIncludeDirectories) -+ -+ -+ $(VC_IncludePath);$(WindowsSDK_IncludePath);%(AdditionalIncludeDirectories) -+ -+ -+ $(VC_IncludePath);$(WindowsSDK_IncludePath);%(AdditionalIncludeDirectories) -+ -+ -+ -+ -+ -+ -+ $(VC_IncludePath);$(WindowsSDK_IncludePath) -+ -+ -+ $(VC_IncludePath);$(WindowsSDK_IncludePath) -+ -+ -+ $(VC_IncludePath);$(WindowsSDK_IncludePath) -+ -+ -+ $(VC_IncludePath);$(WindowsSDK_IncludePath) -+ -+ -+ $(VC_IncludePath);$(WindowsSDK_IncludePath) -+ -+ -+ $(VC_IncludePath);$(WindowsSDK_IncludePath) -+ -+ -+ false -+ $(VC_IncludePath);$(WindowsSDK_IncludePath) -+ -+ -+ false -+ $(VC_IncludePath);$(WindowsSDK_IncludePath) -+ -+ -+ -+ -+ false -+ $(VC_IncludePath);$(WindowsSDK_IncludePath) -+ -+ -+ false -+ $(VC_IncludePath);$(WindowsSDK_IncludePath) -+ -+ -+ -+ _DEBUG;%(PreprocessorDefinitions) -+ true -+ true -+ Win32 -+ $(OutDir)zlibvc.tlb -+ -+ -+ Disabled -+ ..\..\..;..\..\masmx86;%(AdditionalIncludeDirectories) -+ WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -+ -+ -+ MultiThreadedDebugDLL -+ true -+ $(IntDir)zlibvc.pch -+ $(IntDir) -+ $(IntDir) -+ $(OutDir)$(TargetName).pdb -+ false -+ Level3 -+ true -+ ProgramDatabase -+ StreamingSIMDExtensions -+ Guard -+ -+ -+ _DEBUG;%(PreprocessorDefinitions) -+ 0x040c -+ -+ -+ /MACHINE:I386 %(AdditionalOptions) -+ ..\..\masmx86\match686.obj;..\..\masmx86\inffas32.obj;%(AdditionalDependencies) -+ $(OutDir)zlib.lib -+ true -+ .\zlibvc.def -+ true -+ $(OutDir)zlib.pdb -+ true -+ $(OutDir)zlib.lib.map -+ Windows -+ false -+ -+ -+ $(OutDir)zlib.lib -+ -+ - cd ..\..\masmx86 --bld_ml32.bat -- -- -- MachineX86 -- false -- -- -- -- -- _DEBUG;%(PreprocessorDefinitions) -- true -- true -- Win32 -- $(OutDir)zlibvc.tlb -- -- -- Disabled -- ..\..\..;..\..\masmx86;%(AdditionalIncludeDirectories) -- WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -- -- -- MultiThreadedDebug -- true -- $(IntDir)zlibvc.pch -- $(IntDir) -- $(IntDir) -- $(OutDir)$(TargetName).pdb -- false -- Level3 -- true -- ProgramDatabase -- StreamingSIMDExtensions -- Guard -- -- -- _DEBUG;%(PreprocessorDefinitions) -- 0x040c -- -- -- /MACHINE:I386 %(AdditionalOptions) -- ..\..\masmx86\match686.obj;..\..\masmx86\inffas32.obj;%(AdditionalDependencies) -- $(OutDir)zlib.lib -- true -- .\zlibvc.def -- true -- $(OutDir)zlib.pdb -- true -- $(OutDir)zlib.lib.map -- Windows -- false -- -- -- $(OutDir)zlib.lib -- -- -+bld_ml32.bat -+ -+ -+ MachineX86 -+ false -+ -+ -+ -+ -+ _DEBUG;%(PreprocessorDefinitions) -+ true -+ true -+ Win32 -+ $(OutDir)zlibvc.tlb -+ -+ -+ Disabled -+ ..\..\..;..\..\masmx86;%(AdditionalIncludeDirectories) -+ WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -+ -+ -+ MultiThreadedDebug -+ true -+ $(IntDir)zlibvc.pch -+ $(IntDir) -+ $(IntDir) -+ $(OutDir)$(TargetName).pdb -+ false -+ Level3 -+ true -+ ProgramDatabase -+ StreamingSIMDExtensions -+ Guard -+ -+ -+ _DEBUG;%(PreprocessorDefinitions) -+ 0x040c -+ -+ -+ /MACHINE:I386 %(AdditionalOptions) -+ ..\..\masmx86\match686.obj;..\..\masmx86\inffas32.obj;%(AdditionalDependencies) -+ $(OutDir)zlib.lib -+ true -+ .\zlibvc.def -+ true -+ $(OutDir)zlib.pdb -+ true -+ $(OutDir)zlib.lib.map -+ Windows -+ false -+ -+ -+ $(OutDir)zlib.lib -+ -+ - cd ..\..\masmx86 --bld_ml32.bat -- -- -- MachineX86 -- false -- -- -- -- -- _DEBUG;%(PreprocessorDefinitions) -- true -- true -- $(OutDir)zlibvc.tlb -- -- -- Disabled -- %(AdditionalIncludeDirectories);$(ProjectDir)\..\..\..\ -- ARCH_ARM;WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -- -- -- MultiThreadedDebugDLL -- true -- $(IntDir)zlibvc.pch -- $(IntDir) -- $(IntDir) -- $(OutDir)$(TargetName).pdb -- false -- Level3 -- true -- ProgramDatabase -- Guard -- -- -- _DEBUG;%(PreprocessorDefinitions) -- 0x040c -- -- -- /MACHINE:ARM %(AdditionalOptions) -- %(AdditionalDependencies) -- $(OutDir)zlib.lib -- true -- .\zlibvc.def -- true -- $(OutDir)zlib.pdb -- true -- $(OutDir)zlib.lib.map -- Windows -- false -- -- -- $(OutDir)zlib.lib -- -- -- -- -- MachineARM -- false -- -- -- -- -- _DEBUG;%(PreprocessorDefinitions) -- true -- true -- $(OutDir)zlibvc.tlb -- -- -- Disabled -- %(AdditionalIncludeDirectories);$(ProjectDir)\..\..\..\ -- ARCH_ARM;WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -- -- -- MultiThreadedDebugDLL -- true -- $(IntDir)zlibvc.pch -- $(IntDir) -- $(IntDir) -- $(OutDir)$(TargetName).pdb -- false -- Level3 -- true -- ProgramDatabase -- Guard -- -- -- _DEBUG;%(PreprocessorDefinitions) -- 0x040c -- -- -- /MACHINE:ARM64 %(AdditionalOptions) -- %(AdditionalDependencies) -- $(OutDir)zlib.lib -- true -- .\zlibvc.def -- true -- $(OutDir)zlib.pdb -- true -- $(OutDir)zlib.lib.map -- Windows -- false -- -- -- $(OutDir)zlib.lib -- -- -- -- MachineARM64 -- false -- -- -- -- -- _DEBUG;%(PreprocessorDefinitions) -- true -- true -- $(OutDir)zlibvc.tlb -- -- -- Disabled -- %(AdditionalIncludeDirectories);$(ProjectDir)\..\..\..\ -- ARCH_ARM;WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -- -- -- MultiThreadedDebug -- true -- $(IntDir)zlibvc.pch -- $(IntDir) -- $(IntDir) -- $(OutDir)$(TargetName).pdb -- false -- Level3 -- true -- ProgramDatabase -- Guard -- -- -- _DEBUG;%(PreprocessorDefinitions) -- 0x040c -- -- -- /MACHINE:ARM %(AdditionalOptions) -- %(AdditionalDependencies) -- $(OutDir)zlib.lib -- true -- .\zlibvc.def -- true -- $(OutDir)zlib.pdb -- true -- $(OutDir)zlib.lib.map -- Windows -- false -- -- -- $(OutDir)zlib.lib -- -- -- -- -- MachineARM -- false -- -- -- -- -- _DEBUG;%(PreprocessorDefinitions) -- true -- true -- $(OutDir)zlibvc.tlb -- -- -- Disabled -- %(AdditionalIncludeDirectories);$(ProjectDir)\..\..\..\ -- ARCH_ARM;WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -- -- -- MultiThreadedDebug -- true -- $(IntDir)zlibvc.pch -- $(IntDir) -- $(IntDir) -- $(OutDir)$(TargetName).pdb -- false -- Level3 -- true -- ProgramDatabase -- Guard -- -- -- _DEBUG;%(PreprocessorDefinitions) -- 0x040c -- -- -- /MACHINE:ARM64 %(AdditionalOptions) -- %(AdditionalDependencies) -- $(OutDir)zlib.lib -- true -- .\zlibvc.def -- true -- $(OutDir)zlib.pdb -- true -- $(OutDir)zlib.lib.map -- Windows -- false -- -- -- $(OutDir)zlib.lib -- -- -- -- MachineARM64 -- false -- -- -- -- -- NDEBUG;%(PreprocessorDefinitions) -- true -- true -- Win32 -- $(OutDir)zlibvc.tlb -- -- -- OnlyExplicitInline -- ..\..\..;..\..\masmx86;%(AdditionalIncludeDirectories) -- WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -- true -- -- -- MultiThreadedDLL -- true -- true -- $(IntDir)zlibvc.pch -- All -- $(IntDir) -- $(IntDir) -- $(OutDir)$(TargetName).pdb -- false -- Level3 -- true -- true -- Speed -- true -- StreamingSIMDExtensions -- false -- Guard -- -- -- NDEBUG;%(PreprocessorDefinitions) -- 0x040c -- -- -- /MACHINE:I386 %(AdditionalOptions) -- ..\..\masmx86\match686.obj;..\..\masmx86\inffas32.obj;%(AdditionalDependencies) -- $(OutDir)zlib.lib -- true -- false -- .\zlibvc.def -- $(OutDir)zlib.pdb -- true -- $(OutDir)zlib.lib.map -- Windows -- false -- -- -- $(OutDir)zlib.lib -- -- -+bld_ml32.bat -+ -+ -+ MachineX86 -+ false -+ -+ -+ -+ -+ _DEBUG;%(PreprocessorDefinitions) -+ true -+ true -+ $(OutDir)zlibvc.tlb -+ -+ -+ Disabled -+ %(AdditionalIncludeDirectories);$(ProjectDir)\..\..\..\ -+ ARCH_ARM;WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -+ -+ -+ MultiThreadedDebugDLL -+ true -+ $(IntDir)zlibvc.pch -+ $(IntDir) -+ $(IntDir) -+ $(OutDir)$(TargetName).pdb -+ false -+ Level3 -+ true -+ ProgramDatabase -+ Guard -+ -+ -+ _DEBUG;%(PreprocessorDefinitions) -+ 0x040c -+ -+ -+ /MACHINE:ARM %(AdditionalOptions) -+ %(AdditionalDependencies) -+ $(OutDir)zlib.lib -+ true -+ .\zlibvc.def -+ true -+ $(OutDir)zlib.pdb -+ true -+ $(OutDir)zlib.lib.map -+ Windows -+ false -+ -+ -+ $(OutDir)zlib.lib -+ -+ -+ -+ -+ MachineARM -+ false -+ -+ -+ -+ -+ _DEBUG;%(PreprocessorDefinitions) -+ true -+ true -+ $(OutDir)zlibvc.tlb -+ -+ -+ Disabled -+ %(AdditionalIncludeDirectories);$(ProjectDir)\..\..\..\ -+ ARCH_ARM;WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -+ -+ -+ MultiThreadedDebugDLL -+ true -+ $(IntDir)zlibvc.pch -+ $(IntDir) -+ $(IntDir) -+ $(OutDir)$(TargetName).pdb -+ false -+ Level3 -+ true -+ ProgramDatabase -+ Guard -+ -+ -+ _DEBUG;%(PreprocessorDefinitions) -+ 0x040c -+ -+ -+ /MACHINE:ARM64 %(AdditionalOptions) -+ %(AdditionalDependencies) -+ $(OutDir)zlib.lib -+ true -+ .\zlibvc.def -+ true -+ $(OutDir)zlib.pdb -+ true -+ $(OutDir)zlib.lib.map -+ Windows -+ false -+ -+ -+ $(OutDir)zlib.lib -+ -+ -+ -+ MachineARM64 -+ false -+ -+ -+ -+ -+ _DEBUG;%(PreprocessorDefinitions) -+ true -+ true -+ $(OutDir)zlibvc.tlb -+ -+ -+ Disabled -+ %(AdditionalIncludeDirectories);$(ProjectDir)\..\..\..\ -+ ARCH_ARM;WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -+ -+ -+ MultiThreadedDebug -+ true -+ $(IntDir)zlibvc.pch -+ $(IntDir) -+ $(IntDir) -+ $(OutDir)$(TargetName).pdb -+ false -+ Level3 -+ true -+ ProgramDatabase -+ Guard -+ -+ -+ _DEBUG;%(PreprocessorDefinitions) -+ 0x040c -+ -+ -+ /MACHINE:ARM %(AdditionalOptions) -+ %(AdditionalDependencies) -+ $(OutDir)zlib.lib -+ true -+ .\zlibvc.def -+ true -+ $(OutDir)zlib.pdb -+ true -+ $(OutDir)zlib.lib.map -+ Windows -+ false -+ -+ -+ $(OutDir)zlib.lib -+ -+ -+ -+ -+ MachineARM -+ false -+ -+ -+ -+ -+ _DEBUG;%(PreprocessorDefinitions) -+ true -+ true -+ $(OutDir)zlibvc.tlb -+ -+ -+ Disabled -+ %(AdditionalIncludeDirectories);$(ProjectDir)\..\..\..\ -+ ARCH_ARM;WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -+ -+ -+ MultiThreadedDebug -+ true -+ $(IntDir)zlibvc.pch -+ $(IntDir) -+ $(IntDir) -+ $(OutDir)$(TargetName).pdb -+ false -+ Level3 -+ true -+ ProgramDatabase -+ Guard -+ -+ -+ _DEBUG;%(PreprocessorDefinitions) -+ 0x040c -+ -+ -+ /MACHINE:ARM64 %(AdditionalOptions) -+ %(AdditionalDependencies) -+ $(OutDir)zlib.lib -+ true -+ .\zlibvc.def -+ true -+ $(OutDir)zlib.pdb -+ true -+ $(OutDir)zlib.lib.map -+ Windows -+ false -+ -+ -+ $(OutDir)zlib.lib -+ -+ -+ -+ MachineARM64 -+ false -+ -+ -+ -+ -+ NDEBUG;%(PreprocessorDefinitions) -+ true -+ true -+ Win32 -+ $(OutDir)zlibvc.tlb -+ -+ -+ OnlyExplicitInline -+ ..\..\..;..\..\masmx86;%(AdditionalIncludeDirectories) -+ WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -+ true -+ -+ -+ MultiThreadedDLL -+ true -+ true -+ $(IntDir)zlibvc.pch -+ All -+ $(IntDir) -+ $(IntDir) -+ $(OutDir)$(TargetName).pdb -+ false -+ Level3 -+ true -+ true -+ Speed -+ true -+ StreamingSIMDExtensions -+ false -+ Guard -+ -+ -+ NDEBUG;%(PreprocessorDefinitions) -+ 0x040c -+ -+ -+ /MACHINE:I386 %(AdditionalOptions) -+ ..\..\masmx86\match686.obj;..\..\masmx86\inffas32.obj;%(AdditionalDependencies) -+ $(OutDir)zlib.lib -+ true -+ false -+ .\zlibvc.def -+ $(OutDir)zlib.pdb -+ true -+ $(OutDir)zlib.lib.map -+ Windows -+ false -+ -+ -+ $(OutDir)zlib.lib -+ -+ - cd ..\..\masmx86 --bld_ml32.bat -- -- -- MachineX86 -- false -- -- -- -- -- NDEBUG;%(PreprocessorDefinitions) -- true -- true -- Win32 -- $(OutDir)zlibvc.tlb -- -- -- OnlyExplicitInline -- ..\..\..;..\..\masmx86;%(AdditionalIncludeDirectories) -- WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -- true -- -- -- MultiThreaded -- true -- true -- $(IntDir)zlibvc.pch -- All -- $(IntDir) -- $(IntDir) -- $(OutDir)$(TargetName).pdb -- false -- Level3 -- true -- StreamingSIMDExtensions -- false -- Guard -- -- -- NDEBUG;%(PreprocessorDefinitions) -- 0x040c -- -- -- /MACHINE:I386 %(AdditionalOptions) -- ..\..\masmx86\match686.obj;..\..\masmx86\inffas32.obj;%(AdditionalDependencies) -- $(OutDir)zlib.lib -- true -- false -- .\zlibvc.def -- $(OutDir)zlib.pdb -- true -- $(OutDir)zlib.lib.map -- Windows -- false -- -- -- $(OutDir)zlib.lib -- -- -+bld_ml32.bat -+ -+ -+ MachineX86 -+ false -+ -+ -+ -+ -+ NDEBUG;%(PreprocessorDefinitions) -+ true -+ true -+ Win32 -+ $(OutDir)zlibvc.tlb -+ -+ -+ OnlyExplicitInline -+ ..\..\..;..\..\masmx86;%(AdditionalIncludeDirectories) -+ WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -+ true -+ -+ -+ MultiThreaded -+ true -+ true -+ $(IntDir)zlibvc.pch -+ All -+ $(IntDir) -+ $(IntDir) -+ $(OutDir)$(TargetName).pdb -+ false -+ Level3 -+ true -+ StreamingSIMDExtensions -+ false -+ Guard -+ -+ -+ NDEBUG;%(PreprocessorDefinitions) -+ 0x040c -+ -+ -+ /MACHINE:I386 %(AdditionalOptions) -+ ..\..\masmx86\match686.obj;..\..\masmx86\inffas32.obj;%(AdditionalDependencies) -+ $(OutDir)zlib.lib -+ true -+ false -+ .\zlibvc.def -+ $(OutDir)zlib.pdb -+ true -+ $(OutDir)zlib.lib.map -+ Windows -+ false -+ -+ -+ $(OutDir)zlib.lib -+ -+ - cd ..\..\masmx86 --bld_ml32.bat -- -- -- MachineX86 -- false -- -- -- -- -- NDEBUG;%(PreprocessorDefinitions) -- true -- true -- $(OutDir)zlibvc.tlb -- -- -- OnlyExplicitInline -- %(AdditionalIncludeDirectories);$(ProjectDir)\..\..\..\ -- ARCH_ARM;WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -- true -- -- -- MultiThreadedDLL -- true -- true -- $(IntDir)zlibvc.pch -- All -- $(IntDir) -- $(IntDir) -- $(OutDir)$(TargetName).pdb -- false -- Level3 -- true -- true -- Speed -- true -- NotSet -- false -- Guard -- -- -- NDEBUG;%(PreprocessorDefinitions) -- 0x040c -- -- -- /MACHINE:ARM %(AdditionalOptions) -- %(AdditionalDependencies) -- $(OutDir)zlib.lib -- true -- false -- .\zlibvc.def -- $(OutDir)zlib.pdb -- true -- $(OutDir)zlib.lib.map -- Windows -- false -- -- -- $(OutDir)zlib.lib -- -- -- -- -- MachineARM -- false -- -- -- -- -- NDEBUG;%(PreprocessorDefinitions) -- true -- true -- $(OutDir)zlibvc.tlb -- -- -- OnlyExplicitInline -- %(AdditionalIncludeDirectories);$(ProjectDir)\..\..\..\ -- ARCH_ARM;WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -- true -- -- -- MultiThreadedDLL -- true -- true -- $(IntDir)zlibvc.pch -- All -- $(IntDir) -- $(IntDir) -- $(OutDir)$(TargetName).pdb -- false -- Level3 -- true -- true -- Speed -- true -- NotSet -- false -- Guard -- -- -- NDEBUG;%(PreprocessorDefinitions) -- 0x040c -- -- -- /MACHINE:ARM64 %(AdditionalOptions) -- %(AdditionalDependencies) -- $(OutDir)zlib.lib -- true -- false -- .\zlibvc.def -- $(OutDir)zlib.pdb -- true -- $(OutDir)zlib.lib.map -- Windows -- false -- -- -- $(OutDir)zlib.lib -- -- -- -- MachineARM64 -- false -- -- -- -- -- NDEBUG;%(PreprocessorDefinitions) -- true -- true -- $(OutDir)zlibvc.tlb -- -- -- OnlyExplicitInline -- %(AdditionalIncludeDirectories);$(ProjectDir)\..\..\..\ -- ARCH_ARM;WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -- true -- -- -- MultiThreaded -- true -- true -- $(IntDir)zlibvc.pch -- All -- $(IntDir) -- $(IntDir) -- $(OutDir)$(TargetName).pdb -- false -- Level3 -- true -- false -- Guard -- -- -- NDEBUG;%(PreprocessorDefinitions) -- 0x040c -- -- -- /MACHINE:ARM %(AdditionalOptions) -- %(AdditionalDependencies) -- $(OutDir)zlib.lib -- true -- false -- .\zlibvc.def -- $(OutDir)zlib.pdb -- true -- $(OutDir)zlib.lib.map -- Windows -- false -- -- -- $(OutDir)zlib.lib -- -- -- -- -- MachineARM -- false -- -- -- -- -- NDEBUG;%(PreprocessorDefinitions) -- true -- true -- $(OutDir)zlibvc.tlb -- -- -- OnlyExplicitInline -- %(AdditionalIncludeDirectories);$(ProjectDir)\..\..\..\ -- ARCH_ARM;WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -- true -- -- -- MultiThreaded -- true -- true -- $(IntDir)zlibvc.pch -- All -- $(IntDir) -- $(IntDir) -- $(OutDir)$(TargetName).pdb -- false -- Level3 -- true -- false -- Guard -- -- -- NDEBUG;%(PreprocessorDefinitions) -- 0x040c -- -- -- /MACHINE:ARM64 %(AdditionalOptions) -- %(AdditionalDependencies) -- $(OutDir)zlib.lib -- true -- false -- .\zlibvc.def -- $(OutDir)zlib.pdb -- true -- $(OutDir)zlib.lib.map -- Windows -- false -- -- -- $(OutDir)zlib.lib -- -- -- -- MachineARM64 -- false -- -- -- -- -- _DEBUG;%(PreprocessorDefinitions) -- true -- true -- X64 -- $(OutDir)zlibvc.tlb -- -- -- Disabled -- ..\..\..;..\..\masmx86;%(AdditionalIncludeDirectories) -- WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;WIN64;%(PreprocessorDefinitions) -- -- -- MultiThreadedDebugDLL -- true -- $(IntDir)zlibvc.pch -- $(IntDir) -- $(IntDir) -- $(OutDir)$(TargetName).pdb -- false -- Level3 -- true -- ProgramDatabase -- StreamingSIMDExtensions2 -- Guard -- -- -- _DEBUG;%(PreprocessorDefinitions) -- 0x040c -- -- -- ..\..\masmx64\gvmat64.obj;..\..\masmx64\inffasx64.obj;%(AdditionalDependencies) -- $(OutDir)zlib.lib -- true -- .\zlibvc.def -- true -- $(OutDir)zlib.pdb -- true -- $(OutDir)zlib.lib.map -- Windows -- $(OutDir)zlib.lib -- MachineX64 -- -- -+bld_ml32.bat -+ -+ -+ MachineX86 -+ false -+ -+ -+ -+ -+ NDEBUG;%(PreprocessorDefinitions) -+ true -+ true -+ $(OutDir)zlibvc.tlb -+ -+ -+ OnlyExplicitInline -+ %(AdditionalIncludeDirectories);$(ProjectDir)\..\..\..\ -+ ARCH_ARM;WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -+ true -+ -+ -+ MultiThreadedDLL -+ true -+ true -+ $(IntDir)zlibvc.pch -+ All -+ $(IntDir) -+ $(IntDir) -+ $(OutDir)$(TargetName).pdb -+ false -+ Level3 -+ true -+ true -+ Speed -+ true -+ NotSet -+ false -+ Guard -+ -+ -+ NDEBUG;%(PreprocessorDefinitions) -+ 0x040c -+ -+ -+ /MACHINE:ARM %(AdditionalOptions) -+ %(AdditionalDependencies) -+ $(OutDir)zlib.lib -+ true -+ false -+ .\zlibvc.def -+ $(OutDir)zlib.pdb -+ true -+ $(OutDir)zlib.lib.map -+ Windows -+ false -+ -+ -+ $(OutDir)zlib.lib -+ -+ -+ -+ -+ MachineARM -+ false -+ -+ -+ -+ -+ NDEBUG;%(PreprocessorDefinitions) -+ true -+ true -+ $(OutDir)zlibvc.tlb -+ -+ -+ OnlyExplicitInline -+ %(AdditionalIncludeDirectories);$(ProjectDir)\..\..\..\ -+ ARCH_ARM;WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -+ true -+ -+ -+ MultiThreadedDLL -+ true -+ true -+ $(IntDir)zlibvc.pch -+ All -+ $(IntDir) -+ $(IntDir) -+ $(OutDir)$(TargetName).pdb -+ false -+ Level3 -+ true -+ true -+ Speed -+ true -+ NotSet -+ false -+ Guard -+ -+ -+ NDEBUG;%(PreprocessorDefinitions) -+ 0x040c -+ -+ -+ /MACHINE:ARM64 %(AdditionalOptions) -+ %(AdditionalDependencies) -+ $(OutDir)zlib.lib -+ true -+ false -+ .\zlibvc.def -+ $(OutDir)zlib.pdb -+ true -+ $(OutDir)zlib.lib.map -+ Windows -+ false -+ -+ -+ $(OutDir)zlib.lib -+ -+ -+ -+ MachineARM64 -+ false -+ -+ -+ -+ -+ NDEBUG;%(PreprocessorDefinitions) -+ true -+ true -+ $(OutDir)zlibvc.tlb -+ -+ -+ OnlyExplicitInline -+ %(AdditionalIncludeDirectories);$(ProjectDir)\..\..\..\ -+ ARCH_ARM;WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -+ true -+ -+ -+ MultiThreaded -+ true -+ true -+ $(IntDir)zlibvc.pch -+ All -+ $(IntDir) -+ $(IntDir) -+ $(OutDir)$(TargetName).pdb -+ false -+ Level3 -+ true -+ false -+ Guard -+ -+ -+ NDEBUG;%(PreprocessorDefinitions) -+ 0x040c -+ -+ -+ /MACHINE:ARM %(AdditionalOptions) -+ %(AdditionalDependencies) -+ $(OutDir)zlib.lib -+ true -+ false -+ .\zlibvc.def -+ $(OutDir)zlib.pdb -+ true -+ $(OutDir)zlib.lib.map -+ Windows -+ false -+ -+ -+ $(OutDir)zlib.lib -+ -+ -+ -+ -+ MachineARM -+ false -+ -+ -+ -+ -+ NDEBUG;%(PreprocessorDefinitions) -+ true -+ true -+ $(OutDir)zlibvc.tlb -+ -+ -+ OnlyExplicitInline -+ %(AdditionalIncludeDirectories);$(ProjectDir)\..\..\..\ -+ ARCH_ARM;WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;%(PreprocessorDefinitions) -+ true -+ -+ -+ MultiThreaded -+ true -+ true -+ $(IntDir)zlibvc.pch -+ All -+ $(IntDir) -+ $(IntDir) -+ $(OutDir)$(TargetName).pdb -+ false -+ Level3 -+ true -+ false -+ Guard -+ -+ -+ NDEBUG;%(PreprocessorDefinitions) -+ 0x040c -+ -+ -+ /MACHINE:ARM64 %(AdditionalOptions) -+ %(AdditionalDependencies) -+ $(OutDir)zlib.lib -+ true -+ false -+ .\zlibvc.def -+ $(OutDir)zlib.pdb -+ true -+ $(OutDir)zlib.lib.map -+ Windows -+ false -+ -+ -+ $(OutDir)zlib.lib -+ -+ -+ -+ MachineARM64 -+ false -+ -+ -+ -+ -+ _DEBUG;%(PreprocessorDefinitions) -+ true -+ true -+ X64 -+ $(OutDir)zlibvc.tlb -+ -+ -+ Disabled -+ ..\..\..;..\..\masmx86;%(AdditionalIncludeDirectories) -+ WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;WIN64;%(PreprocessorDefinitions) -+ -+ -+ MultiThreadedDebugDLL -+ true -+ $(IntDir)zlibvc.pch -+ $(IntDir) -+ $(IntDir) -+ $(OutDir)$(TargetName).pdb -+ false -+ Level3 -+ true -+ ProgramDatabase -+ StreamingSIMDExtensions2 -+ Guard -+ -+ -+ _DEBUG;%(PreprocessorDefinitions) -+ 0x040c -+ -+ -+ ..\..\masmx64\gvmat64.obj;..\..\masmx64\inffasx64.obj;%(AdditionalDependencies) -+ $(OutDir)zlib.lib -+ true -+ .\zlibvc.def -+ true -+ $(OutDir)zlib.pdb -+ true -+ $(OutDir)zlib.lib.map -+ Windows -+ $(OutDir)zlib.lib -+ MachineX64 -+ -+ - cd ..\..\contrib\masmx64 --bld_ml64.bat -- -- -- false -- -- -- -- -- _DEBUG;%(PreprocessorDefinitions) -- true -- true -- X64 -- $(OutDir)zlibvc.tlb -- -- -- Disabled -- ..\..\..;..\..\masmx86;%(AdditionalIncludeDirectories) -- _CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;WIN64;%(PreprocessorDefinitions) -- -- -- MultiThreadedDebug -- true -- $(IntDir)zlibvc.pch -- $(IntDir) -- $(IntDir) -- $(OutDir)$(TargetName).pdb -- false -- Level3 -- true -- ProgramDatabase -- StreamingSIMDExtensions2 -- Guard -- -- -- _DEBUG;%(PreprocessorDefinitions) -- 0x040c -- -- -- ..\..\masmx64\gvmat64.obj;..\..\masmx64\inffasx64.obj;%(AdditionalDependencies) -- $(OutDir)zlib.lib -- true -- .\zlibvc.def -- true -- $(OutDir)zlib.pdb -- true -- $(OutDir)zlib.lib.map -- Windows -- $(OutDir)zlib.lib -- MachineX64 -- -- -+bld_ml64.bat -+ -+ -+ false -+ -+ -+ -+ -+ _DEBUG;%(PreprocessorDefinitions) -+ true -+ true -+ X64 -+ $(OutDir)zlibvc.tlb -+ -+ -+ Disabled -+ ..\..\..;..\..\masmx86;%(AdditionalIncludeDirectories) -+ _CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;WIN64;%(PreprocessorDefinitions) -+ -+ -+ MultiThreadedDebug -+ true -+ $(IntDir)zlibvc.pch -+ $(IntDir) -+ $(IntDir) -+ $(OutDir)$(TargetName).pdb -+ false -+ Level3 -+ true -+ ProgramDatabase -+ StreamingSIMDExtensions2 -+ Guard -+ -+ -+ _DEBUG;%(PreprocessorDefinitions) -+ 0x040c -+ -+ -+ ..\..\masmx64\gvmat64.obj;..\..\masmx64\inffasx64.obj;%(AdditionalDependencies) -+ $(OutDir)zlib.lib -+ true -+ .\zlibvc.def -+ true -+ $(OutDir)zlib.pdb -+ true -+ $(OutDir)zlib.lib.map -+ Windows -+ $(OutDir)zlib.lib -+ MachineX64 -+ -+ - cd ..\..\contrib\masmx64 --bld_ml64.bat -- -- -- false -- -- -- -- -- NDEBUG;%(PreprocessorDefinitions) -- true -- true -- X64 -- $(OutDir)zlibvc.tlb -- -- -- OnlyExplicitInline -- ..\..\..;..\..\masmx86;%(AdditionalIncludeDirectories) -- WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;WIN64;%(PreprocessorDefinitions) -- true -- -- -- MultiThreadedDLL -- true -- true -- $(IntDir)zlibvc.pch -- All -- $(IntDir) -- $(IntDir) -- $(OutDir)$(TargetName).pdb -- false -- Level3 -- true -- true -- Speed -- true -- StreamingSIMDExtensions2 -- false -- Guard -- -- -- NDEBUG;%(PreprocessorDefinitions) -- 0x040c -- -- -- ..\..\masmx64\gvmat64.obj;..\..\masmx64\inffasx64.obj;%(AdditionalDependencies) -- $(OutDir)zlib.lib -- true -- false -- .\zlibvc.def -- $(OutDir)zlib.pdb -- true -- $(OutDir)zlib.lib.map -- Windows -- $(OutDir)zlib.lib -- MachineX64 -- -- -+bld_ml64.bat -+ -+ -+ false -+ -+ -+ -+ -+ NDEBUG;%(PreprocessorDefinitions) -+ true -+ true -+ X64 -+ $(OutDir)zlibvc.tlb -+ -+ -+ OnlyExplicitInline -+ ..\..\..;..\..\masmx86;%(AdditionalIncludeDirectories) -+ WIN32;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;WIN64;%(PreprocessorDefinitions) -+ true -+ -+ -+ MultiThreadedDLL -+ true -+ true -+ $(IntDir)zlibvc.pch -+ All -+ $(IntDir) -+ $(IntDir) -+ $(OutDir)$(TargetName).pdb -+ false -+ Level3 -+ true -+ true -+ Speed -+ true -+ StreamingSIMDExtensions2 -+ false -+ Guard -+ -+ -+ NDEBUG;%(PreprocessorDefinitions) -+ 0x040c -+ -+ -+ ..\..\masmx64\gvmat64.obj;..\..\masmx64\inffasx64.obj;%(AdditionalDependencies) -+ $(OutDir)zlib.lib -+ true -+ false -+ .\zlibvc.def -+ $(OutDir)zlib.pdb -+ true -+ $(OutDir)zlib.lib.map -+ Windows -+ $(OutDir)zlib.lib -+ MachineX64 -+ -+ - cd ..\..\masmx64 --bld_ml64.bat -- -- -- false -- -- -- -- -- NDEBUG;%(PreprocessorDefinitions) -- true -- true -- X64 -- $(OutDir)zlibvc.tlb -- -- -- OnlyExplicitInline -- ..\..\..;..\..\masmx86;%(AdditionalIncludeDirectories) -- _CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;WIN64;%(PreprocessorDefinitions) -- true -- -- -- MultiThreaded -- true -- true -- $(IntDir)zlibvc.pch -- All -- $(IntDir) -- $(IntDir) -- $(OutDir)$(TargetName).pdb -- false -- Level3 -- true -- StreamingSIMDExtensions2 -- false -- Guard -- -- -- NDEBUG;%(PreprocessorDefinitions) -- 0x040c -- -- -- ..\..\masmx64\gvmat64.obj;..\..\masmx64\inffasx64.obj;%(AdditionalDependencies) -- $(OutDir)zlib.lib -- true -- false -- .\zlibvc.def -- $(OutDir)zlib.pdb -- true -- $(OutDir)zlib.lib.map -- Windows -- $(OutDir)zlib.lib -- MachineX64 -- -- -+bld_ml64.bat -+ -+ -+ false -+ -+ -+ -+ -+ NDEBUG;%(PreprocessorDefinitions) -+ true -+ true -+ X64 -+ $(OutDir)zlibvc.tlb -+ -+ -+ OnlyExplicitInline -+ ..\..\..;..\..\masmx86;%(AdditionalIncludeDirectories) -+ _CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_WARNINGS;ZLIB_WINAPI;WIN64;%(PreprocessorDefinitions) -+ true -+ -+ -+ MultiThreaded -+ true -+ true -+ $(IntDir)zlibvc.pch -+ All -+ $(IntDir) -+ $(IntDir) -+ $(OutDir)$(TargetName).pdb -+ false -+ Level3 -+ true -+ StreamingSIMDExtensions2 -+ false -+ Guard -+ -+ -+ NDEBUG;%(PreprocessorDefinitions) -+ 0x040c -+ -+ -+ ..\..\masmx64\gvmat64.obj;..\..\masmx64\inffasx64.obj;%(AdditionalDependencies) -+ $(OutDir)zlib.lib -+ true -+ false -+ .\zlibvc.def -+ $(OutDir)zlib.pdb -+ true -+ $(OutDir)zlib.lib.map -+ Windows -+ $(OutDir)zlib.lib -+ MachineX64 -+ -+ - cd ..\..\masmx64 --bld_ml64.bat -- -- -- false -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -+bld_ml64.bat -+ -+ -+ false -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ - -\ No newline at end of file diff --git a/tools/ports/mstelemetry/vcpkg.json b/tools/ports/mstelemetry/vcpkg.json new file mode 100644 index 000000000..05341157b --- /dev/null +++ b/tools/ports/mstelemetry/vcpkg.json @@ -0,0 +1,29 @@ +{ + "name": "mstelemetry", + "version": "3.10.100.1", + "port-version": 0, + "description": "Microsoft 1DS C/C++ Client Telemetry Library", + "homepage": "https://github.com/microsoft/cpp_client_telemetry", + "license": "Apache-2.0", + "supports": "(windows | linux | osx | ios | android) & !uwp", + "dependencies": [ + "nlohmann-json", + "sqlite3", + "zlib", + { + "name": "curl", + "features": [ + "ssl" + ], + "platform": "!windows & !osx & !ios & !android" + }, + { + "name": "vcpkg-cmake", + "host": true + }, + { + "name": "vcpkg-cmake-config", + "host": true + } + ] +} diff --git a/tools/vcpkg b/tools/vcpkg index 16d13ffc5..56bb24116 160000 --- a/tools/vcpkg +++ b/tools/vcpkg @@ -1 +1 @@ -Subproject commit 16d13ffc54cec8c05374fc20bd48cbb14ecc974d +Subproject commit 56bb2411609227288b70117ead2c47585ba07713 diff --git a/wrappers/obj-c/ODWLogger.mm b/wrappers/obj-c/ODWLogger.mm index 594603390..9a341d0c7 100644 --- a/wrappers/obj-c/ODWLogger.mm +++ b/wrappers/obj-c/ODWLogger.mm @@ -9,8 +9,22 @@ #import "ODWLogConfiguration.h" #import "ODWSemanticContext.h" #import "ODWSemanticContext_private.h" + +#ifndef MATSDK_OBJC_PRIVACYGUARD_AVAILABLE +#define MATSDK_OBJC_PRIVACYGUARD_AVAILABLE 0 +#endif + +#if MATSDK_OBJC_PRIVACYGUARD_AVAILABLE #import "ODWPrivacyGuard_private.h" +#endif + +#ifndef MATSDK_OBJC_SANITIZER_AVAILABLE +#define MATSDK_OBJC_SANITIZER_AVAILABLE 0 +#endif + +#if MATSDK_OBJC_SANITIZER_AVAILABLE #import "ODWSanitizer_private.h" +#endif #include "EventProperties.hpp" @@ -411,17 +425,35 @@ void PerformActionWithCppExceptionsCatch(void (^block)()) } -(void)initializePrivacyGuardWithODWPrivacyGuardInitConfig:(ODWPrivacyGuardInitConfig *)initConfigObject -{ +{ +#if MATSDK_OBJC_PRIVACYGUARD_AVAILABLE [ODWPrivacyGuard initializePrivacyGuard:_wrappedLogger withODWPrivacyGuardInitConfig:initConfigObject]; +#else + (void)initConfigObject; + [ODWLogger traceException:"Privacy Guard is not available in this build."]; +#endif } -(void)initializeSanitizerWithODWSanitizerInitConfig:(ODWSanitizerInitConfig *)initConfigObject { +#if MATSDK_OBJC_SANITIZER_AVAILABLE [ODWSanitizer initializeSanitizer:_wrappedLogger withODWSanitizerInitConfig:initConfigObject]; +#else + (void)initConfigObject; + [ODWLogger traceException:"Sanitizer is not available in this build."]; +#endif } -(void)initializeSanitizerWithODWSanitizerInitConfig:(ODWSanitizerInitConfig *)initConfigObject urlDomains:(NSArray *)urlDomains emailDomains:(NSArray *)emailDomains analyzerOptions:(int)analyzerOptions { +#if MATSDK_OBJC_SANITIZER_AVAILABLE [ODWSanitizer initializeSanitizer:_wrappedLogger withODWSanitizerInitConfig:initConfigObject urlDomains:urlDomains emailDomains:emailDomains analyzerOptions:analyzerOptions]; +#else + (void)initConfigObject; + (void)urlDomains; + (void)emailDomains; + (void)analyzerOptions; + [ODWLogger traceException:"Sanitizer is not available in this build."]; +#endif } @end diff --git a/wrappers/swift/Package.swift b/wrappers/swift/Package.swift index 1b4136bcc..879943354 100644 --- a/wrappers/swift/Package.swift +++ b/wrappers/swift/Package.swift @@ -2,6 +2,41 @@ // The swift-tools-version declares the minimum version of Swift required to build this package. import PackageDescription +import Foundation + +let packageDirectory = URL(fileURLWithPath: #filePath).deletingLastPathComponent() + +func moduleExists(_ relativePath: String) -> Bool { + FileManager.default.fileExists(atPath: packageDirectory.appendingPathComponent(relativePath).standardizedFileURL.path) +} + +let hasDiagnosticDataViewer = moduleExists("../../lib/modules/dataviewer") +let hasPrivacyGuard = moduleExists("../../lib/modules/privacyguard") +let hasSanitizer = moduleExists("../../lib/modules/sanitizer") + +var excludedSources: [String] = [] +var swiftSettings: [SwiftSetting] = [] + +if !hasDiagnosticDataViewer { + excludedSources.append("DiagnosticDataViewer.swift") +} + +if hasPrivacyGuard { + swiftSettings.append(.define("MATSDK_PRIVACYGUARD_AVAILABLE")) +} else { + excludedSources.append(contentsOf: [ + "CommonDataContext.swift", + "PrivacyGuard.swift", + "PrivacyGuardInitConfig.swift", + ]) +} + +if !hasSanitizer { + excludedSources.append(contentsOf: [ + "Sanitizer.swift", + "SanitizerInitConfig.swift", + ]) +} let package = Package( name: "OneDSSwiftWrapper", @@ -21,8 +56,11 @@ let package = Package( .target( name: "OneDSSwift", dependencies: [], + path: "Sources/OneDSSwift", + exclude: excludedSources, cSettings: [ .headerSearchPath("../../Modules/") - ]), + ], + swiftSettings: swiftSettings), ] ) diff --git a/wrappers/swift/Sources/OneDSSwift/Logger.swift b/wrappers/swift/Sources/OneDSSwift/Logger.swift index 4821df3b6..04a9c1497 100644 --- a/wrappers/swift/Sources/OneDSSwift/Logger.swift +++ b/wrappers/swift/Sources/OneDSSwift/Logger.swift @@ -137,10 +137,12 @@ public final class Logger { /** Initializes and gets an instance of Privacy Guard. - */ + */ + #if MATSDK_PRIVACYGUARD_AVAILABLE public func apply(config initConfigObject: PrivacyGuardInitConfig) { odwLogger.initializePrivacyGuard(with: initConfigObject.getODWPrivacyGuardInitConfig()) } + #endif // MARK: Set Context methods diff --git a/zlib/CMakeLists.txt b/zlib/CMakeLists.txt index cf4d65e5e..7786f2215 100644 --- a/zlib/CMakeLists.txt +++ b/zlib/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 2.4.4) +cmake_minimum_required(VERSION 3.5) set(CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS ON) project(zlib C) From d2e9eb62e2842579481041f3ac8311677e7c56bc Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Fri, 5 Jun 2026 12:57:05 -0500 Subject: [PATCH 02/56] Refresh overlay port source snapshot Point the overlay mstelemetry port at the clean vcpkg source snapshot in this replacement PR and update the archive SHA512 used by vcpkg_from_github. Files changed: tools/ports/mstelemetry/portfile.cmake Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index 648506b40..6b6f97fdb 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,13 +1,13 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF dc53d660024772cd6fd858f7897ff124c2330c28 - SHA512 a8c70f4cc1a3f4dc88a0c5ed3bf2992bad7e85f1cf75238f1a608bc726f9c5317c8a549aeb2174022cf79bbe77a14940f687cc7cdbcbdeb5afd1b2db3944e174 + REF a1b2dc0f73243a65cb21d4b5188729e2eae46e9d + SHA512 332a41906eb332dee33e0e3774d31ecd8952326ba46a65c5bc50de207e36df40fc2d441254748c618200073b5d27ff50f79daad2b0f461659612d90eff4c7368 HEAD_REF main ) # Determine if Apple HTTP should be used (no curl needed). -# Note: BUILD_APPLE_HTTP must remain ON for macOS/iOS — the vcpkg.json +# Note: BUILD_APPLE_HTTP must remain ON for macOS/iOS because the vcpkg.json # curl dependency is excluded on these platforms. set(MATSDK_BUILD_APPLE_HTTP OFF) if(VCPKG_TARGET_IS_OSX OR VCPKG_TARGET_IS_IOS) From eec4b72082498714ebf8c91f02dc56a3c22758a7 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Fri, 5 Jun 2026 19:26:06 -0500 Subject: [PATCH 03/56] Fix Android CMake sources and C++11 vcpkg consumer test Use Android-specific PAL implementations when the top-level CMake path targets Android, and remove the missing bundled zlib simd_stub source from the Android legacy dependency path. Also make the vcpkg consumer test build as C++11 to match the SDK consumer compatibility posture. Files changed: lib/CMakeLists.txt, tests/vcpkg/CMakeLists.txt Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- lib/CMakeLists.txt | 31 +++++++++++++++++++++---------- tests/vcpkg/CMakeLists.txt | 2 +- 2 files changed, 22 insertions(+), 11 deletions(-) diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt index 9058cf362..254a0274a 100644 --- a/lib/CMakeLists.txt +++ b/lib/CMakeLists.txt @@ -161,11 +161,19 @@ if(PAL_IMPLEMENTATION STREQUAL "CPP11") ) endif() endif() - list(APPEND SRCS - pal/posix/DeviceInformationImpl.cpp - pal/posix/SystemInformationImpl.cpp - pal/posix/sysinfo_sources.cpp - ) + if(CMAKE_SYSTEM_NAME STREQUAL "Android") + list(APPEND SRCS + pal/posix/DeviceInformationImpl_Android.cpp + pal/posix/SystemInformationImpl_Android.cpp + pal/posix/sysinfo_sources.cpp + ) + else() + list(APPEND SRCS + pal/posix/DeviceInformationImpl.cpp + pal/posix/SystemInformationImpl.cpp + pal/posix/sysinfo_sources.cpp + ) + endif() if(APPLE) if(BUILD_APPLE_HTTP OR BUILD_IOS) @@ -183,14 +191,19 @@ if(PAL_IMPLEMENTATION STREQUAL "CPP11") pal/posix/NetworkInformationImpl.mm ) else() - list(APPEND SRCS pal/posix/NetworkInformationImpl.cpp) if(CMAKE_SYSTEM_NAME STREQUAL "Android") list(APPEND SRCS + pal/posix/NetworkInformationImpl_Android.cpp http/HttpClient_Android.cpp http/HttpClient_Android.hpp ) + if(CMAKE_CXX_COMPILER_ID MATCHES "Clang") + set_source_files_properties(http/HttpClient_Android.cpp + PROPERTIES COMPILE_FLAGS "-Wno-unused-const-variable") + endif() else() list(APPEND SRCS + pal/posix/NetworkInformationImpl.cpp http/HttpClient_Curl.cpp http/HttpClient_Curl.hpp ) @@ -357,9 +370,8 @@ else() # Also suppress warnings treated as errors in vendored code. target_compile_options(sqlite3_bundled PRIVATE -fno-finite-math-only -Wno-unused-function) - # Build zlib from bundled source, excluding Intel SIMD files (crc_folding.c, - # fill_window_sse.c, x86.c) that require SSE4.2/PCLMULQDQ and cannot compile - # on ARM. simd_stub.c provides the necessary stubs instead. + # Build zlib from bundled source. The upstream SIMD sources are not part of + # this tree, so no Android-specific stubs are needed. add_library(zlib_bundled STATIC "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/adler32.c" "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/compress.c" @@ -376,7 +388,6 @@ else() "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/trees.c" "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/uncompr.c" "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/zutil.c" - "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/simd_stub.c" ) target_include_directories(zlib_bundled PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}/../zlib") set_target_properties(zlib_bundled PROPERTIES POSITION_INDEPENDENT_CODE ON) diff --git a/tests/vcpkg/CMakeLists.txt b/tests/vcpkg/CMakeLists.txt index 42636fa16..c552ae41f 100644 --- a/tests/vcpkg/CMakeLists.txt +++ b/tests/vcpkg/CMakeLists.txt @@ -1,7 +1,7 @@ cmake_minimum_required(VERSION 3.15) project(mstelemetry_vcpkg_test LANGUAGES CXX) -set(CMAKE_CXX_STANDARD 14) +set(CMAKE_CXX_STANDARD 11) set(CMAKE_CXX_STANDARD_REQUIRED ON) set(CMAKE_CXX_EXTENSIONS OFF) From 79b18076f44ad5769e918b7a9d02248d3969ae70 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Fri, 5 Jun 2026 19:26:26 -0500 Subject: [PATCH 04/56] Refresh overlay port source after Android fixes Update the overlay port REF and SHA512 to the source snapshot that includes the Android CMake source fixes and C++11 vcpkg consumer test. Files changed: tools/ports/mstelemetry/portfile.cmake Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index 6b6f97fdb..e75218fd3 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF a1b2dc0f73243a65cb21d4b5188729e2eae46e9d - SHA512 332a41906eb332dee33e0e3774d31ecd8952326ba46a65c5bc50de207e36df40fc2d441254748c618200073b5d27ff50f79daad2b0f461659612d90eff4c7368 + REF eec4b72082498714ebf8c91f02dc56a3c22758a7 + SHA512 0a468343503eb36bb0f04ff0d1701bfa1d70c4b64ff56cc526d36cdf81a031c0ea06c8a3d1444511d20073746bb4d63fd3fd5242c0c9883173e83ed5173dab08 HEAD_REF main ) @@ -51,3 +51,4 @@ file(INSTALL "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_D # Install license vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE") + From e43b55df45dd1ee051e11dcd68ebc7ab75fe1fd4 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Fri, 5 Jun 2026 23:13:22 -0500 Subject: [PATCH 05/56] Exclude module-only headers from core vcpkg install GitHub source archives used by the public vcpkg port do not include the lib/modules submodule. Avoid installing public headers whose exported factories/functions are implemented only by absent optional modules, so core vcpkg consumers do not get linkable-looking APIs without implementations. Files changed: lib/include/CMakeLists.txt Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- lib/include/CMakeLists.txt | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/lib/include/CMakeLists.txt b/lib/include/CMakeLists.txt index 0706448ba..c8aa8ae98 100644 --- a/lib/include/CMakeLists.txt +++ b/lib/include/CMakeLists.txt @@ -7,10 +7,26 @@ list(GET MATSDK_BUILD_VERSION_SPLIT 3 BUILD_NUMBER) #TODO: allow regeneration of Version.hpp using template #configure_file(public/Version.hpp.template "${CMAKE_CURRENT_SOURCE_DIR}/public/Version.hpp") +set(MATSDK_PUBLIC_HEADER_INSTALL_EXCLUDES + PATTERN "public/*.template" EXCLUDE +) + +if(MATSDK_USE_VCPKG_DEPS) + # GitHub source archives used by the public vcpkg port do not include the + # private lib/modules submodule, so do not install public headers whose + # exported factories/functions are implemented only by those modules. + list(APPEND MATSDK_PUBLIC_HEADER_INSTALL_EXCLUDES + PATTERN "CompliantByDefaultFilterApi.hpp" EXCLUDE + PATTERN "IAFDClient.hpp" EXCLUDE + PATTERN "ICdsFactory.hpp" EXCLUDE + PATTERN "IECSClient.hpp" EXCLUDE + ) +endif() + install( DIRECTORY public/ DESTINATION include/mat - PATTERN "public/*.template" EXCLUDE + ${MATSDK_PUBLIC_HEADER_INSTALL_EXCLUDES} ) From 30b61e0f8e09edcb55b930efd6ebaee689276dcb Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Fri, 5 Jun 2026 23:13:38 -0500 Subject: [PATCH 06/56] Refresh overlay port source after header install fix Update the overlay port REF and SHA512 to the source snapshot that excludes module-only public headers from the core vcpkg install. Files changed: tools/ports/mstelemetry/portfile.cmake Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index e75218fd3..55f4dd02e 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF eec4b72082498714ebf8c91f02dc56a3c22758a7 - SHA512 0a468343503eb36bb0f04ff0d1701bfa1d70c4b64ff56cc526d36cdf81a031c0ea06c8a3d1444511d20073746bb4d63fd3fd5242c0c9883173e83ed5173dab08 + REF e43b55df45dd1ee051e11dcd68ebc7ab75fe1fd4 + SHA512 4a390f615abaf3c806cca016e8792f2a0de74a769737c4ccf57301613a14094405162f17d01caa8802fae588109b3be5d5169e5450197881fd0da0355bfe7e51 HEAD_REF main ) From 3ae30fe087ca95d14f41004a281ffa43de7869ad Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sat, 6 Jun 2026 00:07:31 -0500 Subject: [PATCH 07/56] Use Curl for Android vcpkg consumers Build the Android vcpkg package with the native Curl HTTP client instead of the Java-backed Android HTTP client, so native consumers using find_package(MSTelemetry) can initialize the SDK without the Java bridge creating the Android HTTP singleton. Strengthen the vcpkg consumer test by calling LogManager::Initialize and FlushAndTeardown. Files changed: CMakeLists.txt, lib/CMakeLists.txt, tools/ports/mstelemetry/vcpkg.json, tests/vcpkg/main.cpp Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- CMakeLists.txt | 3 ++- lib/CMakeLists.txt | 19 ++++++++++++++----- tests/vcpkg/main.cpp | 15 +++++++++++---- tools/ports/mstelemetry/vcpkg.json | 2 +- 4 files changed, 28 insertions(+), 11 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index ba010e0ef..9f608dd5d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -313,9 +313,10 @@ endif() set(MATSDK_NEEDS_CURL OFF) if(PAL_IMPLEMENTATION STREQUAL "CPP11" AND NOT BUILD_IOS - AND NOT CMAKE_SYSTEM_NAME STREQUAL "Android" + AND (NOT CMAKE_SYSTEM_NAME STREQUAL "Android" OR MATSDK_USE_VCPKG_DEPS) AND NOT BUILD_APPLE_HTTP) set(MATSDK_NEEDS_CURL ON) + add_definitions(-DHAVE_MAT_CURL_HTTP_CLIENT) find_package(CURL REQUIRED) if(MATSDK_USE_VCPKG_DEPS) list(APPEND LIBS CURL::libcurl) diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt index 254a0274a..d6121fd81 100644 --- a/lib/CMakeLists.txt +++ b/lib/CMakeLists.txt @@ -194,12 +194,21 @@ if(PAL_IMPLEMENTATION STREQUAL "CPP11") if(CMAKE_SYSTEM_NAME STREQUAL "Android") list(APPEND SRCS pal/posix/NetworkInformationImpl_Android.cpp - http/HttpClient_Android.cpp - http/HttpClient_Android.hpp ) - if(CMAKE_CXX_COMPILER_ID MATCHES "Clang") - set_source_files_properties(http/HttpClient_Android.cpp - PROPERTIES COMPILE_FLAGS "-Wno-unused-const-variable") + if(MATSDK_USE_VCPKG_DEPS) + list(APPEND SRCS + http/HttpClient_Curl.cpp + http/HttpClient_Curl.hpp + ) + else() + list(APPEND SRCS + http/HttpClient_Android.cpp + http/HttpClient_Android.hpp + ) + if(CMAKE_CXX_COMPILER_ID MATCHES "Clang") + set_source_files_properties(http/HttpClient_Android.cpp + PROPERTIES COMPILE_FLAGS "-Wno-unused-const-variable") + endif() endif() else() list(APPEND SRCS diff --git a/tests/vcpkg/main.cpp b/tests/vcpkg/main.cpp index 6a5e3bbc6..80b477049 100644 --- a/tests/vcpkg/main.cpp +++ b/tests/vcpkg/main.cpp @@ -40,7 +40,14 @@ int main() auto& config = LogManager::GetLogConfiguration(); check(true, "LogManager::GetLogConfiguration() callable"); - // 3. EventProperties with multiple types + // 3. LogManager initialization + { + ILogger* logger = LogManager::Initialize("vcpkg-test-token"); + check(logger != nullptr, "LogManager::Initialize() callable"); + LogManager::FlushAndTeardown(); + } + + // 4. EventProperties with multiple types { EventProperties props("TestEvent"); props.SetProperty("strProp", "value"); @@ -51,7 +58,7 @@ int main() check(true, "SetProperty for string, int, double, bool"); } - // 4. Multiple event types + // 5. Multiple event types { std::vector names = {"App.Started", "App.PageView", "App.Error"}; for (const auto& name : names) { @@ -61,7 +68,7 @@ int main() check(true, "Created multiple event types"); } - // 5. PII annotations + // 6. PII annotations { EventProperties props("PiiTest"); props.SetProperty("userId", "user@example.com", PiiKind_Identity); @@ -69,7 +76,7 @@ int main() check(true, "PII-annotated properties compile and link"); } - // 6. Event priority + // 7. Event priority { EventProperties props("PriorityTest"); props.SetPriority(EventPriority_High); diff --git a/tools/ports/mstelemetry/vcpkg.json b/tools/ports/mstelemetry/vcpkg.json index 05341157b..f514c643c 100644 --- a/tools/ports/mstelemetry/vcpkg.json +++ b/tools/ports/mstelemetry/vcpkg.json @@ -15,7 +15,7 @@ "features": [ "ssl" ], - "platform": "!windows & !osx & !ios & !android" + "platform": "!windows & !osx & !ios" }, { "name": "vcpkg-cmake", From 755165b38ada07817138239e616b850363eabcb5 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sat, 6 Jun 2026 00:07:47 -0500 Subject: [PATCH 08/56] Refresh overlay port source after Android Curl switch Update the overlay port REF and SHA512 to the source snapshot that uses Curl for Android vcpkg consumers. Files changed: tools/ports/mstelemetry/portfile.cmake Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index 55f4dd02e..73b08aa12 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF e43b55df45dd1ee051e11dcd68ebc7ab75fe1fd4 - SHA512 4a390f615abaf3c806cca016e8792f2a0de74a769737c4ccf57301613a14094405162f17d01caa8802fae588109b3be5d5169e5450197881fd0da0355bfe7e51 + REF 3ae30fe087ca95d14f41004a281ffa43de7869ad + SHA512 d7a5bf599570561ed06c70e0ea9b070bbe257338a0c5345ab09777a21b022858e8032bacbf45e0461c0a00883f2dc623f52f5f5d82b69599d1bc26b9ce5c4525 HEAD_REF main ) From 1481adda04cd5e2de0b260ad9b462ec59eaccd74 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sat, 6 Jun 2026 00:37:05 -0500 Subject: [PATCH 09/56] Disable curl non-HTTP protocols for vcpkg port The SDK only needs HTTP/HTTPS. Disable curl default features and enable only ssl so Android vcpkg builds do not pull in unused non-HTTP protocol objects that fail to link on the Android NDK. Files changed: tools/ports/mstelemetry/vcpkg.json Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/vcpkg.json | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/ports/mstelemetry/vcpkg.json b/tools/ports/mstelemetry/vcpkg.json index f514c643c..c598c8c7b 100644 --- a/tools/ports/mstelemetry/vcpkg.json +++ b/tools/ports/mstelemetry/vcpkg.json @@ -12,6 +12,7 @@ "zlib", { "name": "curl", + "default-features": false, "features": [ "ssl" ], From 3da677f5c2a2197e75ac57f210144ea3dde44b1d Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sat, 6 Jun 2026 00:37:19 -0500 Subject: [PATCH 10/56] Refresh overlay port source after curl feature fix Update the overlay port REF and SHA512 to the source snapshot that disables unused curl non-HTTP protocols. Files changed: tools/ports/mstelemetry/portfile.cmake Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index 73b08aa12..69fd1f67f 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF 3ae30fe087ca95d14f41004a281ffa43de7869ad - SHA512 d7a5bf599570561ed06c70e0ea9b070bbe257338a0c5345ab09777a21b022858e8032bacbf45e0461c0a00883f2dc623f52f5f5d82b69599d1bc26b9ce5c4525 + REF 1481adda04cd5e2de0b260ad9b462ec59eaccd74 + SHA512 55b2173dfd9dc5fd30703e12ef527118fdcb3d93cc6a93969408d37946021c24411f8c7bee0a9d10d43d177e0d4b055dd72da5ab94f012f5a016922b3cfc5273 HEAD_REF main ) From 5a6c55bca654d16a44add7cfda348e4d301ccb6a Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sat, 6 Jun 2026 00:56:21 -0500 Subject: [PATCH 11/56] Align Android vcpkg test with API 28 Document and use Android API 28 for the vcpkg Android consumer test, matching vcpkg's Android triplet default. Keep curl default features disabled and request OpenSSL explicitly for the native Android vcpkg HTTP path. Files changed: tools/ports/mstelemetry/vcpkg.json, tests/vcpkg/test-vcpkg-android.sh, tests/vcpkg/README.md, docs/building-with-vcpkg.md Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- docs/building-with-vcpkg.md | 5 ++++- tests/vcpkg/README.md | 4 +++- tests/vcpkg/test-vcpkg-android.sh | 2 +- tools/ports/mstelemetry/vcpkg.json | 3 ++- 4 files changed, 10 insertions(+), 4 deletions(-) diff --git a/docs/building-with-vcpkg.md b/docs/building-with-vcpkg.md index 83fe5d14b..165c7c99b 100644 --- a/docs/building-with-vcpkg.md +++ b/docs/building-with-vcpkg.md @@ -86,7 +86,10 @@ for details on creating your own custom triplets for other platforms. ### Android (cross-compile) -Requires the Android NDK (`ANDROID_NDK_HOME` must be set): +Requires the Android NDK (`ANDROID_NDK_HOME` must be set). The validation +script targets Android API 28, which matches vcpkg's Android triplet default +and avoids mixing dependencies built for a newer API level into a lower-API +consumer binary: ```bash vcpkg install mstelemetry --triplet=arm64-android diff --git a/tests/vcpkg/README.md b/tests/vcpkg/README.md index d9ffcba72..c04de7fab 100644 --- a/tests/vcpkg/README.md +++ b/tests/vcpkg/README.md @@ -77,7 +77,9 @@ The simulator mode uses the built-in vcpkg community triplet `arm64-ios-simulato ### Android (cross-compile) -**Requires:** Android NDK, cmake, VCPKG_ROOT set +**Requires:** Android NDK, cmake, VCPKG_ROOT set. The test targets +`android-28`, matching vcpkg's Android triplet default and its prebuilt +dependency ABI expectations. ```bash # Default: arm64-v8a diff --git a/tests/vcpkg/test-vcpkg-android.sh b/tests/vcpkg/test-vcpkg-android.sh index 6d57c232c..06f173f64 100755 --- a/tests/vcpkg/test-vcpkg-android.sh +++ b/tests/vcpkg/test-vcpkg-android.sh @@ -72,7 +72,7 @@ cmake -S "${SCRIPT_DIR}" -B "${BUILD_DIR}/consumer" \ -DVCPKG_OVERLAY_PORTS="${OVERLAY_PORTS}" \ -DVCPKG_CHAINLOAD_TOOLCHAIN_FILE="${ANDROID_NDK_HOME}/build/cmake/android.toolchain.cmake" \ -DANDROID_ABI="${ANDROID_ABI}" \ - -DANDROID_PLATFORM=android-24 \ + -DANDROID_PLATFORM=android-28 \ -DCMAKE_BUILD_TYPE=Release echo "" diff --git a/tools/ports/mstelemetry/vcpkg.json b/tools/ports/mstelemetry/vcpkg.json index c598c8c7b..7a346039e 100644 --- a/tools/ports/mstelemetry/vcpkg.json +++ b/tools/ports/mstelemetry/vcpkg.json @@ -14,7 +14,7 @@ "name": "curl", "default-features": false, "features": [ - "ssl" + "openssl" ], "platform": "!windows & !osx & !ios" }, @@ -28,3 +28,4 @@ } ] } + From b35bbcd6905b06fca591f04ae0929011947a1ce2 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sat, 6 Jun 2026 00:57:01 -0500 Subject: [PATCH 12/56] Refresh overlay port source after Android API update Update the overlay port REF and SHA512 to the source snapshot that aligns Android vcpkg validation with API 28 and requests OpenSSL explicitly for curl. Files changed: tools/ports/mstelemetry/portfile.cmake Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index 69fd1f67f..a59560378 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF 1481adda04cd5e2de0b260ad9b462ec59eaccd74 - SHA512 55b2173dfd9dc5fd30703e12ef527118fdcb3d93cc6a93969408d37946021c24411f8c7bee0a9d10d43d177e0d4b055dd72da5ab94f012f5a016922b3cfc5273 + REF 5a6c55bca654d16a44add7cfda348e4d301ccb6a + SHA512 87187cfb2aa6bea12c84af19bbd2f643f774bda2f9c03a2be4d37acc80b6ce39d53e203c3219402fc7a6af327232989009e1018e5eda38272c62a8c9f7e288d7 HEAD_REF main ) From 960379ab98b0e6d33348dd828c51a46c39b3a334 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sat, 6 Jun 2026 01:00:43 -0500 Subject: [PATCH 13/56] Propagate vcpkg link dependencies to consumers Export the vcpkg-resolved dependency targets through MSTelemetry::mat so static-library consumers receive sqlite, zlib, nlohmann-json, and curl link requirements. Also fix the template header install exclusion and update the package config Curl comment for Android vcpkg builds. Files changed: lib/CMakeLists.txt, lib/include/CMakeLists.txt, cmake/MSTelemetryConfig.cmake.in Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- cmake/MSTelemetryConfig.cmake.in | 3 ++- lib/CMakeLists.txt | 4 +++- lib/include/CMakeLists.txt | 2 +- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/cmake/MSTelemetryConfig.cmake.in b/cmake/MSTelemetryConfig.cmake.in index 0ad3351e9..f70f40c40 100644 --- a/cmake/MSTelemetryConfig.cmake.in +++ b/cmake/MSTelemetryConfig.cmake.in @@ -7,7 +7,8 @@ find_dependency(unofficial-sqlite3 CONFIG) find_dependency(ZLIB) find_dependency(nlohmann_json CONFIG) -# Curl is needed on Linux (not Windows/iOS/Android/macOS-with-Apple-HTTP). +# Curl is needed on native POSIX HTTP builds (Linux and Android vcpkg; +# not Windows/iOS/macOS-with-Apple-HTTP). # We capture the build-time decision as a boolean rather than re-deriving # it, because the macOS BUILD_APPLE_HTTP edge case can't be inferred from # CMAKE_SYSTEM_NAME alone. diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt index d6121fd81..ec4f71b3b 100644 --- a/lib/CMakeLists.txt +++ b/lib/CMakeLists.txt @@ -361,8 +361,10 @@ endif() ################################################################################################ if(MATSDK_USE_VCPKG_DEPS) # vcpkg mode: all deps resolved via find_package() in root CMakeLists.txt + # These are PUBLIC so static-library consumers get the transitive link set + # through the exported MSTelemetry::mat target. target_link_libraries(mat - PRIVATE + PUBLIC unofficial::sqlite3::sqlite3 ZLIB::ZLIB nlohmann_json::nlohmann_json diff --git a/lib/include/CMakeLists.txt b/lib/include/CMakeLists.txt index c8aa8ae98..c5a0eb9f6 100644 --- a/lib/include/CMakeLists.txt +++ b/lib/include/CMakeLists.txt @@ -8,7 +8,7 @@ list(GET MATSDK_BUILD_VERSION_SPLIT 3 BUILD_NUMBER) #configure_file(public/Version.hpp.template "${CMAKE_CURRENT_SOURCE_DIR}/public/Version.hpp") set(MATSDK_PUBLIC_HEADER_INSTALL_EXCLUDES - PATTERN "public/*.template" EXCLUDE + PATTERN "*.template" EXCLUDE ) if(MATSDK_USE_VCPKG_DEPS) From f1a8d1a49180f4e13212ec3f5c435264ff30636c Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sat, 6 Jun 2026 01:00:58 -0500 Subject: [PATCH 14/56] Refresh overlay port source after dependency export fix Update the overlay port REF and SHA512 to the source snapshot that exports vcpkg dependency targets to downstream static-library consumers. Files changed: tools/ports/mstelemetry/portfile.cmake Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index a59560378..6c51d3e2b 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF 5a6c55bca654d16a44add7cfda348e4d301ccb6a - SHA512 87187cfb2aa6bea12c84af19bbd2f643f774bda2f9c03a2be4d37acc80b6ce39d53e203c3219402fc7a6af327232989009e1018e5eda38272c62a8c9f7e288d7 + REF 960379ab98b0e6d33348dd828c51a46c39b3a334 + SHA512 afd7ce6c2e3ffacacf69d0be3d3532f231dccdbc7b9de27bc90b42351464fef761ea0b3b26ef1830735f5369f2f40368446ef777507fbc8d7ed0927f4b6eb9fa HEAD_REF main ) From 7bf984fcd52019ef2e6ade2c05e3bf5e8f20faef Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sat, 6 Jun 2026 18:17:28 -0500 Subject: [PATCH 15/56] Align Android vcpkg validation with repo support Use API 23 overlay triplets for Android vcpkg validation so dependencies match the repo's Android minSdk instead of requiring API 28 consumers. Remove the unused bundled vcpkg submodule because tests and CI use an external VCPKG_ROOT. Keep Apple sample and legacy tests aligned with the dependency model: core vcpkg builds use Apple HTTP without Obj-C/Swift wrappers, and Android legacy tests reuse bundled zlib. Files changed: - .github/workflows/test-vcpkg.yml - .gitmodules - docs/building-with-vcpkg.md - examples/swift/SampleXcodeApp/SwiftWrapperApp.xcodeproj/project.pbxproj - lib/CMakeLists.txt - tests/functests/CMakeLists.txt - tests/unittests/CMakeLists.txt - tests/vcpkg/README.md - tests/vcpkg/test-vcpkg-android.sh - tests/vcpkg/triplets/*.cmake - tools/ports/mstelemetry/vcpkg.json - tools/vcpkg Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- .github/workflows/test-vcpkg.yml | 7 +- .gitmodules | 4 - docs/building-with-vcpkg.md | 30 +- .../SwiftWrapperApp.xcodeproj/project.pbxproj | 852 +++++++++--------- lib/CMakeLists.txt | 3 +- tests/functests/CMakeLists.txt | 12 +- tests/unittests/CMakeLists.txt | 12 +- tests/vcpkg/README.md | 12 +- tests/vcpkg/test-vcpkg-android.sh | 44 +- .../triplets/arm-neon-android-api23.cmake | 7 + .../vcpkg/triplets/arm64-android-api23.cmake | 7 + tests/vcpkg/triplets/x64-android-api23.cmake | 7 + tests/vcpkg/triplets/x86-android-api23.cmake | 7 + tools/ports/mstelemetry/vcpkg.json | 3 +- tools/vcpkg | 1 - 15 files changed, 541 insertions(+), 467 deletions(-) create mode 100644 tests/vcpkg/triplets/arm-neon-android-api23.cmake create mode 100644 tests/vcpkg/triplets/arm64-android-api23.cmake create mode 100644 tests/vcpkg/triplets/x64-android-api23.cmake create mode 100644 tests/vcpkg/triplets/x86-android-api23.cmake delete mode 160000 tools/vcpkg diff --git a/.github/workflows/test-vcpkg.yml b/.github/workflows/test-vcpkg.yml index a9a25f6e1..bdf37bd2e 100644 --- a/.github/workflows/test-vcpkg.yml +++ b/.github/workflows/test-vcpkg.yml @@ -94,7 +94,7 @@ jobs: android: runs-on: ubuntu-latest - name: Android (arm64-v8a cross-compile) + name: Android (arm64-v8a API 23 cross-compile) steps: - uses: actions/checkout@v4 @@ -103,9 +103,12 @@ jobs: git clone https://github.com/microsoft/vcpkg.git "${{ runner.temp }}/vcpkg" "${{ runner.temp }}/vcpkg/bootstrap-vcpkg.sh" -disableMetrics + - name: Install Android test prerequisites + run: sudo apt-get update && sudo apt-get install -y ninja-build + - name: Run vcpkg port test env: VCPKG_ROOT: ${{ runner.temp }}/vcpkg run: | chmod +x tests/vcpkg/test-vcpkg-android.sh - ./tests/vcpkg/test-vcpkg-android.sh arm64-v8a + ./tests/vcpkg/test-vcpkg-android.sh arm64-v8a 23 diff --git a/.gitmodules b/.gitmodules index 6d27c663c..186328c0d 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,7 +1,3 @@ -[submodule "tools/vcpkg"] - path = tools/vcpkg - url = https://github.com/Microsoft/vcpkg - [submodule "lib/modules"] path = lib/modules url = ../cpp_client_telemetry_modules.git diff --git a/docs/building-with-vcpkg.md b/docs/building-with-vcpkg.md index 165c7c99b..950947596 100644 --- a/docs/building-with-vcpkg.md +++ b/docs/building-with-vcpkg.md @@ -86,15 +86,28 @@ for details on creating your own custom triplets for other platforms. ### Android (cross-compile) -Requires the Android NDK (`ANDROID_NDK_HOME` must be set). The validation -script targets Android API 28, which matches vcpkg's Android triplet default -and avoids mixing dependencies built for a newer API level into a lower-API -consumer binary: +Requires the Android NDK (`ANDROID_NDK_HOME` must be set). vcpkg's built-in +Android triplets default to Android API 28: ```bash vcpkg install mstelemetry --triplet=arm64-android ``` +This repo's Android build declares `minSdk 23`. To build the SDK and all +vcpkg dependencies for API 23, use a custom triplet that sets +`VCPKG_CMAKE_SYSTEM_VERSION` to `23`. The integration tests include API 23 +triplet examples: + +```bash +vcpkg install mstelemetry \ + --triplet=arm64-android-api23 \ + --overlay-triplets=tests/vcpkg/triplets +``` + +Do not mix dependencies built with the default API 28 triplets into an API 23 +consumer binary; build the whole dependency graph with the same Android API +triplet. + Supported triplets: `arm64-android`, `arm-neon-android`, `x64-android`, `x86-android`. @@ -107,11 +120,12 @@ The vcpkg port automatically resolves the following dependencies: | SQLite3 | `sqlite3` | `unofficial::sqlite3::sqlite3` | All | | zlib | `zlib` | `ZLIB::ZLIB` | All | | nlohmann JSON | `nlohmann-json` | `nlohmann_json::nlohmann_json` | All | -| libcurl | `curl[ssl]` | `CURL::libcurl` | Non-Windows, non-Apple, non-Android | +| libcurl | `curl[openssl]` | `CURL::libcurl` | Non-Windows, non-Apple | -Windows, macOS/iOS, and Android use platform-native HTTP clients (WinInet, -NSURLSession, and HttpClient_Android respectively), so curl is not required -on those platforms. +Windows and macOS/iOS use platform-native HTTP clients (WinInet and +NSURLSession respectively). Android vcpkg consumers use native libcurl because +the Java-backed `HttpClient_Android` singleton is initialized by the repo's +Android Gradle/AAR flow, not by standalone native vcpkg consumers. ## Optional: SIMD-Optimized zlib with zlib-ng diff --git a/examples/swift/SampleXcodeApp/SwiftWrapperApp.xcodeproj/project.pbxproj b/examples/swift/SampleXcodeApp/SwiftWrapperApp.xcodeproj/project.pbxproj index 4000bc664..35c80a526 100644 --- a/examples/swift/SampleXcodeApp/SwiftWrapperApp.xcodeproj/project.pbxproj +++ b/examples/swift/SampleXcodeApp/SwiftWrapperApp.xcodeproj/project.pbxproj @@ -1,426 +1,426 @@ -// !$*UTF8*$! -{ - archiveVersion = 1; - classes = { - }; - objectVersion = 56; - objects = { - -/* Begin PBXBuildFile section */ - 2711D2652A45438A000712BD /* SwiftWrapperExampleApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2711D2642A45438A000712BD /* SwiftWrapperExampleApp.swift */; }; - 2711D2672A45438A000712BD /* ContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2711D2662A45438A000712BD /* ContentView.swift */; }; - 2711D26D2A45438C000712BD /* Preview Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 2711D26C2A45438C000712BD /* Preview Assets.xcassets */; }; - A34744202A4642300039D419 /* OneDSSwift in Frameworks */ = {isa = PBXBuildFile; productRef = A347441F2A4642300039D419 /* OneDSSwift */; }; - A34744242A4643B20039D419 /* libmat.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A34744232A4643B20039D419 /* libmat.a */; }; - A34744262A4643FE0039D419 /* libsqlite3.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = A34744252A4643FE0039D419 /* libsqlite3.tbd */; }; - A34744282A46440F0039D419 /* SystemConfiguration.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A34744272A46440F0039D419 /* SystemConfiguration.framework */; }; - A347442A2A46441A0039D419 /* Network.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A34744292A46441A0039D419 /* Network.framework */; }; - A347442C2A46442C0039D419 /* libz.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = A347442B2A46442C0039D419 /* libz.tbd */; }; -/* End PBXBuildFile section */ - -/* Begin PBXFileReference section */ - 2711D2612A45438A000712BD /* SwiftWrapperApp.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = SwiftWrapperApp.app; sourceTree = BUILT_PRODUCTS_DIR; }; - 2711D2642A45438A000712BD /* SwiftWrapperExampleApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SwiftWrapperExampleApp.swift; sourceTree = ""; }; - 2711D2662A45438A000712BD /* ContentView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentView.swift; sourceTree = ""; }; - 2711D26A2A45438C000712BD /* SwiftWrapperApp.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = SwiftWrapperApp.entitlements; sourceTree = ""; }; - 2711D26C2A45438C000712BD /* Preview Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = "Preview Assets.xcassets"; sourceTree = ""; }; - 2711D2732A45452E000712BD /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist; path = Info.plist; sourceTree = ""; }; - 277E76FF2A45FE4D004A3A8F /* swift */ = {isa = PBXFileReference; lastKnownFileType = wrapper; name = swift; path = ../../../wrappers/swift; sourceTree = ""; }; - A34744232A4643B20039D419 /* libmat.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libmat.a; path = "$(MATSDK_INSTALL_DIR)/lib/libmat.a"; sourceTree = ""; }; - A34744252A4643FE0039D419 /* libsqlite3.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libsqlite3.tbd; path = usr/lib/libsqlite3.tbd; sourceTree = SDKROOT; }; - A34744272A46440F0039D419 /* SystemConfiguration.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SystemConfiguration.framework; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk/System/Library/Frameworks/SystemConfiguration.framework; sourceTree = DEVELOPER_DIR; }; - A34744292A46441A0039D419 /* Network.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Network.framework; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk/System/Library/Frameworks/Network.framework; sourceTree = DEVELOPER_DIR; }; - A347442B2A46442C0039D419 /* libz.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libz.tbd; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk/usr/lib/libz.tbd; sourceTree = DEVELOPER_DIR; }; -/* End PBXFileReference section */ - -/* Begin PBXFrameworksBuildPhase section */ - 2711D25E2A45438A000712BD /* Frameworks */ = { - isa = PBXFrameworksBuildPhase; - buildActionMask = 2147483647; - files = ( - A347442C2A46442C0039D419 /* libz.tbd in Frameworks */, - A347442A2A46441A0039D419 /* Network.framework in Frameworks */, - A34744282A46440F0039D419 /* SystemConfiguration.framework in Frameworks */, - A34744202A4642300039D419 /* OneDSSwift in Frameworks */, - A34744242A4643B20039D419 /* libmat.a in Frameworks */, - A34744262A4643FE0039D419 /* libsqlite3.tbd in Frameworks */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXFrameworksBuildPhase section */ - -/* Begin PBXGroup section */ - 2711D2582A45438A000712BD = { - isa = PBXGroup; - children = ( - 277E76FE2A45FE4D004A3A8F /* Packages */, - 2711D2632A45438A000712BD /* SwiftWrapperApp */, - 2711D2622A45438A000712BD /* Products */, - A347441E2A4642300039D419 /* Frameworks */, - ); - sourceTree = ""; - }; - 2711D2622A45438A000712BD /* Products */ = { - isa = PBXGroup; - children = ( - 2711D2612A45438A000712BD /* SwiftWrapperApp.app */, - ); - name = Products; - sourceTree = ""; - }; - 2711D2632A45438A000712BD /* SwiftWrapperApp */ = { - isa = PBXGroup; - children = ( - 2711D2732A45452E000712BD /* Info.plist */, - 2711D2642A45438A000712BD /* SwiftWrapperExampleApp.swift */, - 2711D2662A45438A000712BD /* ContentView.swift */, - 2711D26A2A45438C000712BD /* SwiftWrapperApp.entitlements */, - 2711D26B2A45438C000712BD /* Preview Content */, - ); - path = SwiftWrapperApp; - sourceTree = ""; - }; - 2711D26B2A45438C000712BD /* Preview Content */ = { - isa = PBXGroup; - children = ( - 2711D26C2A45438C000712BD /* Preview Assets.xcassets */, - ); - path = "Preview Content"; - sourceTree = ""; - }; - 277E76FE2A45FE4D004A3A8F /* Packages */ = { - isa = PBXGroup; - children = ( - 277E76FF2A45FE4D004A3A8F /* swift */, - ); - name = Packages; - sourceTree = ""; - }; - A347441E2A4642300039D419 /* Frameworks */ = { - isa = PBXGroup; - children = ( - A347442B2A46442C0039D419 /* libz.tbd */, - A34744292A46441A0039D419 /* Network.framework */, - A34744272A46440F0039D419 /* SystemConfiguration.framework */, - A34744252A4643FE0039D419 /* libsqlite3.tbd */, - A34744232A4643B20039D419 /* libmat.a */, - ); - name = Frameworks; - sourceTree = ""; - }; -/* End PBXGroup section */ - -/* Begin PBXNativeTarget section */ - 2711D2602A45438A000712BD /* SwiftWrapperApp */ = { - isa = PBXNativeTarget; - buildConfigurationList = 2711D2702A45438C000712BD /* Build configuration list for PBXNativeTarget "SwiftWrapperApp" */; - buildPhases = ( - 2711D25D2A45438A000712BD /* Sources */, - 2711D25E2A45438A000712BD /* Frameworks */, - 2711D25F2A45438A000712BD /* Resources */, - ); - buildRules = ( - ); - dependencies = ( - 277E77012A460B83004A3A8F /* PBXTargetDependency */, - ); - name = SwiftWrapperApp; - packageProductDependencies = ( - A347441F2A4642300039D419 /* OneDSSwift */, - ); - productName = SwiftWrapperApp; - productReference = 2711D2612A45438A000712BD /* SwiftWrapperApp.app */; - productType = "com.apple.product-type.application"; - }; -/* End PBXNativeTarget section */ - -/* Begin PBXProject section */ - 2711D2592A45438A000712BD /* Project object */ = { - isa = PBXProject; - attributes = { - BuildIndependentTargetsInParallel = 1; - LastSwiftUpdateCheck = 1430; - LastUpgradeCheck = 1430; - TargetAttributes = { - 2711D2602A45438A000712BD = { - CreatedOnToolsVersion = 14.3; - }; - }; - }; - buildConfigurationList = 2711D25C2A45438A000712BD /* Build configuration list for PBXProject "SwiftWrapperApp" */; - compatibilityVersion = "Xcode 14.0"; - developmentRegion = en; - hasScannedForEncodings = 0; - knownRegions = ( - en, - Base, - ); - mainGroup = 2711D2582A45438A000712BD; - productRefGroup = 2711D2622A45438A000712BD /* Products */; - projectDirPath = ""; - projectRoot = ""; - targets = ( - 2711D2602A45438A000712BD /* SwiftWrapperApp */, - ); - }; -/* End PBXProject section */ - -/* Begin PBXResourcesBuildPhase section */ - 2711D25F2A45438A000712BD /* Resources */ = { - isa = PBXResourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - 2711D26D2A45438C000712BD /* Preview Assets.xcassets in Resources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXResourcesBuildPhase section */ - -/* Begin PBXSourcesBuildPhase section */ - 2711D25D2A45438A000712BD /* Sources */ = { - isa = PBXSourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - 2711D2672A45438A000712BD /* ContentView.swift in Sources */, - 2711D2652A45438A000712BD /* SwiftWrapperExampleApp.swift in Sources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXSourcesBuildPhase section */ - -/* Begin PBXTargetDependency section */ - 277E77012A460B83004A3A8F /* PBXTargetDependency */ = { - isa = PBXTargetDependency; - productRef = 277E77002A460B83004A3A8F /* OneDSSwift */; - }; -/* End PBXTargetDependency section */ - -/* Begin XCBuildConfiguration section */ - 2711D26E2A45438C000712BD /* Debug */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_ENABLE_OBJC_WEAK = YES; - CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_COMMA = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INFINITE_RECURSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; - CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; - CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; - CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; - CLANG_WARN_STRICT_PROTOTYPES = YES; - CLANG_WARN_SUSPICIOUS_MOVE = YES; - CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - COPY_PHASE_STRIP = NO; - DEBUG_INFORMATION_FORMAT = dwarf; - ENABLE_STRICT_OBJC_MSGSEND = YES; - ENABLE_TESTABILITY = YES; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_DYNAMIC_NO_PIC = NO; - GCC_NO_COMMON_BLOCKS = YES; - GCC_OPTIMIZATION_LEVEL = 0; - GCC_PREPROCESSOR_DEFINITIONS = ( - "DEBUG=1", - "$(inherited)", - ); - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; - MTL_FAST_MATH = YES; - ONLY_ACTIVE_ARCH = YES; - SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; - SWIFT_INCLUDE_PATHS = ""; - "SWIFT_INCLUDE_PATHS[arch=*]" = ../../../wrappers/swift/Modules/; - SWIFT_OPTIMIZATION_LEVEL = "-Onone"; - }; - name = Debug; - }; - 2711D26F2A45438C000712BD /* Release */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_ENABLE_OBJC_WEAK = YES; - CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_COMMA = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INFINITE_RECURSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; - CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; - CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; - CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; - CLANG_WARN_STRICT_PROTOTYPES = YES; - CLANG_WARN_SUSPICIOUS_MOVE = YES; - CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - COPY_PHASE_STRIP = NO; - DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; - ENABLE_NS_ASSERTIONS = NO; - ENABLE_STRICT_OBJC_MSGSEND = YES; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_NO_COMMON_BLOCKS = YES; - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - MTL_ENABLE_DEBUG_INFO = NO; - MTL_FAST_MATH = YES; - SWIFT_COMPILATION_MODE = wholemodule; - SWIFT_INCLUDE_PATHS = ""; - SWIFT_OPTIMIZATION_LEVEL = "-O"; - }; - name = Release; - }; - 2711D2712A45438C000712BD /* Debug */ = { - isa = XCBuildConfiguration; - buildSettings = { - ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; - CODE_SIGN_ENTITLEMENTS = SwiftWrapperApp/SwiftWrapperApp.entitlements; - CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 1; - DEVELOPMENT_ASSET_PATHS = "\"SwiftWrapperApp/Preview Content\""; - ENABLE_PREVIEWS = YES; - GENERATE_INFOPLIST_FILE = YES; - INFOPLIST_FILE = SwiftWrapperApp/Info.plist; - "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphoneos*]" = YES; - "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphonesimulator*]" = YES; - "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphoneos*]" = YES; - "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphonesimulator*]" = YES; - "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphoneos*]" = YES; - "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphonesimulator*]" = YES; - "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphoneos*]" = UIStatusBarStyleDefault; - "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphonesimulator*]" = UIStatusBarStyleDefault; - INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; - INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; - IPHONEOS_DEPLOYMENT_TARGET = 16.4; - LD_RUNPATH_SEARCH_PATHS = "@executable_path/Frameworks"; - "LD_RUNPATH_SEARCH_PATHS[arch=*]" = "$(MATSDK_INSTALL_DIR)/lib"; - LIBRARY_SEARCH_PATHS = "$(MATSDK_INSTALL_DIR)/lib"; - MATSDK_INSTALL_DIR = /usr/local; - "LD_RUNPATH_SEARCH_PATHS[sdk=macosx*]" = "@executable_path/../Frameworks"; - MACOSX_DEPLOYMENT_TARGET = 13.3; - MARKETING_VERSION = 1.0; - PRODUCT_BUNDLE_IDENTIFIER = OneDSSwift.SwiftWrapperApp; - PRODUCT_NAME = "$(TARGET_NAME)"; - SDKROOT = auto; - SUPPORTED_PLATFORMS = "iphoneos iphonesimulator macosx"; - SWIFT_EMIT_LOC_STRINGS = YES; - SWIFT_VERSION = 5.0; - TARGETED_DEVICE_FAMILY = "1,2"; - }; - name = Debug; - }; - 2711D2722A45438C000712BD /* Release */ = { - isa = XCBuildConfiguration; - buildSettings = { - ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; - CODE_SIGN_ENTITLEMENTS = SwiftWrapperApp/SwiftWrapperApp.entitlements; - CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 1; - DEVELOPMENT_ASSET_PATHS = "\"SwiftWrapperApp/Preview Content\""; - ENABLE_PREVIEWS = YES; - GENERATE_INFOPLIST_FILE = YES; - INFOPLIST_FILE = SwiftWrapperApp/Info.plist; - "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphoneos*]" = YES; - "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphonesimulator*]" = YES; - "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphoneos*]" = YES; - "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphonesimulator*]" = YES; - "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphoneos*]" = YES; - "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphonesimulator*]" = YES; - "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphoneos*]" = UIStatusBarStyleDefault; - "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphonesimulator*]" = UIStatusBarStyleDefault; - INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; - INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; - IPHONEOS_DEPLOYMENT_TARGET = 16.4; - LD_RUNPATH_SEARCH_PATHS = "@executable_path/Frameworks"; - "LD_RUNPATH_SEARCH_PATHS[arch=*]" = "$(MATSDK_INSTALL_DIR)/lib"; - "LD_RUNPATH_SEARCH_PATHS[sdk=macosx*]" = "@executable_path/../Frameworks"; - LIBRARY_SEARCH_PATHS = "$(MATSDK_INSTALL_DIR)/lib"; - MACOSX_DEPLOYMENT_TARGET = 13.3; - MATSDK_INSTALL_DIR = /usr/local; - MARKETING_VERSION = 1.0; - PRODUCT_BUNDLE_IDENTIFIER = OneDSSwift.SwiftWrapperApp; - PRODUCT_NAME = "$(TARGET_NAME)"; - SDKROOT = auto; - SUPPORTED_PLATFORMS = "iphoneos iphonesimulator macosx"; - SWIFT_EMIT_LOC_STRINGS = YES; - SWIFT_VERSION = 5.0; - TARGETED_DEVICE_FAMILY = "1,2"; - }; - name = Release; - }; -/* End XCBuildConfiguration section */ - -/* Begin XCConfigurationList section */ - 2711D25C2A45438A000712BD /* Build configuration list for PBXProject "SwiftWrapperApp" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - 2711D26E2A45438C000712BD /* Debug */, - 2711D26F2A45438C000712BD /* Release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; - 2711D2702A45438C000712BD /* Build configuration list for PBXNativeTarget "SwiftWrapperApp" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - 2711D2712A45438C000712BD /* Debug */, - 2711D2722A45438C000712BD /* Release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; -/* End XCConfigurationList section */ - -/* Begin XCSwiftPackageProductDependency section */ - 277E77002A460B83004A3A8F /* OneDSSwift */ = { - isa = XCSwiftPackageProductDependency; - productName = OneDSSwift; - }; - A347441F2A4642300039D419 /* OneDSSwift */ = { - isa = XCSwiftPackageProductDependency; - productName = OneDSSwift; - }; -/* End XCSwiftPackageProductDependency section */ - }; - rootObject = 2711D2592A45438A000712BD /* Project object */; -} +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 56; + objects = { + +/* Begin PBXBuildFile section */ + 2711D2652A45438A000712BD /* SwiftWrapperExampleApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2711D2642A45438A000712BD /* SwiftWrapperExampleApp.swift */; }; + 2711D2672A45438A000712BD /* ContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2711D2662A45438A000712BD /* ContentView.swift */; }; + 2711D26D2A45438C000712BD /* Preview Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 2711D26C2A45438C000712BD /* Preview Assets.xcassets */; }; + A34744202A4642300039D419 /* OneDSSwift in Frameworks */ = {isa = PBXBuildFile; productRef = A347441F2A4642300039D419 /* OneDSSwift */; }; + A34744242A4643B20039D419 /* libmat.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A34744232A4643B20039D419 /* libmat.a */; }; + A34744262A4643FE0039D419 /* libsqlite3.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = A34744252A4643FE0039D419 /* libsqlite3.tbd */; }; + A34744282A46440F0039D419 /* SystemConfiguration.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A34744272A46440F0039D419 /* SystemConfiguration.framework */; }; + A347442A2A46441A0039D419 /* Network.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A34744292A46441A0039D419 /* Network.framework */; }; + A347442C2A46442C0039D419 /* libz.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = A347442B2A46442C0039D419 /* libz.tbd */; }; +/* End PBXBuildFile section */ + +/* Begin PBXFileReference section */ + 2711D2612A45438A000712BD /* SwiftWrapperApp.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = SwiftWrapperApp.app; sourceTree = BUILT_PRODUCTS_DIR; }; + 2711D2642A45438A000712BD /* SwiftWrapperExampleApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SwiftWrapperExampleApp.swift; sourceTree = ""; }; + 2711D2662A45438A000712BD /* ContentView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentView.swift; sourceTree = ""; }; + 2711D26A2A45438C000712BD /* SwiftWrapperApp.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = SwiftWrapperApp.entitlements; sourceTree = ""; }; + 2711D26C2A45438C000712BD /* Preview Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = "Preview Assets.xcassets"; sourceTree = ""; }; + 2711D2732A45452E000712BD /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist; path = Info.plist; sourceTree = ""; }; + 277E76FF2A45FE4D004A3A8F /* swift */ = {isa = PBXFileReference; lastKnownFileType = wrapper; name = swift; path = ../../../wrappers/swift; sourceTree = ""; }; + A34744232A4643B20039D419 /* libmat.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libmat.a; path = "$(MATSDK_INSTALL_DIR)/lib/libmat.a"; sourceTree = ""; }; + A34744252A4643FE0039D419 /* libsqlite3.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libsqlite3.tbd; path = usr/lib/libsqlite3.tbd; sourceTree = SDKROOT; }; + A34744272A46440F0039D419 /* SystemConfiguration.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SystemConfiguration.framework; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk/System/Library/Frameworks/SystemConfiguration.framework; sourceTree = DEVELOPER_DIR; }; + A34744292A46441A0039D419 /* Network.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Network.framework; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk/System/Library/Frameworks/Network.framework; sourceTree = DEVELOPER_DIR; }; + A347442B2A46442C0039D419 /* libz.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libz.tbd; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk/usr/lib/libz.tbd; sourceTree = DEVELOPER_DIR; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 2711D25E2A45438A000712BD /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + A347442C2A46442C0039D419 /* libz.tbd in Frameworks */, + A347442A2A46441A0039D419 /* Network.framework in Frameworks */, + A34744282A46440F0039D419 /* SystemConfiguration.framework in Frameworks */, + A34744202A4642300039D419 /* OneDSSwift in Frameworks */, + A34744242A4643B20039D419 /* libmat.a in Frameworks */, + A34744262A4643FE0039D419 /* libsqlite3.tbd in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 2711D2582A45438A000712BD = { + isa = PBXGroup; + children = ( + 277E76FE2A45FE4D004A3A8F /* Packages */, + 2711D2632A45438A000712BD /* SwiftWrapperApp */, + 2711D2622A45438A000712BD /* Products */, + A347441E2A4642300039D419 /* Frameworks */, + ); + sourceTree = ""; + }; + 2711D2622A45438A000712BD /* Products */ = { + isa = PBXGroup; + children = ( + 2711D2612A45438A000712BD /* SwiftWrapperApp.app */, + ); + name = Products; + sourceTree = ""; + }; + 2711D2632A45438A000712BD /* SwiftWrapperApp */ = { + isa = PBXGroup; + children = ( + 2711D2732A45452E000712BD /* Info.plist */, + 2711D2642A45438A000712BD /* SwiftWrapperExampleApp.swift */, + 2711D2662A45438A000712BD /* ContentView.swift */, + 2711D26A2A45438C000712BD /* SwiftWrapperApp.entitlements */, + 2711D26B2A45438C000712BD /* Preview Content */, + ); + path = SwiftWrapperApp; + sourceTree = ""; + }; + 2711D26B2A45438C000712BD /* Preview Content */ = { + isa = PBXGroup; + children = ( + 2711D26C2A45438C000712BD /* Preview Assets.xcassets */, + ); + path = "Preview Content"; + sourceTree = ""; + }; + 277E76FE2A45FE4D004A3A8F /* Packages */ = { + isa = PBXGroup; + children = ( + 277E76FF2A45FE4D004A3A8F /* swift */, + ); + name = Packages; + sourceTree = ""; + }; + A347441E2A4642300039D419 /* Frameworks */ = { + isa = PBXGroup; + children = ( + A347442B2A46442C0039D419 /* libz.tbd */, + A34744292A46441A0039D419 /* Network.framework */, + A34744272A46440F0039D419 /* SystemConfiguration.framework */, + A34744252A4643FE0039D419 /* libsqlite3.tbd */, + A34744232A4643B20039D419 /* libmat.a */, + ); + name = Frameworks; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + 2711D2602A45438A000712BD /* SwiftWrapperApp */ = { + isa = PBXNativeTarget; + buildConfigurationList = 2711D2702A45438C000712BD /* Build configuration list for PBXNativeTarget "SwiftWrapperApp" */; + buildPhases = ( + 2711D25D2A45438A000712BD /* Sources */, + 2711D25E2A45438A000712BD /* Frameworks */, + 2711D25F2A45438A000712BD /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + 277E77012A460B83004A3A8F /* PBXTargetDependency */, + ); + name = SwiftWrapperApp; + packageProductDependencies = ( + A347441F2A4642300039D419 /* OneDSSwift */, + ); + productName = SwiftWrapperApp; + productReference = 2711D2612A45438A000712BD /* SwiftWrapperApp.app */; + productType = "com.apple.product-type.application"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 2711D2592A45438A000712BD /* Project object */ = { + isa = PBXProject; + attributes = { + BuildIndependentTargetsInParallel = 1; + LastSwiftUpdateCheck = 1430; + LastUpgradeCheck = 1430; + TargetAttributes = { + 2711D2602A45438A000712BD = { + CreatedOnToolsVersion = 14.3; + }; + }; + }; + buildConfigurationList = 2711D25C2A45438A000712BD /* Build configuration list for PBXProject "SwiftWrapperApp" */; + compatibilityVersion = "Xcode 14.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = 2711D2582A45438A000712BD; + productRefGroup = 2711D2622A45438A000712BD /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 2711D2602A45438A000712BD /* SwiftWrapperApp */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 2711D25F2A45438A000712BD /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 2711D26D2A45438C000712BD /* Preview Assets.xcassets in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 2711D25D2A45438A000712BD /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 2711D2672A45438A000712BD /* ContentView.swift in Sources */, + 2711D2652A45438A000712BD /* SwiftWrapperExampleApp.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + 277E77012A460B83004A3A8F /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + productRef = 277E77002A460B83004A3A8F /* OneDSSwift */; + }; +/* End PBXTargetDependency section */ + +/* Begin XCBuildConfiguration section */ + 2711D26E2A45438C000712BD /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; + MTL_FAST_MATH = YES; + ONLY_ACTIVE_ARCH = YES; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_INCLUDE_PATHS = ""; + "SWIFT_INCLUDE_PATHS[arch=*]" = ../../../wrappers/swift/Modules/; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + 2711D26F2A45438C000712BD /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + SWIFT_COMPILATION_MODE = wholemodule; + SWIFT_INCLUDE_PATHS = ""; + SWIFT_OPTIMIZATION_LEVEL = "-O"; + }; + name = Release; + }; + 2711D2712A45438C000712BD /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; + CODE_SIGN_ENTITLEMENTS = SwiftWrapperApp/SwiftWrapperApp.entitlements; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_ASSET_PATHS = "\"SwiftWrapperApp/Preview Content\""; + ENABLE_PREVIEWS = YES; + GENERATE_INFOPLIST_FILE = YES; + INFOPLIST_FILE = SwiftWrapperApp/Info.plist; + "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphoneos*]" = YES; + "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphonesimulator*]" = YES; + "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphoneos*]" = YES; + "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphonesimulator*]" = YES; + "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphoneos*]" = YES; + "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphonesimulator*]" = YES; + "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphoneos*]" = UIStatusBarStyleDefault; + "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphonesimulator*]" = UIStatusBarStyleDefault; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + IPHONEOS_DEPLOYMENT_TARGET = 16.4; + LD_RUNPATH_SEARCH_PATHS = "@executable_path/Frameworks"; + "LD_RUNPATH_SEARCH_PATHS[arch=*]" = "$(MATSDK_INSTALL_DIR)/lib"; + "LD_RUNPATH_SEARCH_PATHS[sdk=macosx*]" = "@executable_path/../Frameworks"; + LIBRARY_SEARCH_PATHS = "$(MATSDK_INSTALL_DIR)/lib"; + MACOSX_DEPLOYMENT_TARGET = 13.3; + MATSDK_INSTALL_DIR = /usr/local; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = OneDSSwift.SwiftWrapperApp; + PRODUCT_NAME = "$(TARGET_NAME)"; + SDKROOT = auto; + SUPPORTED_PLATFORMS = "iphoneos iphonesimulator macosx"; + SWIFT_EMIT_LOC_STRINGS = YES; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + 2711D2722A45438C000712BD /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; + CODE_SIGN_ENTITLEMENTS = SwiftWrapperApp/SwiftWrapperApp.entitlements; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_ASSET_PATHS = "\"SwiftWrapperApp/Preview Content\""; + ENABLE_PREVIEWS = YES; + GENERATE_INFOPLIST_FILE = YES; + INFOPLIST_FILE = SwiftWrapperApp/Info.plist; + "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphoneos*]" = YES; + "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphonesimulator*]" = YES; + "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphoneos*]" = YES; + "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphonesimulator*]" = YES; + "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphoneos*]" = YES; + "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphonesimulator*]" = YES; + "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphoneos*]" = UIStatusBarStyleDefault; + "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphonesimulator*]" = UIStatusBarStyleDefault; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + IPHONEOS_DEPLOYMENT_TARGET = 16.4; + LD_RUNPATH_SEARCH_PATHS = "@executable_path/Frameworks"; + "LD_RUNPATH_SEARCH_PATHS[arch=*]" = "$(MATSDK_INSTALL_DIR)/lib"; + "LD_RUNPATH_SEARCH_PATHS[sdk=macosx*]" = "@executable_path/../Frameworks"; + LIBRARY_SEARCH_PATHS = "$(MATSDK_INSTALL_DIR)/lib"; + MACOSX_DEPLOYMENT_TARGET = 13.3; + MATSDK_INSTALL_DIR = /usr/local; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = OneDSSwift.SwiftWrapperApp; + PRODUCT_NAME = "$(TARGET_NAME)"; + SDKROOT = auto; + SUPPORTED_PLATFORMS = "iphoneos iphonesimulator macosx"; + SWIFT_EMIT_LOC_STRINGS = YES; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 2711D25C2A45438A000712BD /* Build configuration list for PBXProject "SwiftWrapperApp" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 2711D26E2A45438C000712BD /* Debug */, + 2711D26F2A45438C000712BD /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 2711D2702A45438C000712BD /* Build configuration list for PBXNativeTarget "SwiftWrapperApp" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 2711D2712A45438C000712BD /* Debug */, + 2711D2722A45438C000712BD /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + +/* Begin XCSwiftPackageProductDependency section */ + 277E77002A460B83004A3A8F /* OneDSSwift */ = { + isa = XCSwiftPackageProductDependency; + productName = OneDSSwift; + }; + A347441F2A4642300039D419 /* OneDSSwift */ = { + isa = XCSwiftPackageProductDependency; + productName = OneDSSwift; + }; +/* End XCSwiftPackageProductDependency section */ + }; + rootObject = 2711D2592A45438A000712BD /* Project object */; +} diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt index ec4f71b3b..678775307 100644 --- a/lib/CMakeLists.txt +++ b/lib/CMakeLists.txt @@ -381,8 +381,7 @@ else() # Also suppress warnings treated as errors in vendored code. target_compile_options(sqlite3_bundled PRIVATE -fno-finite-math-only -Wno-unused-function) - # Build zlib from bundled source. The upstream SIMD sources are not part of - # this tree, so no Android-specific stubs are needed. + # Build zlib from bundled source. add_library(zlib_bundled STATIC "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/adler32.c" "${CMAKE_CURRENT_SOURCE_DIR}/../zlib/compress.c" diff --git a/tests/functests/CMakeLists.txt b/tests/functests/CMakeLists.txt index d3eac21fe..d7109f8cb 100644 --- a/tests/functests/CMakeLists.txt +++ b/tests/functests/CMakeLists.txt @@ -82,9 +82,13 @@ else() set (SQLITE3_LIB "sqlite3") endif() - # Find zlib - find_package( ZLIB REQUIRED ) - include_directories( ${ZLIB_INCLUDE_DIRS} ) + if(TARGET zlib_bundled) + set(MATSDK_TEST_ZLIB zlib_bundled) + else() + find_package( ZLIB REQUIRED ) + set(MATSDK_TEST_ZLIB ZLIB::ZLIB) + include_directories( ${ZLIB_INCLUDE_DIRS} ) + endif() set (PLATFORM_LIBS "") # Add flags for obtaining system UUID via IOKit @@ -124,7 +128,7 @@ else() ${LIBGTEST} ${LIBGMOCK} mat - ZLIB::ZLIB + ${MATSDK_TEST_ZLIB} ${SQLITE3_LIB} ${PLATFORM_LIBS} dl) diff --git a/tests/unittests/CMakeLists.txt b/tests/unittests/CMakeLists.txt index 5ca5b8e77..73daa8f4c 100644 --- a/tests/unittests/CMakeLists.txt +++ b/tests/unittests/CMakeLists.txt @@ -144,9 +144,13 @@ else() set (SQLITE3_LIB "sqlite3") endif() - # Find zlib - find_package( ZLIB REQUIRED ) - include_directories( ${ZLIB_INCLUDE_DIRS} ) + if(TARGET zlib_bundled) + set(MATSDK_TEST_ZLIB zlib_bundled) + else() + find_package( ZLIB REQUIRED ) + set(MATSDK_TEST_ZLIB ZLIB::ZLIB) + include_directories( ${ZLIB_INCLUDE_DIRS} ) + endif() set (PLATFORM_LIBS "") # Add flags for obtaining system UUID via IOKit @@ -189,7 +193,7 @@ else() ${LIBGTEST} ${LIBGMOCK} mat - ZLIB::ZLIB + ${MATSDK_TEST_ZLIB} ${SQLITE3_LIB} ${PLATFORM_LIBS} dl) diff --git a/tests/vcpkg/README.md b/tests/vcpkg/README.md index c04de7fab..30294f185 100644 --- a/tests/vcpkg/README.md +++ b/tests/vcpkg/README.md @@ -77,17 +77,21 @@ The simulator mode uses the built-in vcpkg community triplet `arm64-ios-simulato ### Android (cross-compile) -**Requires:** Android NDK, cmake, VCPKG_ROOT set. The test targets -`android-28`, matching vcpkg's Android triplet default and its prebuilt -dependency ABI expectations. +**Requires:** Android NDK, cmake, ninja, VCPKG_ROOT set. The default test +targets `android-23`, matching this repo's Android `minSdk`. vcpkg's built-in +Android triplets default to `android-28`; use the API 28 form below to test +that default. ```bash -# Default: arm64-v8a +# Default: arm64-v8a, android-23 ./tests/vcpkg/test-vcpkg-android.sh # Other ABIs: ./tests/vcpkg/test-vcpkg-android.sh armeabi-v7a ./tests/vcpkg/test-vcpkg-android.sh x86_64 + +# vcpkg built-in Android triplet default: android-28 +./tests/vcpkg/test-vcpkg-android.sh arm64-v8a 28 ``` Set `ANDROID_NDK_HOME` if the script can't find your NDK automatically. Cross-compiled binary can be tested on device via `adb push`/`adb shell`. diff --git a/tests/vcpkg/test-vcpkg-android.sh b/tests/vcpkg/test-vcpkg-android.sh index 06f173f64..9a6d99811 100755 --- a/tests/vcpkg/test-vcpkg-android.sh +++ b/tests/vcpkg/test-vcpkg-android.sh @@ -1,34 +1,51 @@ #!/bin/bash # Test script: Verify mstelemetry vcpkg port for Android (cross-compile only) -# Usage: ./tests/vcpkg/test-vcpkg-android.sh [ABI] +# Usage: ./tests/vcpkg/test-vcpkg-android.sh [ABI] [API_LEVEL] # ABI: arm64-v8a (default), armeabi-v7a, x86_64, x86 -# Prerequisites: VCPKG_ROOT set, ANDROID_NDK_HOME set, cmake +# API_LEVEL: 23 (default), 28, or another level with a matching overlay triplet +# Prerequisites: VCPKG_ROOT set, ANDROID_NDK_HOME set, cmake, ninja set -e SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" REPO_ROOT="$(cd "${SCRIPT_DIR}/../.." && pwd)" OVERLAY_PORTS="${REPO_ROOT}/tools/ports" -# Android ABI (default: arm64-v8a) +# Android ABI/API (defaults match the repo's Android minSdk) ANDROID_ABI="${1:-arm64-v8a}" +ANDROID_API="${2:-23}" # Map ABI to vcpkg triplet case "${ANDROID_ABI}" in - arm64-v8a) TRIPLET="arm64-android" ;; - armeabi-v7a) TRIPLET="arm-neon-android" ;; - x86_64) TRIPLET="x64-android" ;; - x86) TRIPLET="x86-android" ;; + arm64-v8a) BASE_TRIPLET="arm64-android" ;; + armeabi-v7a) BASE_TRIPLET="arm-neon-android" ;; + x86_64) BASE_TRIPLET="x64-android" ;; + x86) BASE_TRIPLET="x86-android" ;; *) echo "ERROR: Unsupported ABI '${ANDROID_ABI}'. Use: arm64-v8a, armeabi-v7a, x86_64, x86" exit 1 ;; esac -BUILD_DIR="${SCRIPT_DIR}/build-android-${ANDROID_ABI}" +if [ "${ANDROID_API}" = "28" ]; then + TRIPLET="${BASE_TRIPLET}" + OVERLAY_TRIPLETS_ARGS=() +else + TRIPLET="${BASE_TRIPLET}-api${ANDROID_API}" + OVERLAY_TRIPLETS="${SCRIPT_DIR}/triplets" + if [ ! -f "${OVERLAY_TRIPLETS}/${TRIPLET}.cmake" ]; then + echo "ERROR: Android API ${ANDROID_API} requires overlay triplet ${TRIPLET}." + echo " Add ${OVERLAY_TRIPLETS}/${TRIPLET}.cmake or use API 23/28." + exit 1 + fi + OVERLAY_TRIPLETS_ARGS=(-DVCPKG_OVERLAY_TRIPLETS="${OVERLAY_TRIPLETS}") +fi + +BUILD_DIR="${SCRIPT_DIR}/build-android-${ANDROID_ABI}-api${ANDROID_API}" echo "=== MSTelemetry vcpkg port test (Android cross-compile) ===" echo "Repository root: ${REPO_ROOT}" echo "ABI: ${ANDROID_ABI}" +echo "Android API: ${ANDROID_API}" echo "Triplet: ${TRIPLET}" # Check prerequisites @@ -60,19 +77,26 @@ if [ -z "${ANDROID_NDK_HOME}" ] || [ ! -d "${ANDROID_NDK_HOME}" ]; then fi echo "NDK: ${ANDROID_NDK_HOME}" +if ! command -v ninja >/dev/null 2>&1; then + echo "ERROR: ninja is required for Android vcpkg tests." + echo " Using Ninja avoids host IDE generators selecting a different Android NDK." + exit 1 +fi + # Clean previous build rm -rf "${BUILD_DIR}" mkdir -p "${BUILD_DIR}" echo "" echo "--- Step 1: Configure (vcpkg installs deps automatically) ---" -cmake -S "${SCRIPT_DIR}" -B "${BUILD_DIR}/consumer" \ +cmake -G Ninja -S "${SCRIPT_DIR}" -B "${BUILD_DIR}/consumer" \ -DCMAKE_TOOLCHAIN_FILE="${VCPKG_TOOLCHAIN}" \ -DVCPKG_TARGET_TRIPLET="${TRIPLET}" \ -DVCPKG_OVERLAY_PORTS="${OVERLAY_PORTS}" \ + "${OVERLAY_TRIPLETS_ARGS[@]}" \ -DVCPKG_CHAINLOAD_TOOLCHAIN_FILE="${ANDROID_NDK_HOME}/build/cmake/android.toolchain.cmake" \ -DANDROID_ABI="${ANDROID_ABI}" \ - -DANDROID_PLATFORM=android-28 \ + -DANDROID_PLATFORM=android-${ANDROID_API} \ -DCMAKE_BUILD_TYPE=Release echo "" diff --git a/tests/vcpkg/triplets/arm-neon-android-api23.cmake b/tests/vcpkg/triplets/arm-neon-android-api23.cmake new file mode 100644 index 000000000..67a309fd1 --- /dev/null +++ b/tests/vcpkg/triplets/arm-neon-android-api23.cmake @@ -0,0 +1,7 @@ +set(VCPKG_TARGET_ARCHITECTURE arm) +set(VCPKG_CRT_LINKAGE dynamic) +set(VCPKG_LIBRARY_LINKAGE static) +set(VCPKG_CMAKE_SYSTEM_NAME Android) +set(VCPKG_CMAKE_SYSTEM_VERSION 23) +set(VCPKG_MAKE_BUILD_TRIPLET "--host=armv7a-linux-androideabi") +set(VCPKG_CMAKE_CONFIGURE_OPTIONS -DANDROID_ABI=armeabi-v7a -DANDROID_ARM_NEON=ON) diff --git a/tests/vcpkg/triplets/arm64-android-api23.cmake b/tests/vcpkg/triplets/arm64-android-api23.cmake new file mode 100644 index 000000000..8c0c349ce --- /dev/null +++ b/tests/vcpkg/triplets/arm64-android-api23.cmake @@ -0,0 +1,7 @@ +set(VCPKG_TARGET_ARCHITECTURE arm64) +set(VCPKG_CRT_LINKAGE dynamic) +set(VCPKG_LIBRARY_LINKAGE static) +set(VCPKG_CMAKE_SYSTEM_NAME Android) +set(VCPKG_CMAKE_SYSTEM_VERSION 23) +set(VCPKG_MAKE_BUILD_TRIPLET "--host=aarch64-linux-android") +set(VCPKG_CMAKE_CONFIGURE_OPTIONS -DANDROID_ABI=arm64-v8a) diff --git a/tests/vcpkg/triplets/x64-android-api23.cmake b/tests/vcpkg/triplets/x64-android-api23.cmake new file mode 100644 index 000000000..961435d64 --- /dev/null +++ b/tests/vcpkg/triplets/x64-android-api23.cmake @@ -0,0 +1,7 @@ +set(VCPKG_TARGET_ARCHITECTURE x64) +set(VCPKG_CRT_LINKAGE dynamic) +set(VCPKG_LIBRARY_LINKAGE static) +set(VCPKG_CMAKE_SYSTEM_NAME Android) +set(VCPKG_CMAKE_SYSTEM_VERSION 23) +set(VCPKG_MAKE_BUILD_TRIPLET "--host=x86_64-linux-android") +set(VCPKG_CMAKE_CONFIGURE_OPTIONS -DANDROID_ABI=x86_64) diff --git a/tests/vcpkg/triplets/x86-android-api23.cmake b/tests/vcpkg/triplets/x86-android-api23.cmake new file mode 100644 index 000000000..38e324c09 --- /dev/null +++ b/tests/vcpkg/triplets/x86-android-api23.cmake @@ -0,0 +1,7 @@ +set(VCPKG_TARGET_ARCHITECTURE x86) +set(VCPKG_CRT_LINKAGE dynamic) +set(VCPKG_LIBRARY_LINKAGE static) +set(VCPKG_CMAKE_SYSTEM_NAME Android) +set(VCPKG_CMAKE_SYSTEM_VERSION 23) +set(VCPKG_MAKE_BUILD_TRIPLET "--host=i686-linux-android") +set(VCPKG_CMAKE_CONFIGURE_OPTIONS -DANDROID_ABI=x86) diff --git a/tools/ports/mstelemetry/vcpkg.json b/tools/ports/mstelemetry/vcpkg.json index 7a346039e..40ef6fc35 100644 --- a/tools/ports/mstelemetry/vcpkg.json +++ b/tools/ports/mstelemetry/vcpkg.json @@ -16,7 +16,7 @@ "features": [ "openssl" ], - "platform": "!windows & !osx & !ios" + "platform": "linux | android" }, { "name": "vcpkg-cmake", @@ -28,4 +28,3 @@ } ] } - diff --git a/tools/vcpkg b/tools/vcpkg deleted file mode 160000 index 56bb24116..000000000 --- a/tools/vcpkg +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 56bb2411609227288b70117ead2c47585ba07713 From 4d4b51313ebceddcd42539f0427a0f5d668656e3 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sat, 6 Jun 2026 18:21:13 -0500 Subject: [PATCH 16/56] Refresh overlay port source after cleanup Point the overlay port at the source snapshot that removes the bundled vcpkg submodule, aligns Android validation with API 23, and keeps Apple/core dependency behavior consistent. Files changed: - tools/ports/mstelemetry/portfile.cmake Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index 6c51d3e2b..c0c415c06 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF 960379ab98b0e6d33348dd828c51a46c39b3a334 - SHA512 afd7ce6c2e3ffacacf69d0be3d3532f231dccdbc7b9de27bc90b42351464fef761ea0b3b26ef1830735f5369f2f40368446ef777507fbc8d7ed0927f4b6eb9fa + REF 7bf984fcd52019ef2e6ade2c05e3bf5e8f20faef + SHA512 5ece8842a0646239413e58bf74bdac755deb3c949414f64354396501a97396120794fe73d062d8c57a28048ef8b5b46ca316425a05e88b457f11ce4ea894e0b9 HEAD_REF main ) @@ -51,4 +51,3 @@ file(INSTALL "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_D # Install license vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE") - From df711cd122f8708c9c28717eef97d062011d2d00 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sun, 7 Jun 2026 00:44:53 -0500 Subject: [PATCH 17/56] Simplify MATSDK_INSTALL_DIR default in sample helper Seed MATSDK_INSTALL_DIR from the cache/environment and fall back to /usr/local, removing the intermediate _MATSDK_DEFAULT_INSTALL_DIR temporary while preserving -DMATSDK_INSTALL_DIR override precedence. Files changed: - examples/cmake/MSTelemetrySample.cmake Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- examples/cmake/MSTelemetrySample.cmake | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/examples/cmake/MSTelemetrySample.cmake b/examples/cmake/MSTelemetrySample.cmake index c2dab5ece..5a7eca8ab 100644 --- a/examples/cmake/MSTelemetrySample.cmake +++ b/examples/cmake/MSTelemetrySample.cmake @@ -1,9 +1,7 @@ -set(_MATSDK_DEFAULT_INSTALL_DIR "/usr/local") -if(NOT "$ENV{MATSDK_INSTALL_DIR}" STREQUAL "") - set(_MATSDK_DEFAULT_INSTALL_DIR "$ENV{MATSDK_INSTALL_DIR}") +set(MATSDK_INSTALL_DIR "$ENV{MATSDK_INSTALL_DIR}" CACHE PATH "MSTelemetry install prefix") +if(MATSDK_INSTALL_DIR STREQUAL "") + set(MATSDK_INSTALL_DIR "/usr/local" CACHE PATH "MSTelemetry install prefix" FORCE) endif() - -set(MATSDK_INSTALL_DIR "${_MATSDK_DEFAULT_INSTALL_DIR}" CACHE PATH "MSTelemetry install prefix") set(MATSDK_INCLUDE_DIR "${MATSDK_INSTALL_DIR}/include/mat" CACHE PATH "MSTelemetry public headers") set(MATSDK_LIB_DIR "${MATSDK_INSTALL_DIR}/lib" CACHE PATH "MSTelemetry library directory") From b093a7e2e269042a54e4d3d679cf573dc9777f87 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sun, 7 Jun 2026 00:45:48 -0500 Subject: [PATCH 18/56] Refresh overlay port source after sample helper cleanup Point the overlay port REF/SHA512 at the source snapshot that simplifies the MATSDK_INSTALL_DIR default in the sample helper. Files changed: - tools/ports/mstelemetry/portfile.cmake Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index c0c415c06..9f6185881 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF 7bf984fcd52019ef2e6ade2c05e3bf5e8f20faef - SHA512 5ece8842a0646239413e58bf74bdac755deb3c949414f64354396501a97396120794fe73d062d8c57a28048ef8b5b46ca316425a05e88b457f11ce4ea894e0b9 + REF df711cd122f8708c9c28717eef97d062011d2d00 + SHA512 e420de6793a4f53665d70e6b0ea8c570fbbeb65b64917f6c8a9b155f3b492b9c8ed2466b3d4d7852a9d18366a9a7ccf6fe2b45aff1bbb530aeeb032e917e65bd HEAD_REF main ) From 8d442f3d1b0bc5d2727c709713e5d42e1fc47233 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sun, 7 Jun 2026 14:12:52 -0500 Subject: [PATCH 19/56] Clarify vcpkg docs and curl config comment Document that the vcpkg port ships the core SDK only (no private lib/modules), correct the troubleshooting log-file paths/names to match real vcpkg buildtrees, and tighten the curl re-find comment in the package config to match MATSDK_NEEDS_CURL semantics. Files changed: - cmake/MSTelemetryConfig.cmake.in - docs/building-with-vcpkg.md Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- cmake/MSTelemetryConfig.cmake.in | 9 +++++---- docs/building-with-vcpkg.md | 32 ++++++++++++++++++++++++++------ 2 files changed, 31 insertions(+), 10 deletions(-) diff --git a/cmake/MSTelemetryConfig.cmake.in b/cmake/MSTelemetryConfig.cmake.in index f70f40c40..5cf00c560 100644 --- a/cmake/MSTelemetryConfig.cmake.in +++ b/cmake/MSTelemetryConfig.cmake.in @@ -7,10 +7,11 @@ find_dependency(unofficial-sqlite3 CONFIG) find_dependency(ZLIB) find_dependency(nlohmann_json CONFIG) -# Curl is needed on native POSIX HTTP builds (Linux and Android vcpkg; -# not Windows/iOS/macOS-with-Apple-HTTP). -# We capture the build-time decision as a boolean rather than re-deriving -# it, because the macOS BUILD_APPLE_HTTP edge case can't be inferred from +# Curl is re-found only when the SDK was built with the curl HTTP client +# (Linux, Android via vcpkg, and macOS built without Apple HTTP). +# Windows (WinInet), iOS, and macOS-with-Apple-HTTP do not link curl. +# We bake the build-time decision into a boolean rather than re-deriving it, +# because the macOS BUILD_APPLE_HTTP choice can't be inferred from # CMAKE_SYSTEM_NAME alone. if(@MATSDK_NEEDS_CURL@) find_dependency(CURL) diff --git a/docs/building-with-vcpkg.md b/docs/building-with-vcpkg.md index 950947596..2fdb4169c 100644 --- a/docs/building-with-vcpkg.md +++ b/docs/building-with-vcpkg.md @@ -2,6 +2,25 @@ [vcpkg](https://vcpkg.io/) is a Microsoft cross-platform open source C++ package manager. Onboarding instructions for Windows, Linux and Mac OS X [available here](https://docs.microsoft.com/en-us/cpp/build/vcpkg). This document assumes that the customer build system is already configured to use vcpkg ([getting started guide](https://learn.microsoft.com/en-us/vcpkg/get_started/overview)). 1DS C++ SDK maintainers provide a build recipe, `mstelemetry` port or CONTROL file for vcpkg. The mainline vcpkg repo is refreshed to point to latest stable open source release of 1DS C++ SDK. +## Scope: core SDK only (no private modules) + +The vcpkg port builds the **core** 1DS C++ SDK target `MSTelemetry::mat`. It +does **not** include the optional Microsoft-proprietary modules (Privacy Guard, +Sanitizer, ECS/EXP, Compliant-by-Default, AFD, CDS) that live in the private +`lib/modules` submodule. Official vcpkg source archives pin an immutable upstream +commit and do not fetch git submodules, and that submodule is an internal-only +repository, so the port cannot build them. The module-only public headers +(`CompliantByDefaultFilterApi.hpp`, `IAFDClient.hpp`, `ICdsFactory.hpp`, +`IECSClient.hpp`) are intentionally excluded from the installed headers. + +If you need the proprietary modules, build from a full source checkout with +submodules instead of consuming the SDK through vcpkg: + +```console +git clone --recurse-submodules https://github.com/microsoft/cpp_client_telemetry +# then build with the repo's own CMake/build scripts +``` + ## Quick Start ### Installing from the vcpkg registry @@ -173,15 +192,16 @@ cmake -DMATSDK_USE_VCPKG_DEPS=ON \ ## Troubleshooting -vcpkg build log files are created in -`${VCPKG_INSTALL_DIR}/buildtrees/mstelemetry/`. Review the following logs -if you encounter package installation failures: +vcpkg build log files are created under your vcpkg root in +`buildtrees/mstelemetry/` (or wherever `--x-buildtrees-root` points). Review +these logs if you encounter package installation failures: | File | Contents | | ---- | -------- | -| `build-out.log` | Build stdout (compiler output) | -| `build-err.log` | Build stderr (compiler errors/warnings) | -| `config-*.log` | CMake configure output | +| `config--out.log` / `config--err.log` | CMake configure stdout/stderr | +| `config---*.log` | Per-config configure detail (CMakeCache, CMakeConfigureLog, ninja) | +| `install---out.log` / `-err.log` | Build + install stdout/stderr (compiler output/errors) | +| `stdout-.log` | vcpkg per-triplet summary output | You can also pass `--debug` to `vcpkg install` for verbose diagnostics. From 5bba16f57688357ef1a1f0a43a0b6e196ca2b549 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sun, 7 Jun 2026 14:12:53 -0500 Subject: [PATCH 20/56] Fix Apple sample and Android legacy test dependency wiring Make the Swift sample's system libs/frameworks (libz, libsqlite3, SystemConfiguration, Network) SDKROOT-relative instead of pinned to a specific SDK version, so they resolve across iOS device/simulator/macOS. In func/unit tests, prefer the SDK's bundled sqlite3 target when present (Android legacy build has no NDK system sqlite3 lib or header), and link curl only when the SDK uses the curl HTTP client (MATSDK_NEEDS_CURL), since the tests don't use curl directly and Android legacy uses HttpClient_Android. Files changed: - examples/swift/SampleXcodeApp/SwiftWrapperApp.xcodeproj/project.pbxproj - tests/functests/CMakeLists.txt - tests/unittests/CMakeLists.txt Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- .../SwiftWrapperApp.xcodeproj/project.pbxproj | 6 +++--- tests/functests/CMakeLists.txt | 13 ++++++++++--- tests/unittests/CMakeLists.txt | 13 ++++++++++--- 3 files changed, 23 insertions(+), 9 deletions(-) diff --git a/examples/swift/SampleXcodeApp/SwiftWrapperApp.xcodeproj/project.pbxproj b/examples/swift/SampleXcodeApp/SwiftWrapperApp.xcodeproj/project.pbxproj index 35c80a526..4a061510b 100644 --- a/examples/swift/SampleXcodeApp/SwiftWrapperApp.xcodeproj/project.pbxproj +++ b/examples/swift/SampleXcodeApp/SwiftWrapperApp.xcodeproj/project.pbxproj @@ -28,9 +28,9 @@ 277E76FF2A45FE4D004A3A8F /* swift */ = {isa = PBXFileReference; lastKnownFileType = wrapper; name = swift; path = ../../../wrappers/swift; sourceTree = ""; }; A34744232A4643B20039D419 /* libmat.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libmat.a; path = "$(MATSDK_INSTALL_DIR)/lib/libmat.a"; sourceTree = ""; }; A34744252A4643FE0039D419 /* libsqlite3.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libsqlite3.tbd; path = usr/lib/libsqlite3.tbd; sourceTree = SDKROOT; }; - A34744272A46440F0039D419 /* SystemConfiguration.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SystemConfiguration.framework; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk/System/Library/Frameworks/SystemConfiguration.framework; sourceTree = DEVELOPER_DIR; }; - A34744292A46441A0039D419 /* Network.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Network.framework; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk/System/Library/Frameworks/Network.framework; sourceTree = DEVELOPER_DIR; }; - A347442B2A46442C0039D419 /* libz.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libz.tbd; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk/usr/lib/libz.tbd; sourceTree = DEVELOPER_DIR; }; + A34744272A46440F0039D419 /* SystemConfiguration.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SystemConfiguration.framework; path = System/Library/Frameworks/SystemConfiguration.framework; sourceTree = SDKROOT; }; + A34744292A46441A0039D419 /* Network.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Network.framework; path = System/Library/Frameworks/Network.framework; sourceTree = SDKROOT; }; + A347442B2A46442C0039D419 /* libz.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libz.tbd; path = usr/lib/libz.tbd; sourceTree = SDKROOT; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ diff --git a/tests/functests/CMakeLists.txt b/tests/functests/CMakeLists.txt index d7109f8cb..92046fdfc 100644 --- a/tests/functests/CMakeLists.txt +++ b/tests/functests/CMakeLists.txt @@ -73,8 +73,12 @@ if(PAL_IMPLEMENTATION STREQUAL "WIN32") ) else() - # Prefer linking to more recent local sqlite3 - if(EXISTS "/usr/local/lib/libsqlite3.a") + # Prefer the SDK's bundled sqlite3 when present (e.g. the Android legacy + # build, where the NDK has no system sqlite3), then a more recent local + # sqlite3, otherwise the system library. + if(TARGET sqlite3_bundled) + set (SQLITE3_LIB sqlite3_bundled) + elseif(EXISTS "/usr/local/lib/libsqlite3.a") set (SQLITE3_LIB "/usr/local/lib/libsqlite3.a") elseif(EXISTS "/usr/local/opt/sqlite/lib/libsqlite3.a") set (SQLITE3_LIB "/usr/local/opt/sqlite/lib/libsqlite3.a") @@ -133,7 +137,10 @@ else() ${PLATFORM_LIBS} dl) - if(NOT BUILD_IOS) + # Link curl only when the SDK actually uses the curl HTTP client (Linux, and + # macOS without Apple HTTP). The tests don't use curl directly, and on the + # Android legacy path mat uses HttpClient_Android (no system curl in the NDK). + if(NOT BUILD_IOS AND MATSDK_NEEDS_CURL) target_link_libraries(FuncTests curl) endif() diff --git a/tests/unittests/CMakeLists.txt b/tests/unittests/CMakeLists.txt index 73daa8f4c..25b52731f 100644 --- a/tests/unittests/CMakeLists.txt +++ b/tests/unittests/CMakeLists.txt @@ -132,8 +132,12 @@ if(PAL_IMPLEMENTATION STREQUAL "WIN32") ) else() - # Prefer linking to more recent local sqlite3 - if(EXISTS "/usr/local/lib/libsqlite3.a") + # Prefer the SDK's bundled sqlite3 when present (e.g. the Android legacy + # build, where the NDK has no system sqlite3), then a more recent local + # sqlite3, otherwise the system library. + if(TARGET sqlite3_bundled) + set (SQLITE3_LIB sqlite3_bundled) + elseif(EXISTS "/usr/local/lib/libsqlite3.a") set (SQLITE3_LIB "/usr/local/lib/libsqlite3.a") elseif(EXISTS "/usr/local/opt/sqlite/lib/libsqlite3.a") set (SQLITE3_LIB "/usr/local/opt/sqlite/lib/libsqlite3.a") @@ -198,7 +202,10 @@ else() ${PLATFORM_LIBS} dl) - if(NOT BUILD_IOS) + # Link curl only when the SDK actually uses the curl HTTP client (Linux, and + # macOS without Apple HTTP). The tests don't use curl directly, and on the + # Android legacy path mat uses HttpClient_Android (no system curl in the NDK). + if(NOT BUILD_IOS AND MATSDK_NEEDS_CURL) target_link_libraries(UnitTests curl) endif() From dc10473a944ace8417afe0bbd12b76d8a02904f8 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sun, 7 Jun 2026 14:14:17 -0500 Subject: [PATCH 21/56] Refresh overlay port source after review cleanups Point the overlay port REF/SHA512 at the source snapshot that includes the doc/scope clarifications, SDKROOT-relative Apple sample libs, and Android legacy test dependency fixes (bundled sqlite3 + guarded curl). Files changed: - tools/ports/mstelemetry/portfile.cmake Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index 9f6185881..1d7b88e20 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF df711cd122f8708c9c28717eef97d062011d2d00 - SHA512 e420de6793a4f53665d70e6b0ea8c570fbbeb65b64917f6c8a9b155f3b492b9c8ed2466b3d4d7852a9d18366a9a7ccf6fe2b45aff1bbb530aeeb032e917e65bd + REF 5bba16f57688357ef1a1f0a43a0b6e196ca2b549 + SHA512 8da40a545d3b06bb856d450f83a47b1c6249783eb927c63c4519a808419c8dc3aed363c42307c808b24a4d222649edca0714c660dc752789354fb4572576a7c5 HEAD_REF main ) From 1e600c5eaa4e84bf0117fc1e2b98055872a4bb0d Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sun, 7 Jun 2026 14:16:57 -0500 Subject: [PATCH 22/56] Make functests-ios system libs/frameworks SDKROOT-relative Replace the MacOSX10.15.sdk-pinned DEVELOPER_DIR paths for libsqlite3.tbd, libz.tbd, SystemConfiguration.framework, and Network.framework with SDKROOT-relative references, matching the existing UIKit.framework entry so they resolve against the active SDK instead of a fixed version. Files changed: - tests/functests/functests-ios.xcodeproj/project.pbxproj Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tests/functests/functests-ios.xcodeproj/project.pbxproj | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/functests/functests-ios.xcodeproj/project.pbxproj b/tests/functests/functests-ios.xcodeproj/project.pbxproj index e6d00eb35..1f2819ddf 100644 --- a/tests/functests/functests-ios.xcodeproj/project.pbxproj +++ b/tests/functests/functests-ios.xcodeproj/project.pbxproj @@ -61,13 +61,13 @@ 430102FD235E67C900836D50 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 43010305235E682400836D50 /* libFuncTests.a */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.objfile"; name = libFuncTests.a; path = ../../../out/tests/functests/libFuncTests.a; sourceTree = ""; }; 43010307235E699400836D50 /* libmat.a */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.objfile"; name = libmat.a; path = ../../../out/lib/libmat.a; sourceTree = ""; }; - 4301030A235E6A8300836D50 /* libsqlite3.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libsqlite3.tbd; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/usr/lib/libsqlite3.tbd; sourceTree = DEVELOPER_DIR; }; - 4301030C235E6A8B00836D50 /* libz.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libz.tbd; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/usr/lib/libz.tbd; sourceTree = DEVELOPER_DIR; }; - 4301030E235E6AA800836D50 /* SystemConfiguration.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SystemConfiguration.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/SystemConfiguration.framework; sourceTree = DEVELOPER_DIR; }; + 4301030A235E6A8300836D50 /* libsqlite3.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libsqlite3.tbd; path = usr/lib/libsqlite3.tbd; sourceTree = SDKROOT; }; + 4301030C235E6A8B00836D50 /* libz.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libz.tbd; path = usr/lib/libz.tbd; sourceTree = SDKROOT; }; + 4301030E235E6AA800836D50 /* SystemConfiguration.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SystemConfiguration.framework; path = System/Library/Frameworks/SystemConfiguration.framework; sourceTree = SDKROOT; }; 43010310235E6AB000836D50 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; }; 43010312235E6AE200836D50 /* libgmock.a */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.objfile"; name = libgmock.a; path = ../../../third_party/googletest/build/lib/libgmock.a; sourceTree = ""; }; 43010314235E6B1600836D50 /* libgtest.a */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.objfile"; name = libgtest.a; path = ../../../third_party/googletest/build/lib/libgtest.a; sourceTree = ""; }; - FE51D93E243ED8D200E54890 /* Network.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Network.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/Network.framework; sourceTree = DEVELOPER_DIR; }; + FE51D93E243ED8D200E54890 /* Network.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Network.framework; path = System/Library/Frameworks/Network.framework; sourceTree = SDKROOT; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ From c2373dbb4249983da6a49e4215586e4b53345a03 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sun, 7 Jun 2026 14:17:54 -0500 Subject: [PATCH 23/56] Refresh overlay port source after functests-ios SDKROOT fix Point the overlay port REF/SHA512 at the source snapshot that makes the functests-ios Xcode system libs/frameworks SDKROOT-relative. Files changed: - tools/ports/mstelemetry/portfile.cmake Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index 1d7b88e20..a1e71d46f 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF 5bba16f57688357ef1a1f0a43a0b6e196ca2b549 - SHA512 8da40a545d3b06bb856d450f83a47b1c6249783eb927c63c4519a808419c8dc3aed363c42307c808b24a4d222649edca0714c660dc752789354fb4572576a7c5 + REF 1e600c5eaa4e84bf0117fc1e2b98055872a4bb0d + SHA512 d70b7afc4b90f920ae6b914dc3c5d9ad61e26e9e36c7a8d999f824b7e38c33d88cf9ec3769ef20a160e0894d54cdf1cc5fceed69fe8fc5627999f404e4f99510 HEAD_REF main ) From 9b16a8169fc9f12100c73d797c820eb7cd2cf53b Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sun, 7 Jun 2026 18:09:34 -0500 Subject: [PATCH 24/56] Document migration from the previous module-overlay port Add an explicit migration note: the old overlay port built from a local --recurse-submodules checkout (including private lib/modules), but the port now always builds the core SDK from a pinned upstream archive. Map the old --head/overlay and response-file commands to the new core-only install, and point module users to the full source build. Files changed: - docs/building-with-vcpkg.md Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- docs/building-with-vcpkg.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/docs/building-with-vcpkg.md b/docs/building-with-vcpkg.md index 2fdb4169c..ac4f9a6ac 100644 --- a/docs/building-with-vcpkg.md +++ b/docs/building-with-vcpkg.md @@ -21,6 +21,23 @@ git clone --recurse-submodules https://github.com/microsoft/cpp_client_telemetry # then build with the repo's own CMake/build scripts ``` +### Migrating from the previous overlay port + +Earlier versions of this overlay port detected a local `--recurse-submodules` +checkout and built the SDK from it via `build.sh`/`install.sh` (or MSBuild on +Windows), which **included** the private `lib/modules` submodules. That behavior +has been removed. The port now always builds the **core** SDK from a pinned, +immutable upstream archive. + +| Before | Now | +| ------ | --- | +| `vcpkg install --head --overlay-ports=tools/ports mstelemetry` (built from your local checkout, with private submodules) | `vcpkg install mstelemetry` (or `--overlay-ports=tools/ports`) builds the core SDK only, from a pinned commit | +| `vcpkg install @tools/ports/mstelemetry/response_file_linux.txt` / `response_file_mac.txt` | Removed — use a standard triplet (see [Platform-Specific Instructions](#platform-specific-instructions)) | + +If you were relying on the old command to get the proprietary modules, switch to +the full source build above (`git clone --recurse-submodules …`); the modules are +not available through the vcpkg port. + ## Quick Start ### Installing from the vcpkg registry From 6a656a5ebdcf3105ab125a9a1c034b915548970f Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sun, 7 Jun 2026 18:10:25 -0500 Subject: [PATCH 25/56] Refresh overlay port source after migration-note docs Point the overlay port REF/SHA512 at the source snapshot that adds the previous-overlay-port migration note to the vcpkg docs. Files changed: - tools/ports/mstelemetry/portfile.cmake Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index a1e71d46f..5947419b8 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF 1e600c5eaa4e84bf0117fc1e2b98055872a4bb0d - SHA512 d70b7afc4b90f920ae6b914dc3c5d9ad61e26e9e36c7a8d999f824b7e38c33d88cf9ec3769ef20a160e0894d54cdf1cc5fceed69fe8fc5627999f404e4f99510 + REF 9b16a8169fc9f12100c73d797c820eb7cd2cf53b + SHA512 9512ce0ff2480628f8b7e1111c5bd77140f3e2a1dce8ee9395b3e0579e71a10536ebdfdb64bdc1cb5f5cc25258b2f4d794bdc647b2fbb6e06470455160143400 HEAD_REF main ) From 88c1302f6c2fea67f44bc10677c94581f28b5cfa Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sun, 7 Jun 2026 19:56:04 -0500 Subject: [PATCH 26/56] Fix Android API 23 consumer docs and trim source tarball Replace the misleading API 23 install command (which pointed --overlay-triplets at the repo's export-ignored tests/vcpkg/triplets) with self-contained guidance: show the custom triplet content and have consumers place it in their own overlay-triplets directory. Extend .gitattributes export-ignore to docs/, examples/, and all of tests/ (broadened from tests/vcpkg/). The port build never uses these, so excluding them keeps the source tarball to what's needed to build and stops doc/example/test changes from churning the portfile SHA512. Files changed: - .gitattributes - docs/building-with-vcpkg.md Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- .gitattributes | 12 ++++++++---- docs/building-with-vcpkg.md | 24 +++++++++++++++++++----- 2 files changed, 27 insertions(+), 9 deletions(-) diff --git a/.gitattributes b/.gitattributes index 429fefd5c..fb79ca88c 100644 --- a/.gitattributes +++ b/.gitattributes @@ -87,11 +87,15 @@ GNUmakefile text *.xml text *.cfg text -## Exclude vcpkg port and test scaffolding from GitHub tarballs. -## This avoids a chicken-and-egg problem: the portfile contains a SHA512 -## of the tarball, so changes to the portfile must not change the tarball. +## Keep GitHub source tarballs limited to what's needed to build the SDK. +## The vcpkg portfile records a SHA512 of the tarball, so excluding content the +## build never uses (the port files themselves, tests, docs, examples) both +## solves the portfile chicken-and-egg and avoids churning that hash when those +## non-build files change. tools/ports/ export-ignore -tests/vcpkg/ export-ignore +tests/ export-ignore +docs/ export-ignore +examples/ export-ignore ## Self-reference =) .gitignore text diff --git a/docs/building-with-vcpkg.md b/docs/building-with-vcpkg.md index ac4f9a6ac..8d4637d3e 100644 --- a/docs/building-with-vcpkg.md +++ b/docs/building-with-vcpkg.md @@ -130,19 +130,33 @@ vcpkg install mstelemetry --triplet=arm64-android ``` This repo's Android build declares `minSdk 23`. To build the SDK and all -vcpkg dependencies for API 23, use a custom triplet that sets -`VCPKG_CMAKE_SYSTEM_VERSION` to `23`. The integration tests include API 23 -triplet examples: +vcpkg dependencies for API 23, create a custom triplet in your **own** +overlay-triplets directory that sets `VCPKG_CMAKE_SYSTEM_VERSION` to `23`. For +example, save the following as `/arm64-android-api23.cmake`: + +```cmake +set(VCPKG_TARGET_ARCHITECTURE arm64) +set(VCPKG_CRT_LINKAGE dynamic) +set(VCPKG_LIBRARY_LINKAGE static) +set(VCPKG_CMAKE_SYSTEM_NAME Android) +set(VCPKG_CMAKE_SYSTEM_VERSION 23) +set(VCPKG_MAKE_BUILD_TRIPLET "--host=aarch64-linux-android") +set(VCPKG_CMAKE_CONFIGURE_OPTIONS -DANDROID_ABI=arm64-v8a) +``` + +Then install, pointing `--overlay-triplets` at that directory: ```bash vcpkg install mstelemetry \ --triplet=arm64-android-api23 \ - --overlay-triplets=tests/vcpkg/triplets + --overlay-triplets= ``` Do not mix dependencies built with the default API 28 triplets into an API 23 consumer binary; build the whole dependency graph with the same Android API -triplet. +triplet. (For reference, this repo's CI validates equivalent API 23 triplets +under `tests/vcpkg/triplets`, but those are test scaffolding and are not part of +the published package.) Supported triplets: `arm64-android`, `arm-neon-android`, `x64-android`, `x86-android`. From 9541615bdffc727c09da4db2ff07aaa520c29493 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sun, 7 Jun 2026 20:04:27 -0500 Subject: [PATCH 27/56] Refresh overlay port source after docs fix and tarball trim Point the overlay port REF/SHA512 at the source snapshot that fixes the Android API 23 consumer docs and extends export-ignore (docs/, examples/, tests/). Validated: the trimmed tarball downloads with matching SHA512, builds mstelemetry on x64-windows-static, and the consumer test passes 8/8. Files changed: - tools/ports/mstelemetry/portfile.cmake Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index 5947419b8..59ede09a4 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF 9b16a8169fc9f12100c73d797c820eb7cd2cf53b - SHA512 9512ce0ff2480628f8b7e1111c5bd77140f3e2a1dce8ee9395b3e0579e71a10536ebdfdb64bdc1cb5f5cc25258b2f4d794bdc647b2fbb6e06470455160143400 + REF 88c1302f6c2fea67f44bc10677c94581f28b5cfa + SHA512 91d405f6d9504fcf529d0bdd045c01f06953e9309f657e92a303156baff8ada8065748b9a92e0c5f1ac47543e9ff77bcc22d856f8d637e990939bccc7e9c27bc HEAD_REF main ) From 8ad5e13001e34b9cf3b6d89d6b028ee8e9f86273 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Sun, 7 Jun 2026 21:43:29 -0500 Subject: [PATCH 28/56] Reframe vcpkg docs to describe the port, not the change Replace the 'Scope: core SDK only (no private modules)' banner and its internal rationale with a short, neutral statement of what the port provides, and demote the previous-overlay migration details to a brief note near the end. Acknowledges what changed without leading the doc with it. No portfile refresh: docs/ is export-ignored, so this does not change the source tarball. Files changed: - docs/building-with-vcpkg.md Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- docs/building-with-vcpkg.md | 43 +++++++++++-------------------------- 1 file changed, 13 insertions(+), 30 deletions(-) diff --git a/docs/building-with-vcpkg.md b/docs/building-with-vcpkg.md index 8d4637d3e..804fc1925 100644 --- a/docs/building-with-vcpkg.md +++ b/docs/building-with-vcpkg.md @@ -2,42 +2,16 @@ [vcpkg](https://vcpkg.io/) is a Microsoft cross-platform open source C++ package manager. Onboarding instructions for Windows, Linux and Mac OS X [available here](https://docs.microsoft.com/en-us/cpp/build/vcpkg). This document assumes that the customer build system is already configured to use vcpkg ([getting started guide](https://learn.microsoft.com/en-us/vcpkg/get_started/overview)). 1DS C++ SDK maintainers provide a build recipe, `mstelemetry` port or CONTROL file for vcpkg. The mainline vcpkg repo is refreshed to point to latest stable open source release of 1DS C++ SDK. -## Scope: core SDK only (no private modules) - -The vcpkg port builds the **core** 1DS C++ SDK target `MSTelemetry::mat`. It -does **not** include the optional Microsoft-proprietary modules (Privacy Guard, -Sanitizer, ECS/EXP, Compliant-by-Default, AFD, CDS) that live in the private -`lib/modules` submodule. Official vcpkg source archives pin an immutable upstream -commit and do not fetch git submodules, and that submodule is an internal-only -repository, so the port cannot build them. The module-only public headers -(`CompliantByDefaultFilterApi.hpp`, `IAFDClient.hpp`, `ICdsFactory.hpp`, -`IECSClient.hpp`) are intentionally excluded from the installed headers. - -If you need the proprietary modules, build from a full source checkout with -submodules instead of consuming the SDK through vcpkg: +The port provides the core SDK — the `MSTelemetry::mat` target and its public +C++ headers. The optional Microsoft-proprietary modules (Privacy Guard, +Sanitizer, ECS/EXP, Compliant-by-Default, AFD, CDS) are not part of the public +package; to use those, build from a source checkout with submodules: ```console git clone --recurse-submodules https://github.com/microsoft/cpp_client_telemetry # then build with the repo's own CMake/build scripts ``` -### Migrating from the previous overlay port - -Earlier versions of this overlay port detected a local `--recurse-submodules` -checkout and built the SDK from it via `build.sh`/`install.sh` (or MSBuild on -Windows), which **included** the private `lib/modules` submodules. That behavior -has been removed. The port now always builds the **core** SDK from a pinned, -immutable upstream archive. - -| Before | Now | -| ------ | --- | -| `vcpkg install --head --overlay-ports=tools/ports mstelemetry` (built from your local checkout, with private submodules) | `vcpkg install mstelemetry` (or `--overlay-ports=tools/ports`) builds the core SDK only, from a pinned commit | -| `vcpkg install @tools/ports/mstelemetry/response_file_linux.txt` / `response_file_mac.txt` | Removed — use a standard triplet (see [Platform-Specific Instructions](#platform-specific-instructions)) | - -If you were relying on the old command to get the proprietary modules, switch to -the full source build above (`git clone --recurse-submodules …`); the modules are -not available through the vcpkg port. - ## Quick Start ### Installing from the vcpkg registry @@ -221,6 +195,15 @@ cmake -DMATSDK_USE_VCPKG_DEPS=ON \ .. ``` +## Migrating from the older overlay port + +Older revisions of this overlay port could build the SDK with the private +`lib/modules` submodules from a local `--recurse-submodules` checkout. The port +now builds the core SDK from a pinned upstream commit, and the +`response_file_*.txt` shortcuts have been removed (use a standard triplet). If +you relied on the old flow for the proprietary modules, build from a +`--recurse-submodules` source checkout instead. + ## Troubleshooting vcpkg build log files are created under your vcpkg root in From 13b5e7d424b76eade38c56e1f0163ba4381c059a Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 12:11:15 -0500 Subject: [PATCH 29/56] Remove duplicated Apple frameworks from CMake example link lines MATSDK_SAMPLE_PLATFORM_LIBS (from MSTelemetrySample.cmake) already supplies the SDK's required Apple frameworks, so the per-example Darwin PLATFORM_LIBS blocks were re-listing the same frameworks on the link line. Drop the redundant frameworks; keep only each example's own extras (cocoa-app's AppKit, the armv7l -latomic case). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- examples/c/SampleC-Guest/CMakeLists.txt | 5 +---- examples/cpp/EventSender/CMakeLists.txt | 5 +---- examples/cpp/MacProxy/CMakeLists.txt | 5 +---- examples/cpp/SampleCpp/CMakeLists.txt | 5 +---- examples/cpp/SampleCppMini/CMakeLists.txt | 5 +---- examples/objc/cocoa-app/CMakeLists.txt | 5 +++-- 6 files changed, 8 insertions(+), 22 deletions(-) diff --git a/examples/c/SampleC-Guest/CMakeLists.txt b/examples/c/SampleC-Guest/CMakeLists.txt index 2d4a4e368..d99adc010 100644 --- a/examples/c/SampleC-Guest/CMakeLists.txt +++ b/examples/c/SampleC-Guest/CMakeLists.txt @@ -19,9 +19,6 @@ add_executable(SampleC-Guest main.cpp demo.c) source_group(" " REGULAR_EXPRESSION "") set (PLATFORM_LIBS "") -# Add flags for obtaining system UUID via IOKit -if (CMAKE_SYSTEM_NAME STREQUAL "Darwin") -set (PLATFORM_LIBS "-framework CoreFoundation -framework IOKit") -endif() +# The 1DS SDK's required Apple frameworks are provided by MATSDK_SAMPLE_PLATFORM_LIBS. target_link_libraries(SampleC-Guest ${MATSDK_LIBRARY} curl z ${CMAKE_THREAD_LIBS_INIT} ${MATSDK_SQLITE3_LIB} ${MATSDK_SAMPLE_PLATFORM_LIBS} ${PLATFORM_LIBS} dl) diff --git a/examples/cpp/EventSender/CMakeLists.txt b/examples/cpp/EventSender/CMakeLists.txt index 615b96ffe..e9036f539 100644 --- a/examples/cpp/EventSender/CMakeLists.txt +++ b/examples/cpp/EventSender/CMakeLists.txt @@ -19,10 +19,7 @@ add_executable(EventSender EventSender.cpp) source_group(" " REGULAR_EXPRESSION "") set (PLATFORM_LIBS "") -# Add flags for obtaining system UUID via IOKit -if (CMAKE_SYSTEM_NAME STREQUAL "Darwin") -set (PLATFORM_LIBS "-framework CoreFoundation -framework IOKit") -endif() +# The 1DS SDK's required Apple frameworks are provided by MATSDK_SAMPLE_PLATFORM_LIBS. #tcmalloc turned off by default #target_link_libraries(EventSender ${MAT_SDK_LIB}/libmat.a curl z ${CMAKE_THREAD_LIBS_INIT} ${SQLITE3_LIB} dl tcmalloc) diff --git a/examples/cpp/MacProxy/CMakeLists.txt b/examples/cpp/MacProxy/CMakeLists.txt index 93f090fae..18e753333 100644 --- a/examples/cpp/MacProxy/CMakeLists.txt +++ b/examples/cpp/MacProxy/CMakeLists.txt @@ -19,10 +19,7 @@ add_executable(MacProxy main.cpp HttpEventListener.cpp) source_group(" " REGULAR_EXPRESSION "") set (PLATFORM_LIBS "") -# Add flags for obtaining system UUID via IOKit -if (CMAKE_SYSTEM_NAME STREQUAL "Darwin") - set (PLATFORM_LIBS "-framework CoreFoundation -framework IOKit -framework CFNetwork") -endif() +# The 1DS SDK's required Apple frameworks are provided by MATSDK_SAMPLE_PLATFORM_LIBS. # Raspberry Pi 4 with gcc-8 on ARMv7l requires -latomic if (CMAKE_SYSTEM_PROCESSOR STREQUAL "armv7l") diff --git a/examples/cpp/SampleCpp/CMakeLists.txt b/examples/cpp/SampleCpp/CMakeLists.txt index b1bf8e419..f5c2084c3 100644 --- a/examples/cpp/SampleCpp/CMakeLists.txt +++ b/examples/cpp/SampleCpp/CMakeLists.txt @@ -19,10 +19,7 @@ add_executable(SampleCpp main.cpp DebugCallback.cpp demo.c) source_group(" " REGULAR_EXPRESSION "") set (PLATFORM_LIBS "") -# Add flags for obtaining system UUID via IOKit -if (CMAKE_SYSTEM_NAME STREQUAL "Darwin") - set (PLATFORM_LIBS "-framework CoreFoundation -framework IOKit -framework Foundation -framework SystemConfiguration -framework Network") -endif() +# The 1DS SDK's required Apple frameworks are provided by MATSDK_SAMPLE_PLATFORM_LIBS. # Raspberry Pi 4 with gcc-8 on ARMv7l requires -latomic if (CMAKE_SYSTEM_PROCESSOR STREQUAL "armv7l") diff --git a/examples/cpp/SampleCppMini/CMakeLists.txt b/examples/cpp/SampleCppMini/CMakeLists.txt index 665237000..26a84f30b 100644 --- a/examples/cpp/SampleCppMini/CMakeLists.txt +++ b/examples/cpp/SampleCppMini/CMakeLists.txt @@ -19,10 +19,7 @@ add_executable(SampleCppMini main.cpp demo.c) source_group(" " REGULAR_EXPRESSION "") set (PLATFORM_LIBS "") -# Add flags for obtaining system UUID via IOKit -if (CMAKE_SYSTEM_NAME STREQUAL "Darwin") -set (PLATFORM_LIBS "-framework CoreFoundation -framework IOKit") -endif() +# The 1DS SDK's required Apple frameworks are provided by MATSDK_SAMPLE_PLATFORM_LIBS. #tcmalloc turned off by default #target_link_libraries(SampleCppMini ${MAT_SDK_LIB}/libmat.a curl z ${CMAKE_THREAD_LIBS_INIT} ${SQLITE3_LIB} dl tcmalloc) diff --git a/examples/objc/cocoa-app/CMakeLists.txt b/examples/objc/cocoa-app/CMakeLists.txt index 1ee932715..67a6e085c 100644 --- a/examples/objc/cocoa-app/CMakeLists.txt +++ b/examples/objc/cocoa-app/CMakeLists.txt @@ -12,9 +12,10 @@ find_package (Threads) include_directories(. ${MATSDK_SAMPLE_INCLUDE_DIRS}) set (PLATFORM_LIBS "") -# Add flags for obtaining system UUID via IOKit +# AppKit is required by this Cocoa sample app itself; the SDK's Apple frameworks +# are provided by MATSDK_SAMPLE_PLATFORM_LIBS. if (CMAKE_SYSTEM_NAME STREQUAL "Darwin") -set (PLATFORM_LIBS "-framework Foundation -framework CoreFoundation -framework IOKit -framework AppKit") +set (PLATFORM_LIBS "-framework AppKit") endif() From b980398669cf567a9593b191f10efd01be6b174c Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 12:24:22 -0500 Subject: [PATCH 30/56] Drop unused PLATFORM_LIBS from examples that have no extra libs After centralizing the SDK's Apple frameworks in MATSDK_SAMPLE_PLATFORM_LIBS, SampleC-Guest, EventSender and SampleCppMini no longer put anything in PLATFORM_LIBS, so the empty variable and its link-line reference were dead. Remove them. SampleCpp/MacProxy (armv7l -latomic) and cocoa-app (AppKit) still use PLATFORM_LIBS and keep it. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- examples/c/SampleC-Guest/CMakeLists.txt | 3 +-- examples/cpp/EventSender/CMakeLists.txt | 3 +-- examples/cpp/SampleCppMini/CMakeLists.txt | 3 +-- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/examples/c/SampleC-Guest/CMakeLists.txt b/examples/c/SampleC-Guest/CMakeLists.txt index d99adc010..18573f8af 100644 --- a/examples/c/SampleC-Guest/CMakeLists.txt +++ b/examples/c/SampleC-Guest/CMakeLists.txt @@ -18,7 +18,6 @@ include_directories(. ${MATSDK_SAMPLE_INCLUDE_DIRS}) add_executable(SampleC-Guest main.cpp demo.c) source_group(" " REGULAR_EXPRESSION "") -set (PLATFORM_LIBS "") # The 1DS SDK's required Apple frameworks are provided by MATSDK_SAMPLE_PLATFORM_LIBS. -target_link_libraries(SampleC-Guest ${MATSDK_LIBRARY} curl z ${CMAKE_THREAD_LIBS_INIT} ${MATSDK_SQLITE3_LIB} ${MATSDK_SAMPLE_PLATFORM_LIBS} ${PLATFORM_LIBS} dl) +target_link_libraries(SampleC-Guest ${MATSDK_LIBRARY} curl z ${CMAKE_THREAD_LIBS_INIT} ${MATSDK_SQLITE3_LIB} ${MATSDK_SAMPLE_PLATFORM_LIBS} dl) diff --git a/examples/cpp/EventSender/CMakeLists.txt b/examples/cpp/EventSender/CMakeLists.txt index e9036f539..98f1ca512 100644 --- a/examples/cpp/EventSender/CMakeLists.txt +++ b/examples/cpp/EventSender/CMakeLists.txt @@ -18,10 +18,9 @@ include_directories(. ${MATSDK_SAMPLE_INCLUDE_DIRS}) add_executable(EventSender EventSender.cpp) source_group(" " REGULAR_EXPRESSION "") -set (PLATFORM_LIBS "") # The 1DS SDK's required Apple frameworks are provided by MATSDK_SAMPLE_PLATFORM_LIBS. #tcmalloc turned off by default #target_link_libraries(EventSender ${MAT_SDK_LIB}/libmat.a curl z ${CMAKE_THREAD_LIBS_INIT} ${SQLITE3_LIB} dl tcmalloc) -target_link_libraries(EventSender ${MATSDK_LIBRARY} curl z ${CMAKE_THREAD_LIBS_INIT} ${MATSDK_SQLITE3_LIB} ${MATSDK_SAMPLE_PLATFORM_LIBS} ${PLATFORM_LIBS} dl) +target_link_libraries(EventSender ${MATSDK_LIBRARY} curl z ${CMAKE_THREAD_LIBS_INIT} ${MATSDK_SQLITE3_LIB} ${MATSDK_SAMPLE_PLATFORM_LIBS} dl) diff --git a/examples/cpp/SampleCppMini/CMakeLists.txt b/examples/cpp/SampleCppMini/CMakeLists.txt index 26a84f30b..c359ec1c5 100644 --- a/examples/cpp/SampleCppMini/CMakeLists.txt +++ b/examples/cpp/SampleCppMini/CMakeLists.txt @@ -18,10 +18,9 @@ include_directories(. ${MATSDK_SAMPLE_INCLUDE_DIRS}) add_executable(SampleCppMini main.cpp demo.c) source_group(" " REGULAR_EXPRESSION "") -set (PLATFORM_LIBS "") # The 1DS SDK's required Apple frameworks are provided by MATSDK_SAMPLE_PLATFORM_LIBS. #tcmalloc turned off by default #target_link_libraries(SampleCppMini ${MAT_SDK_LIB}/libmat.a curl z ${CMAKE_THREAD_LIBS_INIT} ${SQLITE3_LIB} dl tcmalloc) -target_link_libraries(SampleCppMini ${MATSDK_LIBRARY} curl z ${CMAKE_THREAD_LIBS_INIT} ${MATSDK_SQLITE3_LIB} ${MATSDK_SAMPLE_PLATFORM_LIBS} ${PLATFORM_LIBS} dl) +target_link_libraries(SampleCppMini ${MATSDK_LIBRARY} curl z ${CMAKE_THREAD_LIBS_INIT} ${MATSDK_SQLITE3_LIB} ${MATSDK_SAMPLE_PLATFORM_LIBS} dl) From 6193ae12ff295388db1a5cfe4471b7e0d47103f0 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 12:38:02 -0500 Subject: [PATCH 31/56] Refresh commented tcmalloc link hint to current variable names The optional 'link with tcmalloc' hint still referenced the pre-refactor variables (MAT_SDK_LIB, SQLITE3_LIB), so it would not have linked if uncommented. Update each hint to mirror that example's active link line (MATSDK_LIBRARY, MATSDK_SQLITE3_LIB, MATSDK_SAMPLE_PLATFORM_LIBS, plus PLATFORM_LIBS for SampleCpp) so the tcmalloc toggle stays usable. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- examples/cpp/EventSender/CMakeLists.txt | 2 +- examples/cpp/SampleCpp/CMakeLists.txt | 2 +- examples/cpp/SampleCppMini/CMakeLists.txt | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/cpp/EventSender/CMakeLists.txt b/examples/cpp/EventSender/CMakeLists.txt index 98f1ca512..bf2b0edd0 100644 --- a/examples/cpp/EventSender/CMakeLists.txt +++ b/examples/cpp/EventSender/CMakeLists.txt @@ -21,6 +21,6 @@ source_group(" " REGULAR_EXPRESSION "") # The 1DS SDK's required Apple frameworks are provided by MATSDK_SAMPLE_PLATFORM_LIBS. #tcmalloc turned off by default -#target_link_libraries(EventSender ${MAT_SDK_LIB}/libmat.a curl z ${CMAKE_THREAD_LIBS_INIT} ${SQLITE3_LIB} dl tcmalloc) +#target_link_libraries(EventSender ${MATSDK_LIBRARY} curl z ${CMAKE_THREAD_LIBS_INIT} ${MATSDK_SQLITE3_LIB} ${MATSDK_SAMPLE_PLATFORM_LIBS} dl tcmalloc) target_link_libraries(EventSender ${MATSDK_LIBRARY} curl z ${CMAKE_THREAD_LIBS_INIT} ${MATSDK_SQLITE3_LIB} ${MATSDK_SAMPLE_PLATFORM_LIBS} dl) diff --git a/examples/cpp/SampleCpp/CMakeLists.txt b/examples/cpp/SampleCpp/CMakeLists.txt index f5c2084c3..edd2950e2 100644 --- a/examples/cpp/SampleCpp/CMakeLists.txt +++ b/examples/cpp/SampleCpp/CMakeLists.txt @@ -27,7 +27,7 @@ if (CMAKE_SYSTEM_PROCESSOR STREQUAL "armv7l") endif() #tcmalloc turned off by default -#target_link_libraries(SampleCpp ${MAT_SDK_LIB}/libmat.a curl z ${CMAKE_THREAD_LIBS_INIT} ${SQLITE3_LIB} dl tcmalloc) +#target_link_libraries(SampleCpp ${MATSDK_LIBRARY} curl z ${CMAKE_THREAD_LIBS_INIT} ${MATSDK_SQLITE3_LIB} ${MATSDK_SAMPLE_PLATFORM_LIBS} ${PLATFORM_LIBS} dl tcmalloc) # TODO: use add_library to allow linking against a proper exported SDK target target_link_libraries(SampleCpp ${MATSDK_LIBRARY} curl z ${CMAKE_THREAD_LIBS_INIT} ${MATSDK_SQLITE3_LIB} ${MATSDK_SAMPLE_PLATFORM_LIBS} ${PLATFORM_LIBS} dl) diff --git a/examples/cpp/SampleCppMini/CMakeLists.txt b/examples/cpp/SampleCppMini/CMakeLists.txt index c359ec1c5..4ae676c41 100644 --- a/examples/cpp/SampleCppMini/CMakeLists.txt +++ b/examples/cpp/SampleCppMini/CMakeLists.txt @@ -21,6 +21,6 @@ source_group(" " REGULAR_EXPRESSION "") # The 1DS SDK's required Apple frameworks are provided by MATSDK_SAMPLE_PLATFORM_LIBS. #tcmalloc turned off by default -#target_link_libraries(SampleCppMini ${MAT_SDK_LIB}/libmat.a curl z ${CMAKE_THREAD_LIBS_INIT} ${SQLITE3_LIB} dl tcmalloc) +#target_link_libraries(SampleCppMini ${MATSDK_LIBRARY} curl z ${CMAKE_THREAD_LIBS_INIT} ${MATSDK_SQLITE3_LIB} ${MATSDK_SAMPLE_PLATFORM_LIBS} dl tcmalloc) target_link_libraries(SampleCppMini ${MATSDK_LIBRARY} curl z ${CMAKE_THREAD_LIBS_INIT} ${MATSDK_SQLITE3_LIB} ${MATSDK_SAMPLE_PLATFORM_LIBS} dl) From ababb79c581fbbe5e546d3d16d31bec1823fa6fc Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 13:26:07 -0500 Subject: [PATCH 32/56] Link tests against CURL::libcurl target instead of bare curl The unit/func test CMake re-links the SDK's external deps and already uses the ZLIB::ZLIB imported target for zlib, but linked curl by bare name. Bare 'curl' works in legacy builds (system -lcurl) but bypasses the vcpkg CURL::libcurl target (missing include dirs / wrong lib in a static vcpkg tree). Switch to CURL::libcurl, which find_package(CURL) exposes globally and the SDK itself links. Also drop the redundant NOT BUILD_IOS guard, since MATSDK_NEEDS_CURL is already false on iOS. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tests/functests/CMakeLists.txt | 6 ++++-- tests/unittests/CMakeLists.txt | 6 ++++-- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/tests/functests/CMakeLists.txt b/tests/functests/CMakeLists.txt index 92046fdfc..d1348c99d 100644 --- a/tests/functests/CMakeLists.txt +++ b/tests/functests/CMakeLists.txt @@ -140,8 +140,10 @@ else() # Link curl only when the SDK actually uses the curl HTTP client (Linux, and # macOS without Apple HTTP). The tests don't use curl directly, and on the # Android legacy path mat uses HttpClient_Android (no system curl in the NDK). - if(NOT BUILD_IOS AND MATSDK_NEEDS_CURL) - target_link_libraries(FuncTests curl) + # MATSDK_NEEDS_CURL already excludes iOS/Apple-HTTP; use the CURL::libcurl + # imported target so this is also correct under vcpkg (matches ZLIB::ZLIB above). + if(MATSDK_NEEDS_CURL) + target_link_libraries(FuncTests CURL::libcurl) endif() endif() diff --git a/tests/unittests/CMakeLists.txt b/tests/unittests/CMakeLists.txt index 25b52731f..353c8d030 100644 --- a/tests/unittests/CMakeLists.txt +++ b/tests/unittests/CMakeLists.txt @@ -205,8 +205,10 @@ else() # Link curl only when the SDK actually uses the curl HTTP client (Linux, and # macOS without Apple HTTP). The tests don't use curl directly, and on the # Android legacy path mat uses HttpClient_Android (no system curl in the NDK). - if(NOT BUILD_IOS AND MATSDK_NEEDS_CURL) - target_link_libraries(UnitTests curl) + # MATSDK_NEEDS_CURL already excludes iOS/Apple-HTTP; use the CURL::libcurl + # imported target so this is also correct under vcpkg (matches ZLIB::ZLIB above). + if(MATSDK_NEEDS_CURL) + target_link_libraries(UnitTests CURL::libcurl) endif() endif() From ea8a4bc1956faf38cc50e4828efc8881f2697ae3 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 16:38:56 -0500 Subject: [PATCH 33/56] Clarify Android API-level mixing guidance in vcpkg docs Make the failure direction explicit: the hazard is linking higher-API dependencies (default *-android triplets target API 28) into a lower-API (23) consumer, which references Bionic symbols absent at the lower API (e.g. __sendto_chk, added at API 26) and fails to link. The reverse is safe because Android native code is forward-compatible. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- docs/building-with-vcpkg.md | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/docs/building-with-vcpkg.md b/docs/building-with-vcpkg.md index 804fc1925..f08366a81 100644 --- a/docs/building-with-vcpkg.md +++ b/docs/building-with-vcpkg.md @@ -126,11 +126,17 @@ vcpkg install mstelemetry \ --overlay-triplets= ``` -Do not mix dependencies built with the default API 28 triplets into an API 23 -consumer binary; build the whole dependency graph with the same Android API -triplet. (For reference, this repo's CI validates equivalent API 23 triplets -under `tests/vcpkg/triplets`, but those are test scaffolding and are not part of -the published package.) +Build the whole dependency graph with the same Android API triplet. The failing +case is mixing dependencies built at a *higher* API level into a *lower*-API +consumer binary: the default `*-android` triplets target API 28, so linking them +into an API 23 consumer can fail because the higher-API objects reference Bionic +libc symbols that do not exist at API 23 (for example FORTIFY helpers such as +`__sendto_chk`, which Bionic added at API 26), producing unresolved-symbol link +errors — or, if they slip through, runtime crashes on lower-API devices. The +reverse — lower-API dependencies in a higher-API consumer — is safe, because +Android native code is forward-compatible. (For reference, this repo's CI +validates equivalent API 23 triplets under `tests/vcpkg/triplets`, but those are +test scaffolding and are not part of the published package.) Supported triplets: `arm64-android`, `arm-neon-android`, `x64-android`, `x86-android`. From cf5d796274fd94341665a2f0c5d8140dcc39b095 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 16:41:03 -0500 Subject: [PATCH 34/56] Simplify Android API-mixing note Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- docs/building-with-vcpkg.md | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) diff --git a/docs/building-with-vcpkg.md b/docs/building-with-vcpkg.md index f08366a81..5cebf5682 100644 --- a/docs/building-with-vcpkg.md +++ b/docs/building-with-vcpkg.md @@ -126,17 +126,13 @@ vcpkg install mstelemetry \ --overlay-triplets= ``` -Build the whole dependency graph with the same Android API triplet. The failing -case is mixing dependencies built at a *higher* API level into a *lower*-API -consumer binary: the default `*-android` triplets target API 28, so linking them -into an API 23 consumer can fail because the higher-API objects reference Bionic -libc symbols that do not exist at API 23 (for example FORTIFY helpers such as -`__sendto_chk`, which Bionic added at API 26), producing unresolved-symbol link -errors — or, if they slip through, runtime crashes on lower-API devices. The -reverse — lower-API dependencies in a higher-API consumer — is safe, because -Android native code is forward-compatible. (For reference, this repo's CI -validates equivalent API 23 triplets under `tests/vcpkg/triplets`, but those are -test scaffolding and are not part of the published package.) +Build the whole dependency graph with the same Android API triplet. Mixing +*higher*-API dependencies into a *lower*-API consumer fails to link — the default +`*-android` triplets target API 28, and their objects reference Bionic libc +symbols absent at API 23. The reverse (lower-API deps in a higher-API consumer) +is safe, since Android native code is forward-compatible. (This repo's CI +validates equivalent API 23 triplets under `tests/vcpkg/triplets`, which are test +scaffolding and not part of the published package.) Supported triplets: `arm64-android`, `arm-neon-android`, `x64-android`, `x86-android`. From 4e23d709c48b697a29700fd825d4509d8da3fef3 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 17:26:46 -0500 Subject: [PATCH 35/56] Make vcpkg consumer test assert real runtime behavior The smoke test had six check(true, ...) calls that could never fail, so 'Results: N/N passed' overstated what was verified. Replace them with falsifiable assertions that exercise the public API and would catch a broken-but-linkable build: - LogConfiguration stores/reports a config key (HasConfig) - EventProperties stores the name, the expected property count, and the int64 value (GetProperties / as_int64) - PII kind is recorded on the property (piiKind) - Event priority round-trips (GetPriority) Compile/link/no-crash remains the implicit assertion of running at all. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tests/vcpkg/main.cpp | 51 ++++++++++++++++++++++---------------------- 1 file changed, 26 insertions(+), 25 deletions(-) diff --git a/tests/vcpkg/main.cpp b/tests/vcpkg/main.cpp index 80b477049..978131451 100644 --- a/tests/vcpkg/main.cpp +++ b/tests/vcpkg/main.cpp @@ -31,56 +31,57 @@ int main() printf("=== MSTelemetry vcpkg integration test ===\n"); // ---- Core API tests ---- + // Reaching this point already proves the headers compiled and the program + // linked against MSTelemetry::mat; the checks below assert real runtime + // behavior so a broken-but-linkable build still fails. printf("\n-- Core API --\n"); - // 1. Verify headers compile and link - check(true, "Headers found and compiled successfully"); - - // 2. LogManager configuration - auto& config = LogManager::GetLogConfiguration(); - check(true, "LogManager::GetLogConfiguration() callable"); + // LogManager configuration accepts and reports a config value. + { + auto& config = LogManager::GetLogConfiguration(); + config["vcpkgTestKey"] = "vcpkgTestValue"; + check(config.HasConfig("vcpkgTestKey"), + "LogConfiguration stores and reports a config key"); + } - // 3. LogManager initialization + // LogManager initialization returns a usable logger. { ILogger* logger = LogManager::Initialize("vcpkg-test-token"); - check(logger != nullptr, "LogManager::Initialize() callable"); + check(logger != nullptr, "LogManager::Initialize() returns a logger"); LogManager::FlushAndTeardown(); } - // 4. EventProperties with multiple types + // EventProperties stores the name and typed property values. { EventProperties props("TestEvent"); props.SetProperty("strProp", "value"); props.SetProperty("intProp", (int64_t)42); props.SetProperty("dblProp", 3.14); props.SetProperty("boolProp", true); - check(props.GetName() == "TestEvent", "Event name matches"); - check(true, "SetProperty for string, int, double, bool"); - } - // 5. Multiple event types - { - std::vector names = {"App.Started", "App.PageView", "App.Error"}; - for (const auto& name : names) { - EventProperties ep(name); - ep.SetProperty("timestamp", (int64_t)1234567890); - } - check(true, "Created multiple event types"); + check(props.GetName() == "TestEvent", "Event name round-trips"); + + const auto& stored = props.GetProperties(); + check(stored.size() == 4, "All four typed properties stored"); + check(stored.count("intProp") == 1 && stored.at("intProp").as_int64 == 42, + "Int64 property value round-trips"); } - // 6. PII annotations + // PII annotation is recorded on the stored property. { EventProperties props("PiiTest"); props.SetProperty("userId", "user@example.com", PiiKind_Identity); - props.SetProperty("ip", "127.0.0.1", PiiKind_IPv4Address); - check(true, "PII-annotated properties compile and link"); + const auto& stored = props.GetProperties(); + check(stored.count("userId") == 1 && + stored.at("userId").piiKind == PiiKind_Identity, + "PII kind recorded on property"); } - // 7. Event priority + // Event priority round-trips. { EventProperties props("PriorityTest"); props.SetPriority(EventPriority_High); - check(true, "SetPriority compiles and links"); + check(props.GetPriority() == EventPriority_High, "Priority round-trips"); } printf("\n=== Results: %d/%d passed ===\n", pass_count, test_count); From 22a774fa99cb87a4f780e60693f00b78ce54d72c Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 18:38:50 -0500 Subject: [PATCH 36/56] Apply review cleanups to vcpkg port build - CMakeLists.txt: drop dead CMAKE_REQUIRED_LIBRARIES (no check_*/try_compile consumes it); prefer the CURL::libcurl imported target with a variable fallback for CMake < 3.12, fixing the CURL_INCLUDE_DIRS dereference typo; remove the dead INSTALL_LIB_DIR assignments (CPack uses CPACK_*). - lib/CMakeLists.txt: restore the Tcmalloc target_link_libraries TODO note; trim zlib_bundled warning suppressions to just -Wno-implicit-function-declaration (bundled zlib is 1.3.2, which removed K&R definitions -- validated with the Android NDK r29 Clang) and fix the stale 1.2.11 comment. - docs/building-with-vcpkg.md: note that Windows vcpkg builds use WinInet (MSVC/WIN32 PAL); curl is declared for linux | android only. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- CMakeLists.txt | 16 +++++++++------- docs/building-with-vcpkg.md | 8 ++++++++ lib/CMakeLists.txt | 15 ++++++++++----- 3 files changed, 27 insertions(+), 12 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 9f608dd5d..21a7f0d0b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -321,9 +321,15 @@ if(PAL_IMPLEMENTATION STREQUAL "CPP11" if(MATSDK_USE_VCPKG_DEPS) list(APPEND LIBS CURL::libcurl) else() - include_directories(CURL_INCLUDE_DIRS) - set(CMAKE_REQUIRED_LIBRARIES "${CURL_LIBRARIES}") - list(APPEND LIBS "${CURL_LIBRARIES}") + # Prefer the imported target, which carries curl's include dirs and link + # flags. Fall back to the find-module variables on CMake < 3.12, where + # find_package(CURL) does not define CURL::libcurl. + if(TARGET CURL::libcurl) + list(APPEND LIBS CURL::libcurl) + else() + include_directories(${CURL_INCLUDE_DIRS}) + list(APPEND LIBS "${CURL_LIBRARIES}") + endif() endif() endif() @@ -379,13 +385,9 @@ endif() if (BUILD_PACKAGE) if ("${CMAKE_PACKAGE_TYPE}" STREQUAL "deb") - # FIXME: hardcode it for 64-bit Linux for now - set(INSTALL_LIB_DIR ${CMAKE_INSTALL_PREFIX}/lib/${CPACK_DEBIAN_ARCHITECTURE}-linux-gnu) include(tools/MakeDeb.cmake) endif() if ("${CMAKE_PACKAGE_TYPE}" STREQUAL "rpm") - # TODO: [MG] - fix path - set(INSTALL_LIB_DIR ${CMAKE_INSTALL_PREFIX}/lib/${CMAKE_SYSTEM_PROCESSOR}-linux-gnu) include(tools/MakeRpm.cmake) endif() if ("${CMAKE_PACKAGE_TYPE}" STREQUAL "tgz") diff --git a/docs/building-with-vcpkg.md b/docs/building-with-vcpkg.md index 5cebf5682..83557c485 100644 --- a/docs/building-with-vcpkg.md +++ b/docs/building-with-vcpkg.md @@ -153,6 +153,14 @@ NSURLSession respectively). Android vcpkg consumers use native libcurl because the Java-backed `HttpClient_Android` singleton is initialized by the repo's Android Gradle/AAR flow, not by standalone native vcpkg consumers. +> **Note (Windows):** The port targets the MSVC/`WIN32` PAL on Windows, which +> uses WinInet, so `curl` is declared for `linux | android` only. A MinGW / +> non-MSVC Windows triplet — or forcing `-DPAL_IMPLEMENTATION=CPP11` on Windows — +> selects the curl HTTP client, which the port does not provision on Windows +> (broadening `curl` to `windows` would pull an unused curl into every MSVC +> build, since vcpkg platform expressions can't key off the PAL). Use a standard +> MSVC triplet such as `x64-windows-static` for Windows vcpkg builds. + ## Optional: SIMD-Optimized zlib with zlib-ng The vcpkg port depends on stock `zlib` by default. If you want SIMD-optimized diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt index 678775307..ee5d6d5e3 100644 --- a/lib/CMakeLists.txt +++ b/lib/CMakeLists.txt @@ -359,6 +359,9 @@ endif() ################################################################################################ # Link dependencies ################################################################################################ +# TODO: allow adding "${Tcmalloc_LIBRARIES}" to target_link_libraries for memory leak debugging +# (USE_TCMALLOC / FindTcmalloc.cmake are configured for Debug builds in the root CMakeLists.txt, +# but the library is not yet linked here). if(MATSDK_USE_VCPKG_DEPS) # vcpkg mode: all deps resolved via find_package() in root CMakeLists.txt # These are PUBLIC so static-library consumers get the transitive link set @@ -401,11 +404,13 @@ else() ) target_include_directories(zlib_bundled PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}/../zlib") set_target_properties(zlib_bundled PROPERTIES POSITION_INDEPENDENT_CODE ON) - # Bundled zlib 1.2.11 uses K&R-style function definitions and POSIX functions - # (close/read/write) without explicit includes; suppress warnings from - # vendored code we don't modify. - target_compile_options(zlib_bundled PRIVATE - -Wno-strict-prototypes -Wno-deprecated-non-prototype -Wno-implicit-function-declaration) + # Bundled zlib 1.3.2's gz*.c call POSIX functions (read/write/lseek/close) + # without including -- this target compiles the sources directly + # and does not run zlib's configure step that would define Z_HAVE_UNISTD_H. + # Suppress the resulting implicit-declaration error so the project's -Werror + # does not fail on vendored code we don't modify. (zlib 1.3 removed K&R + # function definitions, so the prototype warnings no longer need suppressing.) + target_compile_options(zlib_bundled PRIVATE -Wno-implicit-function-declaration) target_link_libraries(mat PRIVATE sqlite3_bundled zlib_bundled ${LIBS}) elseif(PAL_IMPLEMENTATION STREQUAL "WIN32") From 83c80fb0df8ee83043ba8af538addd81473b730d Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 18:40:22 -0500 Subject: [PATCH 37/56] Refresh overlay port source after review cleanups Point the overlay portfile at 22a774fa (curl linkage cleanup, dead-code removal, zlib_bundled flag trim) and update the source archive SHA512. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index 59ede09a4..bd484f9ba 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF 88c1302f6c2fea67f44bc10677c94581f28b5cfa - SHA512 91d405f6d9504fcf529d0bdd045c01f06953e9309f657e92a303156baff8ada8065748b9a92e0c5f1ac47543e9ff77bcc22d856f8d637e990939bccc7e9c27bc + REF 22a774fa99cb87a4f780e60693f00b78ce54d72c + SHA512 c58782954d96fb0e3bdad5357bb4935da0b7e838bc9465b6b7d06a53c4c4bd2b262ddd51e601f0e9aad21e8275bba251d988d6a579a617ef82b0f9ac4686effd HEAD_REF main ) From 18cef5942bb43626c8e0a375c9d88396f54a11a8 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 18:44:17 -0500 Subject: [PATCH 38/56] Fix MinGW vcpkg curl dependency Include curl for MinGW vcpkg triplets and make UNREFERENCED_PARAMETER ignore existing non-MSVC Windows definitions that assign to const references under MinGW. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- lib/include/public/ctmacros.hpp | 7 ++++++- tools/ports/mstelemetry/vcpkg.json | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/lib/include/public/ctmacros.hpp b/lib/include/public/ctmacros.hpp index 42547e41d..b8aae4637 100644 --- a/lib/include/public/ctmacros.hpp +++ b/lib/include/public/ctmacros.hpp @@ -52,7 +52,12 @@ #endif // TODO: [MG] - ideally we'd like to use __attribute__((unused)) with gcc/clang -#ifndef UNREFERENCED_PARAMETER +#ifndef _MSC_VER +#ifdef UNREFERENCED_PARAMETER +#undef UNREFERENCED_PARAMETER +#endif +#define UNREFERENCED_PARAMETER(...) +#elif !defined(UNREFERENCED_PARAMETER) #define UNREFERENCED_PARAMETER(...) #endif diff --git a/tools/ports/mstelemetry/vcpkg.json b/tools/ports/mstelemetry/vcpkg.json index 40ef6fc35..7580303b8 100644 --- a/tools/ports/mstelemetry/vcpkg.json +++ b/tools/ports/mstelemetry/vcpkg.json @@ -16,7 +16,7 @@ "features": [ "openssl" ], - "platform": "linux | android" + "platform": "linux | android | mingw" }, { "name": "vcpkg-cmake", From 5e60bc530cd8516c737d48aa61b0ecde643e1688 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 18:44:39 -0500 Subject: [PATCH 39/56] Refresh overlay port source after MinGW fix Point the mstelemetry overlay port at the commit that adds MinGW curl dependency coverage and the MinGW-safe unused-parameter macro. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index bd484f9ba..fa869e2a8 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF 22a774fa99cb87a4f780e60693f00b78ce54d72c - SHA512 c58782954d96fb0e3bdad5357bb4935da0b7e838bc9465b6b7d06a53c4c4bd2b262ddd51e601f0e9aad21e8275bba251d988d6a579a617ef82b0f9ac4686effd + REF 18cef5942bb43626c8e0a375c9d88396f54a11a8 + SHA512 65cca158762b8126d5bdce9f75861fb627df18beef9bfdd6736fe50c5b981c94fb84d106a0ac9fa0560c09b7e249ed687b6fd3cac0e00208ca311e2c11184461 HEAD_REF main ) From 31c5499949117c25f7ce9461d4d236a9469d81ac Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 18:48:08 -0500 Subject: [PATCH 40/56] Exclude MinGW from vcpkg port support Revert the experimental MinGW curl/macro changes and make the port manifest match the documented Windows support boundary: MSVC Windows triplets are supported, MinGW is not. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- lib/include/public/ctmacros.hpp | 7 +------ tools/ports/mstelemetry/portfile.cmake | 4 ++-- tools/ports/mstelemetry/vcpkg.json | 4 ++-- 3 files changed, 5 insertions(+), 10 deletions(-) diff --git a/lib/include/public/ctmacros.hpp b/lib/include/public/ctmacros.hpp index b8aae4637..42547e41d 100644 --- a/lib/include/public/ctmacros.hpp +++ b/lib/include/public/ctmacros.hpp @@ -52,12 +52,7 @@ #endif // TODO: [MG] - ideally we'd like to use __attribute__((unused)) with gcc/clang -#ifndef _MSC_VER -#ifdef UNREFERENCED_PARAMETER -#undef UNREFERENCED_PARAMETER -#endif -#define UNREFERENCED_PARAMETER(...) -#elif !defined(UNREFERENCED_PARAMETER) +#ifndef UNREFERENCED_PARAMETER #define UNREFERENCED_PARAMETER(...) #endif diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index fa869e2a8..bd484f9ba 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF 18cef5942bb43626c8e0a375c9d88396f54a11a8 - SHA512 65cca158762b8126d5bdce9f75861fb627df18beef9bfdd6736fe50c5b981c94fb84d106a0ac9fa0560c09b7e249ed687b6fd3cac0e00208ca311e2c11184461 + REF 22a774fa99cb87a4f780e60693f00b78ce54d72c + SHA512 c58782954d96fb0e3bdad5357bb4935da0b7e838bc9465b6b7d06a53c4c4bd2b262ddd51e601f0e9aad21e8275bba251d988d6a579a617ef82b0f9ac4686effd HEAD_REF main ) diff --git a/tools/ports/mstelemetry/vcpkg.json b/tools/ports/mstelemetry/vcpkg.json index 7580303b8..894008929 100644 --- a/tools/ports/mstelemetry/vcpkg.json +++ b/tools/ports/mstelemetry/vcpkg.json @@ -5,7 +5,7 @@ "description": "Microsoft 1DS C/C++ Client Telemetry Library", "homepage": "https://github.com/microsoft/cpp_client_telemetry", "license": "Apache-2.0", - "supports": "(windows | linux | osx | ios | android) & !uwp", + "supports": "((windows & !mingw) | linux | osx | ios | android) & !uwp", "dependencies": [ "nlohmann-json", "sqlite3", @@ -16,7 +16,7 @@ "features": [ "openssl" ], - "platform": "linux | android | mingw" + "platform": "linux | android" }, { "name": "vcpkg-cmake", From de2b6efc40b7c1542ca71f9415d6fdc08456c940 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 18:50:12 -0500 Subject: [PATCH 41/56] Fix vcpkg consumer property count check EventProperties initializes EventInfo.Level by default, so the vcpkg consumer test should verify the four custom typed keys are present rather than requiring the entire property map to contain exactly four entries. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tests/vcpkg/main.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tests/vcpkg/main.cpp b/tests/vcpkg/main.cpp index 978131451..7364a3977 100644 --- a/tests/vcpkg/main.cpp +++ b/tests/vcpkg/main.cpp @@ -62,7 +62,11 @@ int main() check(props.GetName() == "TestEvent", "Event name round-trips"); const auto& stored = props.GetProperties(); - check(stored.size() == 4, "All four typed properties stored"); + check(stored.count("strProp") == 1 && + stored.count("intProp") == 1 && + stored.count("dblProp") == 1 && + stored.count("boolProp") == 1, + "All four typed properties stored"); check(stored.count("intProp") == 1 && stored.at("intProp").as_int64 == 42, "Int64 property value round-trips"); } From af3a9595a51c80646304cbc359ae6c07b9ef8e46 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 18:54:58 -0500 Subject: [PATCH 42/56] Strengthen vcpkg property value checks Verify string, double, and bool EventProperty values in addition to key presence and the existing int64 check. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tests/vcpkg/main.cpp | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/tests/vcpkg/main.cpp b/tests/vcpkg/main.cpp index 7364a3977..c7b5d68da 100644 --- a/tests/vcpkg/main.cpp +++ b/tests/vcpkg/main.cpp @@ -3,6 +3,7 @@ #include #include +#include #include #include @@ -26,6 +27,11 @@ static void check(bool cond, const char* name) } } +static bool near(double actual, double expected) +{ + return std::fabs(actual - expected) < 0.000001; +} + int main() { printf("=== MSTelemetry vcpkg integration test ===\n"); @@ -67,8 +73,20 @@ int main() stored.count("dblProp") == 1 && stored.count("boolProp") == 1, "All four typed properties stored"); + check(stored.count("strProp") == 1 && + stored.at("strProp").type == EventProperty::TYPE_STRING && + std::string(stored.at("strProp").as_string) == "value", + "String property value round-trips"); check(stored.count("intProp") == 1 && stored.at("intProp").as_int64 == 42, "Int64 property value round-trips"); + check(stored.count("dblProp") == 1 && + stored.at("dblProp").type == EventProperty::TYPE_DOUBLE && + near(stored.at("dblProp").as_double, 3.14), + "Double property value round-trips"); + check(stored.count("boolProp") == 1 && + stored.at("boolProp").type == EventProperty::TYPE_BOOLEAN && + stored.at("boolProp").as_bool, + "Bool property value round-trips"); } // PII annotation is recorded on the stored property. From f39634390876cb0cc18e743ee4fa286dc1d36197 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 18:58:37 -0500 Subject: [PATCH 43/56] Trim redundant sentence from zlib_bundled flag comment Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- lib/CMakeLists.txt | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt index ee5d6d5e3..067de7e02 100644 --- a/lib/CMakeLists.txt +++ b/lib/CMakeLists.txt @@ -408,8 +408,7 @@ else() # without including -- this target compiles the sources directly # and does not run zlib's configure step that would define Z_HAVE_UNISTD_H. # Suppress the resulting implicit-declaration error so the project's -Werror - # does not fail on vendored code we don't modify. (zlib 1.3 removed K&R - # function definitions, so the prototype warnings no longer need suppressing.) + # does not fail on vendored code we don't modify. target_compile_options(zlib_bundled PRIVATE -Wno-implicit-function-declaration) target_link_libraries(mat PRIVATE sqlite3_bundled zlib_bundled ${LIBS}) From 3644b0dc97a3daf3735d0c81f433f500bb6a1c1b Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 19:01:39 -0500 Subject: [PATCH 44/56] Refresh overlay port source after zlib comment trim and merge Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index bd484f9ba..f79eb18d3 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF 22a774fa99cb87a4f780e60693f00b78ce54d72c - SHA512 c58782954d96fb0e3bdad5357bb4935da0b7e838bc9465b6b7d06a53c4c4bd2b262ddd51e601f0e9aad21e8275bba251d988d6a579a617ef82b0f9ac4686effd + REF b9534bb99384a8711b7e9f1852d4cb3e7f5b846b + SHA512 2288d2508079710b599f682adaf9de9449d6a8353baf426ffa30b2629194f7f36a330ae4be0adf862f0a6948c07422d2316df7b2de5f55403517820309455a4c HEAD_REF main ) From cdc62dbcbad9d8fa16b352819a731c79bdee8a89 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 22:03:55 -0500 Subject: [PATCH 45/56] Define Z_HAVE_UNISTD_H for bundled zlib instead of suppressing the warning zlib_bundled compiles zlib's pristine sources without its configure step, so gz*.c lacked and called POSIX read/write/lseek/close via implicit (int-returning) declarations -- which we were silencing with -Wno-implicit-function-declaration. On Android LP64 those functions return ssize_t/off_t, so the implicit declarations are a latent prototype mismatch. Define Z_HAVE_UNISTD_H (as zlib's own POSIX configure would) so zconf.h pulls in and the functions get their real declarations. All 15 bundled zlib sources then compile clean under the project's -Werror with no warning suppression (validated with the Android NDK r29 Clang). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- lib/CMakeLists.txt | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt index 067de7e02..552bd59fa 100644 --- a/lib/CMakeLists.txt +++ b/lib/CMakeLists.txt @@ -404,12 +404,11 @@ else() ) target_include_directories(zlib_bundled PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}/../zlib") set_target_properties(zlib_bundled PROPERTIES POSITION_INDEPENDENT_CODE ON) - # Bundled zlib 1.3.2's gz*.c call POSIX functions (read/write/lseek/close) - # without including -- this target compiles the sources directly - # and does not run zlib's configure step that would define Z_HAVE_UNISTD_H. - # Suppress the resulting implicit-declaration error so the project's -Werror - # does not fail on vendored code we don't modify. - target_compile_options(zlib_bundled PRIVATE -Wno-implicit-function-declaration) + # Bundled zlib compiles the pristine sources without zlib's configure step, + # so tell it is available (Android is POSIX). This gives gz*.c the + # real POSIX declarations for read/write/lseek/close instead of relying on + # implicit (int-returning) declarations. + target_compile_definitions(zlib_bundled PRIVATE Z_HAVE_UNISTD_H) target_link_libraries(mat PRIVATE sqlite3_bundled zlib_bundled ${LIBS}) elseif(PAL_IMPLEMENTATION STREQUAL "WIN32") From b7c252649c23e93f54fb66c7c62ead6c9cac8cfd Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 22:04:33 -0500 Subject: [PATCH 46/56] Refresh overlay port source after Z_HAVE_UNISTD_H change Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index f79eb18d3..b0912f071 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF b9534bb99384a8711b7e9f1852d4cb3e7f5b846b - SHA512 2288d2508079710b599f682adaf9de9449d6a8353baf426ffa30b2629194f7f36a330ae4be0adf862f0a6948c07422d2316df7b2de5f55403517820309455a4c + REF cdc62dbcbad9d8fa16b352819a731c79bdee8a89 + SHA512 1367d0adcf0c779a237d84ff956c08d0e74590935698dd039174d559742dabe941391108cf6b7a3c6bb57039622730052ecf415fbb7569e98480feeffe1416c4 HEAD_REF main ) From f98700d609c8833855dfb496ca2d2581ee5638b0 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 22:58:40 -0500 Subject: [PATCH 47/56] Scope warning suppressions to where they are needed Two warning-suppression flags were broader than the issue they covered: - lib/http/HttpClient_Android.cpp declares an unused `Tag` log constant. Instead of suppressing -Wunused-const-variable for the whole file, annotate the constant with __attribute__((unused)) (a log tag is a standard convention and may be used later) and drop the per-file -Wno-unused-const-variable from lib/CMakeLists.txt. - The global -Wno-reorder added to CXX_EXTRA_WARN_FLAGS in CMakeLists.txt was redundant. The only member-init-order warning is in the private submodule's Sanitizer.cpp, which already has its own per-file -Wno-reorder scope in lib/CMakeLists.txt. msft/main builds the full tree (with submodules) under -Wall -Werror -Wextra using only that per-file scope, so remove the global flag. Files changed: - CMakeLists.txt - lib/CMakeLists.txt - lib/http/HttpClient_Android.cpp Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- CMakeLists.txt | 8 ++------ lib/CMakeLists.txt | 4 ---- lib/http/HttpClient_Android.cpp | 2 +- 3 files changed, 3 insertions(+), 11 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 21a7f0d0b..1f3a31525 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -143,13 +143,9 @@ if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "MSVC") elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") # -Wno-unknown-warning-option is Clang-only, omitted here set(WARN_FLAGS "-Wall -Werror -Wextra -Wno-unused-parameter -Wno-unused-but-set-variable") - # -Wno-reorder is C++-only; added to CXX_FLAGS below (suppresses member-init-order warnings in submodule code) - set(CXX_EXTRA_WARN_FLAGS "-Wno-reorder") else() # Clang / AppleClang set(WARN_FLAGS "-Wall -Werror -Wextra -Wno-unused-parameter -Wno-unknown-warning-option -Wno-unused-but-set-variable") - # -Wno-reorder is C++-only; added to CXX_FLAGS below (suppresses member-init-order warnings in submodule code) - set(CXX_EXTRA_WARN_FLAGS "-Wno-reorder") endif() if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") @@ -177,13 +173,13 @@ if (NOT CMAKE_BUILD_TYPE STREQUAL "Debug") #TODO: -fno-rtti message(STATUS "Building Release ...") set(CMAKE_C_FLAGS "$ENV{CFLAGS} ${CMAKE_C_FLAGS} -std=c11 ${REL_FLAGS}") - set(CMAKE_CXX_FLAGS "$ENV{CXXFLAGS} ${CMAKE_CXX_FLAGS} -std=c++11 ${REL_FLAGS} ${CXX_EXTRA_WARN_FLAGS}") + set(CMAKE_CXX_FLAGS "$ENV{CXXFLAGS} ${CMAKE_CXX_FLAGS} -std=c++11 ${REL_FLAGS}") else() set(USE_TCMALLOC 1) message(STATUS "Building Debug ...") include(tools/FindTcmalloc.cmake) set(CMAKE_C_FLAGS "$ENV{CFLAGS} ${CMAKE_C_FLAGS} -std=c11 ${DBG_FLAGS}") - set(CMAKE_CXX_FLAGS "$ENV{CXXFLAGS} ${CMAKE_CXX_FLAGS} -std=c++11 ${DBG_FLAGS} ${CXX_EXTRA_WARN_FLAGS}") + set(CMAKE_CXX_FLAGS "$ENV{CXXFLAGS} ${CMAKE_CXX_FLAGS} -std=c++11 ${DBG_FLAGS}") endif() #Remove /Zi for Win32 debug compiler issue diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt index 552bd59fa..533144c06 100644 --- a/lib/CMakeLists.txt +++ b/lib/CMakeLists.txt @@ -205,10 +205,6 @@ if(PAL_IMPLEMENTATION STREQUAL "CPP11") http/HttpClient_Android.cpp http/HttpClient_Android.hpp ) - if(CMAKE_CXX_COMPILER_ID MATCHES "Clang") - set_source_files_properties(http/HttpClient_Android.cpp - PROPERTIES COMPILE_FLAGS "-Wno-unused-const-variable") - endif() endif() else() list(APPEND SRCS diff --git a/lib/http/HttpClient_Android.cpp b/lib/http/HttpClient_Android.cpp index dbbe0eee1..48f646acd 100644 --- a/lib/http/HttpClient_Android.cpp +++ b/lib/http/HttpClient_Android.cpp @@ -11,7 +11,7 @@ namespace MAT_NS_BEGIN { - constexpr static auto Tag = "HttpClient_Android"; + constexpr static auto Tag __attribute__((unused)) = "HttpClient_Android"; HttpClient_Android::HttpRequest::~HttpRequest() noexcept { From 32b5ea509a6218a7e3d4a06953072685a01ba801 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 22:59:43 -0500 Subject: [PATCH 48/56] Refresh overlay port source after warning-suppression scoping Point the overlay portfile at the f98700d6 source snapshot so the mstelemetry vcpkg port builds the warning-suppression scoping change. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index b0912f071..b8adc5bed 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF cdc62dbcbad9d8fa16b352819a731c79bdee8a89 - SHA512 1367d0adcf0c779a237d84ff956c08d0e74590935698dd039174d559742dabe941391108cf6b7a3c6bb57039622730052ecf415fbb7569e98480feeffe1416c4 + REF f98700d609c8833855dfb496ca2d2581ee5638b0 + SHA512 aba33b862abd1f484ecb8f0bf55960cdcf8eb3996df670f35331a603033ddd2139ffc16451660b40964f5cac4896d6c3003ea703b2d72753d68a528a252f2175 HEAD_REF main ) From 6e152439b5b3a6116d03c2b10660f25f5fc06ed3 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 23:10:22 -0500 Subject: [PATCH 49/56] Remove orphaned Tag constant from HttpClient_Android.cpp The Tag log-component string was unused and is not part of the SDK logging convention: the LOG_TRACE/INFO/WARN/ERROR macros resolve the component automatically via getMATSDKLogComponent(), and the other HttpClient backends (Curl, WinInet, WinRt) define no such constant. HttpClient_Android.cpp performs no logging at all, so drop the dead constant entirely instead of annotating it __attribute__((unused)). Files changed: - lib/http/HttpClient_Android.cpp Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- lib/http/HttpClient_Android.cpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/lib/http/HttpClient_Android.cpp b/lib/http/HttpClient_Android.cpp index 48f646acd..c41a09d19 100644 --- a/lib/http/HttpClient_Android.cpp +++ b/lib/http/HttpClient_Android.cpp @@ -11,8 +11,6 @@ namespace MAT_NS_BEGIN { - constexpr static auto Tag __attribute__((unused)) = "HttpClient_Android"; - HttpClient_Android::HttpRequest::~HttpRequest() noexcept { EraseFromParent(); From 65c746e7d2bb47961d71a7ba485459af08827fb2 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 23:10:53 -0500 Subject: [PATCH 50/56] Refresh overlay port source after removing Tag constant Point the mstelemetry overlay portfile at the 6e152439 source snapshot. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index b8adc5bed..19e238909 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF f98700d609c8833855dfb496ca2d2581ee5638b0 - SHA512 aba33b862abd1f484ecb8f0bf55960cdcf8eb3996df670f35331a603033ddd2139ffc16451660b40964f5cac4896d6c3003ea703b2d72753d68a528a252f2175 + REF 6e152439b5b3a6116d03c2b10660f25f5fc06ed3 + SHA512 c47a9f2f8ba0ada0db66c670a075c673c90270be151f6a757c382682a4ce2b77694b876866ed788a9873670d51293491ec3f6631f58b0556ec01714aa56d2b2a HEAD_REF main ) From 3ce5d3a6c008d2705432bf43b2e9956795942dda Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Mon, 8 Jun 2026 23:35:07 -0500 Subject: [PATCH 51/56] Rename near() helper in vcpkg consumer test to avoid Windows macro main.cpp includes LogManager.hpp, which on Windows transitively pulls in and the legacy empty ear macro from the Windows SDK. The local static bool near(double, double) helper then expands to static bool (double, double) and fails to compile (C2062), breaking the test-vcpkg-windows.ps1 consumer build. Rename it to nearlyEqual(). Files changed: - tests/vcpkg/main.cpp Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tests/vcpkg/main.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/vcpkg/main.cpp b/tests/vcpkg/main.cpp index c7b5d68da..d9a345d61 100644 --- a/tests/vcpkg/main.cpp +++ b/tests/vcpkg/main.cpp @@ -27,7 +27,7 @@ static void check(bool cond, const char* name) } } -static bool near(double actual, double expected) +static bool nearlyEqual(double actual, double expected) { return std::fabs(actual - expected) < 0.000001; } @@ -81,7 +81,7 @@ int main() "Int64 property value round-trips"); check(stored.count("dblProp") == 1 && stored.at("dblProp").type == EventProperty::TYPE_DOUBLE && - near(stored.at("dblProp").as_double, 3.14), + nearlyEqual(stored.at("dblProp").as_double, 3.14), "Double property value round-trips"); check(stored.count("boolProp") == 1 && stored.at("boolProp").type == EventProperty::TYPE_BOOLEAN && From 841c6f725ea2df72c57e93c7f85a922ab3472f11 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Tue, 9 Jun 2026 00:27:52 -0500 Subject: [PATCH 52/56] Guard CURL::libcurl target in test link rules for old CMake tests/functests and tests/unittests linked the CURL::libcurl imported target unconditionally. On the project's minimum CMake (3.5), a legacy (non-vcpkg) find_package(CURL) only sets CURL_LIBRARIES/CURL_INCLUDE_DIRS and does not define CURL::libcurl until CMake 3.12, so configuration would fail. Mirror the root CMakeLists.txt guard: prefer the imported target when present and fall back to \ otherwise. Files changed: - tests/functests/CMakeLists.txt - tests/unittests/CMakeLists.txt Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tests/functests/CMakeLists.txt | 11 ++++++++--- tests/unittests/CMakeLists.txt | 11 ++++++++--- 2 files changed, 16 insertions(+), 6 deletions(-) diff --git a/tests/functests/CMakeLists.txt b/tests/functests/CMakeLists.txt index d1348c99d..61863ff5f 100644 --- a/tests/functests/CMakeLists.txt +++ b/tests/functests/CMakeLists.txt @@ -140,10 +140,15 @@ else() # Link curl only when the SDK actually uses the curl HTTP client (Linux, and # macOS without Apple HTTP). The tests don't use curl directly, and on the # Android legacy path mat uses HttpClient_Android (no system curl in the NDK). - # MATSDK_NEEDS_CURL already excludes iOS/Apple-HTTP; use the CURL::libcurl - # imported target so this is also correct under vcpkg (matches ZLIB::ZLIB above). + # MATSDK_NEEDS_CURL already excludes iOS/Apple-HTTP. Prefer the CURL::libcurl + # imported target (correct under vcpkg, matches ZLIB::ZLIB above) and fall back + # to the find-module variables on CMake < 3.12, which does not define it. if(MATSDK_NEEDS_CURL) - target_link_libraries(FuncTests CURL::libcurl) + if(TARGET CURL::libcurl) + target_link_libraries(FuncTests CURL::libcurl) + else() + target_link_libraries(FuncTests ${CURL_LIBRARIES}) + endif() endif() endif() diff --git a/tests/unittests/CMakeLists.txt b/tests/unittests/CMakeLists.txt index 353c8d030..efba3d67a 100644 --- a/tests/unittests/CMakeLists.txt +++ b/tests/unittests/CMakeLists.txt @@ -205,10 +205,15 @@ else() # Link curl only when the SDK actually uses the curl HTTP client (Linux, and # macOS without Apple HTTP). The tests don't use curl directly, and on the # Android legacy path mat uses HttpClient_Android (no system curl in the NDK). - # MATSDK_NEEDS_CURL already excludes iOS/Apple-HTTP; use the CURL::libcurl - # imported target so this is also correct under vcpkg (matches ZLIB::ZLIB above). + # MATSDK_NEEDS_CURL already excludes iOS/Apple-HTTP. Prefer the CURL::libcurl + # imported target (correct under vcpkg, matches ZLIB::ZLIB above) and fall back + # to the find-module variables on CMake < 3.12, which does not define it. if(MATSDK_NEEDS_CURL) - target_link_libraries(UnitTests CURL::libcurl) + if(TARGET CURL::libcurl) + target_link_libraries(UnitTests CURL::libcurl) + else() + target_link_libraries(UnitTests ${CURL_LIBRARIES}) + endif() endif() endif() From 6b6ac3fae599a6c7f9f12976512cd71e0cacba86 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Tue, 9 Jun 2026 16:41:06 -0500 Subject: [PATCH 53/56] vcpkg: drop redundant port-version: 0 from mstelemetry manifest Per vcpkg convention (review feedback from @walbourn), port-version defaults to 0 and should be omitted when it is 0. Remove the explicit field. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/vcpkg.json | 1 - 1 file changed, 1 deletion(-) diff --git a/tools/ports/mstelemetry/vcpkg.json b/tools/ports/mstelemetry/vcpkg.json index 894008929..caf301e3b 100644 --- a/tools/ports/mstelemetry/vcpkg.json +++ b/tools/ports/mstelemetry/vcpkg.json @@ -1,7 +1,6 @@ { "name": "mstelemetry", "version": "3.10.100.1", - "port-version": 0, "description": "Microsoft 1DS C/C++ Client Telemetry Library", "homepage": "https://github.com/microsoft/cpp_client_telemetry", "license": "Apache-2.0", From 0604492f5eebd0e0fac86c1a0f63f6f799cf0f01 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Tue, 9 Jun 2026 17:15:55 -0500 Subject: [PATCH 54/56] cmake: use VERSION 3.5...3.29 range for the bumped CMakeLists Per review feedback from @walbourn: keep the 3.5 minimum so consumers on older CMake (distro defaults, the Android NDK CMake, etc.) still build, while setting the policy version to 3.29 for modern policy behavior and to avoid the CMake 3.31+ deprecation warning that a bare VERSION 3.5 emits. CMake older than 3.12 sees the extra dots as version separators and ignores the ...3.29, treating it as VERSION 3.5 (documented behavior), so this is fully backward compatible. Verified CMake 4.3.2 configures cleanly with no error or deprecation and CMAKE_MINIMUM_REQUIRED_VERSION=3.5. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- CMakeLists.txt | 2 +- examples/c/SampleC-Guest/CMakeLists.txt | 2 +- examples/cpp/EventSender/CMakeLists.txt | 2 +- examples/cpp/MacProxy/CMakeLists.txt | 2 +- examples/cpp/SampleCpp/CMakeLists.txt | 2 +- examples/cpp/SampleCppMini/CMakeLists.txt | 2 +- examples/objc/cocoa-app/CMakeLists.txt | 2 +- lib/android_build/app/src/main/cpp/CMakeLists.txt | 2 +- zlib/CMakeLists.txt | 2 +- 9 files changed, 9 insertions(+), 9 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 1f3a31525..dea843b23 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.5) +cmake_minimum_required(VERSION 3.5...3.29) project(MSTelemetry LANGUAGES C CXX) ################################################################################################ diff --git a/examples/c/SampleC-Guest/CMakeLists.txt b/examples/c/SampleC-Guest/CMakeLists.txt index 18573f8af..1092f1f19 100644 --- a/examples/c/SampleC-Guest/CMakeLists.txt +++ b/examples/c/SampleC-Guest/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.5) +cmake_minimum_required(VERSION 3.5...3.29) project(SampleC-Guest) # Uncomment for building i386 binary on x86_64 system diff --git a/examples/cpp/EventSender/CMakeLists.txt b/examples/cpp/EventSender/CMakeLists.txt index bf2b0edd0..deeae0729 100644 --- a/examples/cpp/EventSender/CMakeLists.txt +++ b/examples/cpp/EventSender/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.5) +cmake_minimum_required(VERSION 3.5...3.29) project(EventSender) # Uncomment for building i386 binary on x86_64 system diff --git a/examples/cpp/MacProxy/CMakeLists.txt b/examples/cpp/MacProxy/CMakeLists.txt index 18e753333..030725fee 100644 --- a/examples/cpp/MacProxy/CMakeLists.txt +++ b/examples/cpp/MacProxy/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.5) +cmake_minimum_required(VERSION 3.5...3.29) project(MacProxy) # Uncomment for building i386 binary on x86_64 system diff --git a/examples/cpp/SampleCpp/CMakeLists.txt b/examples/cpp/SampleCpp/CMakeLists.txt index edd2950e2..2fbdaeb81 100644 --- a/examples/cpp/SampleCpp/CMakeLists.txt +++ b/examples/cpp/SampleCpp/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.5) +cmake_minimum_required(VERSION 3.5...3.29) project(SampleCpp) # Uncomment for building i386 binary on x86_64 system diff --git a/examples/cpp/SampleCppMini/CMakeLists.txt b/examples/cpp/SampleCppMini/CMakeLists.txt index 4ae676c41..908465570 100644 --- a/examples/cpp/SampleCppMini/CMakeLists.txt +++ b/examples/cpp/SampleCppMini/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.5) +cmake_minimum_required(VERSION 3.5...3.29) project(SampleCppMini) # Uncomment for building i386 binary on x86_64 system diff --git a/examples/objc/cocoa-app/CMakeLists.txt b/examples/objc/cocoa-app/CMakeLists.txt index 67a6e085c..629f20ee0 100644 --- a/examples/objc/cocoa-app/CMakeLists.txt +++ b/examples/objc/cocoa-app/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.5) +cmake_minimum_required(VERSION 3.5...3.29) project(foo) include(${CMAKE_CURRENT_LIST_DIR}/../../cmake/MSTelemetrySample.cmake) diff --git a/lib/android_build/app/src/main/cpp/CMakeLists.txt b/lib/android_build/app/src/main/cpp/CMakeLists.txt index 1ee7d8662..2e86b5a54 100644 --- a/lib/android_build/app/src/main/cpp/CMakeLists.txt +++ b/lib/android_build/app/src/main/cpp/CMakeLists.txt @@ -3,7 +3,7 @@ # Sets the minimum version of CMake required to build the native library. -cmake_minimum_required(VERSION 3.5) +cmake_minimum_required(VERSION 3.5...3.29) set(CMAKE_CXX_STANDARD 14) set(CMAKE_CXX_STANDARD_REQUIRED ON) diff --git a/zlib/CMakeLists.txt b/zlib/CMakeLists.txt index 7786f2215..d7c3867da 100644 --- a/zlib/CMakeLists.txt +++ b/zlib/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.5) +cmake_minimum_required(VERSION 3.5...3.29) set(CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS ON) project(zlib C) From 94399e9724de8a063fd04b459eb070d0759ea66b Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Tue, 9 Jun 2026 17:16:56 -0500 Subject: [PATCH 55/56] Refresh overlay port source after CMake version-range change Point the mstelemetry overlay portfile at the 0604492f source snapshot. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index 19e238909..ee472a128 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF 6e152439b5b3a6116d03c2b10660f25f5fc06ed3 - SHA512 c47a9f2f8ba0ada0db66c670a075c673c90270be151f6a757c382682a4ce2b77694b876866ed788a9873670d51293491ec3f6631f58b0556ec01714aa56d2b2a + REF 0604492f5eebd0e0fac86c1a0f63f6f799cf0f01 + SHA512 5d17a675b1941e4f286f0308c601a0a9497458e2c77a9664700fcc1d7d477fc140a3d6859c249599f1f1020276288203edf4366928e3d8a4462953c0244376bc HEAD_REF main ) From 79e2cf92a4c2825055f913548a2eb0cf008d1f1e Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Tue, 9 Jun 2026 17:23:45 -0500 Subject: [PATCH 56/56] Refresh overlay port source after merging main (Version.hpp bump) The main merge brought lib/include/public/Version.hpp (3.10.159.1), a tarball source, so point the overlay portfile at the 65a0c754 merge commit. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tools/ports/mstelemetry/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/ports/mstelemetry/portfile.cmake b/tools/ports/mstelemetry/portfile.cmake index ee472a128..699af45f2 100644 --- a/tools/ports/mstelemetry/portfile.cmake +++ b/tools/ports/mstelemetry/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO microsoft/cpp_client_telemetry - REF 0604492f5eebd0e0fac86c1a0f63f6f799cf0f01 - SHA512 5d17a675b1941e4f286f0308c601a0a9497458e2c77a9664700fcc1d7d477fc140a3d6859c249599f1f1020276288203edf4366928e3d8a4462953c0244376bc + REF 65a0c754d2ee6a53bdcb3b79b36ac66483a7cf98 + SHA512 75da6be4233bfb05bafb1b31d6b80737e6efde4596adb93582dc0175f0154b8a5df7bdf5434d957ccdc31653da160959fe09f5e9f2997e6c0796759af9651755 HEAD_REF main )