summaryrefslogtreecommitdiffstats
path: root/intl/bindtextdom.c
diff options
context:
space:
mode:
authorBruno Haible <bruno@clisp.org>2001-01-15 14:59:52 +0000
committerBruno Haible <bruno@clisp.org>2001-01-15 14:59:52 +0000
commite0560b43903ad644e19cff68c3b744a39d891613 (patch)
tree06626d434c05c2100b54330c3c6b6ff82926b803 /intl/bindtextdom.c
parent4d48f86a3ab0114dce08c731553f90727f7dde03 (diff)
downloadexternal_gettext-e0560b43903ad644e19cff68c3b744a39d891613.zip
external_gettext-e0560b43903ad644e19cff68c3b744a39d891613.tar.gz
external_gettext-e0560b43903ad644e19cff68c3b744a39d891613.tar.bz2
Portability fixes for K&R C compilers, SunOS "make" and others.
Diffstat (limited to 'intl/bindtextdom.c')
-rw-r--r--intl/bindtextdom.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/intl/bindtextdom.c b/intl/bindtextdom.c
index 673a061..1d5c561 100644
--- a/intl/bindtextdom.c
+++ b/intl/bindtextdom.c
@@ -1,5 +1,5 @@
/* Implementation of the bindtextdomain(3) function
- Copyright (C) 1995, 1996, 1997, 1998, 2000 Free Software Foundation, Inc.
+ Copyright (C) 1995-1998, 2000, 2001 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
@@ -67,6 +67,11 @@ void free ();
# define _nl_domain_bindings _nl_domain_bindings__
#endif
+/* Some compilers, like SunOS4 cc, don't have offsetof in <stddef.h>. */
+#ifndef offsetof
+# define offsetof(type,ident) ((size_t)&(((type*)0)->ident))
+#endif
+
/* @@ end of prolog @@ */
/* Contains the default location of the message catalogs. */
@@ -95,8 +100,9 @@ __libc_rwlock_define (extern, _nl_state_lock)
#endif
/* Prototypes for local functions. */
-static void set_binding_values (const char *domainname, const char **dirnamep,
- const char **codesetp);
+static void set_binding_values PARAMS ((const char *domainname,
+ const char **dirnamep,
+ const char **codesetp));
/* Specifies the directory name *DIRNAMEP and the output codeset *CODESETP
to be used for the DOMAINNAME message catalog.