Skip to content

Commit 02d77e1

Browse files
committed
build: utilize CDeps in FindFMT.cmake
Signed-off-by: Alfi Maulana <[email protected]>
1 parent c4c803d commit 02d77e1

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

cmake/FindFMT.cmake

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
1-
include(CPM)
2-
cpmaddpackage("gh:fmtlib/fmt#${FMT_FIND_VERSION}")
1+
find_package(CDeps 0.1.0 REQUIRED)
32

4-
include(FindPackageHandleStandardArgs)
5-
find_package_handle_standard_args(FMT REQUIRED_VARS fmt_ADDED)
3+
cdeps_download_package(FMT github.com/fmtlib/fmt ${FMT_FIND_VERSION})
4+
cdeps_build_package(FMT)
5+
cdeps_install_package(FMT)
6+
7+
include(CMakeFindDependencyMacro)
8+
find_dependency(FMT ${FMT_FIND_VERSION} CONFIG
9+
PATHS ${FMT_INSTALL_DIR}/lib/cmake NO_DEFAULT_PATH)

0 commit comments

Comments
 (0)