On Thursday 21 May 2009, David Carter wrote: > I'm writing a configuration that will use Microsoft's secure functions > when available, and use the standard versions on other platforms. I've > got these lines in CMakeLists.txt: > > CHECK_FUNCTION_EXISTS("ctime_s" HAVE_CTIME_S) > CHECK_FUNCTION_EXISTS("strcpy_s" HAVE_STRCPY_S) > CHECK_FUNCTION_EXISTS("strncpy_s" HAVE_STRNCPY_S) > CHECK_FUNCTION_EXISTS("strncat_s" HAVE_STRNCAT_S) > > It works for all functions except ctime_s, even though I know it's in > there, defined in the time.h (or ctime for C++) header.
Maybe some preprocessor symbol has to be defined to get it enabled ? Or it's just a macro and check_function_exists() expects a real function ? In CMakeFile/CMakeError.log you should see the error message which was generated. Alex _______________________________________________ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake