3 # Prints a table of the charsets (system dependent name, portable name, and
4 # X11 name) for all locales.
6 ${CC-cc} -o locale_codeset locale_codeset.c
7 ${CC-cc} -o locale_charset
-I..
/include locale_charset.c \
8 -DHAVE_CONFIG_H -I..
-DLIBDIR='"'`cd ../lib && pwd`'"' \
10 ${CC-cc} -o locale_x11encoding locale_x11encoding.c \
11 -I/usr
/X11R
6/include \
12 -L/usr
/X11R
6/lib
-lX11
13 #${CC-cc} -o locale_x11encoding locale_x11encoding.c \
14 # -I/packages/gnu/XFree86/include \
15 # -L/packages/gnu/XFree86/lib -lX11 \
16 # -Wl,-rpath,/packages/gnu/XFree86/lib
18 printf '%-15s%-17s%-17s %-17s %-17s\n\n' \
19 "locale name" "locale charmap" "nl_langinfo(CODESET)" "locale_charset()" "X11 encoding"
20 for lc
in `./all-locales | sort | uniq`
22 charmap
=`LC_ALL=$lc ./locale_charmap 2>/dev/null || echo '<error>'`
23 codeset
=`LC_ALL=$lc ./locale_codeset 2>/dev/null || echo '<error>'`
24 charset
=`LC_ALL=$lc ./locale_charset 2>/dev/null || echo '<error>'`
25 x11encoding
=`LC_ALL=$lc ./locale_x11encoding 2>/dev/null || echo '<error>'`
26 printf '%-15s %-17s %-17s %-17s %-17s\n' \
27 "$lc" "$charmap" "$codeset" "$charset" "$x11encoding"