diff --git a/.github/actions/install-dependencies/action.yml b/.github/actions/install-dependencies/action.yml index 6a52a55..78ce4d8 100644 --- a/.github/actions/install-dependencies/action.yml +++ b/.github/actions/install-dependencies/action.yml @@ -14,7 +14,7 @@ runs: run: echo "OPENTELEMETRY_CPP_VERSION=${OPENTELEMETRY_CPP_VERSION}" >> "${GITHUB_ENV}" env: # renovate: datasource=github-releases depName=open-telemetry/opentelemetry-cpp - OPENTELEMETRY_CPP_VERSION: v1.22.0 + OPENTELEMETRY_CPP_VERSION: v1.23.0 - name: Make /usr/local/include and /usr/local/lib writable shell: bash diff --git a/Dockerfile b/Dockerfile index 359d0d5..211f8e8 100644 --- a/Dockerfile +++ b/Dockerfile @@ -8,7 +8,7 @@ ENV CC=clang-18 WORKDIR /build # renovate: datasource=github-releases depName=open-telemetry/opentelemetry-cpp -ENV OPENTELEMETRY_CPP_VERSION=v1.22.0 +ENV OPENTELEMETRY_CPP_VERSION=v1.23.0 RUN \ git clone https://github.com/open-telemetry/opentelemetry-cpp.git \ --depth=1 -b "${OPENTELEMETRY_CPP_VERSION}" --single-branch && \ diff --git a/src/os_utils.cpp b/src/os_utils.cpp index c4634a7..4c03fb6 100644 --- a/src/os_utils.cpp +++ b/src/os_utils.cpp @@ -93,7 +93,11 @@ std::string get_os_type(std::string_view os) std::pair{"NetBSD"sv, kNetbsd}, std::pair{"OpenBSD"sv, kOpenbsd}, std::pair{"SunOS"sv, kSolaris}, +#if OPENTELEMETRY_VERSION_MAJOR == 1 && OPENTELEMETRY_VERSION_MINOR < 22 std::pair{"OS/390"sv, kZOs} +#else + std::pair{"OS/390"sv, kZos} +#endif }; #ifdef USE_MPH diff --git a/test/os_utils/get_os_type.cpp b/test/os_utils/get_os_type.cpp index 9f034cf..99a27a0 100644 --- a/test/os_utils/get_os_type.cpp +++ b/test/os_utils/get_os_type.cpp @@ -30,6 +30,12 @@ TEST_P(GetOsTypeTest, get_os_type) EXPECT_EQ(actual, expected); } +#if OPENTELEMETRY_VERSION_MAJOR == 1 && OPENTELEMETRY_VERSION_MINOR < 22 +static constexpr const char* z_os = kZOs; +#else +static constexpr const char* z_os = kZos; +#endif + INSTANTIATE_TEST_SUITE_P( Table, GetOsTypeTest, @@ -52,7 +58,7 @@ INSTANTIATE_TEST_SUITE_P( std::make_tuple("NetBSD", kNetbsd), std::make_tuple("OpenBSD", kOpenbsd), std::make_tuple("SunOS", kSolaris), - std::make_tuple("OS/390", kZOs), + std::make_tuple("OS/390", z_os), std::make_tuple("UNKNOWN", "UNKNOWN") ) );