Bug 713

Summary: poky-image-sato do_rootfs fails when GLIBC_GENERATE_LOCALES is missing en_GB.UTF-8
Product: [Build System, Metadata & Runtime] Meta-yocto Reporter: Scott Garman <scott.a.garman>
Component: meta-yoctoAssignee: Saul Wold <sgw>
Status: RESOLVED NOTABUG QA Contact:
Severity: normal    
Priority: Medium CC: poky.bs.watcher, poky.watcher, richard.purdie, sgw
Version: 0.9   
Target Milestone: 1.0 M4   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: ---

Description Scott Garman 2011-02-12 20:53:33 UTC
Steps to reproduce:

1. Uncomment GLIBC_GENERATE_LOCALES in your local.conf and remove en_GB.UTF-8:

GLIBC_GENERATE_LOCALES = "en_US.UTF-8"

2. bitbake poky-image-sato

Result: do_rootfs fails at the end of the build with the following:

+ '[' '!' -z 'locale-base-en-us locale-base-en-gb' ']'
+ for i in '${package_lingusa}'
+ opkg-cl -f /raid0/sources/poky/build/tmp/work/qemux86-poky-linux/poky-image-sato-1.0-r0/opkg.conf -o /raid0/sources/poky/build/tmp/work/qemux86-poky-linux/poky-image-sato-1.0-r0/rootfs --force-overwrite install locale-base-en-us
Installing locale-base-en-us (2.12-r13) to root...
Downloading file:/raid0/sources/poky/build/tmp/deploy/ipk/i586/locale-base-en-us_2.12-r13_i586.ipk.
Configuring locale-base-en-us.
+ for i in '${package_lingusa}'
+ opkg-cl -f /raid0/sources/poky/build/tmp/work/qemux86-poky-linux/poky-image-sato-1.0-r0/opkg.conf -o /raid0/sources/poky/build/tmp/work/qemux86-poky-linux/poky-image-sato-1.0-r0/rootfs --force-overwrite install locale-base-en-gb
Unknown package 'locale-base-en-gb'.
Collected errors:
 * opkg_install_cmd: Cannot install package locale-base-en-gb.

So it appears that list of locales to generate for the image is not honoring GLIBC_GENERATE_LOCALES.
Comment 1 Saul Wold 2011-02-13 22:29:43 UTC
Initial Evaluation seems to indicate that this is either coming in from image.bbclass or from the poky-eglibc.ing which lists locale-base-en-gb as a dependency for libc, further investigating is happening.
Comment 2 Richard Purdie 2011-02-14 04:50:19 UTC
To quote local.conf.sample:

# Set GLIBC_GENERATE_LOCALES to the locales you wish to generate should you not
# wish to perform the time-consuming step of generating all LIBC locales.
# NOTE: If removing en_US.UTF-8 you will also need to uncomment, and set
# appropriate values for IMAGE_LINGUAS and LIMIT_BUILT_LOCALES
# WARNING: this may break localisation!
#GLIBC_GENERATE_LOCALES = "en_GB.UTF-8 en_US.UTF-8"
# See message above as to whether setting these is required
#IMAGE_LINGUAS ?= "en-gb"
#LIMIT_BUILT_LOCALES ?= "POSIX en_GB"

and its implied that if you change GLIBC_GENERATE_LOCALES, you need to change IMAGE_LINGUAS too to match.

I think we need to improve the documentation here and make the variables consistent but the failure is expected given the configuration you setup.
Comment 3 Saul Wold 2011-02-20 21:34:39 UTC
Per Richard comment in(In reply to comment #2)

> I think we need to improve the documentation here and make the variables
> consistent but the failure is expected given the configuration you setup.

I am closing this as not a  bug, please verify you can get the correct behaviour by changing IMAGE_LINGUS as described.