Mercurial > hg > octave-nkf > gnulib-hg
changeset 4393:03ca5982ec96
Add a section "how to add a new module", suggested by Simon Josefsson.
author | Bruno Haible <bruno@clisp.org> |
---|---|
date | Wed, 11 Jun 2003 10:57:36 +0000 |
parents | c3f755572af2 |
children | 1c8a2d2c4ae8 |
files | README |
diffstat | 1 files changed, 28 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/README +++ b/README @@ -36,7 +36,34 @@ name), we should be able to include it. If your functions define completely new but rarely used functionality, -you should probably consider packaging it as a seperate library +you should probably consider packaging it as a seperate library. + +How to add a new module +----------------------- + +* Add the header files and source files to lib/. +* If the module needs configure-time checks, write an autoconf + macro for it in m4/<module>.m4. See m4/README for details. +* Write a module description modules/<module>, based on modules/TEMPLATE. +* Add the module to the list in MODULES.html.sh. + +You can test that a module builds correctly with: + $ ./gnulib-tool --create-testdir --dir=/tmp/testdir module1 ... moduleN + $ cd /tmp/testdir + $ ./configure && make + +Other things: +* Check the license and copyright year of headers. +* Add source files to config/srclist* if they are identical to upstream + and should be upgraded in gnulib whenever the upstream source changes. +* Include header files in source files to verify the function prototypes. +* Make sure a replacement function doesn't cause warnings or clashes on + systems that have the function. +* Autoconf functions can use gl_* prefix. The AC_* prefix is for + autoconf internal functions. +* Try to prevent that the files are built if they aren't needed on a + platform. Valid excuses to this rule include ELIDE constructs that + lead to an empty .o file (see getopt module). High Quality ============