From 78881d07ab2a97cca675ea790d65b2bf79303903 Mon Sep 17 00:00:00 2001 From: Malkierian Date: Sat, 8 Jun 2024 11:02:28 -0700 Subject: [PATCH] Add prefix to ExternalProject to make everything go in the Torch directory (no more Torch-prefix). Add `$` to TORCH_EXECUTABLE to get the right subdirectory for the build directory. --- CMakeLists.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index bf6a1842..1bdf642e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -490,11 +490,12 @@ endif() include(ExternalProject) ExternalProject_Add(Torch + PREFIX Torch SOURCE_DIR ${CMAKE_SOURCE_DIR}/Torch CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${CMAKE_BINARY_DIR}/Torch ) ExternalProject_Get_Property(Torch install_dir) -set(TORCH_EXECUTABLE ${install_dir}/src/Torch-build/torch) +set(TORCH_EXECUTABLE ${install_dir}/src/Torch-build/$/torch) add_custom_target( ExtractAssets DEPENDS Torch