shithub: choc

Download patch

ref: 360da28234c5aef0690a115fcf625e06d95470d2
parent: 9d815c5d43b8bfddab5900cd24abb9c11ddbcb90
author: Alex Mayfield <alexmax2742@gmail.com>
date: Sun Jun 3 06:50:32 EDT 2018

Fix strcasecmp detection

Our detection must include strings.h.

--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -46,9 +46,9 @@
 
 find_package(m)
 
-include(CheckFunctionExists)
-check_function_exists(strcasecmp HAVE_DECL_STRCASECMP)
-check_function_exists(strncasecmp HAVE_DECL_STRNCASECMP)
+include(CheckSymbolExists)
+check_symbol_exists(strcasecmp "strings.h" HAVE_DECL_STRCASECMP)
+check_symbol_exists(strncasecmp "strings.h" HAVE_DECL_STRNCASECMP)
 
 set(WINDOWS_RC_VERSION "${PROJECT_VERSION_MAJOR}, ${PROJECT_VERSION_MINOR}, ${PROJECT_VERSION_PATCH}, 0")