Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
S
stitchEm
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Franco (nextime) Lanza
stitchEm
Commits
0bff65f8
Commit
0bff65f8
authored
Apr 06, 2020
by
keven-ma
Committed by
jeremad
Apr 11, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix CUDA runtime errors caused by /GL compiler option
parent
729ba40e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
0 deletions
+12
-0
libvideostitch_CUDA.cmake
lib/libvideostitch_CUDA.cmake
+12
-0
No files found.
lib/libvideostitch_CUDA.cmake
View file @
0bff65f8
...
...
@@ -136,9 +136,21 @@ cuda_include_directories(src ${CMAKE_EXTERNAL_DEPS}/include)
cuda_include_directories
(
${
VS_DISCOVERY_PUBLIC_HEADERS_DIR
}
)
cuda_include_directories
(
${
VS_LIB_PUBLIC_HEADERS_DIR
}
)
if
(
MSVC
)
string
(
FIND
${
CMAKE_CXX_FLAGS_RELEASE
}
"/GL"
CONTAINS_GL_FLAG
)
# /GL option will cause CUDA runtime errors when building with Visual Studio 2017 and CUDA 10.2
STRING
(
REPLACE
" /GL"
""
CMAKE_CXX_FLAGS_RELEASE
"
${
CMAKE_CXX_FLAGS_RELEASE
}
"
)
endif
()
# CMake object libs don't work with CUDA
cuda_compile
(
BACKEND_OBJECTS_CUDA
${
CUDA_SOURCES
}
)
if
(
MSVC
)
if
(
CONTAINS_GL_FLAG GREATER 0
)
set
(
CMAKE_CXX_FLAGS_RELEASE
"
${
CMAKE_CXX_FLAGS_RELEASE
}
/GL"
)
endif
()
endif
()
add_library
(
${
VS_LIB_OBJECTS_CUDA
}
OBJECT
${
CORE_LIB_SOURCES
}
${
CORE_LIB_HEADERS
}
${
CUDA_BACKEND_SOURCES
}
${
CUDA_BACKEND_HEADERS
}
)
add_cppcheck
(
${
VS_LIB_OBJECTS_CUDA
}
VS
)
...
...
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