early-access version 2853
This commit is contained in:
40
externals/vcpkg/ports/azure-iot-sdk-c/fix-install-location.patch
vendored
Executable file
40
externals/vcpkg/ports/azure-iot-sdk-c/fix-install-location.patch
vendored
Executable file
@@ -0,0 +1,40 @@
|
||||
diff --git a/provisioning_client/CMakeLists.txt b/provisioning_client/CMakeLists.txt
|
||||
index 39f269d51..ff53ca32d 100644
|
||||
--- a/provisioning_client/CMakeLists.txt
|
||||
+++ b/provisioning_client/CMakeLists.txt
|
||||
@@ -357,7 +357,7 @@ if(${use_installed_dependencies})
|
||||
set(CMAKE_INSTALL_LIBDIR "lib")
|
||||
endif()
|
||||
|
||||
- install(TARGETS ${provisioning_libs} EXPORT azure_prov_sdksTargets
|
||||
+ install(TARGETS ${provisioning_libs} EXPORT azure_iot_sdksTargets
|
||||
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
|
||||
@@ -372,26 +372,6 @@ if(${use_installed_dependencies})
|
||||
VERSION ${PROV_SDK_VERSION}
|
||||
COMPATIBILITY SameMajorVersion
|
||||
)
|
||||
-
|
||||
- configure_file("../configs/${PROJECT_NAME}Config.cmake"
|
||||
- "${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}/${PROJECT_NAME}Config.cmake"
|
||||
- COPYONLY
|
||||
- )
|
||||
-
|
||||
- install(EXPORT azure_prov_sdksTargets
|
||||
- FILE
|
||||
- "${PROJECT_NAME}Targets.cmake"
|
||||
- DESTINATION
|
||||
- ${package_location}
|
||||
- )
|
||||
-
|
||||
- install(
|
||||
- FILES
|
||||
- "../configs/${PROJECT_NAME}Config.cmake"
|
||||
- "${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}/${PROJECT_NAME}ConfigVersion.cmake"
|
||||
- DESTINATION
|
||||
- ${package_location}
|
||||
- )
|
||||
else()
|
||||
# Install Provisioning libs
|
||||
if(NOT DEFINED CMAKE_INSTALL_LIBDIR)
|
13
externals/vcpkg/ports/azure-iot-sdk-c/fix-iothubclient-includes.patch
vendored
Executable file
13
externals/vcpkg/ports/azure-iot-sdk-c/fix-iothubclient-includes.patch
vendored
Executable file
@@ -0,0 +1,13 @@
|
||||
diff --git a/iothub_client/CMakeLists.txt b/iothub_client/CMakeLists.txt
|
||||
index 07ab3b7..9769a08 100644
|
||||
--- a/iothub_client/CMakeLists.txt
|
||||
+++ b/iothub_client/CMakeLists.txt
|
||||
@@ -441,7 +441,7 @@ add_library(iothub_client
|
||||
target_include_directories(iothub_client
|
||||
PUBLIC
|
||||
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/inc>
|
||||
- $<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}/azureiot/include>
|
||||
+ $<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}/azureiot>
|
||||
)
|
||||
applyXcodeBuildFlagsIfNeeded(iothub_client)
|
||||
target_link_libraries(iothub_client ${iothub_client_libs})
|
112
externals/vcpkg/ports/azure-iot-sdk-c/improve-external-deps-preview.patch
vendored
Executable file
112
externals/vcpkg/ports/azure-iot-sdk-c/improve-external-deps-preview.patch
vendored
Executable file
@@ -0,0 +1,112 @@
|
||||
diff --git a/configs/azure_iot_sdksConfig.cmake b/configs/azure_iot_sdksConfig.cmake
|
||||
index b9c62e8..edf5847 100644
|
||||
--- a/configs/azure_iot_sdksConfig.cmake
|
||||
+++ b/configs/azure_iot_sdksConfig.cmake
|
||||
@@ -1,5 +1,11 @@
|
||||
#Copyright (c) Microsoft. All rights reserved.
|
||||
#Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
||||
+include(CMakeFindDependencyMacro)
|
||||
+find_dependency(unofficial-parson)
|
||||
+find_dependency(uamqp)
|
||||
+find_dependency(uhttp)
|
||||
+find_dependency(umqtt)
|
||||
+find_dependency(azure_c_shared_utility)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/azure_iot_sdksTargets.cmake")
|
||||
|
||||
diff --git a/iothub_client/tests/iothubclient_amqp_dt_e2e/CMakeLists.txt b/iothub_client/tests/iothubclient_amqp_dt_e2e/CMakeLists.txt
|
||||
index 33b5b8709..45ef7b87a 100644
|
||||
--- a/iothub_client/tests/iothubclient_amqp_dt_e2e/CMakeLists.txt
|
||||
+++ b/iothub_client/tests/iothubclient_amqp_dt_e2e/CMakeLists.txt
|
||||
@@ -31,12 +31,10 @@ set(${theseTestsName}_c_files
|
||||
|
||||
set(${theseTestsName}_c_files
|
||||
../../../certs/certs.c
|
||||
- ../../../deps/parson/parson.c
|
||||
)
|
||||
|
||||
set(${theseTestsName}_h_files
|
||||
../../../certs/certs.h
|
||||
- ../../../deps/parson/parson.h
|
||||
../common_dt_e2e/iothubclient_common_dt_e2e.h
|
||||
)
|
||||
|
||||
diff --git a/iothub_client/tests/iothubclient_mqtt_dt_e2e_sfc/CMakeLists.txt b/iothub_client/tests/iothubclient_mqtt_dt_e2e_sfc/CMakeLists.txt
|
||||
index d05d654..5872c8d 100644
|
||||
--- a/iothub_client/tests/iothubclient_mqtt_dt_e2e_sfc/CMakeLists.txt
|
||||
+++ b/iothub_client/tests/iothubclient_mqtt_dt_e2e_sfc/CMakeLists.txt
|
||||
@@ -31,12 +31,10 @@ set(${theseTestsName}_nuget_c_files
|
||||
|
||||
set(${theseTestsName}_c_files
|
||||
../../../certs/certs.c
|
||||
- ../../../deps/parson/parson.c
|
||||
)
|
||||
|
||||
set(${theseTestsName}_h_files
|
||||
../../../certs/certs.h
|
||||
- ../../../deps/parson/parson.h
|
||||
../common_dt_e2e/iothubclient_common_dt_e2e.h
|
||||
)
|
||||
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index ba2f8e016..19885c8b8 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -179,17 +179,6 @@ endif()
|
||||
# Use solution folders.
|
||||
set_property(GLOBAL PROPERTY USE_FOLDERS ON)
|
||||
|
||||
-# build the parson library for json parsing
|
||||
-add_library(parson
|
||||
- ./deps/parson/parson.c
|
||||
- ./deps/parson/parson.h
|
||||
-)
|
||||
-if (MSVC)
|
||||
- set_source_files_properties(../deps/parson/parson.c PROPERTIES COMPILE_FLAGS "/wd4244 /wd4232")
|
||||
-endif()
|
||||
-set(parson_h_install_files ./deps/parson/parson.h)
|
||||
-set(parson_install_libs parson)
|
||||
-
|
||||
if (IN_OPENWRT)
|
||||
ADD_DEFINITIONS("$ENV{TARGET_LDFLAGS}" "$ENV{TARGET_CPPFLAGS}" "$ENV{TARGET_CFLAGS}")
|
||||
INCLUDE_DIRECTORIES("$ENV{TOOLCHAIN_DIR}/usr/include" "$ENV{TARGET_LDFLAGS}" "$ENV{TARGET_CPPFLAGS}" "$ENV{TARGET_CFLAGS}")
|
||||
@@ -407,7 +396,7 @@ endif()
|
||||
|
||||
if (${use_installed_dependencies})
|
||||
# Install azure_iot_sdks
|
||||
- set(package_location "cmake")
|
||||
+ set(package_location "${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME}")
|
||||
|
||||
include(CMakePackageConfigHelpers)
|
||||
|
||||
@@ -422,14 +411,10 @@ if (${use_installed_dependencies})
|
||||
COPYONLY
|
||||
)
|
||||
|
||||
- install(FILES ${parson_h_install_files}
|
||||
- DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/azureiot
|
||||
- )
|
||||
- install(TARGETS ${parson_install_libs} EXPORT azure_iot_sdksTargets
|
||||
- ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
- LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
- INCLUDES DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/azureiot
|
||||
- )
|
||||
+ find_package(unofficial-parson REQUIRED CONFIG)
|
||||
+ if(NOT TARGET parson)
|
||||
+ add_library(parson ALIAS unofficial::parson::parson)
|
||||
+ endif()
|
||||
|
||||
install(EXPORT azure_iot_sdksTargets
|
||||
FILE
|
||||
@@ -446,11 +431,5 @@ if (${use_installed_dependencies})
|
||||
DESTINATION
|
||||
${package_location}
|
||||
)
|
||||
-else()
|
||||
- install(FILES ${parson_h_install_files}
|
||||
- DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/azureiot)
|
||||
- install(TARGETS ${parson_install_libs}
|
||||
- ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
- LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
endif()
|
||||
|
79
externals/vcpkg/ports/azure-iot-sdk-c/improve-external-deps.patch
vendored
Executable file
79
externals/vcpkg/ports/azure-iot-sdk-c/improve-external-deps.patch
vendored
Executable file
@@ -0,0 +1,79 @@
|
||||
diff --git a/configs/azure_iot_sdksConfig.cmake b/configs/azure_iot_sdksConfig.cmake
|
||||
index b9c62e8..edf5847 100644
|
||||
--- a/configs/azure_iot_sdksConfig.cmake
|
||||
+++ b/configs/azure_iot_sdksConfig.cmake
|
||||
@@ -1,5 +1,11 @@
|
||||
#Copyright (c) Microsoft. All rights reserved.
|
||||
#Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
||||
+include(CMakeFindDependencyMacro)
|
||||
+find_dependency(unofficial-parson)
|
||||
+find_dependency(uamqp)
|
||||
+find_dependency(uhttp)
|
||||
+find_dependency(umqtt)
|
||||
+find_dependency(azure_c_shared_utility)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/azure_iot_sdksTargets.cmake")
|
||||
|
||||
diff --git a/iothub_client/tests/iothubclient_amqp_dt_e2e/CMakeLists.txt b/iothub_client/tests/iothubclient_amqp_dt_e2e/CMakeLists.txt
|
||||
index 33b5b8709..45ef7b87a 100644
|
||||
--- a/iothub_client/tests/iothubclient_amqp_dt_e2e/CMakeLists.txt
|
||||
+++ b/iothub_client/tests/iothubclient_amqp_dt_e2e/CMakeLists.txt
|
||||
@@ -22,11 +22,9 @@ set(${theseTestsName}_c_files
|
||||
|
||||
set(${theseTestsName}_c_files
|
||||
../../../certs/certs.c
|
||||
- ../../../deps/parson/parson.c
|
||||
)
|
||||
set(${theseTestsName}_h_files
|
||||
../../../certs/certs.h
|
||||
- ../../../deps/parson/parson.h
|
||||
../common_dt_e2e/iothubclient_common_dt_e2e.h
|
||||
)
|
||||
|
||||
diff --git a/iothub_client/tests/iothubclient_mqtt_dt_e2e_sfc/CMakeLists.txt b/iothub_client/tests/iothubclient_mqtt_dt_e2e_sfc/CMakeLists.txt
|
||||
index d05d654..5872c8d 100644
|
||||
--- a/iothub_client/tests/iothubclient_mqtt_dt_e2e_sfc/CMakeLists.txt
|
||||
+++ b/iothub_client/tests/iothubclient_mqtt_dt_e2e_sfc/CMakeLists.txt
|
||||
@@ -22,12 +22,10 @@ set(${theseTestsName}_nuget_c_files
|
||||
|
||||
set(${theseTestsName}_c_files
|
||||
../../../certs/certs.c
|
||||
- ../../../deps/parson/parson.c
|
||||
)
|
||||
|
||||
set(${theseTestsName}_h_files
|
||||
../../../certs/certs.h
|
||||
- ../../../deps/parson/parson.h
|
||||
../common_dt_e2e/iothubclient_common_dt_e2e.h
|
||||
)
|
||||
|
||||
diff --git a/deps/CMakeLists.txt b/deps/CMakeLists.txt
|
||||
index 22e24f851..7dc30beba 100644
|
||||
--- a/deps/CMakeLists.txt
|
||||
+++ b/deps/CMakeLists.txt
|
||||
@@ -37,5 +37,8 @@ endif()
|
||||
if(NOT ${use_installed_dependencies})
|
||||
add_subdirectory(${CMAKE_CURRENT_LIST_DIR}/parson)
|
||||
else()
|
||||
- find_package(parson REQUIRED CONFIG)
|
||||
+ find_package(unofficial-parson REQUIRED CONFIG)
|
||||
+ if(NOT TARGET parson)
|
||||
+ add_library(parson ALIAS unofficial::parson::parson)
|
||||
+ endif()
|
||||
endif()
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index b72bd41ed..b2812f1fd 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -242,7 +242,10 @@ endif()
|
||||
|
||||
add_subdirectory(${CMAKE_CURRENT_LIST_DIR}/deps)
|
||||
if(${use_installed_dependencies})
|
||||
- find_package(parson REQUIRED CONFIG)
|
||||
+ find_package(unofficial-parson REQUIRED CONFIG)
|
||||
+ if(NOT TARGET parson)
|
||||
+ add_library(parson ALIAS unofficial::parson::parson)
|
||||
+ endif()
|
||||
endif()
|
||||
|
||||
include_directories(${MACRO_UTILS_INC_FOLDER})
|
58
externals/vcpkg/ports/azure-iot-sdk-c/portfile.cmake
vendored
Executable file
58
externals/vcpkg/ports/azure-iot-sdk-c/portfile.cmake
vendored
Executable file
@@ -0,0 +1,58 @@
|
||||
vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
|
||||
|
||||
if("public-preview" IN_LIST FEATURES)
|
||||
vcpkg_from_github(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
REPO Azure/azure-iot-sdk-c
|
||||
REF cb2e8d390df56ffa31d08ca0a79ab58ff96160cc
|
||||
SHA512 6798b17d6768b3ccbd0eb66719b50f364cd951736eb71110e2dc9deca054a1566ff88b9e8c5e9b52536e4308cad6cd3cbebff3282c123083e3afaee5535e724b
|
||||
HEAD_REF public-preview
|
||||
PATCHES
|
||||
improve-external-deps-preview.patch
|
||||
)
|
||||
else()
|
||||
vcpkg_from_github(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
REPO Azure/azure-iot-sdk-c
|
||||
REF 5805fb669ffe2adff021d68c62725d0bd783ac49
|
||||
SHA512 8f1aa1020f3bb8b3e801f3977d11be50fd07d961c89ac921f795ef8a99312f12e1ddb2268ce3d2fb84b6a42bb5806cde410e6b51c7c4539a9a11a9ae512dbcd1
|
||||
HEAD_REF master
|
||||
PATCHES
|
||||
fix-install-location.patch
|
||||
improve-external-deps.patch
|
||||
fix-iothubclient-includes.patch
|
||||
)
|
||||
endif()
|
||||
|
||||
vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
|
||||
FEATURES
|
||||
use-prov-client hsm_type_symm_key
|
||||
use-prov-client use_prov_client
|
||||
)
|
||||
|
||||
file(COPY "${CURRENT_INSTALLED_DIR}/share/azure-c-shared-utility/azure_iot_build_rules.cmake" DESTINATION "${SOURCE_PATH}/deps/azure-c-shared-utility/configs/")
|
||||
file(COPY "${SOURCE_PATH}/configs/azure_iot_sdksFunctions.cmake" DESTINATION "${CURRENT_PACKAGES_DIR}/share/cmake/azure_iot_sdks/")
|
||||
|
||||
vcpkg_cmake_configure(
|
||||
SOURCE_PATH "${SOURCE_PATH}"
|
||||
OPTIONS ${FEATURE_OPTIONS}
|
||||
-Dskip_samples=ON
|
||||
-Duse_installed_dependencies=ON
|
||||
-Duse_default_uuid=ON
|
||||
-Dbuild_as_dynamic=OFF
|
||||
-Duse_edge_modules=ON
|
||||
-Dwarnings_as_errors=OFF
|
||||
MAYBE_UNUSED_VARIABLES
|
||||
build_as_dynamic
|
||||
warnings_as_errors
|
||||
)
|
||||
|
||||
vcpkg_cmake_install()
|
||||
|
||||
vcpkg_cmake_config_fixup(PACKAGE_NAME azure_iot_sdks CONFIG_PATH "lib/cmake/azure_iot_sdks")
|
||||
|
||||
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include" "${CURRENT_PACKAGES_DIR}/debug/share")
|
||||
|
||||
configure_file("${SOURCE_PATH}/LICENSE" "${CURRENT_PACKAGES_DIR}/share/${PORT}/copyright" COPYONLY)
|
||||
|
||||
vcpkg_copy_pdbs()
|
71
externals/vcpkg/ports/azure-iot-sdk-c/vcpkg.json
vendored
Executable file
71
externals/vcpkg/ports/azure-iot-sdk-c/vcpkg.json
vendored
Executable file
@@ -0,0 +1,71 @@
|
||||
{
|
||||
"name": "azure-iot-sdk-c",
|
||||
"version-date": "2022-01-21",
|
||||
"port-version": 2,
|
||||
"description": "A C99 SDK for connecting devices to Microsoft Azure IoT services",
|
||||
"homepage": "https://github.com/Azure/azure-iot-sdk-c",
|
||||
"license": "MIT",
|
||||
"dependencies": [
|
||||
"azure-c-shared-utility",
|
||||
"azure-macro-utils-c",
|
||||
"azure-uamqp-c",
|
||||
"azure-uhttp-c",
|
||||
"azure-umqtt-c",
|
||||
"parson",
|
||||
"umock-c",
|
||||
{
|
||||
"name": "vcpkg-cmake",
|
||||
"host": true
|
||||
},
|
||||
{
|
||||
"name": "vcpkg-cmake-config",
|
||||
"host": true
|
||||
}
|
||||
],
|
||||
"features": {
|
||||
"public-preview": {
|
||||
"description": "A version of the azure-iot-sdk-c containing public-preview features.",
|
||||
"dependencies": [
|
||||
{
|
||||
"name": "azure-c-shared-utility",
|
||||
"features": [
|
||||
"public-preview"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "azure-macro-utils-c",
|
||||
"features": [
|
||||
"public-preview"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "azure-uamqp-c",
|
||||
"features": [
|
||||
"public-preview"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "azure-uhttp-c",
|
||||
"features": [
|
||||
"public-preview"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "azure-umqtt-c",
|
||||
"features": [
|
||||
"public-preview"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "umock-c",
|
||||
"features": [
|
||||
"public-preview"
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
"use-prov-client": {
|
||||
"description": "Enables device provisioning client for DPS"
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user