]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
build: Move more code into libgettextsrc.
authorBruno Haible <bruno@clisp.org>
Sun, 12 Oct 2025 10:50:54 +0000 (12:50 +0200)
committerBruno Haible <bruno@clisp.org>
Sun, 12 Oct 2025 11:03:57 +0000 (13:03 +0200)
* gettext-tools/src/lang-table.h (language_table, language_table_size,
language_variant_table, language_variant_table_size): Mark as
LIBGETTEXTSRC_DLL_VARIABLE.
* gettext-tools/src/Makefile.am (libgettextsrc_la_SOURCES): Add msgl-fsearch.c,
lang-table.c, plural-count.c.
(msgmerge_SOURCES): Remove msgl-fsearch.c, lang-table.c, plural-count.c.
(msginit_SOURCES): Likewise.
* gettext-tools/src/FILES: Update.

gettext-tools/src/FILES
gettext-tools/src/Makefile.am
gettext-tools/src/lang-table.h

index 54d6ecaf2cf3a5af6342e03423730c9496f9f42b..5d36b01c363b0c6d4da62d02aa0d14364fac8150 100644 (file)
@@ -142,13 +142,18 @@ msgl-charset.h
 msgl-charset.c
                 Checking the encoding of a list-of-messages.
 
+plural-count.h
+plural-count.c
+                Extracting the plural count of a header of a lists-of-messages.
+
+msgl-fsearch.h
+msgl-fsearch.c
+                Fast fuzzy search among a list-of-messages.
+
 +-------------- The 'msgmerge' program
 | msgl-equal.h
 | msgl-equal.c
 |               Comparing two lists-of-messages.
-| plural-count.h
-| plural-count.c
-|               Extracting the plural count of a header of a lists-of-messages.
 | msgl-merge.h
 | msgl-merge.c
 |               Merging a definitions file with a references file.
index 1bcebf69112b07ad04453c605aecc9f3b5e06b66..380b52f3cf9b32194f3402b2f22884d9095566ab 100644 (file)
@@ -225,7 +225,8 @@ FORMAT_SOURCE += \
   format-gcc-internal.c \
   format-gfc-internal.c
 
-# libgettextsrc contains all code that is needed by at least two programs.
+# libgettextsrc contains all code that is needed by at least two programs
+# and that does not use OpenMP.
 libgettextsrc_la_SOURCES = \
   $(COMMON_SOURCE) \
   read-catalog-special.c \
@@ -241,8 +242,11 @@ libgettextsrc_la_SOURCES = \
   msgl-check.c \
   file-list.c \
   msgl-charset.c \
+  msgl-fsearch.c \
+  lang-table.c \
   po-time.c \
   plural-exp.c plural-eval.c plural-table.c \
+  plural-count.c \
   quote.h \
   sentence.h sentence.c \
   $(FORMAT_SOURCE) \
@@ -305,7 +309,7 @@ msgmerge_SOURCES = msgmerge.c
 else
 msgmerge_SOURCES = ../woe32dll/c++msgmerge.cc
 endif
-msgmerge_SOURCES += msgl-fsearch.c msgl-merge.c lang-table.c plural-count.c
+msgmerge_SOURCES += msgl-merge.c
 msgunfmt_SOURCES = msgunfmt.c
 msgunfmt_SOURCES += \
   read-mo.c read-java.c read-csharp.c read-resources.c read-tcl.c \
@@ -397,7 +401,7 @@ else
 msggrep_SOURCES = ../woe32dll/c++msggrep.cc
 endif
 msginit_SOURCES = msginit.c
-msginit_SOURCES += msgl-fsearch.c msgl-merge.c lang-table.c plural-count.c
+msginit_SOURCES += msgl-merge.c
 msginit_SOURCES += ../../gettext-runtime/intl/localealias.c
 if !WOE32DLL
 msguniq_SOURCES = msguniq.c
index ebf193b9816fc7c2c71431b99549ec8db12e814f..909b7bdd09e93c516c8f477960fb998e012826bc 100644 (file)
@@ -1,5 +1,5 @@
 /* Table of languages.
-   Copyright (C) 2001-2007, 2019 Free Software Foundation, Inc.
+   Copyright (C) 2001-2025 Free Software Foundation, Inc.
    Written by Bruno Haible <haible@clisp.cons.org>, 2005.
 
    This program is free software: you can redistribute it and/or modify
@@ -32,11 +32,11 @@ struct language_table_entry
   const char *english;
 };
 
-extern struct language_table_entry language_table[];
-extern const size_t language_table_size;
+extern LIBGETTEXTSRC_DLL_VARIABLE struct language_table_entry language_table[];
+extern LIBGETTEXTSRC_DLL_VARIABLE const size_t language_table_size;
 
-extern struct language_table_entry language_variant_table[];
-extern const size_t language_variant_table_size;
+extern LIBGETTEXTSRC_DLL_VARIABLE struct language_table_entry language_variant_table[];
+extern LIBGETTEXTSRC_DLL_VARIABLE const size_t language_variant_table_size;
 
 
 #ifdef __cplusplus