diff options
author | Jim Meyering <meyering@redhat.com> | 2008-05-19 16:14:13 +0200 |
---|---|---|
committer | Jim Meyering <meyering@redhat.com> | 2008-05-26 08:37:08 +0200 |
commit | 7855cbfcac867621c18d1fc85abe5332f6aae1ec (patch) | |
tree | 26eb36b6769761b261ea8c7419c5ce4cea9d5a60 /src | |
parent | 29290d04856214345f966ccd8016aa0aaf758662 (diff) | |
download | coreutils-7855cbfcac867621c18d1fc85abe5332f6aae1ec.tar.xz |
use gnulib's proper_name_utf8 function, but *not* proper_name
* bootstrap.conf (gnulib_modules): Add propername.
(XGETTEXT_OPTIONS): Add options to tell xgettext about the functions.
* src/cat.c, src/cp.c, src/df.c, src/du.c, src/split.c:
Mark Torbjörn Granlund's name.
* src/ptx.c: Mark François Pinard's name.
Use "TRANSLATORS:" comment marker, rather than "Note to translators:".
* src/system.h: Include propername.h.
(proper_name): Define away.
* src/Makefile.am (cat_LDADD, df_LDADD, du_LDADD, ptx_LDADD, split_LDADD):
Initialize, so we can...
(cat_LDADD, cp_LDADD, df_LDADD, du_LDADD, ptx_LDADD, split_LDADD):
...Use "+=" to append $(LIBICONV) for each program that uses
proper_name_utf8.
Diffstat (limited to 'src')
-rw-r--r-- | src/Makefile.am | 14 | ||||
-rw-r--r-- | src/cat.c | 6 | ||||
-rw-r--r-- | src/cp.c | 4 | ||||
-rw-r--r-- | src/df.c | 5 | ||||
-rw-r--r-- | src/du.c | 3 | ||||
-rw-r--r-- | src/ptx.c | 8 | ||||
-rw-r--r-- | src/split.c | 4 | ||||
-rw-r--r-- | src/system.h | 7 |
8 files changed, 40 insertions, 11 deletions
diff --git a/src/Makefile.am b/src/Makefile.am index 668e1786e..8d1cfcfd3 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -75,6 +75,12 @@ AM_CPPFLAGS = -I$(top_srcdir)/lib # replacement functions defined in libcoreutils.a. LDADD = ../lib/libcoreutils.a $(LIBINTL) ../lib/libcoreutils.a +cat_LDADD = $(LDADD) +df_LDADD = $(LDADD) +du_LDADD = $(LDADD) +ptx_LDADD = $(LDADD) +split_LDADD = $(LDADD) + # for eaccess in lib/euidaccess.c. chcon_LDADD = $(LDADD) $(LIB_SELINUX) cp_LDADD = $(LDADD) $(LIB_EACCESS) $(LIB_SELINUX) @@ -137,6 +143,14 @@ ginstall_LDADD += $(LIB_ACL) stat_LDADD = $(LDADD) $(LIB_SELINUX) +# Append $(LIBICONV) to each program that uses proper_name_utf8. +cat_LDADD += $(LIBICONV) +cp_LDADD += $(LIBICONV) +df_LDADD += $(LIBICONV) +du_LDADD += $(LIBICONV) +ptx_LDADD += $(LIBICONV) +split_LDADD += $(LIBICONV) + $(PROGRAMS): ../lib/libcoreutils.a # Get the release year from ../lib/version-etc.c. @@ -1,5 +1,5 @@ /* cat -- concatenate files and print on the standard output. - Copyright (C) 88, 90, 91, 1995-2007 Free Software Foundation, Inc. + Copyright (C) 88, 90, 91, 1995-2008 Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -43,7 +43,9 @@ /* The official name of this program (e.g., no `g' prefix). */ #define PROGRAM_NAME "cat" -#define AUTHORS "Torbjorn Granlund", "Richard M. Stallman" +#define AUTHORS \ + proper_name_utf8 ("Torbjorn Granlund", "Torbj\303\266rn Granlund"), \ + "Richard M. Stallman" /* Undefine, to avoid warning about redefinition on some systems. */ #undef max @@ -52,7 +52,9 @@ /* The official name of this program (e.g., no `g' prefix). */ #define PROGRAM_NAME "cp" -#define AUTHORS "Torbjorn Granlund", "David MacKenzie", "Jim Meyering" +#define AUTHORS \ + proper_name_utf8 ("Torbjorn Granlund", "Torbj\303\266rn Granlund"), \ + "David MacKenzie", "Jim Meyering" /* Used by do_copy, make_dir_parents_private, and re_protect to keep a list of leading directories whose protections @@ -1,5 +1,5 @@ /* df - summarize free disk space - Copyright (C) 91, 1995-2007 Free Software Foundation, Inc. + Copyright (C) 91, 1995-2008 Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -38,7 +38,8 @@ #define PROGRAM_NAME "df" #define AUTHORS \ - "Torbjorn Granlund", "David MacKenzie", "Paul Eggert" + proper_name_utf8 ("Torbjorn Granlund", "Torbj\303\266rn Granlund"), \ + "David MacKenzie", "Paul Eggert" /* Name this program was run with. */ char *program_name; @@ -50,7 +50,8 @@ extern bool fts_debug; #define PROGRAM_NAME "du" #define AUTHORS \ - "Torbjorn Granlund", "David MacKenzie, Paul Eggert", "Jim Meyering" + proper_name_utf8 ("Torbjorn Granlund", "Torbj\303\266rn Granlund"), \ + "David MacKenzie, Paul Eggert", "Jim Meyering" #if DU_DEBUG # define FTS_CROSS_CHECK(Fts) fts_cross_check (Fts) @@ -34,10 +34,10 @@ /* The official name of this program (e.g., no `g' prefix). */ #define PROGRAM_NAME "ptx" -/* Note to translator: Please translate "F. Pinard" to "François - Pinard" if "ç" (c-with-cedilla) is available in the - translation's character set and encoding. */ -#define AUTHORS _("F. Pinard") +/* TRANSLATORS: Please translate "F. Pinard" to "François Pinard" + if "ç" (c-with-cedilla) is available in the translation's character + set and encoding. */ +#define AUTHORS proper_name_utf8 ("F. Pinard", "Fran\xc3\xa7ois Pinard") /* Number of possible characters in a byte. */ #define CHAR_SET_SIZE 256 diff --git a/src/split.c b/src/split.c index f84d40e41..d78b506e4 100644 --- a/src/split.c +++ b/src/split.c @@ -40,7 +40,9 @@ /* The official name of this program (e.g., no `g' prefix). */ #define PROGRAM_NAME "split" -#define AUTHORS "Torbjorn Granlund", "Richard M. Stallman" +#define AUTHORS \ + proper_name_utf8 ("Torbjorn Granlund", "Torbj\303\266rn Granlund"), \ + "Richard M. Stallman" #define DEFAULT_SUFFIX_LENGTH 2 diff --git a/src/system.h b/src/system.h index b640c01df..f7c689f8e 100644 --- a/src/system.h +++ b/src/system.h @@ -454,6 +454,13 @@ enum #include "closein.h" #include "closeout.h" #include "version-etc.h" +#include "propername.h" +/* Define away proper_name (leaving proper_name_utf8, which affects far + fewer programs), since it's not worth the cost of adding ~17KB to + the x86_64 text size of every single program. This avoids a 40% + (almost ~2MB) increase in the on-disk space utilization for the set + of the 100 binaries. */ +#define proper_name(x) (x) #define case_GETOPT_VERSION_CHAR(Program_name, Authors) \ case GETOPT_VERSION_CHAR: \ |