From b339c942c14523b261d0205c0452d79d11bb0278 Mon Sep 17 00:00:00 2001 From: Pierre Labastie Date: Fri, 10 Feb 2012 09:43:23 +0000 Subject: [PATCH] Add a choice between installing the full set of supported locales and installing just the minimal set for tests, after glibc build. If the second option is chosen, the locale specified in LANG is also installed, if not in the minimal set. --- Config.in | 16 ++++++++++++++-- LFS/lfs.xsl | 26 ++++++++++++++++++++++++-- common/libs/func_book_parser | 1 + common/libs/func_validate_configs.sh | 2 +- jhalfs | 1 + 5 files changed, 41 insertions(+), 5 deletions(-) diff --git a/Config.in b/Config.in index 5bbf4dc..b193ed8 100644 --- a/Config.in +++ b/Config.in @@ -260,7 +260,7 @@ menu "--- BOOK Settings" default "hppa1.1-unknown-linux-gnu" if PROC_hppa1 default "hppa2.0-unknown-linux-gnu" if PROC_hppa2 - default "arm-unknown-linux-gnu" if ARCH_ARM && BOOK_CLFS2 + default "arm-unknown-linux-gnueabi" if ARCH_ARM && BOOK_CLFS2 default "arm-unknown-linux-uclibc" if PROC_ARM default "armv5l-unknown-linux-uclibc" if PROC_ARM5L @@ -980,7 +980,19 @@ menu "--- Build Settings" string "Language" default "$LANG" help - #-- Language information in /etc/profile See for values + #-- LANG variable set in /etc/profile + # See http://sourceware.org/git/?p=glibc.git;a=blob;f=localedata/SUPPORTED + # for values (or the file localedata/SUPPORTED in glibc tarball) + + config FULL_LOCALE + bool "Install the full set of locales" + default n + help + #-- If set to y, the full set of supported locales + # will be installed. Otherwise, only the minimal set + # necessary for the tests will be installed, + # together with the locale associated to the + # LANG you have chosen, if not in the minimal set. #--- Groff page choice diff --git a/LFS/lfs.xsl b/LFS/lfs.xsl index 932684a..9f681ca 100644 --- a/LFS/lfs.xsl +++ b/LFS/lfs.xsl @@ -39,6 +39,9 @@ + + + @@ -180,8 +183,27 @@ rm -rf $PKG_DEST - - + + + + + + + + + + if LOCALE=`grep " + + /" $PKGDIR/localedata/SUPPORTED`; then + CHARMAP=`echo $LOCALE | sed 's,[^/]*/\([^ ]*\) [\],\1,'` + INPUT=`echo $LOCALE | sed 's,[/.].*,,'` + LOCALE=`echo $LOCALE | sed 's,/.*,,'` + localedef -i $INPUT -f $CHARMAP $LOCALE +fi + + + +