summaryrefslogtreecommitdiff
blob: f12623f2068a95bd481d254fc191cc7d5f816dbc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
--- a/third_party/nvfuser/CMakeLists.txt	2023-11-30 21:42:07.336946970 +0100
+++ b/third_party/nvfuser/CMakeLists.txt	2023-11-30 21:46:35.101749250 +0100
@@ -18,7 +18,7 @@
 set(NVFUSER_ROOT ${PROJECT_SOURCE_DIR})
 set(NVFUSER_SRCS_DIR "${NVFUSER_ROOT}/csrc")
 set(TORCH_ROOT "${CMAKE_CURRENT_SOURCE_DIR}/../..")
-set(TORCH_INSTALL_LIB_DIR ${TORCH_ROOT}/torch/lib)
+set(TORCH_INSTALL_LIB_DIR ${CMAKE_INSTALL_LIBDIR})
 
 # --- build nvfuser_codegen library
 
@@ -218,7 +218,7 @@
     message(STATUS "somehow this is happening")
     set_target_properties(${NVFUSER} PROPERTIES LINK_FLAGS ${TORCH_PYTHON_LINK_FLAGS})
   endif()
-  install(TARGETS ${NVFUSER} EXPORT NvfuserTargets DESTINATION ${TORCH_ROOT}/nvfuser/)
+  install(TARGETS ${NVFUSER} EXPORT NvfuserTargets DESTINATION "${TORCH_INSTALL_LIB_DIR}")
 
   # install nvfuser python files
   install(DIRECTORY "${NVFUSER_ROOT}/python/"
--- a/functorch/CMakeLists.txt	2023-11-30 20:30:45.805209036 +0100
+++ b/functorch/CMakeLists.txt	2023-11-30 20:31:13.284766157 +0100
@@ -35,4 +35,4 @@
 if(NOT ${TORCH_PYTHON_LINK_FLAGS} STREQUAL "")
   set_target_properties(${PROJECT_NAME} PROPERTIES LINK_FLAGS ${TORCH_PYTHON_LINK_FLAGS})
 endif()
-install(TARGETS ${PROJECT_NAME} DESTINATION "${CMAKE_CURRENT_SOURCE_DIR}")
+install(TARGETS ${PROJECT_NAME} DESTINATION "${CMAKE_INSTALL_LIBDIR}")