From 29583196dfae2565a35c7a8759cc8a5640d6a2b1 Mon Sep 17 00:00:00 2001 From: Even Rouault Date: Sun, 9 Feb 2020 00:53:35 +0100 Subject: Use relative directory to locate PROJ resource files. Fixes #1490 This is an extension of the Window-specific logic added recently to Unix builds. This reuses parts of proposed past commit https://github.com/OSGeo/PROJ/pull/1517/commits/82a07e51c6e24ddb936d131ababe29f1ac36ef14 (credits to @abellgithub) --- cmake/ProjConfig.cmake | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'cmake/ProjConfig.cmake') diff --git a/cmake/ProjConfig.cmake b/cmake/ProjConfig.cmake index 661e6e4f..fa085384 100644 --- a/cmake/ProjConfig.cmake +++ b/cmake/ProjConfig.cmake @@ -25,9 +25,11 @@ check_include_files("stdlib.h;stdarg.h;string.h;float.h" STDC_HEADERS) check_function_exists(localeconv HAVE_LOCALECONV) check_function_exists(strerror HAVE_STRERROR) - -# check libm need on unix -check_library_exists(m ceil "" HAVE_LIBM) +if(NOT WIN32) + check_library_exists(dl dladdr "" HAVE_LIBDL) + # check libm need on unix + check_library_exists(m ceil "" HAVE_LIBM) +endif() set(PACKAGE "proj") set(PACKAGE_BUGREPORT "https://github.com/OSGeo/PROJ/issues") -- cgit v1.2.3