Bug 11562

Summary: poky-tiny: Error with "GNU gettext"when building core-image-tiny-initramfs
Product: [Build System, Metadata & Runtime] Meta-yocto Reporter: Jose Perez C <jose.perez.carranza>
Component: meta-yoctoAssignee: Alejandro Hernandez <alejandro.hernandez>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: Medium+ CC: poky.bs.watcher, poky.watcher
Version: unspecified   
Target Milestone: 2.4 M1   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: No (bug/feature does not impact docs)
Attachments:
Description Flags
poky-tiny error none

Description Jose Perez C 2017-05-22 19:51:05 UTC
Created attachment 3772 [details]
poky-tiny error

When building image core-image-tiny-initramfs an error related to gettext is appearing  when executing  do_configure for systemd-boot task. 

==== Steps ===

1. add to local.conf
   DISTRO = "poky-tiny"
   MACHINE = "intel-corei7-64"

2. bitbake-layers add-layer "../meta-intel"
3. bitbake core-image-tiny-initramfs

=== EXPECTED RESULT ===

Image should be built correctly 

=== ACTUAL RESULT ===

configure: error: GNU gettext tools not found; required for intltool
Comment 1 Alejandro Hernandez 2017-05-22 21:51:55 UTC
This can be reproduced when setting DISTRO="poky-tiny" and invoking:

$ bitbake systemd-boot

it seems that the configure script from systemd-boot is not able to find gettext, even though invoking gettext from a devshell works just fine.

This is likely a dependency issue regarding systemd-boot or intltool.
Comment 2 Alejandro Hernandez 2017-05-22 21:59:28 UTC
Its interesting that this appears to only be affecting poky-tiny:

TARGET_SYS        = "x86_64-poky-linux-musl"
MACHINE           = "intel-corei7-64"
DISTRO            = "poky-tiny"

| configure: error: GNU gettext tools not found; required for intltool

whereas:

TARGET_SYS        = "x86_64-poky-linux"
MACHINE           = "intel-corei7-64"
DISTRO            = "poky"

Succeeds with no issues.
Comment 3 Alejandro Hernandez 2017-05-22 22:08:44 UTC
So I thought it might have been caused by using MUSL, but setting:

TCLIBC = "musl"

Shows no error either.
Comment 4 Alejandro Hernandez 2017-05-22 22:16:39 UTC
Found it.

The problem is that on one case (DISTRO="poky") BASEDEPENDS has the following content:

BASEDEPENDS="virtual/x86_64-poky-linux-musl-gcc virtual/x86_64-poky-linux-musl-compilerlibs virtual/libc virtual/gettext gettext-native"

whereas when using DISTRO="poky-tiny" it contains:

BASEDEPENDS="virtual/x86_64-poky-linux-musl-gcc virtual/x86_64-poky-linux-musl-compilerlibs virtual/libc gettext-minimal-native"

So gettext-minimal-native appears not to be enought to build systemd-boot.

This is caused because on tiny we set:

USE_NLS="no"

Causing the gettext.bbclass to add gettext-minimal-native to BASEDEPENDS instead of gettext-native.


Setting gettext-native as a dependency to intltool-native fixes the problem.