summaryrefslogtreecommitdiff
path: root/doc/gnulib-intro.texi
diff options
context:
space:
mode:
authorBruno Haible <bruno@clisp.org>2008-12-06 13:04:07 +0100
committerBruno Haible <bruno@clisp.org>2008-12-06 13:04:07 +0100
commit52c2cd2f06d1ed983abb9d86006ca45a75181b2e (patch)
tree0e28051fef0ec03acea96d69cba70704c33f5b02 /doc/gnulib-intro.texi
parent0c0a2a11abc9d8e44cadc139df77731532897f0e (diff)
downloadgnulib-52c2cd2f06d1ed983abb9d86006ca45a75181b2e.tar.gz
Advocacy documentation.
Diffstat (limited to 'doc/gnulib-intro.texi')
-rw-r--r--doc/gnulib-intro.texi34
1 files changed, 34 insertions, 0 deletions
diff --git a/doc/gnulib-intro.texi b/doc/gnulib-intro.texi
index 169ca80547..fa282a4b29 100644
--- a/doc/gnulib-intro.texi
+++ b/doc/gnulib-intro.texi
@@ -1,3 +1,37 @@
+@node Benefits
+@section Benefits of using Gnulib
+
+Gnulib is useful to enhance various aspects of a package:
+
+@itemize @bullet
+@item
+Portability: With Gnulib, a package maintainer can program against the
+POSIX and GNU libc APIs and nevertheless expect good portability to
+platforms that don't implement POSIX.
+
+@item
+Maintainability: When a package uses modules from Gnulib instead of code
+written specifically for that package, the maintainer has less code to
+maintain.
+
+@item
+Security: Gnulib provides functions that are immune against vulnerabilities
+that plagues the uses of the corresponding commonplace functions. For
+example, @code{asprintf}, @code{canonicalize_file_name} are not affected
+by buffer sizing problems that affect @code{sprintf}, @code{realpath}.
+@code{openat} does not have the race conditions that @code{open} has. Etc.
+
+@item
+Reliability: Gnulib provides functions that combine a call to a system
+function with a check of the result. Examples are @code{xalloc},
+@code{xprintf}, @code{xstrtod}, @code{xgetcwd}.
+
+@item
+Structure: Gnulib offers a way to structure code into modules, typically
+one include file, one source code file, and one autoconf macro for each
+functionality. Modularity helps maintainability.
+@end itemize
+
@node Library vs Reusable Code
@section Library vs. Reusable Code