File tree Expand file tree Collapse file tree 2 files changed +18
-3
lines changed
Expand file tree Collapse file tree 2 files changed +18
-3
lines changed Original file line number Diff line number Diff line change 1313 steps :
1414 - uses : actions/checkout@v5
1515 with :
16+ # NOTE: this should not be recursive, we really don't want to bundle vcpkg
1617 submodules : true
1718
1819 - name : Build SDist
9394 with :
9495 submodules : recursive
9596
96- # TODO: this is somewhat expensive. maybe we can drop the vcpkg submodule somehow?
9797 - name : Unshallow vcpkg submodule
9898 run : git -C libdave/cpp/vcpkg fetch --unshallow
9999
Original file line number Diff line number Diff line change 2626
2727# General build environment/toolchain setup
2828set (LIBDAVE_SRC_PATH ${CMAKE_CURRENT_SOURCE_DIR} /libdave/cpp)
29-
30- set (CMAKE_TOOLCHAIN_FILE "${LIBDAVE_SRC_PATH} /vcpkg/scripts/buildsystems/vcpkg.cmake" CACHE STRING "" )
3129set (VCPKG_MANIFEST_DIR "${LIBDAVE_SRC_PATH} /vcpkg-alts/${LIBDAVE_CRYPTO} " CACHE STRING "" )
3230
31+ set (_VCPKG_TOOLCHAIN "${LIBDAVE_SRC_PATH} /vcpkg/scripts/buildsystems/vcpkg.cmake" )
32+ if (NOT EXISTS ${_VCPKG_TOOLCHAIN} )
33+ if (DEFINED ENV{VCPKG_ROOT})
34+ set (_VCPKG_TOOLCHAIN "$ENV{VCPKG_ROOT} /scripts/buildsystems/vcpkg.cmake" )
35+ else ()
36+ message (FATAL_ERROR "\
37+ vcpkg toolchain not found.
38+ If you're installing from PyPI, clone https://github.com/microsoft/vcpkg
39+ and set the $VCPKG_ROOT environment variable to that location.
40+ (If you are a developer contributing to this package, ensure that
41+ all submodules are initialized instead).
42+ " )
43+ endif ()
44+ endif ()
45+ set (CMAKE_TOOLCHAIN_FILE ${_VCPKG_TOOLCHAIN} CACHE STRING "" )
46+ message (STATUS "Using vcpkg toolchain ${CMAKE_TOOLCHAIN_FILE} " )
47+
3348
3449# Architecture-specific ~~hacks~~ target specification
3550if (WIN32 )
You can’t perform that action at this time.
0 commit comments