# HG changeset patch # User Sebastien Jodogne # Date 1503510391 -7200 # Node ID 60d92061361025bfec1f809b4ec432d289f6d4fd # Parent 2b4bc54f96272e0f12a6635b5c47a2fd83b12dbe fixes for freebsd diff -r 2b4bc54f9627 -r 60d920613610 Resources/CMake/PostgreSQLConfiguration.cmake --- a/Resources/CMake/PostgreSQLConfiguration.cmake Wed Aug 23 19:41:42 2017 +0200 +++ b/Resources/CMake/PostgreSQLConfiguration.cmake Wed Aug 23 19:46:31 2017 +0200 @@ -150,7 +150,8 @@ file(READ ${CMAKE_SOURCE_DIR}/Resources/Platforms/printf_archetype.c SOURCE) check_c_source_compiles("${SOURCE}" printf_archetype) - if (printf_archetype) + if (printf_archetype AND + NOT CMAKE_SYSTEM_NAME STREQUAL "FreeBSD") set(PG_PRINTF_ATTRIBUTE "gnu_printf") else() set(PG_PRINTF_ATTRIBUTE "printf") @@ -159,6 +160,7 @@ check_function_exists("unsetenv" HAVE_UNSETENV) check_function_exists("getaddrinfo" HAVE_GETADDRINFO) check_function_exists("gettimeofday" HAVE_GETTIMEOFDAY) + check_function_exists("srandom" HAVE_SRANDOM) check_type_size("struct addrinfo" SIZE_STRUCT_ADDRINFO) if (HAVE_SIZE_STRUCT_ADDRINFO)