Skip to contentSkip to conversation

libkcapi: Fix missing bash (for apps) and unneeded checksums (for testapp) when building

PATCH In review Krzysztof Kozlowski 2 participants 4 messages Jan 25, 2019 – Jan 28, 2019

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 libkcapi: Fix missing bash (for apps) and unneeded checksums (for testapp) when building

Fix build failures:
1. with "apps" PACKAGECONFIG:

    ERROR: libkcapi-1.1.3+gitAUTOINC+1c736c43eb-r0 do_package:
    QA Issue: libkcapi: Files/directories were installed but not shipped in any package:
      /usr/bin/.sha1hmac.hmac
      /usr/lib/.libkcapi.so.1.1.3.hmac

2. with "testapp" PACKAGECONFIG:

ERROR: libkcapi-1.1.3+gitAUTOINC+1c736c43eb-r0 do_package_qa:
QA Issue: /usr/libexec/libkcapi/test.sh contained in package libkcapi requires /bin/bash, but no providers found in RDEPENDS_libkcapi? [file-rdeps]

---
 meta-oe/recipes-crypto/libkcapi/libkcapi_git.bb | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
meta-oe/recipes-crypto/libkcapi/libkcapi_git.bb +5 -1
index a93ddc823740..f70f774bf2d6 100644
@@ -16,13 +16,17 @@ SRC_URI = " \
 inherit autotools
 
 PACKAGECONFIG ??= ""
-PACKAGECONFIG[testapp] = "--enable-kcapi-test,,,"
+PACKAGECONFIG[testapp] = "--enable-kcapi-test,,,bash"
 PACKAGECONFIG[apps] = "--enable-kcapi-speed --enable-kcapi-hasher --enable-kcapi-rngapp --enable-kcapi-encapp --enable-kcapi-dgstapp,,,"
 
 do_install_append() {
     # bindir contains testapp and apps.  However it is always created, even
     # when no binaries are installed (empty bin_PROGRAMS in Makefile.am),
     rmdir --ignore-fail-on-non-empty ${D}${bindir}
+
+    # Remove the generated binary checksum files
+    rm -f ${D}${bindir}/.*.hmac
+    rm -f ${D}${libdir}/.*.hmac
 }
 
 CPPFLAGS_append_libc-musl_toolchain-clang = " -Wno-error=sign-compare"
Signature · 1 line
2.7.4
#1 lore raw

PATCH 2/2 libkcapi: Bump to v1.1.4

License file was updated with new dates ("2016" -> "2016 - 2019").

---
 meta-oe/recipes-crypto/libkcapi/libkcapi_git.bb | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)
meta-oe/recipes-crypto/libkcapi/libkcapi_git.bb +3 -4
index f70f774bf2d6..46c66a1b2c92 100644
@@ -1,14 +1,13 @@
 SUMMARY = "Linux Kernel Crypto API User Space Interface Library"
 HOMEPAGE = "http://www.chronox.de/libkcapi.html"
 LICENSE = "BSD | GPL-2.0"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d0421cf231423bda10cea691b613e866"
+LIC_FILES_CHKSUM = "file://COPYING;md5=14d5a68b28755c04ebdba226e888b157"
 
 DEPENDS = "libtool"
 
 S = "${WORKDIR}/git"
-# Use v1.1.3 with changes on top for building in OE
-SRCREV = "1c736c43eb71fbb5640d00efaf34a1edf1972c49"
-PV = "1.1.3+git${SRCPV}"
+SRCREV = "3c56934f44a8f5a1257c342942e6e034fc6f20be"
+PV = "1.1.4+git${SRCPV}"
 SRC_URI = " \
     git://github.com/smuellerDD/libkcapi.git \
 "
Signature · 1 line
2.7.4
#2 lore raw
In reply to Krzysztof Kozlowski

Another approach could be remove bashism from the shell script which is demanding it and ask for simple bin/sh

Quoted 56 lines · Krzysztof Kozlowski

Fix build failures:
1. with "apps" PACKAGECONFIG:

ERROR: libkcapi-1.1.3+gitAUTOINC+1c736c43eb-r0 do_package:
QA Issue: libkcapi: Files/directories were installed but not shipped
in any package:

      /usr/bin/.sha1hmac.hmac
      /usr/lib/.libkcapi.so.1.1.3.hmac

2. with "testapp" PACKAGECONFIG:

ERROR: libkcapi-1.1.3+gitAUTOINC+1c736c43eb-r0 do_package_qa:
QA Issue: /usr/libexec/libkcapi/test.sh contained in package libkcapi
requires /bin/bash,
but no providers found in RDEPENDS_libkcapi? [file-rdeps]

---
 meta-oe/recipes-crypto/libkcapi/libkcapi_git.bb | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
meta-oe/recipes-crypto/libkcapi/libkcapi_git.bb +1 -2
index a93ddc823740..f70f774bf2d6 100644
@@ -16,13 +16,17 @@ SRC_URI = " \
 inherit autotools
 
 PACKAGECONFIG ??= ""
-PACKAGECONFIG[testapp] = "--enable-kcapi-test,,,"
+PACKAGECONFIG[testapp] = "--enable-kcapi-test,,,bash"
 PACKAGECONFIG[apps] = "--enable-kcapi-speed --enable-kcapi-hasher
--enable-kcapi-rngapp --enable-kcapi-encapp --enable-kcapi-dgstapp,,,"
 
 do_install_append() {
     # bindir contains testapp and apps.  However it is always created,

even

     # when no binaries are installed (empty bin_PROGRAMS in Makefile.am),
     rmdir --ignore-fail-on-non-empty ${D}${bindir}
meta-oe/recipes-crypto/libkcapi/libkcapi_git.bb +4 -1
+
+    # Remove the generated binary checksum files
+    rm -f ${D}${bindir}/.*.hmac
+    rm -f ${D}${libdir}/.*.hmac
 }
 
 CPPFLAGS_append_libc-musl_toolchain-clang = " -Wno-error=sign-compare"
--

2.7.4

--
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel

#3 lore raw
Quoted 2 lines · Khem Raj

Another approach could be remove bashism from the shell script which is demanding it and ask for simple bin/sh

I took a look at this approach and it would be not trivial work. Bashism appears in multiple places, starting from trivial function keyword up to [[ ]] operators. On the other hand, these scripts are enabled only for testapps package config which are useful during development, not production. Therefore I expect that final image will not have testapps and bash.

Best regards,
Krzysztof