dev-libs/xmlsec: Sync with Gentoo

It's from Gentoo commit 885e8b3941b4617906768a9358979fd5e4da01a7.
This commit is contained in:
Flatcar Buildbot 2024-07-01 07:13:49 +00:00 committed by Mathieu Tortuyaux
parent 502d9f3c10
commit d51a4a9e17
No known key found for this signature in database
GPG Key ID: AC5CCFB52545D9B8
4 changed files with 23 additions and 158 deletions

View File

@ -1,5 +1,6 @@
DIST xmlsec1-1.2.37.tar.gz 2009175 BLAKE2B 19f43ba6bf6eb49428b9c5563baecbab21476f326cceee13785ae16769afa258f100732831c0f3f7d160543bd075cdcfdc5cbf11b7406637ee6c2f0e27c07f30 SHA512 99220cb28a346ffac0023f9f177d6a7be3ddcea04bea434b7dc926c1f0aaa5564d75f74f92896ac100179c04d77e001f688ddf46fed4e0a0b4f20b7b87c24900
DIST xmlsec1-1.2.38.tar.gz 2036578 BLAKE2B 03f7e1b5e659793bf1984c5a59582d9459089ce913620d5cc1e5a5d0eb65557580cd23fa190db277298fd7cc55bd41563b93cf61a37c8b7521a4690cd2ca3489 SHA512 724089777caae95db27e67f24381c066eaae23a9d64819a18bb04837c1ab1b380d19be2c7ee25659ca481d9eab96fcbe8027a430a0ac1630ad3b073cddd20fac
DIST xmlsec1-1.2.39.tar.gz 2036905 BLAKE2B c1844f2068f6afe8dff3bf3fcf45a7180f09cae3418812b49b5c86b5387c795900a9ebd2077691d51d778c081f4282a54fdc11e7a54e6b8d969ef2871c2f5bb8 SHA512 bc8457bca8ada87c12d3be685bf8ad805f102b4ac1265e257ba12137e0430783973f27d22bfcb7559be5e89cb4c01b3556488fa641fc7c9d8f403972fdc8f2f7
DIST xmlsec1-1.3.1.tar.gz 2432943 BLAKE2B 1dafdffd959579add5c579e3fa9c9f9ddc73ce4aadc6fc2139506e6e64ffcd1bbe7298786e414900eb9f33f93b0a47da64e686c499e48d4c80d81b256db6692e SHA512 7f30c15c3edcafe70fa5febaa0ba39f73f8d30525ee102b5961a658dd2842fbc58e63f7595f15b150d71bf735bfa7688c3694a191b0d475776ca26902d90d25f
DIST xmlsec1-1.3.2.tar.gz 2437263 BLAKE2B d11953c6e2a263a6742ef62309c2f29e2ba5761d58bee5f8cc761965d0e16fea148811ac3d8036d271400840a62ff2a7fff947bb5331170d3bcc598c558b2a95 SHA512 328f3d27cc1dadee27e5ee4649f6c5a094203cc27f42f1fe98fd429f7dd5630eaadff0e8bf14616016fc3530482ed8bcee4870289a41a083f6dd9bd603782a92
DIST xmlsec1-1.3.3.tar.gz 2435741 BLAKE2B 1b0e44a8a5185d67b8f97ec72cd8e215fe79a988eb7ade0d2890be662b693d511857b24670ec692f9452bf95ad8c53ff80c250ecbcd167742477a83e0b72fda0 SHA512 1535b6f878259914ab9574892d05c927fbcd548986cf7bcf91e435acb2cb74eb11e58163f797038ee13a11444882814b2b4318cd677053fbe52557a2e4acf68a
DIST xmlsec1-1.3.4.tar.gz 2435656 BLAKE2B b398f970e5b201971419b537125e9a7430c8d7c1c57e193b2592ee3f01ce797993607a210e87ad44e99bc0ef49ac4c350492268a3ac3bedbb81d937d99837468 SHA512 959a97ed7d7cbdc3e5ef037b2cb4f05bda299274c09ed3dfe24f7203d97e3dfc13bf480e15a2d15bcc7893569d341204884de58cc9b462b6c29306b67672e9c7

View File

@ -1,114 +0,0 @@
https://github.com/lsh123/xmlsec/commit/ffb327376f5bb69e8dfe7f805529e45a40118c2b
From ffb327376f5bb69e8dfe7f805529e45a40118c2b Mon Sep 17 00:00:00 2001
From: lsh123 <aleksey@aleksey.com>
Date: Mon, 20 Nov 2023 11:50:43 -0500
Subject: [PATCH] Fix libxml2 v2.12.0 includes (#729)
--- a/apps/crypto.c
+++ b/apps/crypto.c
@@ -12,6 +12,7 @@
#endif
#include <string.h>
+#include <stdlib.h>
#include <xmlsec/xmlsec.h>
#include <xmlsec/keys.h>
--- a/apps/xmlsec.c
+++ b/apps/xmlsec.c
@@ -22,6 +22,7 @@
#include <libxml/xmlmemory.h>
#include <libxml/parser.h>
#include <libxml/xpath.h>
+#include <libxml/xmlsave.h>
#include <libxml/xpathInternals.h>
#ifndef XMLSEC_NO_XSLT
@@ -3030,7 +3031,7 @@ xmlSecAppInit(void) {
/* Init libxml */
xmlInitParser();
LIBXML_TEST_VERSION
- xmlTreeIndentString = "\t";
+ xmlThrDefTreeIndentString("\t");
#ifndef XMLSEC_NO_XSLT
xmlIndentTreeOutput = 1;
#endif /* XMLSEC_NO_XSLT */
--- a/include/xmlsec/xmlsec.h
+++ b/include/xmlsec/xmlsec.h
@@ -12,6 +12,7 @@
#define __XMLSEC_H__
#include <libxml/tree.h>
+#include <libxml/parser.h>
#include <xmlsec/version.h>
#include <xmlsec/exports.h>
--- a/src/errors_helpers.h
+++ b/src/errors_helpers.h
@@ -136,7 +136,7 @@ extern "C" {
*/
#define xmlSecXmlError(errorFunction, errorObject) \
{ \
- xmlErrorPtr error = xmlGetLastError(); \
+ const xmlError * error = xmlGetLastError(); \
int code = (error != NULL) ? error->code : 0; \
const char* message = (error != NULL) ? error->message : NULL; \
xmlSecError(XMLSEC_ERRORS_HERE, \
@@ -159,7 +159,7 @@ extern "C" {
*/
#define xmlSecXmlError2(errorFunction, errorObject, msg, param) \
{ \
- xmlErrorPtr error = xmlGetLastError(); \
+ const xmlError * error = xmlGetLastError(); \
int code = (error != NULL) ? error->code : 0; \
const char* message = (error != NULL) ? error->message : NULL; \
xmlSecError(XMLSEC_ERRORS_HERE, \
@@ -181,7 +181,7 @@ extern "C" {
*/
#define xmlSecXmlParserError(errorFunction, ctxt, errorObject) \
{ \
- xmlErrorPtr error = xmlCtxtGetLastError(ctxt);\
+ const xmlError * error = xmlCtxtGetLastError(ctxt);\
int code = (error != NULL) ? error->code : 0; \
const char* message = (error != NULL) ? error->message : NULL; \
xmlSecError(XMLSEC_ERRORS_HERE, \
@@ -205,7 +205,7 @@ extern "C" {
*/
#define xmlSecXmlParserError2(errorFunction, ctxt, errorObject, msg, param) \
{ \
- xmlErrorPtr error = xmlCtxtGetLastError(ctxt);\
+ const xmlError * error = xmlCtxtGetLastError(ctxt);\
int code = (error != NULL) ? error->code : 0; \
const char* message = (error != NULL) ? error->message : NULL; \
xmlSecError(XMLSEC_ERRORS_HERE, \
@@ -227,7 +227,7 @@ extern "C" {
*/
#define xmlSecXsltError(errorFunction, ctxt, errorObject) \
{ \
- xmlErrorPtr error = xmlGetLastError(); \
+ const xmlError * error = xmlGetLastError(); \
int code = (error != NULL) ? error->code : 0; \
const char* message = (error != NULL) ? error->message : NULL; \
xmlSecError(XMLSEC_ERRORS_HERE, \
--- a/src/mscrypto/certkeys.c
+++ b/src/mscrypto/certkeys.c
@@ -18,6 +18,7 @@
#include "globals.h"
#include <string.h>
+#include <stdlib.h>
#ifndef XMLSEC_NO_GOST
#include "csp_oid.h"
--- a/src/mscrypto/signatures.c
+++ b/src/mscrypto/signatures.c
@@ -17,6 +17,7 @@
#include "globals.h"
#include <string.h>
+#include <stdlib.h>
#ifndef XMLSEC_NO_GOST
#include "csp_calg.h"

View File

@ -3,34 +3,34 @@
EAPI=8
inherit autotools
DESCRIPTION="Command line tool for signing, verifying, encrypting and decrypting XML"
HOMEPAGE="https://www.aleksey.com/xmlsec"
SRC_URI="https://www.aleksey.com/xmlsec/download/${PN}1-${PV}.tar.gz"
S="${WORKDIR}/${PN}1-${PV}"
LICENSE="MIT"
# Upstream consider major version bumps to be changes in either X or Y in X.Y.Z
SLOT="0/$(ver_cut 1-2)"
KEYWORDS="amd64 ~arm arm64 ~loong ~ppc ppc64 ~riscv ~sparc x86"
IUSE="doc gcrypt gnutls http nss +openssl static-libs test"
SLOT="0"
KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc ~ppc64 ~riscv ~sparc ~x86"
IUSE="doc gcrypt gnutls nss +openssl static-libs test"
RESTRICT="!test? ( test )"
REQUIRED_USE="
|| ( gnutls nss openssl )
|| ( gcrypt gnutls nss openssl )
gnutls? ( gcrypt )
"
RDEPEND="
>=dev-libs/libxml2-2.7.4
>=dev-libs/libxml2-2.7.4[ftp(+)]
>=dev-libs/libxslt-1.0.20
dev-libs/libltdl
gcrypt? ( >=dev-libs/libgcrypt-1.4.0:= )
gnutls? ( >=net-libs/gnutls-3.6.13:= )
gnutls? ( >=net-libs/gnutls-2.8.0:= )
nss? (
>=dev-libs/nspr-4.4.1
>=dev-libs/nss-3.9
)
openssl? ( dev-libs/openssl:= )
openssl? (
dev-libs/openssl:=
)
"
DEPEND="${RDEPEND}"
BDEPEND="
@ -43,43 +43,21 @@ BDEPEND="
"
PATCHES=(
"${FILESDIR}"/${PN}-1.3.0-optimisation.patch
"${FILESDIR}"/${P}-libxml2-2.12.0-includes.patch
"${FILESDIR}"/${PN}-1.2.37-libressl.patch # bug #903001
)
src_prepare() {
default
eautoreconf
}
src_configure() {
local myeconfargs=(
$(use_enable doc docs)
$(use_enable static-libs static)
$(use_with gcrypt)
$(use_with gnutls)
$(use_with nss nspr)
$(use_with nss)
$(use_with openssl)
--disable-werror
--enable-mans
--enable-pkgconfig
--enable-concatkdf
--enable-pbkdf2
--enable-ec
--enable-dh
--enable-sha3
--enable-files
$(use_enable http)
--disable-ftp
)
# Bash because of bug #721128
CONFIG_SHELL="${BROOT}"/bin/bash econf "${myeconfargs[@]}"
CONFIG_SHELL="${BROOT}"/bin/bash econf \
$(use_enable doc docs) \
$(use_enable static-libs static) \
$(use_with gcrypt) \
$(use_with gnutls) \
$(use_with nss nspr) \
$(use_with nss) \
$(use_with openssl) \
--enable-mans \
--enable-pkgconfig
}
src_test() {