libp11: backport fix for missing p11_ver.h in installed headers
PATCH 1/1 libp11: backport fix for missing p11_ver.h in installed headers
From: Daiane Angolini <[email protected]>
The installed public header libp11.h includes "p11_ver.h", but that header is generated by configure (from p11_ver.h.in, via AC_CONFIG_FILES) and was never listed in include_HEADERS, so it never gets installed.
Any consumer including <libp11.h> therefore fails to build. For example rng-tools with PACKAGECONFIG "libp11" enabled:
| In file included from rngd_pkcs11.c:28: | recipe-sysroot/usr/include/libp11.h:28:10: fatal error: p11_ver.h: No such file or directory | 28 | #include "p11_ver.h" | | ^~~~~~~~~~~ | compilation terminated.
Backport the upstream fix, which adds p11_ver.h to include_HEADERS. It landed after the libp11-0.4.19 tag and is not part of any release yet, so it cannot be picked up by a version upgrade.
Signed-off-by Daiane Angolini <[email protected]>
--- ...-p11_ver.h-file-to-installed-headers.patch | 32 +++++++++++++++++++ .../recipes-support/libp11/libp11_0.4.19.bb | 4 ++- 2 files changed, 35 insertions(+), 1 deletion(-) create mode 100644 meta-oe/recipes-support/libp11/libp11/0001-Add-missing-p11_ver.h-file-to-installed-headers.patch
meta-oe/recipes-support/libp11/libp11/0001-Add-missing-p11_ver.h-file-to-installed-headers.patch new file +32 -0
@@ -0,0 +1,32 @@ +From 007043d355a9f7f1cd3cb6e80d16cad609fdf2a1 Mon Sep 17 00:00:00 2001 +From: botantony <[email protected]> +Date: Wed, 22 Jul 2026 02:50:28 +0200 +Subject: [PATCH] Add missing `p11_ver.h` file to installed headers + +Running `make install` does not install `p11_ver.h` header which is used +by `p11_err.h`. This PR fixes it + +Found in https://github.com/Homebrew/homebrew-core/pull/294427 + +Signed-off-by: botantony <[email protected]> + +Upstream-Status: Backport [https://github.com/OpenSC/libp11/commit/007043d355a9f7f1cd3cb6e80d16cad609fdf2a1] +--- + src/Makefile.am | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/Makefile.am b/src/Makefile.am +index 92d3fdb..549ac67 100644 +--- a/src/Makefile.am ++++ b/src/Makefile.am +@@ -9,7 +9,7 @@ EXTRA_DIST = Makefile.mak libp11.rc.in pkcs11.rc.in + + # Headers + noinst_HEADERS= libp11-int.h pkcs11.h p11_pthread.h provider_helpers.h util.h +-include_HEADERS= libp11.h p11_err.h ++include_HEADERS= libp11.h p11_err.h p11_ver.h + + lib_LTLIBRARIES = libp11.la + enginesexec_LTLIBRARIES = +-- +2.43.0
meta-oe/recipes-support/libp11/libp11_0.4.19.bb +3 -1
@@ -9,7 +9,9 @@ LICENSE = "LGPL-2.0-or-later" LIC_FILES_CHKSUM = "file://COPYING;md5=fad9b3332be894bab9bc501572864b29" DEPENDS = "libtool openssl" -SRC_URI = "git://github.com/OpenSC/libp11.git;branch=master;protocol=https;tag=${BPN}-${PV}" +SRC_URI = "git://github.com/OpenSC/libp11.git;branch=master;protocol=https;tag=${BPN}-${PV} \ + file://0001-Add-missing-p11_ver.h-file-to-installed-headers.patch \ + " SRCREV = "ae5756ccf5cb7929bb8edc986a9e6a65584406bd"
Signature · 1 line
2.43.0