2 1) Dependencies for using gnulib-tool (maintainer environment)
3 2) Dependencies for building the imported code (target environment)
6 1) Dependencies for using gnulib-tool (maintainer environment)
7 **************************************************************
9 The following packages are needed by maintainers for using 'gnulib-tool'.
10 We call this the "maintainer environment", although it is not necessarily
11 a maintainer's or developer's machine; it can also be some containerized
14 In general, Gnulib prefers the latest stable version of each package,
15 but in some cases it also supports older versions; this caters to
16 commonly-used software distributions that may lag behind the latest
17 stable package. Support for older versions is not guaranteed, though,
18 and the version numbers in the following list may be incremented
21 * A C runtime, compiler, linker, etc.
22 + Mandatory. Using the platform's native 'cc' gives good portability
23 exposure, but you can also use GCC 3.1 or newer.
27 https://ftp.gnu.org/gnu/gcc/
30 + Mandatory. Using the platform's native 'make' gives good portability
31 exposure for in-tree builds, but VPATH builds on OpenBSD or Solaris
32 require GNU Make 3.79.1 or newer.
34 https://www.gnu.org/software/make/
36 https://ftp.gnu.org/gnu/make/
38 * GNU M4 1.4.5 or newer.
40 1.4.5 or newer is mandatory, but 1.4.9 or newer is recommended.
41 If you want to build it from source, use the tarball from
42 https://gitlab.com/gnu-m4/ci-distcheck/-/jobs/artifacts/master/raw/m4-snapshot.tar?job=check-optimized
44 https://www.gnu.org/software/m4/
46 https://ftp.gnu.org/gnu/m4/
48 * Autoconf 2.64 or newer.
51 https://www.gnu.org/software/autoconf/
53 https://ftp.gnu.org/gnu/autoconf/
55 * Automake 1.14 or newer.
58 https://www.gnu.org/software/automake/
60 https://ftp.gnu.org/gnu/automake/
63 + Mandatory. Using the platform's native 'sh' gives good portability
64 exposure, but you can also use Bash.
66 https://www.gnu.org/software/bash/
68 https://ftp.gnu.org/gnu/bash/
70 * Core POSIX utilities, including:
71 [ basename cat chgrp chmod chown cp dd echo expand expr
72 false hostname install join kill ln ls md5sum mkdir mkfifo
73 mknod mv printenv pwd rm rmdir sleep sort tee test touch
75 + Mandatory. Using the platform's native utilities gives good portability
76 exposure, but you can also use GNU coreutils.
78 https://www.gnu.org/software/coreutils/
80 https://ftp.gnu.org/gnu/coreutils/
82 * The comparison utilities 'cmp' and 'diff'.
83 + Mandatory. Using the platform's native utilities gives good portability
84 exposure, but you can also use GNU diffutils.
86 https://www.gnu.org/software/diffutils/
88 https://ftp.gnu.org/gnu/diffutils/
90 * The patch utility 'patch'.
91 + Mandatory if you use gnulib-local diffs. Using the platform's native
92 utilities gives good portability exposure, but you can also use GNU
95 https://www.gnu.org/software/patch/
97 https://ftp.gnu.org/gnu/patch/
100 + Mandatory. Using the platform's native grep gives good portability
101 exposure, but you can also use GNU grep.
103 https://www.gnu.org/software/grep/
105 https://ftp.gnu.org/gnu/grep/
109 Using the platform's native awk, mawk, or nawk gives good portability
110 exposure, but you can also use GNU awk.
112 https://www.gnu.org/software/gawk/
114 https://ftp.gnu.org/gnu/gawk/
116 * Python 3.7 or newer.
118 Without it, gnulib-tool is between 8 times and 100 times slower and may lack
119 functionality added after April 2024.
121 https://www.python.org/
123 https://www.python.org/downloads/
124 + Pre-built package name:
125 - On Debian and Debian-based systems: python3,
126 - On Red Hat distributions: python3.
127 - Other: https://repology.org/project/python/versions
130 + If your project wants to follow GNU Coding Standards:
131 + Always use the newest available gettext release, see
132 <https://www.gnu.org/software/gnulib/manual/html_node/gettextize-and-autopoint.html>.
133 + Use the 'gettext' module.
134 + If your project cares more about ease of development on older platforms:
135 + gettext 0.17 or newer.
136 + Use the 'gettext-h' module.
138 Needed if you use modules that use internationalization (many do).
140 https://www.gnu.org/software/gettext/
142 https://ftp.gnu.org/gnu/gettext/
143 + Pre-built package name:
144 - On Debian and Debian-based systems: gettext,
145 - On Red Hat distributions: gettext.
146 - Other: https://repology.org/project/gettext/versions
148 * Bison 2.0 or newer.
150 Needed if you use the 'parse-datetime' module.
152 https://www.gnu.org/software/bison/
154 https://ftp.gnu.org/gnu/bison/
155 + Pre-built package name:
156 - On Debian and Debian-based systems: bison,
157 - On Red Hat distributions: bison.
158 - Other: https://repology.org/project/bison/versions
160 * GNU gperf 3.0.1 or newer.
161 + 3.0.1 or newer is mandatory, but 3.1 or newer is recommended.
162 Needed if you use the 'iconv_open' module or some of the
163 unictype/*, unicase/*, uninorm/* modules.
165 https://www.gnu.org/software/gperf/
167 https://ftp.gnu.org/gnu/gperf/
168 + Pre-built package name:
169 - On Debian and Debian-based systems: gperf,
170 - On Red Hat distributions: gperf.
171 - Other: https://repology.org/project/gperf/versions
173 * Texinfo 4.6 or newer.
175 Needed if you use modules that include documentation.
177 https://www.gnu.org/software/texinfo/
179 https://ftp.gnu.org/gnu/texinfo/
180 + Pre-built package name:
181 - On Debian and Debian-based systems: texinfo,
182 - On Red Hat distributions: texinfo.
183 - Other: https://repology.org/project/texinfo/versions
187 Needed on platforms where the vendor's 'sed' program is too buggy.
189 https://www.gnu.org/software/sed/
191 https://ftp.gnu.org/gnu/sed/
193 * GNU libtool 1.5.22 or newer.
195 Needed if you want to invoke gnulib-tool with option --libtool.
196 libtool 2.2.x or newer is needed if you want to invoke gnulib-tool
197 with options --create-testdir/--test and --libtool.
199 https://www.gnu.org/software/libtool/
201 https://ftp.gnu.org/gnu/libtool/
203 * GNU tar 1.28 or newer.
205 Needed if you use the 'gnumakefile' module, which sets TAR_OPTIONS
206 to --sort=names (added in version 1.28) in GNUmakefile for 'make dist'.
208 https://www.gnu.org/software/tar/
210 https://ftp.gnu.org/gnu/tar/
212 Note: Solaris 10 is no longer supported as maintainer environment.
213 <https://lists.gnu.org/archive/html/bug-gnulib/2024-07/msg00076.html>
216 2) Dependencies for building the imported code (target environment)
217 *******************************************************************
219 The following packages are needed for building the package that imports
222 * A C runtime, compiler, linker, etc.
223 + Mandatory. Using the platform's native 'cc' gives good portability
224 exposure, but you can also use GCC 3.1 or newer.
228 https://ftp.gnu.org/gnu/gcc/
231 + Mandatory. Using the platform's native 'make' gives good portability
232 exposure for in-tree builds, but VPATH builds on OpenBSD or Solaris
233 require GNU Make 3.79.1 or newer.
235 https://www.gnu.org/software/make/
237 https://ftp.gnu.org/gnu/make/
240 + Mandatory. Using the platform's native 'sh' gives good portability
241 exposure, but you can also use Bash.
243 https://www.gnu.org/software/bash/
245 https://ftp.gnu.org/gnu/bash/
247 * Core POSIX utilities, including:
248 [ basename cat chgrp chmod chown cp dd echo expand expr
249 false hostname install kill ln ls md5sum mkdir mkfifo
250 mknod mv printenv pwd rm rmdir sleep sort tee test touch
252 + Mandatory. Using the platform's native utilities gives good portability
253 exposure, but you can also use GNU coreutils.
255 https://www.gnu.org/software/coreutils/
257 https://ftp.gnu.org/gnu/coreutils/
259 * The comparison utilities 'cmp' and 'diff'.
260 + Mandatory. Using the platform's native utilities gives good portability
261 exposure, but you can also use GNU diffutils.
263 https://www.gnu.org/software/diffutils/
265 https://ftp.gnu.org/gnu/diffutils/
268 + Mandatory. Using the platform's native grep gives good portability
269 exposure, but you can also use GNU grep.
271 https://www.gnu.org/software/grep/
273 https://ftp.gnu.org/gnu/grep/
277 Using the platform's native awk, mawk, or nawk gives good portability
278 exposure, but you can also use GNU awk.
280 https://www.gnu.org/software/gawk/
282 https://ftp.gnu.org/gnu/gawk/
284 Prerequisites on Windows
285 ------------------------
289 Provides a POSIX-like environment and binary packages necessary to
290 build and run software. Native Windows binaries can be built with
291 a packaged mingw tool chain. This method is preferred over MSYS2.
295 https://cygwin.com/install.html
300 Various modules work best with certain libraries installed. These are runtime
301 dependencies that are also build dependencies.
303 For modules 'abort-debug' and 'stack-trace':
306 Needed for producing C stack traces with source file names and
309 https://github.com/ianlancetaylor/libbacktrace
311 https://github.com/ianlancetaylor/libbacktrace
312 + Pre-built package name:
313 - On Debian and Debian-based systems: libgcc-N-dev,
314 - On Red Hat distributions: --.
315 - Other: https://repology.org/project/libbacktrace/versions
319 + Recommended on Linux systems.
320 Needed so that the creation of backup files respects the access control
321 lists (ACLs) set on the original files.
323 https://savannah.nongnu.org/projects/acl/
325 https://download.savannah.nongnu.org/releases/acl/
326 + Pre-built package name:
327 - On Debian and Debian-based systems: libacl1-dev,
328 - On Red Hat distributions: libacl-devel.
329 - Other: https://repology.org/project/acl/versions
331 + Recommended on Linux systems.
332 Needed so that the creation of backup files respects the access control
333 lists (ACLs) set on the original files, with fewer system calls.
335 https://savannah.nongnu.org/projects/attr/
337 https://download.savannah.nongnu.org/releases/attr/
338 + Pre-built package name:
339 - On Debian and Debian-based systems: libattr1-dev,
340 - On Red Hat distributions: libattr-devel.
341 - Other: https://repology.org/project/attr/versions
343 For module 'gettext-h':
344 * libintl, part of GNU gettext
345 + Not needed on systems with glibc.
346 But highly recommended on all other systems.
347 Needed for localization (translation) of messages to the user's
350 https://www.gnu.org/software/gettext/
352 https://ftp.gnu.org/gnu/gettext/
353 + Pre-built package name:
354 - On Debian and Debian-based systems: --,
355 - On Red Hat distributions: --.
356 - Other: https://repology.org/project/gettext/versions
357 + If it is installed in a nonstandard directory, pass the option
358 --with-libintl-prefix=DIR to 'configure'.
362 + Not needed on systems with glibc and on NetBSD.
363 But highly recommended on all other systems.
364 Needed for character set conversion of strings from/to Unicode.
366 https://www.gnu.org/software/libiconv/
368 https://ftp.gnu.org/gnu/libiconv/
369 + Pre-built package name:
370 - On Debian and Debian-based systems: --,
371 - On Red Hat distributions: --.
372 - Other: https://repology.org/project/libiconv/versions
373 + If it is installed in a nonstandard directory, pass the option
374 --with-libiconv-prefix=DIR to 'configure'.
375 + On mingw, a slim alternative is the 'win-iconv' package version 0.0.8
376 from https://github.com/win-iconv/win-iconv .
381 Needed for fast multiprecision computations.
383 https://www.gnu.org/software/gmp/
385 https://ftp.gnu.org/gnu/gmp/
386 + Pre-built package name:
387 - On Debian and Debian-based systems: libgmp-dev,
388 - On Red Hat distributions: gmp-devel.
389 - Other: https://repology.org/project/gmp/versions
390 + If it is installed in a nonstandard directory, pass the option
391 --with-libgmp-prefix to 'configure'.
393 For module 'readline':
396 Needed for interactive editing of textual input.
398 https://www.gnu.org/software/readline/
400 https://ftp.gnu.org/gnu/readline/
401 + Pre-built package name:
402 - On Debian and Debian-based systems: libreadline-dev,
403 - On Red Hat distributions: readline-devel.
404 - Other: https://repology.org/project/readline/versions
405 + If it is installed in a nonstandard directory, pass the option
406 --with-libreadline-prefix=DIR to 'configure'.
408 For modules 'terminfo' and 'termcap':
409 * GNU ncurses (preferred)
410 or libtermcap (discouraged) or a curses library (legacy).
412 Needed for fancy input/output in terminal emulators.
414 https://www.gnu.org/software/ncurses/
416 https://ftp.gnu.org/gnu/ncurses/
417 + Pre-built package name:
418 - On Debian and Debian-based systems: libncurses-dev,
419 - On Red Hat distributions: ncurses-devel.
420 - Other: https://repology.org/project/ncurses/versions
421 + If it is installed in a nonstandard directory, pass the option
422 --with-libncurses-prefix=DIR or --with-libtermcap-prefix to 'configure'.
424 For modules 'crypto/md5-buffer', 'crypto/sha*-buffer':
427 Needed for optimized crypto hash sums.
429 https://www.openssl.org/
431 https://www.openssl.org/source/
432 + Pre-built package name:
433 - On Debian and Debian-based systems: libssl-dev,
434 - On Red Hat distributions: openssl-devel.
435 - Other: https://repology.org/project/openssl/versions
440 If your package includes the tests for the Gnulib modules that you imported,
441 you will want to maximize the test coverage of these tests, that is, to
442 minimize the number of tests that are skipped. To this effect, you need to
443 install a couple of locales, used by the tests.
445 You can get a listing of the locales installed by default through
447 (Note: On glibc systems, this command displays the encoding names in a
448 mutilated form, e.g. it transforms "en_US.UTF-8" to "en_US.utf8".)
450 To install the needed locales on glibc systems:
452 $ sudo localedef -i en_US -f UTF-8 en_US.UTF-8
453 $ sudo localedef -i ar_SA -f ISO-8859-6 ar_SA.ISO-8859-6
454 $ sudo localedef -i de_DE -f UTF-8 de_DE.UTF-8
455 $ sudo localedef -i es_ES -f UTF-8 es_ES.UTF-8
456 $ sudo localedef -i fa_IR -f UTF-8 fa_IR
457 $ sudo localedef -i fr_FR -f ISO-8859-1 fr_FR.ISO-8859-1
458 $ sudo localedef -i fr_FR -f UTF-8 fr_FR.UTF-8
459 $ sudo localedef -i ja_JP -f EUC-JP ja_JP.EUC-JP
460 $ sudo localedef -i tr_TR -f UTF-8 tr_TR.UTF-8
461 $ sudo localedef -i zh_CN -f GB18030 zh_CN.GB18030
462 $ sudo localedef -i zh_HK -f BIG5-HKSCS zh_HK.BIG5-HKSCS
464 On Debian and Debian-based systems, if you want these locales to be
465 persistent across automatic system updates, the approach is different:
466 There, you need to enable the locales in the file /etc/locale.gen and