X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;f=doc%2Fgnulib.texi;h=b3b09dc285ddf373c9989d70921e1384a18e5568;hb=6e32a4f3592731c432e463a855e303cdc73c4e4c;hp=0f9d54309bbb540e80b3013f32bd58b317bccff2;hpb=4d9ef0a59e46216cf11afad2500596813dcd0028;p=gnulib.git diff --git a/doc/gnulib.texi b/doc/gnulib.texi index 0f9d54309..b3b09dc28 100644 --- a/doc/gnulib.texi +++ b/doc/gnulib.texi @@ -1,5 +1,5 @@ \input texinfo @c -*-texinfo-*- -@comment $Id: gnulib.texi,v 1.11 2005-07-11 15:12:49 karl Exp $ +@comment $Id: gnulib.texi,v 1.15 2005-07-30 13:47:19 karl Exp $ @comment %**start of header @setfilename gnulib.info @settitle GNU Gnulib @@ -7,7 +7,7 @@ @syncodeindex pg cp @comment %**end of header -@set UPDATED $Date: 2005-07-11 15:12:49 $ +@set UPDATED $Date: 2005-07-30 13:47:19 $ @copying This manual is for GNU Gnulib (updated @value{UPDATED}), @@ -87,6 +87,7 @@ Getting started: * inet_ntoa:: * Out of memory handling:: * Library version handling:: +* Regular expressions:: @end menu @@ -295,7 +296,7 @@ fail. @node Library version handling @section Library version handling -The module ``check_version'' can be useful when your gnulib +The module @samp{check-version} can be useful when your gnulib application is a system library. You will typically wrap the call to the @code{check_version} function through a library API, your library header file may contain: @@ -306,8 +307,16 @@ header file may contain: extern const char *stringprep_check_version (const char *req_version); @end example -The implementation of @code{stringprep_check_version} would simply -pass on the call to @code{check_version}. +To avoid ELF symbol collisions with other libraries that use the +@samp{check-version} module, add to @file{config.h} through a +AC_DEFINE something like: + +@example +AC_DEFINE(check_version, stringprep_check_version, [Rename check_version.]) +@end example + +The @code{stringprep_check_version} function will thus be implemented +by the @code{check_version} module. There are two uses of the interface. The first is a way to provide for applications to find out the version number of the library it @@ -338,6 +347,17 @@ Typical uses look like: @end example +@node Regular expressions +@section Regular expressions + +Gnulib supports many different types of regular expressions; although +the underlying features are the same or identical, the syntax used +varies. The descriptions given here for the different types are +generated automatically. + +@include regexprops-generic.texi + + @node Invoking gnulib-tool @chapter Invoking gnulib-tool @@ -503,12 +523,14 @@ SUBDIRS += gl @end example Finally, you have to add compiler and linker flags in the appropriate -source directories, so that you can make use -of the gnulib library. For example: +source directories, so that you can make use of the gnulib library. +Since some modules (@samp{getopt}, for example) may copy files into +the build directory, @file{top_builddir/lib} is needed as well +as @file{top_srcdir/lib}. For example: @example ... -AM_CPPFLAGS = -I$(top_srcdir)/lib +AM_CPPFLAGS = -I$(top_srcdir)/lib -I$(top_builddir)/lib ... LIBADD = lib/libgnu.a ... @@ -527,7 +549,7 @@ of the definition for some symbols may be significant. For example, to use the @code{time_r} gnulib module you should use include header file provided by the gnulib, and so @samp{#include "time_r.h"}, but you shouldn't explicitely -@samp{#include } as it is allready done in @file{time_r.h} +@samp{#include } as it is already done in @file{time_r.h} before the redefinition of some symbols. @node Importing updated files