about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries/science/math/libtorch/test/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/science/math/libtorch/test/CMakeLists.txt')
-rw-r--r--nixpkgs/pkgs/development/libraries/science/math/libtorch/test/CMakeLists.txt5
1 files changed, 5 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/libraries/science/math/libtorch/test/CMakeLists.txt b/nixpkgs/pkgs/development/libraries/science/math/libtorch/test/CMakeLists.txt
new file mode 100644
index 000000000000..4e96704a4c17
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/science/math/libtorch/test/CMakeLists.txt
@@ -0,0 +1,5 @@
+cmake_minimum_required(VERSION 3.0)
+find_package(Torch REQUIRED)
+set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${TORCH_CXX_FLAGS}")
+add_executable(test test.cpp)
+target_link_libraries(test "${TORCH_LIBRARIES}")