diff options
| -rw-r--r-- | CMakeLists.txt | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 438e622..c496ad9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt | |||
| @@ -220,14 +220,17 @@ if(HAVE_STRCASECMP) | |||
| 220 | add_definitions(-DHAVE_STRCASECMP) | 220 | add_definitions(-DHAVE_STRCASECMP) |
| 221 | endif() | 221 | endif() |
| 222 | 222 | ||
| 223 | check_function_exists(strlcat HAVE_STRLCAT) | 223 | # Emscripten's strlcat and strlcpy triggers ASAN errors |
| 224 | if(HAVE_STRLCAT) | 224 | if(NOT EMSCRIPTEN) |
| 225 | add_definitions(-DHAVE_STRLCAT) | 225 | check_function_exists(strlcat HAVE_STRLCAT) |
| 226 | endif() | 226 | if(HAVE_STRLCAT) |
| 227 | add_definitions(-DHAVE_STRLCAT) | ||
| 228 | endif() | ||
| 227 | 229 | ||
| 228 | check_function_exists(strlcpy HAVE_STRLCPY) | 230 | check_function_exists(strlcpy HAVE_STRLCPY) |
| 229 | if(HAVE_STRLCPY) | 231 | if(HAVE_STRLCPY) |
| 230 | add_definitions(-DHAVE_STRLCPY) | 232 | add_definitions(-DHAVE_STRLCPY) |
| 233 | endif() | ||
| 231 | endif() | 234 | endif() |
| 232 | 235 | ||
| 233 | check_function_exists(strndup HAVE_STRNDUP) | 236 | check_function_exists(strndup HAVE_STRNDUP) |
