[
https://issues.apache.org/jira/browse/PROTON-1974?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16701095#comment-16701095
]
Jiri Daněk commented on PROTON-1974:
------------------------------------
h3. Patch
{noformat}
diff --git a/tools/cmake/Modules/FindCyrusSASL.cmake
b/tools/cmake/Modules/FindCyrusSASL.cmake
index ebd0eab1..eeb3dbfc 100644
--- a/tools/cmake/Modules/FindCyrusSASL.cmake
+++ b/tools/cmake/Modules/FindCyrusSASL.cmake
@@ -47,6 +47,7 @@ set (CyrusSASL_VERSION ${PC_CyrusSASL_VERSION})
include (FindPackageHandleStandardArgs)
find_package_handle_standard_args (CyrusSASL
+ FOUND_VAR CyrusSASL_FOUND
REQUIRED_VARS CyrusSASL_LIBRARY CyrusSASL_INCLUDE_DIR
VERSION_VAR CyrusSASL_VERSION
)
diff --git a/tools/cmake/Modules/FindJsonCpp.cmake
b/tools/cmake/Modules/FindJsonCpp.cmake
index 083d3fc9..242718dc 100644
--- a/tools/cmake/Modules/FindJsonCpp.cmake
+++ b/tools/cmake/Modules/FindJsonCpp.cmake
@@ -49,6 +49,7 @@ set(JsonCpp_VERSION ${PC_JsonCpp_VERSION})
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(JsonCpp
+ FOUND_VAR JsonCpp_FOUND
REQUIRED_VARS JsonCpp_LIBRARY JsonCpp_INCLUDE_DIR
VERSION_VAR JsonCpp_VERSION)
diff --git a/tools/cmake/Modules/FindLibuv.cmake
b/tools/cmake/Modules/FindLibuv.cmake
index 422e124a..e38cfaf9 100644
--- a/tools/cmake/Modules/FindLibuv.cmake
+++ b/tools/cmake/Modules/FindLibuv.cmake
@@ -49,6 +49,7 @@ set(Libuv_VERSION ${PC_Libuv_VERSION})
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(Libuv
+ FOUND_VAR Libuv_FOUND
REQUIRED_VARS Libuv_LIBRARY Libuv_INCLUDE_DIR
VERSION_VAR Libuv_VERSION)
{noformat}
> Libraries are not being correctly detected in CMake build scripts when old
> CMake is used
> ----------------------------------------------------------------------------------------
>
> Key: PROTON-1974
> URL: https://issues.apache.org/jira/browse/PROTON-1974
> Project: Qpid Proton
> Issue Type: Bug
> Components: build, proton-c
> Affects Versions: proton-c-0.25.0, proton-c-0.26.0
> Environment: RHEL 7, CMake 2.8.12.2
> Reporter: Jiri Daněk
> Priority: Major
>
> On CMake 2.8.12.2, function {{find_package_handle_standard_args}} sets (by
> default) only the {{<PACKAGENAME>_FOUND}} variable. With newer versions, such
> as 3.12.1, both the uppercased, as well as the unmodified
> {{<PackageName>_FOUND}} are set. Proton examines the unmodified variable.
> As a result, with older CMake, optional libraries such as Cyrus SASL are
> detected by CMake, but then are not used by proton-c, as if they were not
> present on the system.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]