Commit graph

7 commits

Author SHA1 Message Date
Азалия Смарагдова
61b1544289 Landlock support has been added. 2022-08-15 13:32:24 +05:00
Kelvin M. Klann
891fd02701 build: add new TARNAME variable
That expands to `@PACKAGE_TARNAME@`, similar to the existing
PACKAGE_TARNAME variable.

To make it easier to use (and read) and to be more consistent with the
surrounding variables (NAME and VERSION).

Note that the original PACKAGE_TARNAME is still needed, as by default
(on autoconf v2.69) `docdir=@docdir@` in config.mk.in expands to the
following in config.mk:

    docdir=${datarootdir}/doc/${PACKAGE_TARNAME}
2022-08-14 02:17:39 -03:00
Kelvin M. Klann
9a45c34fc7 build: rename DOCDIR to docdir
To match other similar variables, such as datarootdir and mandir.
2022-08-13 23:38:53 -03:00
Kelvin M. Klann
3bb8064677 config.mk.in: move basic variables to the top
Move up the variables that are defined in the `AC_INIT` call on
configure.ac.

And put VERSION last, to match the usual `$(NAME)-$(VERSION)` usage.
2022-08-13 23:38:32 -03:00
Kelvin M. Klann
0d200264b1 config.mk.in: move CC variable near CFLAGS
Move it to the bottom, near other compilation-related flags.
2022-08-13 17:06:56 -03:00
Kelvin M. Klann
8fc604f5f0 build: add autoconf auto-generation comment to input files
To note on the output files that they are generated and to clarify how
they are generated.

From the manual of GNU Autoconf (version 2.69):

>  -- Variable: configure_input
>      A comment saying that the file was generated automatically by
>      'configure' and giving the name of the input file.  'AC_OUTPUT'
>      adds a comment line containing this variable to the top of every
>      makefile it creates.  For other files, you should reference this
>      variable in a comment at the top of each input file.  For
>      example, an input shell script should begin like this:
>
>           #!/bin/sh
>           # @configure_input@
>
>      The presence of that line also reminds people editing the file
>      that it needs to be processed by 'configure' in order to be used.

Resulting output on config.mk:

    # config.mk.  Generated from config.mk.in by configure.

Relates to #5140.
2022-07-16 01:07:40 -03:00
Kelvin M. Klann
4e8244fb81 makefiles: deduplicate configure-time vars into new config.mk.in
Currently, the configure-time variables (that is, the ones that assign
to placeholders, such as "@HAVE_MAN@", which are set/replaced at
configure-time) are defined on multiple files (such as on Makefile.in
and on common.mk.in).

To avoid duplication, centralize these variables on a single file
(config.mk.in) and replace all of the other definitions of them with an
include of config.mk.
2022-06-12 16:08:47 -03:00