rng-tools: Fix underquoted m4 and libgcrypt floating dependency
PATCH 1/1 rng-tools: Fix underquoted m4 and libgcrypt floating dependency
The underquoted m4 caused build failures if libgcrypt wasn't present. The floating dependency on libgcrypt was just plain incorrect, particularly given the incorrect libgcrypt RDEPENDS. Change to use PACKAGECONFIG an default to on.
meta/recipes-support/rng-tools/rng-tools/underquote.patch new file +31 -0
@@ -0,0 +1,31 @@ +Fix underquoted m4 entry. This causes a failure if gcrypt isn't present: + +| configure: libgcrypt support disabled +| ../rng-tools-5/configure: line 4345: ac_fn_c_try_link: command not found +| configure: error: in `/media/build1/poky/build/tmp/work/i586-poky-linux/rng-tools/5-r0/build': + +RP +2016/2/16 + +Index: rng-tools-5/configure.ac +=================================================================== +--- rng-tools-5.orig/configure.ac ++++ rng-tools-5/configure.ac +@@ -71,7 +71,7 @@ AS_IF( + [test "x$with_libgcrypt" != "xno"], + [ + AC_CHECK_HEADER([gcrypt.h], +- AC_CHECK_LIB( ++ [AC_CHECK_LIB( + [gcrypt], + [gcry_check_version], , + [ +@@ -80,7 +80,7 @@ AS_IF( + AC_MSG_NOTICE([libgcrypt support disabled]) + fi + ] +- ), ++ )], + [if test "x$with_libgcrypt" != "xcheck"; then + AC_MSG_FAILURE([libgcrypt headers not found]); else + AC_MSG_NOTICE([libgcrypt support disabled])
meta/recipes-support/rng-tools/rng-tools_5.bb +3 -3
@@ -5,6 +5,7 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=0b6f033afe6db235e559456585dc8cdc" SRC_URI = "http://heanet.dl.sourceforge.net/sourceforge/gkernel/${BP}.tar.gz \ file://0001-If-the-libc-is-lacking-argp-use-libargp.patch \ file://0002-Add-argument-to-control-the-libargp-dependency.patch \ + file://underquote.patch \ file://init \ file://default"
@@ -20,12 +21,11 @@ python () { inherit autotools update-rc.d -PACKAGECONFIG = "" +PACKAGECONFIG = "libgcrypt" PACKAGECONFIG_libc-musl = "libargp" PACKAGECONFIG_libc-uclibc = "libargp" PACKAGECONFIG[libargp] = "--with-libargp,--without-libargp,argp-standalone," - -RDEPENDS_${PN} = "libgcrypt" +PACKAGECONFIG[libgcrypt] = "--with-libgcrypt,--without-libgcrypt,libgcrypt," do_install_append() { # Only install the init script when 'sysvinit' is in DISTRO_FEATURES.
Quoted 66 lines · Richard Purdie
The underquoted m4 caused build failures if libgcrypt wasn't present. The floating
dependency on libgcrypt was just plain incorrect, particularly given the incorrect
libgcrypt RDEPENDS. Change to use PACKAGECONFIG an default to on.Signed-off-by Richard Purdie <[email protected]>meta/recipes-support/rng-tools/rng-tools/underquote.patch new file +5
-0@@ -0,0 +1,31 @@ +Fix underquoted m4 entry. This causes a failure if gcrypt isn't present: + +| configure: libgcrypt support disabled +| ../rng-tools-5/configure: line 4345: ac_fn_c_try_link: command not found +| configure: error: in`/media/build1/poky/build/tmp/work/i586-poky-linux/rng-tools/5-r0/build':
meta/recipes-support/rng-tools/rng-tools/underquote.patch new file +19
-0+ +RP +2016/2/16 + +Index: rng-tools-5/configure.ac +=================================================================== +--- rng-tools-5.orig/configure.ac ++++ rng-tools-5/configure.ac +@@ -71,7 +71,7 @@ AS_IF( + [test "x$with_libgcrypt" != "xno"], + [ + AC_CHECK_HEADER([gcrypt.h], +- AC_CHECK_LIB( ++ [AC_CHECK_LIB( + [gcrypt], + [gcry_check_version], , + [ +@@ -80,7 +80,7 @@ AS_IF( + AC_MSG_NOTICE([libgcryptsupport disabled])
meta/recipes-support/rng-tools/rng-tools/underquote.patch new file +6
-0+ fi + ] +- ), ++ )], + [if test "x$with_libgcrypt" != "xcheck"; then + AC_MSG_FAILURE([libgcrypt headers notfound]); else
meta/recipes-support/rng-tools/rng-tools/underquote.patch new file +1
-0+ AC_MSG_NOTICE([libgcrypt support disabled])meta/recipes-support/rng-tools/rng-tools_5.bb +0
-0@@ -5,6 +5,7 @@ LIC_FILES_CHKSUM ="file://COPYING;md5=0b6f033afe6db235e559456585dc8cdc"
SRC_URI= "http://heanet.dl.sourceforge.net/sourceforge/gkernel/${BP}.tar.gz \ file://0001-If-the-libc-is-lacking-argp-use-libargp.patch \file://0002-Add-argument-to-control-the-libargp-dependency.patch \
meta/recipes-support/rng-tools/rng-tools_5.bb +1
-0+ file://underquote.patch \ file://init \ file://default"
meta/recipes-support/rng-tools/rng-tools_5.bb python () { · line 27
Quoted 8 lines
meta/recipes-support/rng-tools/rng-tools_5.bb +1
-1@@ -20,12 +21,11 @@ python () { inherit autotools update-rc.d -PACKAGECONFIG = "" +PACKAGECONFIG = "libgcrypt" PACKAGECONFIG_libc-musl = "libargp" PACKAGECONFIG_libc-uclibc = "libargp"
I'm not sure how well musl/uclibc support libgcrypt, but this does end up not including gcrypt support for those libcs, unless we switch it to _append_libc-.
Quoted 7 lines · Christopher Larson
meta/recipes-support/rng-tools/rng-tools_5.bb python () { · line 26
Quoted 4 lines
meta/recipes-support/rng-tools/rng-tools_5.bb +1
-1-PACKAGECONFIG = "" +PACKAGECONFIG = "libgcrypt" PACKAGECONFIG_libc-musl = "libargp" PACKAGECONFIG_libc-uclibc = "libargp"I'm not sure how well musl/uclibc support libgcrypt, but this does end up not including gcrypt support for those libcs, unless we switch it to _append_libc-.
I shouldn't have pulled the original patch without testing. The M2 rc2 build then failed due to this so I've merged my fix since I *really* want to get that build done tonight, finally.
The dependency was already there really from the RDEPENDS which is why I opted to do this. I'll take follow up patches to resolve any musl/uclibc issues.
Cheers,
Richard