From fcbf63e62c627deae76c1b8cb8c0876c536ed811 Mon Sep 17 00:00:00 2001 From: Jari Vetoniemi Date: Mon, 16 Mar 2020 18:49:26 +0900 Subject: Fresh start --- jni/iconv/libcharset/tools/all-charsets-X11 | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100755 jni/iconv/libcharset/tools/all-charsets-X11 (limited to 'jni/iconv/libcharset/tools/all-charsets-X11') diff --git a/jni/iconv/libcharset/tools/all-charsets-X11 b/jni/iconv/libcharset/tools/all-charsets-X11 new file mode 100755 index 0000000..95003ca --- /dev/null +++ b/jni/iconv/libcharset/tools/all-charsets-X11 @@ -0,0 +1,28 @@ +#!/bin/sh + +# Prints a table of the charsets (system dependent name, portable name, and +# X11 name) for all locales. + +${CC-cc} -o locale_codeset locale_codeset.c +${CC-cc} -o locale_charset -I../include locale_charset.c \ + -DHAVE_CONFIG_H -I.. -DLIBDIR='"'`cd ../lib && pwd`'"' \ + ../lib/localcharset.c +${CC-cc} -o locale_x11encoding locale_x11encoding.c \ + -I/usr/X11R6/include \ + -L/usr/X11R6/lib -lX11 +#${CC-cc} -o locale_x11encoding locale_x11encoding.c \ +# -I/packages/gnu/XFree86/include \ +# -L/packages/gnu/XFree86/lib -lX11 \ +# -Wl,-rpath,/packages/gnu/XFree86/lib + +printf '%-15s%-17s%-17s %-17s %-17s\n\n' \ + "locale name" "locale charmap" "nl_langinfo(CODESET)" "locale_charset()" "X11 encoding" +for lc in `./all-locales | sort | uniq` +do + charmap=`LC_ALL=$lc ./locale_charmap 2>/dev/null || echo ''` + codeset=`LC_ALL=$lc ./locale_codeset 2>/dev/null || echo ''` + charset=`LC_ALL=$lc ./locale_charset 2>/dev/null || echo ''` + x11encoding=`LC_ALL=$lc ./locale_x11encoding 2>/dev/null || echo ''` + printf '%-15s %-17s %-17s %-17s %-17s\n' \ + "$lc" "$charmap" "$codeset" "$charset" "$x11encoding" +done -- cgit v1.2.3-70-g09d2