From: Bruno Haible Date: Sun, 24 Aug 2003 17:51:43 +0000 (+0000) Subject: Add extern "C" { ... }. X-Git-Tag: v0.13~312 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9346431ccd3e5032bd32ecd8f6cbd80298473c7e;p=thirdparty%2Fgettext.git Add extern "C" { ... }. --- diff --git a/gettext-tools/src/ChangeLog b/gettext-tools/src/ChangeLog index fbc7086cd..54da418d5 100644 --- a/gettext-tools/src/ChangeLog +++ b/gettext-tools/src/ChangeLog @@ -38,14 +38,21 @@ * format.h: Likewise. * message.h: Likewise. * msgl-ascii.h: Likewise. + * msgl-cat.h: Likewise. + * msgl-charset.h: Likewise. + * msgl-english.h: Likewise. + * msgl-equal.h: Likewise. * msgl-iconv.h: Likewise. * open-po.h: Likewise. * po-charset.h: Likewise. + * po-lex.h: Likewise. * po-time.h: Likewise. * read-po-abstract.h: Likewise. * str-list.h: Likewise. * write-po.h: Likewise. * xgettext.h: Likewise. + * read-po.h: Likewise. + (this): Redefine to a different symbol. * xgettext.c: Add extern "C" around all "x-*.h" includes. 2003-08-22 Bruno Haible diff --git a/gettext-tools/src/msgl-cat.h b/gettext-tools/src/msgl-cat.h index 7b6f97477..abdc56495 100644 --- a/gettext-tools/src/msgl-cat.h +++ b/gettext-tools/src/msgl-cat.h @@ -1,5 +1,5 @@ /* Message list concatenation and duplicate handling. - Copyright (C) 2001-2002 Free Software Foundation, Inc. + Copyright (C) 2001-2003 Free Software Foundation, Inc. Written by Bruno Haible , 2001. This program is free software; you can redistribute it and/or modify @@ -19,10 +19,16 @@ #ifndef _MSGL_CAT_H #define _MSGL_CAT_H +#include + #include "message.h" #include "str-list.h" -#include + +#ifdef __cplusplus +extern "C" { +#endif + /* These variables control which messages are selected. */ extern int more_than; @@ -44,4 +50,10 @@ extern msgdomain_list_ty * catenate_msgdomain_list (string_list_ty *file_list, const char *to_code); + +#ifdef __cplusplus +} +#endif + + #endif /* _MSGL_CAT_H */ diff --git a/gettext-tools/src/msgl-charset.h b/gettext-tools/src/msgl-charset.h index 7fe28b385..75ded5862 100644 --- a/gettext-tools/src/msgl-charset.h +++ b/gettext-tools/src/msgl-charset.h @@ -1,5 +1,5 @@ /* Message list charset and locale charset handling. - Copyright (C) 2001-2002 Free Software Foundation, Inc. + Copyright (C) 2001-2003 Free Software Foundation, Inc. Written by Bruno Haible , 2001. This program is free software; you can redistribute it and/or modify @@ -21,7 +21,19 @@ #include "message.h" + +#ifdef __cplusplus +extern "C" { +#endif + + extern void compare_po_locale_charsets (const msgdomain_list_ty *mdlp); + +#ifdef __cplusplus +} +#endif + + #endif /* _MSGL_CHARSET_H */ diff --git a/gettext-tools/src/msgl-english.h b/gettext-tools/src/msgl-english.h index c3f1128f2..19c80a5f3 100644 --- a/gettext-tools/src/msgl-english.h +++ b/gettext-tools/src/msgl-english.h @@ -1,5 +1,5 @@ /* Message translation initialization for English. - Copyright (C) 2001-2002 Free Software Foundation, Inc. + Copyright (C) 2001-2003 Free Software Foundation, Inc. Written by Bruno Haible , 2001. This program is free software; you can redistribute it and/or modify @@ -21,7 +21,19 @@ #include "message.h" + +#ifdef __cplusplus +extern "C" { +#endif + + extern msgdomain_list_ty * msgdomain_list_english (msgdomain_list_ty *mdlp); + +#ifdef __cplusplus +} +#endif + + #endif /* _MSGL_ENGLISH_H */ diff --git a/gettext-tools/src/msgl-equal.h b/gettext-tools/src/msgl-equal.h index 5eafa00ef..1db2d2c41 100644 --- a/gettext-tools/src/msgl-equal.h +++ b/gettext-tools/src/msgl-equal.h @@ -1,5 +1,5 @@ /* Message list test for equality. - Copyright (C) 2001-2002 Free Software Foundation, Inc. + Copyright (C) 2001-2003 Free Software Foundation, Inc. Written by Bruno Haible , 2001. This program is free software; you can redistribute it and/or modify @@ -19,9 +19,15 @@ #ifndef _MSGL_EQUAL_H #define _MSGL_EQUAL_H +#include + #include "message.h" -#include + +#ifdef __cplusplus +extern "C" { +#endif + extern bool string_list_equal (const string_list_ty *slp1, @@ -42,4 +48,10 @@ extern bool const msgdomain_list_ty *mdlp2, bool ignore_potcdate); + +#ifdef __cplusplus +} +#endif + + #endif /* _MSGL_EQUAL_H */ diff --git a/gettext-tools/src/po-lex.h b/gettext-tools/src/po-lex.h index ce85bf3fe..c9e0aafc2 100644 --- a/gettext-tools/src/po-lex.h +++ b/gettext-tools/src/po-lex.h @@ -28,6 +28,12 @@ #include "pos.h" #include "xerror.h" + +#ifdef __cplusplus +extern "C" { +#endif + + /* Lexical analyzer for reading PO files. */ @@ -149,4 +155,10 @@ struct msgstr_def size_t msgstr_len; }; + +#ifdef __cplusplus +} +#endif + + #endif diff --git a/gettext-tools/src/read-po.h b/gettext-tools/src/read-po.h index ce5c3e366..f40163e75 100644 --- a/gettext-tools/src/read-po.h +++ b/gettext-tools/src/read-po.h @@ -1,5 +1,5 @@ /* Reading PO files. - Copyright (C) 1995-1998, 2000-2002 Free Software Foundation, Inc. + Copyright (C) 1995-1998, 2000-2003 Free Software Foundation, Inc. This file was written by Bruno Haible . This program is free software; you can redistribute it and/or modify @@ -25,6 +25,17 @@ #include #include + +/* For including this file in C++ mode. */ +#ifdef __cplusplus +# define this thiss +#endif + +#ifdef __cplusplus +extern "C" { +#endif + + /* The following pair of structures cooperate to create a derived class from class abstract_po_reader_ty. (See read-po-abstract.h for an explanation.) It implements the default behaviour of reading a PO file and converting it @@ -160,4 +171,10 @@ extern msgdomain_list_ty *read_po (FILE *fp, const char *real_filename, a list of messages. */ extern msgdomain_list_ty *read_po_file (const char *input_name); + +#ifdef __cplusplus +} +#endif + + #endif /* _READ_PO_H */