Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
gaoqiong
flash-attention
Commits
5259c586
Unverified
Commit
5259c586
authored
Oct 25, 2024
by
bnellnm
Committed by
GitHub
Oct 25, 2024
Browse files
use better method to specify cuda libraries (#23)
Signed-off-by:
Bill Nell
<
bill@neuralmagic.com
>
parent
013f0c4f
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
5 deletions
+1
-5
cmake/utils.cmake
cmake/utils.cmake
+1
-5
No files found.
cmake/utils.cmake
View file @
5259c586
...
...
@@ -359,11 +359,7 @@ function (define_gpu_extension_target GPU_MOD_NAME)
# Don't use `TORCH_LIBRARIES` for CUDA since it pulls in a bunch of
# dependencies that are not necessary and may not be installed.
if
(
GPU_LANGUAGE STREQUAL
"CUDA"
)
if
(
"
${
CUDA_CUDA_LIB
}
"
STREQUAL
""
)
set
(
CUDA_CUDA_LIB
"
${
CUDA_CUDA_LIBRARY
}
"
)
endif
()
target_link_libraries
(
${
GPU_MOD_NAME
}
PRIVATE
${
CUDA_CUDA_LIB
}
${
CUDA_LIBRARIES
}
)
target_link_libraries
(
${
GPU_MOD_NAME
}
PRIVATE CUDA::cudart CUDA::cuda_driver
)
else
()
target_link_libraries
(
${
GPU_MOD_NAME
}
PRIVATE
${
TORCH_LIBRARIES
}
)
endif
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment