gdbm: depend on readline

Submitted by Andrii Bordunov via Openembedded-core on Dec. 21, 2018, 10:40 p.m. | Patch ID: 157384

Details

Message ID 1545432031-27272-1-git-send-email-rbilovol@cisco.com
State New
Headers show

Commit Message

Andrii Bordunov via Openembedded-core Dec. 21, 2018, 10:40 p.m.
This package depends on readline recipe.
In traditional OE build readline is a dependency
of python3 and few other packages, thus at the time
of gdbm build it is available.

However, if some custom set of recipes is build,
there is a race between gdbm and python3 build
and availability of readline isn't deterministic,
causing next build error:
| ../../gdbm-1.18/src/input-rl.c:18:31: fatal error: readline/readline.h: No such file or directory
|  #include <readline/readline.h>
|                                ^
| compilation terminated.

Thus add readline dependency explicitly.

Cudos to Kostiantyn Iarmak <kiarmak@cisco.com> who
found this issue.

Signed-off-by: Ruslan Bilovol <rbilovol@cisco.com>
---
 meta/recipes-support/gdbm/gdbm_1.18.1.bb | 2 ++
 1 file changed, 2 insertions(+)

Patch hide | download patch | download mbox

diff --git a/meta/recipes-support/gdbm/gdbm_1.18.1.bb b/meta/recipes-support/gdbm/gdbm_1.18.1.bb
index 16ecc50..215ae47 100644
--- a/meta/recipes-support/gdbm/gdbm_1.18.1.bb
+++ b/meta/recipes-support/gdbm/gdbm_1.18.1.bb
@@ -15,6 +15,8 @@  SRC_URI[sha256sum] = "86e613527e5dba544e73208f42b78b7c022d4fa5a6d5498bf18c8d6f74
 
 inherit autotools gettext texinfo lib_package ptest
 
+DEPENDS += "readline"
+
 # Needed for dbm python module
 EXTRA_OECONF = "-enable-libgdbm-compat"
 

Comments

Andrii Bordunov via Openembedded-core Dec. 22, 2018, 2:30 a.m.
Quoting Ruslan Bilovol (2018-12-21 14:40:31)
> This package depends on readline recipe.
> In traditional OE build readline is a dependency
> of python3 and few other packages, thus at the time
> of gdbm build it is available.
> 
> However, if some custom set of recipes is build,
> there is a race between gdbm and python3 build
> and availability of readline isn't deterministic,
> causing next build error:
> | ../../gdbm-1.18/src/input-rl.c:18:31: fatal error: readline/readline.h: No such file or directory
> |  #include <readline/readline.h>
> |                                ^
> | compilation terminated.
> 
> Thus add readline dependency explicitly.
> 
> Cudos to Kostiantyn Iarmak <kiarmak@cisco.com> who
> found this issue.
> 
> Signed-off-by: Ruslan Bilovol <rbilovol@cisco.com>
> ---
>  meta/recipes-support/gdbm/gdbm_1.18.1.bb | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/meta/recipes-support/gdbm/gdbm_1.18.1.bb b/meta/recipes-support/gdbm/gdbm_1.18.1.bb
> index 16ecc50..215ae47 100644
> --- a/meta/recipes-support/gdbm/gdbm_1.18.1.bb
> +++ b/meta/recipes-support/gdbm/gdbm_1.18.1.bb
> @@ -15,6 +15,8 @@ SRC_URI[sha256sum] = "86e613527e5dba544e73208f42b78b7c022d4fa5a6d5498bf18c8d6f74
>  
>  inherit autotools gettext texinfo lib_package ptest
>  
> +DEPENDS += "readline"
> +
>  # Needed for dbm python module
>  EXTRA_OECONF = "-enable-libgdbm-compat"

configure.ac should autodetect presence of readline library:
http://git.savannah.gnu.org/cgit/gdbm.git/tree/configure.ac?h=v1.18.1#n123

If input-rl.c gets compiled, then configure.ac detected readline
somewhere and set GDBM_COND_READLINE.
Jacob Kroon Dec. 22, 2018, 10:11 a.m.
On Fri, 21 Dec 2018, 23:40 Ruslan Bilovol via Openembedded-core <
openembedded-core@lists.openembedded.org wrote:

> This package depends on readline recipe.
> In traditional OE build readline is a dependency
> of python3 and few other packages, thus at the time
> of gdbm build it is available.
>
> However, if some custom set of recipes is build,
> there is a race between gdbm and python3 build
> and availability of readline isn't deterministic,
> causing next build error:
> | ../../gdbm-1.18/src/input-rl.c:18:31: fatal error: readline/readline.h:
> No such file or directory
> |  #include <readline/readline.h>
> |                                ^
> | compilation terminated.
>
> Thus add readline dependency explicitly.
>

I thought that nowadays with per-recipe sysroots, these sort of issues were
a thing of the past ? Am I missing something ? This patch is for master
right ?

/Jacob

Cudos to Kostiantyn Iarmak <kiarmak@cisco.com> who
> found this issue.
>
> Signed-off-by: Ruslan Bilovol <rbilovol@cisco.com>
> ---
>  meta/recipes-support/gdbm/gdbm_1.18.1.bb | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/meta/recipes-support/gdbm/gdbm_1.18.1.bb
> b/meta/recipes-support/gdbm/gdbm_1.18.1.bb
> index 16ecc50..215ae47 100644
> --- a/meta/recipes-support/gdbm/gdbm_1.18.1.bb
> +++ b/meta/recipes-support/gdbm/gdbm_1.18.1.bb
> @@ -15,6 +15,8 @@ SRC_URI[sha256sum] =
> "86e613527e5dba544e73208f42b78b7c022d4fa5a6d5498bf18c8d6f74
>
>  inherit autotools gettext texinfo lib_package ptest
>
> +DEPENDS += "readline"
> +
>  # Needed for dbm python module
>  EXTRA_OECONF = "-enable-libgdbm-compat"
>
> --
> 1.9.1
>
> --
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core
>