[azure-core-cpp] Fix gcc13 compilation error (#34393)

* Generate Imath.pc

* update version

* add dependency imath minizip-ng

* updata version

* update version

* Fix gcc13 compilation error

* update version

* update patch

* update version

* update verison

* update version
This commit is contained in:
jim wang 2023-11-01 03:42:23 +08:00 committed by GitHub
parent 71ab19baf4
commit ec19a4a790
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 124 additions and 2 deletions

View File

@ -0,0 +1,115 @@
diff --git a/CMakePresets.json b/CMakePresets.json
index eb862b0..2331864 100644
--- a/CMakePresets.json
+++ b/CMakePresets.json
@@ -370,6 +370,24 @@
"rhs": "Linux"
}
},
+ {
+ "name": "linux-basic-clang-13",
+ "displayName": "Linux clang-13",
+ "description": "Using compilers: C = /usr/bin/clang-13, CXX = /usr/bin/clang++-13",
+ "binaryDir": "${sourceDir}/out/build/${presetName}",
+ "generator": "Ninja",
+ "hidden": true,
+ "cacheVariables": {
+ "CMAKE_INSTALL_PREFIX": "${sourceDir}/out/install/${presetName}",
+ "CMAKE_C_COMPILER": "/usr/bin/clang-13",
+ "CMAKE_CXX_COMPILER": "/usr/bin/clang++-13"
+ },
+ "condition": {
+ "type": "equals",
+ "lhs": "${hostSystemName}",
+ "rhs": "Linux"
+ }
+ },
{
"name": "linux-basic-g++",
"displayName": "Linux G++",
@@ -403,9 +421,19 @@
"inherits": [ "linux-basic-clang-11", "debug-build" ]
},
{
- "name": "linux-clang-11-debug-tests",
- "inherits": [ "linux-basic-clang-11", "debug-build", "enable-tests" ],
- "displayName": "Linux clang 11 Debug+Tests"
+ "name": "linux-clang-13-debug-tests",
+ "inherits": [ "linux-basic-clang-13", "debug-build", "enable-tests" ],
+ "displayName": "Linux clang 13 Debug+Tests"
+ },
+ {
+ "name": "linux-clang-11-debug",
+ "displayName": "Linux clang 11 Debug",
+ "inherits": [ "linux-basic-clang-11", "debug-build" ]
+ },
+ {
+ "name": "linux-clang-13-debug-tests",
+ "inherits": [ "linux-basic-clang-13", "debug-build", "enable-tests" ],
+ "displayName": "Linux clang 13 Debug+Tests"
},
{
"name": "linux-g++-debug",
diff --git a/sdk/core/azure-core/inc/azure/core/base64.hpp b/sdk/core/azure-core/inc/azure/core/base64.hpp
index 97d01ce..97264cb 100644
--- a/sdk/core/azure-core/inc/azure/core/base64.hpp
+++ b/sdk/core/azure-core/inc/azure/core/base64.hpp
@@ -10,8 +10,9 @@
#pragma once
#include <algorithm>
-#include <cstdint>
+#include <cstdint> // defines std::uint8_t
#include <stdexcept>
+#include <stdint.h> // deprecated, defines uint8_t in global namespace. TODO: Remove when uint8_t in the global namespace is removed.
#include <string>
#include <vector>
diff --git a/sdk/core/azure-core/inc/azure/core/uuid.hpp b/sdk/core/azure-core/inc/azure/core/uuid.hpp
index 1fe0788..d2acb48 100644
--- a/sdk/core/azure-core/inc/azure/core/uuid.hpp
+++ b/sdk/core/azure-core/inc/azure/core/uuid.hpp
@@ -11,8 +11,9 @@
#include "azure/core/platform.hpp"
#include <array>
-#include <cstdint>
+#include <cstdint> // defines std::uint8_t
#include <cstring>
+#include <stdint.h> // deprecated, defines uint8_t in global namespace. TODO: Remove in the future when references to uint8_t and friends are removed.
#include <string>
namespace Azure { namespace Core {
diff --git a/eng/pipelines/templates/stages/platform-matrix.json b/eng/pipelines/templates/stages/platform-matrix.json
index e0ac5ae..af17184 100644
--- a/eng/pipelines/templates/stages/platform-matrix.json
+++ b/eng/pipelines/templates/stages/platform-matrix.json
@@ -148,6 +148,16 @@
"AptDependencies": "g++-9",
"CC": "/usr/bin/gcc-9",
"CXX": "/usr/bin/g++-9"
+ },
+ "clang-13": {
+ "AptDependencies": "clang-13",
+ "CC": "/usr/bin/clang-13",
+ "CXX": "/usr/bin/clang++-13"
+ },
+ "clang-15": {
+ "AptDependencies": "clang-15",
+ "CC": "/usr/bin/clang-15",
+ "CXX": "/usr/bin/clang++-15"
},
"included_coverage": {
"AptDependencies": "gcovr lcov",
@@ -156,6 +166,11 @@
"CODE_COVERAGE": "enabled",
"PublishMapFiles": "true"
},
+ "included_debug": {
+ "CMAKE_BUILD_TYPE": "Debug",
+ "CmakeArgs": " -DBUILD_TESTING=ON -DBUILD_PERFORMANCE_TESTS=ON -DRUN_LONG_UNIT_TESTS=ON",
+ "PublishMapFiles": "true"
+ },
"included_release": {
"CMAKE_BUILD_TYPE": "Release",
"CmakeArgs": " -DBUILD_TESTING=ON -DBUILD_PERFORMANCE_TESTS=ON -DRUN_LONG_UNIT_TESTS=ON",

View File

@ -3,6 +3,8 @@ vcpkg_from_github(
REPO Azure/azure-sdk-for-cpp
REF azure-core_1.10.3
SHA512 b3705cf757a14693f65a5ea4a43cc3c5f8377b3156ef24869bd664e9e8b25797fd21107ad543db476335bbb2389687cc1ed8fb8fe1010bb9b5a0eb406f3c0d59
PATCHES
fix_gcc13.patch
)
vcpkg_check_features(

View File

@ -1,7 +1,7 @@
{
"name": "azure-core-cpp",
"version-semver": "1.10.3",
"port-version": 1,
"port-version": 2,
"description": [
"Microsoft Azure Core SDK for C++",
"This library provides shared primitives, abstractions, and helpers for modern Azure SDK client libraries written in the C++."

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "3de5ec61efe0f113131a5a7847a2964b930b8f88",
"version-semver": "1.10.3",
"port-version": 2
},
{
"git-tree": "0f2e80c3e438f6738b7f0910f3122f21d52eb653",
"version-semver": "1.10.3",

View File

@ -422,7 +422,7 @@
},
"azure-core-cpp": {
"baseline": "1.10.3",
"port-version": 1
"port-version": 2
},
"azure-core-tracing-opentelemetry-cpp": {
"baseline": "1.0.0-beta.4",