Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
glslang
Project
Overview
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
Chen Yisong
glslang
Commits
b8483872
Commit
b8483872
authored
Feb 18, 2020
by
durswd
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add an option to make RTTI enabled
parent
ae594356
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
0 deletions
+7
-0
CMakeLists.txt
CMakeLists.txt
+7
-0
No files found.
CMakeLists.txt
View file @
b8483872
...
@@ -56,6 +56,7 @@ CMAKE_DEPENDENT_OPTION(ENABLE_HLSL
...
@@ -56,6 +56,7 @@ CMAKE_DEPENDENT_OPTION(ENABLE_HLSL
ON
"NOT ENABLE_GLSLANG_WEBMIN"
ON
"NOT ENABLE_GLSLANG_WEBMIN"
OFF
)
OFF
)
option
(
ENABLE_RTTI
"Enables RTTI"
OFF
)
option
(
ENABLE_OPT
"Enables spirv-opt capability if present"
ON
)
option
(
ENABLE_OPT
"Enables spirv-opt capability if present"
ON
)
option
(
ENABLE_PCH
"Enables Precompiled header"
ON
)
option
(
ENABLE_PCH
"Enables Precompiled header"
ON
)
option
(
ENABLE_CTEST
"Enables testing"
ON
)
option
(
ENABLE_CTEST
"Enables testing"
ON
)
...
@@ -117,7 +118,9 @@ if(${CMAKE_CXX_COMPILER_ID} MATCHES "GNU")
...
@@ -117,7 +118,9 @@ if(${CMAKE_CXX_COMPILER_ID} MATCHES "GNU")
add_compile_options
(
-Wall -Wmaybe-uninitialized -Wuninitialized -Wunused -Wunused-local-typedefs
add_compile_options
(
-Wall -Wmaybe-uninitialized -Wuninitialized -Wunused -Wunused-local-typedefs
-Wunused-parameter -Wunused-value -Wunused-variable -Wunused-but-set-parameter -Wunused-but-set-variable -fno-exceptions
)
-Wunused-parameter -Wunused-value -Wunused-variable -Wunused-but-set-parameter -Wunused-but-set-variable -fno-exceptions
)
add_compile_options
(
-Wno-reorder
)
# disable this from -Wall, since it happens all over.
add_compile_options
(
-Wno-reorder
)
# disable this from -Wall, since it happens all over.
if
(
NOT ENABLE_RTTI
)
add_compile_options
(
-fno-rtti
)
add_compile_options
(
-fno-rtti
)
endif
()
if
(
NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS
"9.0.0"
)
if
(
NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS
"9.0.0"
)
add_compile_options
(
-Werror=deprecated-copy
)
add_compile_options
(
-Werror=deprecated-copy
)
endif
()
endif
()
...
@@ -125,9 +128,13 @@ elseif(${CMAKE_CXX_COMPILER_ID} MATCHES "Clang")
...
@@ -125,9 +128,13 @@ elseif(${CMAKE_CXX_COMPILER_ID} MATCHES "Clang")
add_compile_options
(
-Wall -Wuninitialized -Wunused -Wunused-local-typedefs
add_compile_options
(
-Wall -Wuninitialized -Wunused -Wunused-local-typedefs
-Wunused-parameter -Wunused-value -Wunused-variable
)
-Wunused-parameter -Wunused-value -Wunused-variable
)
add_compile_options
(
-Wno-reorder
)
# disable this from -Wall, since it happens all over.
add_compile_options
(
-Wno-reorder
)
# disable this from -Wall, since it happens all over.
if
(
NOT ENABLE_RTTI
)
add_compile_options
(
-fno-rtti
)
add_compile_options
(
-fno-rtti
)
endif
()
elseif
(
${
CMAKE_CXX_COMPILER_ID
}
MATCHES
"MSVC"
)
elseif
(
${
CMAKE_CXX_COMPILER_ID
}
MATCHES
"MSVC"
)
if
(
NOT ENABLE_RTTI
)
add_compile_options
(
/GR-
)
# Disable RTTI
add_compile_options
(
/GR-
)
# Disable RTTI
endif
()
endif
()
endif
()
if
(
ENABLE_GLSLANG_JS
)
if
(
ENABLE_GLSLANG_JS
)
...
...
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