commit something which idk when i write them

This commit is contained in:
2026-04-21 22:33:21 +08:00
parent 5c18e2ccbc
commit d3fd3c2b0d
6 changed files with 25 additions and 19 deletions

View File

@@ -1,9 +1,15 @@
# Check YYCC path variable
# Check YYCC path environment variable
if (NOT DEFINED YYCC_PATH)
message(FATAL_ERROR "You must set YYCC_PATH variable to one of CMake distribution of YYCC installation path.")
message(FATAL_ERROR "You must set YYCC_PATH variable to one of YYCC CMake distribution installation path.")
endif()
# Find YYCC library
find_package(YYCCommonplace REQUIRED
HINTS ${YYCC_PATH} NO_DEFAULT_PATH
)
# It will produce YYCC::YYCCommonplace target for including and linking.
#
# Please note we MUST set CMake variable YYCCommonplace_ROOT to make sure CMake can found YYCC in out given path.
# The cache status of YYCCommonplace_ROOT is doesn't matter.
# CMake will throw error if we use HINTS feature in find_package to find YYCC.
set(YYCCommonplace_ROOT ${YYCC_PATH} CACHE PATH
"The path to YYCC CMake distribution installation path.")
find_package(YYCCommonplace REQUIRED)