m4/: Reformat the Autoconf macros in `aclocal' style.
authorMark Wooding <mdw@distorted.org.uk>
Sun, 9 Aug 2020 10:58:37 +0000 (11:58 +0100)
committerMark Wooding <mdw@distorted.org.uk>
Sun, 9 Aug 2020 12:05:58 +0000 (13:05 +0100)
Add a `LICENSE' section, and `# serial' markers.

m4/mdw-auto-version.m4
m4/mdw-decl-environ.m4
m4/mdw-define-paths.m4
m4/mdw-dir-texmf.m4
m4/mdw-libtool-version-info.m4
m4/mdw-manext.m4
m4/mdw-silent-rules.m4

index bdc48cf..5ea1041 100644 (file)
@@ -1,16 +1,58 @@
 dnl -*-autoconf-*-
 
-dnl --- *@-mdw_AUTO_VERSION-@* ---
-dnl
-dnl Author:    Mark Wooding
-dnl
-dnl Synopsis:  mdw_AUTO_VERSION
-dnl
-dnl Arguments: ---
-dnl
-dnl Use:       Defines an m4 macro AUTO_VERSION which contains the current
-dnl            version number, worked out in some clever way.
+### SYNOPSIS
+###
+###   mdw_AUTO_VERSION
+###
+### DESCRIPTION
+###
+###   Defines an m4 macro `AUTO_VERSION' which contains the current package's
+###   version number, worked out in some clever way.
+###
+###   The heavy lifting is performed by the `auto-version' script (q.v.).  In
+###   brief:
+###
+###    * if this is a Git working tree (i.e., there is a `.git' file or
+###      directory at toplevel) then call `git describe' and use its output;
+###
+###     * if there is a `RELEASE' file, then use its contents literally;
+###
+###     * if there is a `debian/changelog' file, then use the most recent
+###      entry's version number;
+###
+###     * otherwise use `UNKNOWN'.
+###
+### LICENSE
+###
+###   Copyright (c) 2008 Mark Wooding <mdw@distorted.org.uk>
+###
+###   This program is free software: you can redistribute it and/or modify it
+###   under the terms of the GNU General Public License as published by the
+###   Free Software Foundation, either version 2 of the License, or (at your
+###   option) any later version.
+###
+###   This program is distributed in the hope that it will be useful, but
+###   WITHOUT ANY WARRANTY; without even the implied warranty of
+###   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+###   General Public License for more details.
+###
+###   You should have received a copy of the GNU General Public License along
+###   with this program. If not, see <http://www.gnu.org/licenses/>.
+###
+###   As a special exception, the respective Autoconf Macro's copyright owner
+###   gives unlimited permission to copy, distribute and modify the configure
+###   scripts that are the output of Autoconf when processing the Macro. You
+###   need not follow the terms of the GNU General Public License when using
+###   or distributing such scripts, even though portions of the text of the
+###   Macro appear in them. The GNU General Public License (GPL) does govern
+###   all other use of the material that constitutes the Autoconf Macro.
+###
+###   This special exception to the GPL applies to versions of the Autoconf
+###   Macro released by the Autoconf Archive. When you make and distribute a
+###   modified version of the Autoconf Macro, you may extend this special
+###   exception to the GPL to apply to your modified version as well.
 
+# serial 1
 AC_DEFUN([mdw_AUTO_VERSION], [nobody cares...])
 m4_define([mdw_AUTO_VERSION], [m4_define([AUTO_VERSION], m4_esyscmd([
   ver=UNKNOWN
index 880e499..52138e1 100644 (file)
@@ -1,17 +1,45 @@
 dnl -*-autoconf-*-
 
-dnl --- *@-mdw_DECL_ENVIRON-@* ---
-dnl
-dnl Author:    Mark Wooding
-dnl
-dnl Synopsis:  mdw_DECL_ENVIRON
-dnl
-dnl Arguments: ---
-dnl
-dnl Use:       Searches for a declaration of the global `environ' variable.
-dnl            If one is found in one of the `usual' places, DECL_ENVIRON
-dnl            is defined as a preprocessor symbol.
+### SYNOPSIS
+###
+###   mdw_DECL_ENVIRON
+###
+### DESCRIPTION
+###
+###   Define a preprocessor symbol `DECL_ENVIRON' if the `environ' vector is
+###   declared in one of the `usual' places.
+###
+### LICENSE
+###
+###   Copyright (c) 1999 Mark Wooding <mdw@distorted.org.uk>
+###
+###   This program is free software: you can redistribute it and/or modify it
+###   under the terms of the GNU General Public License as published by the
+###   Free Software Foundation, either version 2 of the License, or (at your
+###   option) any later version.
+###
+###   This program is distributed in the hope that it will be useful, but
+###   WITHOUT ANY WARRANTY; without even the implied warranty of
+###   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+###   General Public License for more details.
+###
+###   You should have received a copy of the GNU General Public License along
+###   with this program. If not, see <http://www.gnu.org/licenses/>.
+###
+###   As a special exception, the respective Autoconf Macro's copyright owner
+###   gives unlimited permission to copy, distribute and modify the configure
+###   scripts that are the output of Autoconf when processing the Macro. You
+###   need not follow the terms of the GNU General Public License when using
+###   or distributing such scripts, even though portions of the text of the
+###   Macro appear in them. The GNU General Public License (GPL) does govern
+###   all other use of the material that constitutes the Autoconf Macro.
+###
+###   This special exception to the GPL applies to versions of the Autoconf
+###   Macro released by the Autoconf Archive. When you make and distribute a
+###   modified version of the Autoconf Macro, you may extend this special
+###   exception to the GPL to apply to your modified version as well.
 
+# serial 1
 AC_DEFUN([mdw_DECL_ENVIRON],
 [AC_CACHE_CHECK([for declaration of \`environ'], mdw_cv_environ,
 [AC_EGREP_CPP([\<environ\>],
index d3089e6..5253774 100644 (file)
@@ -1,27 +1,64 @@
 dnl -*-autoconf-*-
 
-dnl --- *@-mdw_DEFINE_PATHS-@*
-dnl
-dnl Author:    Mark Wooding
-dnl
-dnl Synopsis:  mdw_DEFINE_PATHS(CODE)
-dnl
-dnl Arguments: CODE = shell script code to execute
-dnl
-dnl Use:       Fixes up various variables so that pathname defines can be
-dnl            defined.  Within CODE, you may use the following macros:
-dnl
-dnl            mdw_PROG(NAME)          Transformed program name
-dnl
-dnl            mdw_PATH(PATH)          Expanded path (may contain variables)
-dnl
-dnl            mdw_DEFINE_PROG(SYMBOL, PROG)
-dnl                                    Define a symbol as a transformed
-dnl                                    program name.
-dnl
-dnl            mdw_DEFINE_PATH(SYMBOL, NAME)
-dnl                                    Define a symbol as an expanded path
+### SYNOPSIS
+###
+###   mdw_DEFINE_PATHS(BODY)
+###
+###   mdw_PROG(PROG)
+###   mdw_PATH(PATH)
+###   mdw_DEFINE_PROG(SYMBOL, PROG)
+###   mdw_DEFINE_PATH(SYMBOL, PATH)
+###
+### DESCRIPTION
+###
+###   This collection of macros is useful for hardcoding pathname strings
+###   into binary programs.
+###
+###   Within the BODY of `mdw_DEFINE_PATHS', a number of variables are `fixed
+###   up' so that they can be properly expanded.  The other macros are only
+###   really useful within this body.
+###
+###   `mdw_PROG' expands, in the shell, to the transformed name of the
+###   program PROG.
+###
+###   `mdw_PATH' expands, in the shell, to the recursive expansion of PATH,
+###   which should be a string containing parameter expansions.
+###
+###   `mdw_DEFINE_PROG' is a convenience macro which defines the preprocessor
+###   SYMBOL to the result of `mdw_PROG(PROG)'; similarly `mdw_DEFINE_PATH'
+###   defines SYMBOL to the result of `mdw_PATH(PATH)'.
+###
+### LICENSE
+###
+###   Copyright (c) 2002 Mark Wooding <mdw@distorted.org.uk>
+###
+###   This program is free software: you can redistribute it and/or modify it
+###   under the terms of the GNU General Public License as published by the
+###   Free Software Foundation, either version 2 of the License, or (at your
+###   option) any later version.
+###
+###   This program is distributed in the hope that it will be useful, but
+###   WITHOUT ANY WARRANTY; without even the implied warranty of
+###   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+###   General Public License for more details.
+###
+###   You should have received a copy of the GNU General Public License along
+###   with this program. If not, see <http://www.gnu.org/licenses/>.
+###
+###   As a special exception, the respective Autoconf Macro's copyright owner
+###   gives unlimited permission to copy, distribute and modify the configure
+###   scripts that are the output of Autoconf when processing the Macro. You
+###   need not follow the terms of the GNU General Public License when using
+###   or distributing such scripts, even though portions of the text of the
+###   Macro appear in them. The GNU General Public License (GPL) does govern
+###   all other use of the material that constitutes the Autoconf Macro.
+###
+###   This special exception to the GPL applies to versions of the Autoconf
+###   Macro released by the Autoconf Archive. When you make and distribute a
+###   modified version of the Autoconf Macro, you may extend this special
+###   exception to the GPL to apply to your modified version as well.
 
+# serial 1
 AC_DEFUN([mdw_DEFINE_PATHS],
 [mdw_prefix=$prefix mdw_exec_prefix=$exec_prefix
 mdw_transform=`echo "$program_transform_name"|sed 's,\\\\\\\\,\\\\,g; s,\\$\\$,$,g'`
index 6e1c0ee..e2bfd45 100644 (file)
@@ -1,16 +1,54 @@
 dnl -*-autoconf-*-
 
-dnl --- *@-mdw_DIR_TEXMF-@* ---
-dnl
-dnl Author:     Mark Wooding
-dnl
-dnl Synopsis:   mdw_DIR_TEXMF
-dnl
-dnl Arguments:  ---
-dnl
-dnl Use:        Sets the substitution `texmfdir' as a sensible TeX install
-dnl             tree.
+### SYNOPSIS
+###
+###   mdw_DIR_TEXMF
+###
+### DESCRIPTION
+###
+###   Define the substitution `@texmfdir@' to name a sensible TeX
+###   installation root directory.
+###
+###   A `--with-texmfdir' command-line option is defined, which allows the
+###   end user to select a specific installation root.  The default is chosen
+###   according to a heuristic, which is currently to use the first of
+###
+###     * `DATADIR/texmf',
+###     * `PREFIX/lib/texmf',
+###     * `PREFIX/texmf',
+###     * `LIBDIR/lib/texmf'.
+###
+### LICENSE
+###
+###   Copyright (c) 2002 Mark Wooding <mdw@distorted.org.uk>
+###
+###   This program is free software: you can redistribute it and/or modify it
+###   under the terms of the GNU General Public License as published by the
+###   Free Software Foundation, either version 2 of the License, or (at your
+###   option) any later version.
+###
+###   This program is distributed in the hope that it will be useful, but
+###   WITHOUT ANY WARRANTY; without even the implied warranty of
+###   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+###   General Public License for more details.
+###
+###   You should have received a copy of the GNU General Public License along
+###   with this program. If not, see <http://www.gnu.org/licenses/>.
+###
+###   As a special exception, the respective Autoconf Macro's copyright owner
+###   gives unlimited permission to copy, distribute and modify the configure
+###   scripts that are the output of Autoconf when processing the Macro. You
+###   need not follow the terms of the GNU General Public License when using
+###   or distributing such scripts, even though portions of the text of the
+###   Macro appear in them. The GNU General Public License (GPL) does govern
+###   all other use of the material that constitutes the Autoconf Macro.
+###
+###   This special exception to the GPL applies to versions of the Autoconf
+###   Macro released by the Autoconf Archive. When you make and distribute a
+###   modified version of the Autoconf Macro, you may extend this special
+###   exception to the GPL to apply to your modified version as well.
 
+# serial 1
 AC_DEFUN([mdw_DIR_TEXMF], [
 AC_ARG_WITH([texmfdir],
 [  --with-texmfdir=DIR     set the TeX install directory to DIR],
index 2f19157..dc9fe05 100644 (file)
@@ -1,17 +1,46 @@
 dnl -*-autoconf-*-
 
-dnl --- *@-mdw_LIBTOOL_VERSION_INFO-@* ---
-dnl
-dnl Author:    Mark Wooding
-dnl
-dnl Synopsis:  mdw_LIBTOOL_VERSION
-dnl
-dnl Arguments: ---
-dnl
-dnl Use:       Decodes the PACKAGE_VERSION variable as a libtool
-dnl            version-info string.  Strictly speaking, this is very
-dnl            naughty.
+### SYNOPSIS
+###
+###   mdw_LIBTOOL_VERSION_INFO
+###
+### DESCRIPTION
+###
+###   Decodes the `PACKAGE_VERSION' variable as a `libtool' version-info
+###   string, available as the `@LIBTOOL_VERSION_INFO@' substitution.
+###   Strictly speaking, this is very naughty.
+###
+### LICENSE
+###
+###   Copyright (c) 2008 Mark Wooding <mdw@distorted.org.uk>
+###
+###   This program is free software: you can redistribute it and/or modify it
+###   under the terms of the GNU General Public License as published by the
+###   Free Software Foundation, either version 2 of the License, or (at your
+###   option) any later version.
+###
+###   This program is distributed in the hope that it will be useful, but
+###   WITHOUT ANY WARRANTY; without even the implied warranty of
+###   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+###   General Public License for more details.
+###
+###   You should have received a copy of the GNU General Public License along
+###   with this program. If not, see <http://www.gnu.org/licenses/>.
+###
+###   As a special exception, the respective Autoconf Macro's copyright owner
+###   gives unlimited permission to copy, distribute and modify the configure
+###   scripts that are the output of Autoconf when processing the Macro. You
+###   need not follow the terms of the GNU General Public License when using
+###   or distributing such scripts, even though portions of the text of the
+###   Macro appear in them. The GNU General Public License (GPL) does govern
+###   all other use of the material that constitutes the Autoconf Macro.
+###
+###   This special exception to the GPL applies to versions of the Autoconf
+###   Macro released by the Autoconf Archive. When you make and distribute a
+###   modified version of the Autoconf Macro, you may extend this special
+###   exception to the GPL to apply to your modified version as well.
 
+# serial 1
 AC_DEFUN([mdw_LIBTOOL_VERSION_INFO], [
   set -- $(echo $PACKAGE_VERSION |
   sed 's:[^\([0-9][0-9]*\)\.\([0-9][0-9]*\)\.\([0-9][0-9]*\).*$]:\1 \2 \3:'
index 5b35426..0d5b90d 100644 (file)
@@ -1,15 +1,48 @@
 dnl -*-autoconf-*-
 
-dnl --- *@-mdw_MANEXT-@* ---
-dnl
-dnl Author:    Mark Wooding
-dnl
-dnl Synopsis:  mdw_MANEXT
-dnl
-dnl Arguments: ---
-dnl
-dnl Use:       Sets the substitution `manext' for man page extensions.
+### SYNOPSIS
+###
+###   mdw_MANEXT
+###
+### DESCRIPTION
+###
+###   Define the `@manext@' substitution as an extension to append to manpage
+###   section names.
+###
+###   A `--with-man-ext' command-line option is defined, which allows the end
+###   user to override the setting; otherwise it is set to DFLT.
+###
+### LICENSE
+###
+###   Copyright (c) 2003 Mark Wooding <mdw@distorted.org.uk>
+###
+###   This program is free software: you can redistribute it and/or modify it
+###   under the terms of the GNU General Public License as published by the
+###   Free Software Foundation, either version 2 of the License, or (at your
+###   option) any later version.
+###
+###   This program is distributed in the hope that it will be useful, but
+###   WITHOUT ANY WARRANTY; without even the implied warranty of
+###   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+###   General Public License for more details.
+###
+###   You should have received a copy of the GNU General Public License along
+###   with this program. If not, see <http://www.gnu.org/licenses/>.
+###
+###   As a special exception, the respective Autoconf Macro's copyright owner
+###   gives unlimited permission to copy, distribute and modify the configure
+###   scripts that are the output of Autoconf when processing the Macro. You
+###   need not follow the terms of the GNU General Public License when using
+###   or distributing such scripts, even though portions of the text of the
+###   Macro appear in them. The GNU General Public License (GPL) does govern
+###   all other use of the material that constitutes the Autoconf Macro.
+###
+###   This special exception to the GPL applies to versions of the Autoconf
+###   Macro released by the Autoconf Archive. When you make and distribute a
+###   modified version of the Autoconf Macro, you may extend this special
+###   exception to the GPL to apply to your modified version as well.
 
+# serial 1
 AC_DEFUN([mdw_MANEXT], [
 AC_ARG_WITH([man-ext],
 [  --with-man-ext=EXT      give manpages the EXT extension (e.g., foo.3EXT)],
index dbc877e..c3fe927 100644 (file)
@@ -1,15 +1,44 @@
 dnl -*-autoconf-*-
 
-dnl --- *@-mdw_SILENT_RULES-@* ---
-dnl
-dnl Author:    Mark Wooding
-dnl
-dnl Synopsis:  mdw_SILENT_RULES
-dnl
-dnl Arguments: ---
-dnl
-dnl Use:       Enables the Automake `silent-rules' feature, if available.
+### SYNOPSIS
+###
+###   mdw_SILENT_RULES
+###
+### DESCRIPTION
+###
+###   Set Automake's `silent-rules' feature on by default, if available.
+###
+### LICENSE
+###
+###   Copyright (c) 2010 Mark Wooding <mdw@distorted.org.uk>
+###
+###   This program is free software: you can redistribute it and/or modify it
+###   under the terms of the GNU General Public License as published by the
+###   Free Software Foundation, either version 2 of the License, or (at your
+###   option) any later version.
+###
+###   This program is distributed in the hope that it will be useful, but
+###   WITHOUT ANY WARRANTY; without even the implied warranty of
+###   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+###   General Public License for more details.
+###
+###   You should have received a copy of the GNU General Public License along
+###   with this program. If not, see <http://www.gnu.org/licenses/>.
+###
+###   As a special exception, the respective Autoconf Macro's copyright owner
+###   gives unlimited permission to copy, distribute and modify the configure
+###   scripts that are the output of Autoconf when processing the Macro. You
+###   need not follow the terms of the GNU General Public License when using
+###   or distributing such scripts, even though portions of the text of the
+###   Macro appear in them. The GNU General Public License (GPL) does govern
+###   all other use of the material that constitutes the Autoconf Macro.
+###
+###   This special exception to the GPL applies to versions of the Autoconf
+###   Macro released by the Autoconf Archive. When you make and distribute a
+###   modified version of the Autoconf Macro, you may extend this special
+###   exception to the GPL to apply to your modified version as well.
 
+# serial 1
 AC_DEFUN([mdw_SILENT_RULES], [
   m4_ifdef([AM_SILENT_RULES], [
     AM_SILENT_RULES([yes])