From acd9f139aa0613a4e16b357446cde68a67f8f6b6 Mon Sep 17 00:00:00 2001 From: Mihai Patrascoiu Date: Mar 01 2022 18:47:20 +0000 Subject: Apply patch for "libldap" linking problems on Fedora36 --- diff --git a/0000-Recent-versions-of-openldap-have-merged-libldap_r-into-libldap.patch b/0000-Recent-versions-of-openldap-have-merged-libldap_r-into-libldap.patch new file mode 100644 index 0000000..89ff2a3 --- /dev/null +++ b/0000-Recent-versions-of-openldap-have-merged-libldap_r-into-libldap.patch @@ -0,0 +1,20 @@ +commit e687e131c5fb783ddf13640f1cec6a3086ad3090 +Author: Chris Burr +Date: Mon Jan 24 15:34:07 2022 +0100 + + Recent versions of openldap have merged libldap_r into libldap + +diff --git a/src/utils/CMakeLists.txt b/src/utils/CMakeLists.txt +index 2a7871b8..1998f531 100644 +--- a/src/utils/CMakeLists.txt ++++ b/src/utils/CMakeLists.txt +@@ -7,7 +7,8 @@ if (IS_IFCE) + list (APPEND src_mds "${CMAKE_CURRENT_SOURCE_DIR}/mds/gfal_mds.c") + else (IS_IFCE) + list (APPEND gfal2_utils_definitions "-DMDS_BDII_EXTERNAL=0") +- list (APPEND is_ifce_link "ldap_r" "lber") ++ find_library(LDAP_LIBRARY NAMES ldap_r ldap) ++ list (APPEND is_ifce_link ${LDAP_LIBRARY} "lber") + list (APPEND src_mds + "${CMAKE_CURRENT_SOURCE_DIR}/mds/gfal_mds.c" + "${CMAKE_CURRENT_SOURCE_DIR}/mds/gfal_mds_internal.c" diff --git a/gfal2.spec b/gfal2.spec index b77f036..5841917 100644 --- a/gfal2.spec +++ b/gfal2.spec @@ -20,6 +20,9 @@ URL: https://dmc-docs.web.cern.ch/dmc-docs/gfal2/gfal2.html # popd # tar czf gfal2-2.20.0.tar.gz --exclude-vcs gfal2-2.20.0 Source0: %{name}-%{version}.tar.gz +# Patch from: +# https://gitlab.cern.ch/dmc/gfal2/-/merge_requests/43 +Patch0: 0000-Recent-versions-of-openldap-have-merged-libldap_r-into-libldap.patch #main lib dependencies BuildRequires: gcc-c++ @@ -223,6 +226,7 @@ gfal2 tests %prep %setup -q +%patch0 -p1 %build # Make sure the version in the spec file and the version used