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
OpenDAS
dlib
Commits
04371157
Commit
04371157
authored
Mar 22, 2022
by
Øystein Myrmo
Committed by
Davis E. King
Mar 23, 2022
Browse files
Increase template-depth for Clang only when needed
Clang 7 increased the default template-depth to 1024.
parent
4ebf3ef0
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
2 deletions
+3
-2
dlib/cmake_utils/set_compiler_specific_options.cmake
dlib/cmake_utils/set_compiler_specific_options.cmake
+3
-2
No files found.
dlib/cmake_utils/set_compiler_specific_options.cmake
View file @
04371157
...
...
@@ -131,8 +131,9 @@ if (CMAKE_COMPILER_IS_GNUCXX)
list
(
APPEND active_compile_opts
"-Wreturn-type"
)
endif
()
if
(
"Clang"
MATCHES
${
CMAKE_CXX_COMPILER_ID
}
)
# Increase clang's default tempalte recurision depth so the dnn examples don't error out.
if
(
"Clang"
MATCHES
${
CMAKE_CXX_COMPILER_ID
}
AND CMAKE_CXX_COMPILER_VERSION VERSION_LESS 7.0.0
)
# Clang 6 had a default template recursion depth of 256. This was changed to 1024 in Clang 7.
# It must be increased on Clang 6 and below to ensure that the dnn examples don't error out.
list
(
APPEND active_compile_opts
"-ftemplate-depth=500"
)
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