From owner-svn-ports-all@freebsd.org Fri Jan 1 02:29:40 2021 Return-Path: Delivered-To: svn-ports-all@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 4AB724BAC7B; Fri, 1 Jan 2021 02:29:40 +0000 (UTC) (envelope-from jhale@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4D6TW81f4dz4mdY; Fri, 1 Jan 2021 02:29:40 +0000 (UTC) (envelope-from jhale@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 2B9221B520; Fri, 1 Jan 2021 02:29:40 +0000 (UTC) (envelope-from jhale@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 1012TdGM005248; Fri, 1 Jan 2021 02:29:39 GMT (envelope-from jhale@FreeBSD.org) Received: (from jhale@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 1012Tdr2005247; Fri, 1 Jan 2021 02:29:39 GMT (envelope-from jhale@FreeBSD.org) Message-Id: <202101010229.1012Tdr2005247@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhale set sender to jhale@FreeBSD.org using -f From: "Jason E. Hale" Date: Fri, 1 Jan 2021 02:29:39 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r559796 - in head/security: gpgme-cpp gpgme/files X-SVN-Group: ports-head X-SVN-Commit-Author: jhale X-SVN-Commit-Paths: in head/security: gpgme-cpp gpgme/files X-SVN-Commit-Revision: 559796 X-SVN-Commit-Repository: ports MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 01 Jan 2021 02:29:40 -0000 Author: jhale Date: Fri Jan 1 02:29:39 2021 New Revision: 559796 URL: https://svnweb.freebsd.org/changeset/ports/559796 Log: security/gpgme-cpp: Fix constness The 1.15.0 release of gpgme-cpp adds a `Signature::operator<` which is missing a const. In 6a6d2a27648, Signature got an operator< . This is used in *security/libkleo*, for instance, to sort the signatures for display. The build failure looks like this (trimmed for brevity, on 13-): === /usr/include/c++/v1/algorithm:715:71: error: invalid operands to binary expression ('const GpgME::UserID::Signature' and 'const GpgME::UserID::Signature') bool operator()(const _T1& __x, const _T1& __y) const {return __x < __y;} /wrkdirs/usr/ports/security/libkleo/work/libkleo-20.12.0/src/models/ useridlistmodel.cpp:203:14: note: in instantiation of function template specialization 'std::__1::sort' requested here std::sort(sigs.begin(), sigs.end()); === PR: 252283 Submitted by: adridg Added: head/security/gpgme/files/patch-git-key.h (contents, props changed) Modified: head/security/gpgme-cpp/Makefile Modified: head/security/gpgme-cpp/Makefile ============================================================================== --- head/security/gpgme-cpp/Makefile Fri Jan 1 02:20:54 2021 (r559795) +++ head/security/gpgme-cpp/Makefile Fri Jan 1 02:29:39 2021 (r559796) @@ -1,6 +1,6 @@ # $FreeBSD$ -PORTREVISION= 0 +PORTREVISION= 1 PKGNAMESUFFIX= -${SLAVEPORT} MAINTAINER= jhale@FreeBSD.org Added: head/security/gpgme/files/patch-git-key.h ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/security/gpgme/files/patch-git-key.h Fri Jan 1 02:29:39 2021 (r559796) @@ -0,0 +1,29 @@ +The operator< should be const, so it can be applied to const Signatures. +This fixes a build failure in security/libkleo. + +diff --git lang/cpp/src/key.cpp lang/cpp/src/key.cpp +index e536d080..7411e9e4 100644 +--- lang/cpp/src/key.cpp ++++ lang/cpp/src/key.cpp +@@ -865,7 +865,7 @@ UserID::Signature::Signature(const shared_gpgme_key_t &k, gpgme_user_id_t u, gpg + { + } + +-bool UserID::Signature::operator<(const Signature &other) ++bool UserID::Signature::operator<(const Signature &other) const + { + // based on cmp_signodes() in g10/keylist.c + +diff --git lang/cpp/src/key.h lang/cpp/src/key.h +index a7931672..57001a03 100644 +--- lang/cpp/src/key.h ++++ lang/cpp/src/key.h +@@ -468,7 +468,7 @@ public: + } + + /*! Defines a canonical sort order for signatures of the same user ID. */ +- bool operator<(const Signature &other); ++ bool operator<(const Signature &other) const; + + bool isNull() const + {