Skip to content

Commit

Permalink
update ziti-sdk to v0.36.5 (#797)
Browse files Browse the repository at this point in the history
* update vcpkg baseline to 2023.12.12
* update ziti-sdk-c@0.36.5

---------

Co-authored-by: Shawn Carey <shawn.carey@netfoundry.io>
  • Loading branch information
ekoby and scareything authored Feb 13, 2024
1 parent 8dfdbd4 commit 6d97cc9
Show file tree
Hide file tree
Showing 12 changed files with 28 additions and 26 deletions.
4 changes: 2 additions & 2 deletions .github/actions/build/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,9 @@ runs:

- uses: lukka/run-vcpkg@v10
with:
# use 2023.06.20 vcpkg baseline,
# use 2023.12.12 vcpkg baseline,
# see https://learn.microsoft.com/en-us/vcpkg/users/examples/versioning.getting-started#builtin-baseline
vcpkgGitCommitId: 'f6a5d4e8eb7476b8d7fc12a56dff300c1c986131'
vcpkgGitCommitId: 'c8696863d371ab7f46e213d8f5ca923c4aef2a00'

- uses: lukka/run-cmake@v10.6 # pin version to avoid failed glibc dependency on ubuntu 20 runners. go back to @latest when ubuntu 22+ is adopted for runner os.
name: Configure CMake
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ ENV VCPKG_ROOT=/usr/local/vcpkg
ENV VCPKG_FORCE_SYSTEM_BINARIES=yes

RUN cd /usr/local \
&& git clone --branch 2023.06.20 https://github.com/microsoft/vcpkg \
&& git clone --branch 2023.12.12 https://github.com/microsoft/vcpkg \
&& ./vcpkg/bootstrap-vcpkg.sh -disableMetrics

COPY ./entrypoint.sh /root/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ ENV VCPKG_ROOT=/usr/local/vcpkg
ENV VCPKG_FORCE_SYSTEM_BINARIES=yes

RUN cd /usr/local \
&& git clone --branch 2023.06.20 https://github.com/microsoft/vcpkg \
&& git clone --branch 2023.12.12 https://github.com/microsoft/vcpkg \
&& ./vcpkg/bootstrap-vcpkg.sh -disableMetrics

WORKDIR /github/workspace
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ ENV VCPKG_ROOT=/usr/local/vcpkg
ENV VCPKG_FORCE_SYSTEM_BINARIES=yes

RUN cd /usr/local \
&& git clone --branch 2023.06.20 https://github.com/microsoft/vcpkg \
&& git clone --branch 2023.12.12 https://github.com/microsoft/vcpkg \
&& ./vcpkg/bootstrap-vcpkg.sh -disableMetrics \
&& chmod -R ugo+rwX /usr/local/vcpkg

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ ENV VCPKG_FORCE_SYSTEM_BINARIES=yes

RUN cd /usr/local \
&& git config --global advice.detachedHead false \
&& git clone --branch 2023.06.20 https://github.com/microsoft/vcpkg \
&& git clone --branch 2023.12.12 https://github.com/microsoft/vcpkg \
&& ./vcpkg/bootstrap-vcpkg.sh -disableMetrics

WORKDIR /github/workspace
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ ENV VCPKG_FORCE_SYSTEM_BINARIES=yes

RUN cd /usr/local \
&& git config --global advice.detachedHead false \
&& git clone --branch 2023.06.20 https://github.com/microsoft/vcpkg \
&& git clone --branch 2023.12.12 https://github.com/microsoft/vcpkg \
&& ./vcpkg/bootstrap-vcpkg.sh -disableMetrics

WORKDIR /github/workspace
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ ENV VCPKG_FORCE_SYSTEM_BINARIES=yes

RUN cd /usr/local \
&& git config --global advice.detachedHead false \
&& git clone --branch 2023.06.20 https://github.com/microsoft/vcpkg \
&& git clone --branch 2023.12.12 https://github.com/microsoft/vcpkg \
&& ./vcpkg/bootstrap-vcpkg.sh -disableMetrics

COPY ./entrypoint.sh /root/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ ENV VCPKG_FORCE_SYSTEM_BINARIES=yes

RUN cd /usr/local \
&& git config --global advice.detachedHead false \
&& git clone --branch 2023.06.20 https://github.com/microsoft/vcpkg \
&& git clone --branch 2023.12.12 https://github.com/microsoft/vcpkg \
&& ./vcpkg/bootstrap-vcpkg.sh -disableMetrics

COPY ./entrypoint.sh /root/
Expand Down
15 changes: 1 addition & 14 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ cmake_minimum_required(VERSION 3.20)


set(ZITI_SDK_DIR "" CACHE FILEPATH "developer option: use local ziti-sdk-c checkout")
set(ZITI_SDK_VERSION "0.35.12" CACHE STRING "ziti-sdk-c version or branch to use")
set(ZITI_SDK_VERSION "0.36.5" CACHE STRING "ziti-sdk-c version or branch to use")

# if TUNNEL_SDK_ONLY then don't descend into programs/ziti-edge-tunnel
option(TUNNEL_SDK_ONLY "build only ziti-tunnel-sdk (without ziti)" OFF)
Expand Down Expand Up @@ -119,19 +119,6 @@ message("cross-compiling: ${CMAKE_CROSSCOMPILING}")
link_directories(${CMAKE_BINARY_DIR}/lib)

add_subdirectory(deps)

find_package(libuv CONFIG QUIET)
if (libuv_FOUND)
if (TARGET uv_a)
set(tunnel_libuv_lib uv_a)
else()
set(tunnel_libuv_lib uv)
endif()
else()
find_path(tunnel_libuv_include_dir NAMES uv.h)
find_library(tunnel_libuv_lib uv_a NAMES uv)
endif()

add_subdirectory(lib/ziti-tunnel)

if(NOT TUNNEL_SDK_ONLY)
Expand Down
1 change: 0 additions & 1 deletion lib/ziti-tunnel/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@ target_include_directories(ziti-tunnel-sdk-c
target_link_libraries(ziti-tunnel-sdk-c
PUBLIC ziti
PUBLIC lwipcore
PUBLIC ${tunnel_libuv_lib}
)

#copy relevant .h files to the include folder
Expand Down
18 changes: 17 additions & 1 deletion programs/tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,24 @@ project(tests)
add_executable(ziti-edge-tunnel-test ziti-edge-tunnel-test.c)
set_property(TARGET ziti-edge-tunnel-test PROPERTY C_STANDARD 11)

find_package(libuv CONFIG QUIET)
if (libuv_FOUND)
# newer libuv versions have proper namespacing
if (TARGET libuv::uv_a)
set(libuv_lib libuv::uv_a)
elseif (TARGET uv_a)
set(libuv_lib uv_a)
elseif (TARGET libuv::uv)
set(libuv_lib libuv::uv)
else()
set(libuv_lib uv)
endif()
else()
find_library(libuv_lib uv_a NAMES uv)
endif()

target_link_libraries(ziti-edge-tunnel-test
PUBLIC ${tunnel_libuv_lib}
PUBLIC ${libuv_lib}
)

install(TARGETS ziti-edge-tunnel-test
Expand Down
2 changes: 1 addition & 1 deletion vcpkg.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,5 @@
]
}
},
"builtin-baseline": "f6a5d4e8eb7476b8d7fc12a56dff300c1c986131"
"builtin-baseline": "c8696863d371ab7f46e213d8f5ca923c4aef2a00"
}

0 comments on commit 6d97cc9

Please sign in to comment.