Bug#427625: libc6: bindtextdomain not properly documented?
This is probably a stupid question but take a look at this simple
printf("domain = %s\n", textdomain("ppx"));
When I strace this, it never looks in /home/joshua/ppx/locale. I tested
this on 3 Debian systems and 1 Gentoo system. Am I doing something
stupid? I keep reading the docs for bindtextdomain but I don't
understand what I'm doing wrong. For example:
$ cc test.c -o test
$ strace ./test 2>&1 |grep ppx
write(1, "domain = ppx\nAmerica\n", 21domain = ppx
On my box, it looks in /usr/lib/locale/. I suspected that my compiler
toolchain was broken but on my brother's gentoo box, it searches
/usr/lib64/locale instead of the directory I specify in bindtextdomain.
On the other hand, if I strace /usr/bin/hello then it searches
/usr/share/locale which is correct. But if I dpkg-buildpackage hello
using apt-src then that build of hello searches /usr/lib/locale/. So
maybe my compiler toolchain really is broken?
Can you shed any light the behavior of bindtextdomain?
-- System Information:
Debian Release: 4.0
APT prefers stable
APT policy: (500, 'stable')
Architecture: i386 (i686)
Shell: /bin/sh linked to /bin/bash
Kernel: Linux 22.214.171.124-b3
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
-- no debconf information