From a708327db6a37920780f1547ff306ddc3be94ca4 Mon Sep 17 00:00:00 2001 From: Patrick Nicolas Date: Sun, 3 Nov 2024 08:43:33 +0100 Subject: [PATCH] Use find_program for toktx --- client/CMakeLists.txt | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/client/CMakeLists.txt b/client/CMakeLists.txt index 48b58481..b6aee78a 100644 --- a/client/CMakeLists.txt +++ b/client/CMakeLists.txt @@ -257,12 +257,13 @@ add_custom_target(assets ALL DEPENDS add_dependencies(wivrn assets) if(ANDROID) + find_program(TOKTX toktx REQUIRED) add_custom_command(OUTPUT ${ASSETS_DIR}/wivrn.ktx2 - COMMAND toktx --encode astc --astc_blk_d 4x4 --astc_quality 100 --genmipmap ${ASSETS_DIR}/wivrn.ktx2 ${ASSETS_DIR}/wivrn.png + COMMAND ${TOKTX} --encode astc --astc_blk_d 4x4 --astc_quality 100 --genmipmap ${ASSETS_DIR}/wivrn.ktx2 ${ASSETS_DIR}/wivrn.png DEPENDS ${ASSETS_DIR}/wivrn.png) add_custom_command(OUTPUT ${ASSETS_DIR}/WoodFloor051_1K-JPG_Color.ktx2 - COMMAND toktx --encode astc --astc_blk_d 12x12 --astc_quality 100 --genmipmap ${ASSETS_DIR}/WoodFloor051_1K-JPG_Color.ktx2 ${AST_SRC_DIR}/WoodFloor051_1K-JPG_Color.jpg + COMMAND ${TOKTX} --encode astc --astc_blk_d 12x12 --astc_quality 100 --genmipmap ${ASSETS_DIR}/WoodFloor051_1K-JPG_Color.ktx2 ${AST_SRC_DIR}/WoodFloor051_1K-JPG_Color.jpg DEPENDS ${AST_SRC_DIR}/WoodFloor051_1K-JPG_Color.jpg) add_custom_command(OUTPUT ${ASSETS_DIR}/vr_splash.png