Prechádzať zdrojové kódy

Enable automagic locale data downloads

Eric Andersen 21 rokov pred
rodič
commit
86be4f7e5a
2 zmenil súbory, kde vykonal 18 pridanie a 4 odobranie
  1. 15 1
      Makefile
  2. 3 3
      extra/Configs/Config.in

+ 15 - 1
Makefile

@@ -35,7 +35,7 @@ endif
 
 
 ifeq ($(strip $(HAVE_DOT_CONFIG)),y)
 ifeq ($(strip $(HAVE_DOT_CONFIG)),y)
 
 
-all: headers subdirs shared utils finished
+all: headers pregen subdirs shared utils finished
 
 
 # In this section, we need .config
 # In this section, we need .config
 -include .config.cmd
 -include .config.cmd
@@ -164,6 +164,20 @@ endif
 	fi
 	fi
 	$(MAKE) -C libc/sysdeps/linux/$(TARGET_ARCH) headers
 	$(MAKE) -C libc/sysdeps/linux/$(TARGET_ARCH) headers
 
 
+# Command used to download source code
+WGET:=wget --passive-ftp
+
+pregen: headers
+ifeq ($(strip $(UCLIBC_DOWNLOAD_PREGENERATED_LOCALE_DATA)),y)
+	(cd extra/locale; \
+	$(WGET) http://www.uclibc.org/downloads/uClibc-locale-030818.tgz);
+endif
+ifeq ($(strip $(UCLIBC_PREGENERATED_LOCALE_DATA)),y)
+	(cd extra/locale; zcat uClibc-locale-030818.tgz | tar -xvf -)
+	make -C extra/locale pregen
+endif
+
+
 subdirs: $(patsubst %, _dir_%, $(DIRS))
 subdirs: $(patsubst %, _dir_%, $(DIRS))
 
 
 $(patsubst %, _dir_%, $(DIRS)) : dummy
 $(patsubst %, _dir_%, $(DIRS)) : dummy

+ 3 - 3
extra/Configs/Config.in

@@ -418,7 +418,7 @@ config UCLIBC_HAS_WCHAR
 	  Most people will answer N.
 	  Most people will answer N.
 
 
 config UCLIBC_HAS_LOCALE
 config UCLIBC_HAS_LOCALE
-	bool "Locale Support (experimental/incomplete)"
+	bool "Locale Support"
 	select UCLIBC_HAS_WCHAR
 	select UCLIBC_HAS_WCHAR
 	select UCLIBC_HAS_CTYPE_TABLES
 	select UCLIBC_HAS_CTYPE_TABLES
 	default n
 	default n
@@ -443,9 +443,9 @@ config UCLIBC_PREGENERATED_LOCALE_DATA
 	depends on UCLIBC_HAS_LOCALE
 	depends on UCLIBC_HAS_LOCALE
 	default n
 	default n
 	help
 	help
-	  If you are selective and only want locale data for a few selected
+	  If you are selective and only want locale data for a few particular
 	  locales, or you enjoy pain, or you are a rabid do-it-yourself sort of
 	  locales, or you enjoy pain, or you are a rabid do-it-yourself sort of
-	  person, you can turn this option off, and manually walk through the
+	  person, you can turn this option off and manually walk through the
 	  mostly undocumented procedure needed to generate your own locale
 	  mostly undocumented procedure needed to generate your own locale
 	  data.
 	  data.