diff --git a/net-im/libquotient/Makefile b/net-im/libquotient/Makefile index a7baa9492b5b..391de8c11914 100644 --- a/net-im/libquotient/Makefile +++ b/net-im/libquotient/Makefile @@ -1,33 +1,33 @@ PORTNAME= libquotient DISTVERSION= 0.7.1 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= net-im MAINTAINER= adridg@FreeBSD.org COMMENT= Matrix IM support library using Qt technologies WWW= https://github.com/quotient-im/libQuotient LICENSE= LGPL21 LICENSE_FILE= ${WRKSRC}/COPYING LIB_DEPENDS= libqt5keychain.so:security/qtkeychain@qt5 USES= cmake qt:5 tar:xz USE_QT= concurrent core gui multimedia network \ buildtools:build qmake:build testlib:build CONFLICTS= libqmatrixclient\* USE_GITHUB= yes GH_ACCOUNT= quotient-im GH_PROJECT= libQuotient CMAKE_ARGS= -DQuotient_INSTALL_TESTS=OFF # Work around compiler bug, see pr: 272285 USES+= llvm CC= ${LLVM_PREFIX}/bin/clang CPP= ${LLVM_PREFIX}/bin/clang-cpp CXX= ${LLVM_PREFIX}/bin/clang++ .include diff --git a/net-im/libquotient/files/patch-lib_qt__connection__util.h b/net-im/libquotient/files/patch-lib_qt__connection__util.h index e180df41eedd..a1ee6b2cbc57 100644 --- a/net-im/libquotient/files/patch-lib_qt__connection__util.h +++ b/net-im/libquotient/files/patch-lib_qt__connection__util.h @@ -1,52 +1,52 @@ The call std::bind_front() below only works from LLVM 14 on because libc++ needs https://reviews.llvm.org/D107199 to work correctly, otherwise uses of connectSingleShot() fail. See net-im/neochat for example [1]: In file included from /wrkdirs/usr/ports/net-im/neochat/work/neochat-23.04.2/src/controller.cpp:5: In file included from /wrkdirs/usr/ports/net-im/neochat/work/neochat-23.04.2/src/controller.h:6: In file included from /usr/local/include/qt5/QtCore/QObject:1: In file included from /usr/local/include/qt5/QtCore/qobject.h:46: In file included from /usr/local/include/qt5/QtCore/qobjectdefs.h:48: In file included from /usr/local/include/qt5/QtCore/qnamespace.h:43: In file included from /usr/local/include/qt5/QtCore/qglobal.h:142: In file included from /usr/include/c++/v1/algorithm:653: In file included from /usr/include/c++/v1/functional:495: In file included from /usr/include/c++/v1/__functional/bind_front.h:14: /usr/include/c++/v1/__functional/perfect_forward.h:77:9: error: no matching constructor for initialization of 'tuple' __bound_(_VSTD::forward<_BoundArgs>(__bound)...) { } ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/local/include/Quotient/qt_connection_util.h:22:14: note: in instantiation of function template specialization 'std::__perfect_forward_impl, std::__tuple_indices<0, 1>>::__perfect_forward_impl, std::__tuple_indices<0, 1>> &>' requested here [slotLike, pConn = std::move(pConn)](const auto&... args) ^ /usr/local/include/Quotient/qt_connection_util.h:93:23: note: in instantiation of function template specialization 'Quotient::_impl::connect, std::__tuple_indices<0, 1>>>' requested here return _impl::connect<_impl::SingleShot>( ^ /wrkdirs/usr/ports/net-im/neochat/work/neochat-23.04.2/src/controller.cpp:372:25: note: in instantiation of function template specialization 'Quotient::connectSingleShot' requested here connectSingleShot(connection, &Connection::syncDone, this, &Controller::initiated); ^ [1] https://pkg-status.freebsd.org/beefy2/data/124amd64-quarterly/8898bf465b47/logs/neochat-23.04.2.log --- lib/qt_connection_util.h +++ lib/qt_connection_util.h @@ -3,6 +3,8 @@ #pragma once +#include // For __FreeBSD_version + #include "function_traits.h" #include @@ -81,7 +83,10 @@ inline auto connectSingleShot(auto* sender, auto signal, ContextT* context, // object has to be pre-bound to the slot to make it self-contained if constexpr (_impl::PmfSlot) { auto&& boundSlot = -# if __cpp_lib_bind_front // Needs Apple Clang 13 (other platforms are fine) +# if __cpp_lib_bind_front && \ -+ !defined(__FreeBSD_version) || __FreeBSD_version >= 1301504 ++ (!defined(__FreeBSD_version) || __FreeBSD_version >= 1301504) + // This requires LLVM >= 14, this only works with libc++ commit + // https://reviews.llvm.org/D107199. std::bind_front(slot, context); # else [context, slot](const auto&... args)