Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
BC
public
external
mbedtls
Commits
469238a9
Commit
469238a9
authored
Jan 31, 2014
by
Manuel Pégourié-Gonnard
Browse files
cmake: add 'ASan' build type
parent
0933d1fe
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
1 deletion
+3
-1
CMakeLists.txt
CMakeLists.txt
+3
-1
No files found.
CMakeLists.txt
View file @
469238a9
...
@@ -9,6 +9,7 @@ if(CMAKE_COMPILER_IS_GNUCC)
...
@@ -9,6 +9,7 @@ if(CMAKE_COMPILER_IS_GNUCC)
set
(
CMAKE_C_FLAGS
"
${
CMAKE_C_FLAGS
}
-O2 -Wall -Wextra -W -Wdeclaration-after-statement"
)
set
(
CMAKE_C_FLAGS
"
${
CMAKE_C_FLAGS
}
-O2 -Wall -Wextra -W -Wdeclaration-after-statement"
)
set
(
CMAKE_C_FLAGS_DEBUG
"-g3 -O0"
)
set
(
CMAKE_C_FLAGS_DEBUG
"-g3 -O0"
)
set
(
CMAKE_C_FLAGS_COVERAGE
"-g3 -O0 --coverage"
)
set
(
CMAKE_C_FLAGS_COVERAGE
"-g3 -O0 --coverage"
)
set
(
CMAKE_C_FLAGS_ASAN
"-fsanitize=address -fno-omit-frame-pointer -g3 -O1"
)
set
(
CMAKE_C_FLAGS_CHECK
"
${
CMAKE_C_FLAGS
}
-Werror -Wlogical-op -Wwrite-strings"
)
set
(
CMAKE_C_FLAGS_CHECK
"
${
CMAKE_C_FLAGS
}
-Werror -Wlogical-op -Wwrite-strings"
)
set
(
CMAKE_C_FLAGS_CHECKFULL
"
${
CMAKE_C_FLAGS_CHECK
}
-Wcast-qual"
)
set
(
CMAKE_C_FLAGS_CHECKFULL
"
${
CMAKE_C_FLAGS_CHECK
}
-Wcast-qual"
)
endif
(
CMAKE_COMPILER_IS_GNUCC
)
endif
(
CMAKE_COMPILER_IS_GNUCC
)
...
@@ -17,11 +18,12 @@ if(CMAKE_COMPILER_IS_CLANG)
...
@@ -17,11 +18,12 @@ if(CMAKE_COMPILER_IS_CLANG)
set
(
CMAKE_C_FLAGS
"
${
CMAKE_C_FLAGS
}
-O2 -Wall -Wextra -W -Wdeclaration-after-statement"
)
set
(
CMAKE_C_FLAGS
"
${
CMAKE_C_FLAGS
}
-O2 -Wall -Wextra -W -Wdeclaration-after-statement"
)
set
(
CMAKE_C_FLAGS_DEBUG
"-g3 -O0"
)
set
(
CMAKE_C_FLAGS_DEBUG
"-g3 -O0"
)
set
(
CMAKE_C_FLAGS_COVERAGE
"-g3 -O0 --coverage"
)
set
(
CMAKE_C_FLAGS_COVERAGE
"-g3 -O0 --coverage"
)
set
(
CMAKE_C_FLAGS_ASAN
"-fsanitize=address -fno-omit-frame-pointer -g3 -O1"
)
set
(
CMAKE_C_FLAGS_CHECK
"
${
CMAKE_C_FLAGS
}
-Werror -Wpointer-arith -Wwrite-strings -Wdocumentation"
)
set
(
CMAKE_C_FLAGS_CHECK
"
${
CMAKE_C_FLAGS
}
-Werror -Wpointer-arith -Wwrite-strings -Wdocumentation"
)
endif
(
CMAKE_COMPILER_IS_CLANG
)
endif
(
CMAKE_COMPILER_IS_CLANG
)
set
(
CMAKE_BUILD_TYPE
${
CMAKE_BUILD_TYPE
}
set
(
CMAKE_BUILD_TYPE
${
CMAKE_BUILD_TYPE
}
CACHE STRING
"Choose the type of build: None Debug Release Coverage Check CheckFull"
CACHE STRING
"Choose the type of build: None Debug Release Coverage
ASan
Check CheckFull"
FORCE
)
FORCE
)
if
(
CMAKE_BUILD_TYPE STREQUAL
"Coverage"
)
if
(
CMAKE_BUILD_TYPE STREQUAL
"Coverage"
)
...
...
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