openwrt-packages/libs/getdns/patches/getdns-1.6.0-fix-crosscompi...

12 lines
340 B
Diff

--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -523,7 +523,7 @@ set(STRPTIME_TEST_SOURCE "\n
res = strptime(\"20070207111842\", \"%Y%m%d%H%M%S\", &tm);\n
if (!res) return 1; return 0; }")
-if (HAVE_STRPTIME)
+if (HAVE_STRPTIME AND NOT CMAKE_CROSSCOMPILING)
check_c_source_runs("${STRPTIME_TEST_SOURCE}" STRPTIME_WORKS)
endif ()