summaryrefslogtreecommitdiffstats
path: root/man/meson.build (follow)
Commit message (Collapse)AuthorAgeFilesLines
* meson: rename conflicting target namesYu Watanabe2023-03-031-2/+2
| | | | | | | | | | | | | | | The update-man-rules and update-dbus-docs targets are both declared in the main meson.build and man/meson.build, so we cannot build the target with 'meson compile' command: ==== $ meson compile update-man-rules INFO: autodetecting backend as ninja ERROR: Can't invoke target `update-man-rules`: ambiguous name.Add target type and/or path: - ./man/update-man-rules:custom - ./update-man-rules:run ==== Let's rename the targets declared in man/meson.build.
* meson: Use meson test suite featureJan Janssen2022-05-041-0/+1
| | | | | | This makes it easier to only test a subset of tests without having to specify them all on the command line: meson test -C build --suite headers
* meson: also allow setting GIT_VERSION via templatesZbigniew Jędrzejewski-Szmek2022-04-051-1/+1
| | | | | | | | | GIT_VERSION is not available as a config.h variable, because it's rendered into version.h during builds. Let's rework jinja2 rendering to also parse version.h. No functional change, the new variable is so far unused. I guess this will make partial rebuilds a bit slower, but it's useful to be able to use the full version string.
* meson: replace sh+find with an internal glob in the python helperZbigniew Jędrzejewski-Szmek2022-03-231-4/+3
| | | | | | | | As suggested in https://github.com/systemd/systemd/pull/22810#discussion_r831708052 This makes the whole thing simpler. A glob is passed to helper which then resolves it on its own. This way it's trivial to call the helper with a different set of files for testing.
* meson: Add missing test dependenciesDaan De Meyer2022-01-211-1/+2
| | | | | | Currently, running "meson build" followed by "meson test -C build" will result in many failed tests due to missing dependencies. This commit adds the missing dependencies to make sure no tests fail.
* meson: Add check argument to remaining run_command() callsJan Janssen2022-01-111-1/+1
|
* build: preserve correct mode when generating files via jinja2Christian Brauner2021-11-081-2/+1
| | | | | | | | | When using "capture : true" in custom_target()s the mode of the source file is not preserved when the generated file is not installed and so needs to be tweaked manually. Switch from output capture to creating the target file and copy the permissions from the input file. Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
* meson: fix creation of man pages indicesZbigniew Jędrzejewski-Szmek2021-09-211-0/+1
| | | | Fixes #20795. Bug introduced in f12c5d36a9a162f833987b03fbf0b65248581cbb.
* meson: use alias_target for doc update commandsZbigniew Jędrzejewski-Szmek2021-07-271-37/+61
| | | | | | | | | | | This undoes part of 4c890ad3cc7b3445683d7b52bc00e4a58bef5e94: the implementations of update-dbus-docs and update-man-rules are moved back to man/meson.build, and alias_target() is used to keep the visible target names unchanged. The rules for man pages are reworked so that it's possible to invoke the targets even if xstlproc is not available. After all, xsltproc is only needed for the final formatted output, and not other processing.
* meson: use a/b instead of join_paths(a,b)Zbigniew Jędrzejewski-Szmek2021-07-271-6/+6
| | | | It is nicer and shorter.
* man: prevent race condition when generating systemd.directives.xmlasavah2021-05-201-0/+1
|
* meson: use jinja2 also for custom-entities.entZbigniew Jędrzejewski-Szmek2021-05-191-7/+7
| | | | | | | | | | | | | | | | | | | | This doesn't matter too much, but makes things a bit more consistent. A minor advantage is that the file is not a configuration file for meson anymore, so: a) It is not built unless pulled in by another target. Since we don't usually build man pages by default, this saves a tiny amount of work. b) When the .in file is updated, meson does not reconfigure everything, but just rebuilds the dependent targets. Now that the conversion is finished, time for benchmarking: a full build with default settings (and -Dstandalonebinaries=true), yields before this pull request: 1687 targets, 148.13s user 35.17s system 317% cpu 57.697 total with the full pull request: 1714 targets, 143.07s user 27.87s system 314% cpu 54.369 total The difference doesn't seem significant. Partial rebuilds might be faster as mentioned before.
* meson: use custom configuration_data() object for man/man and man/html helpersZbigniew Jędrzejewski-Szmek2021-05-191-2/+5
| | | | | | | | | | I want to stop using 'substs'. But in this case, configure_file() is nicer than custom_target(), because it causes meson to immediately generate the helpers after configuration, so it's possible to do 'meson build && build/man/man ...', without building anything first. We only substitute one variable here, so let's use a custom configuration_data() object.
* meson: call find_program() once and reuse the variable everywhereZbigniew Jędrzejewski-Szmek2021-05-141-5/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Meson 0.58 has gotten quite bad with emitting a message every time a quoted command is used: Program /home/zbyszek/src/systemd-work/tools/meson-make-symlink.sh found: YES (/home/zbyszek/src/systemd-work/tools/meson-make-symlink.sh) Program sh found: YES (/usr/bin/sh) Program sh found: YES (/usr/bin/sh) Program sh found: YES (/usr/bin/sh) Program sh found: YES (/usr/bin/sh) Program sh found: YES (/usr/bin/sh) Program sh found: YES (/usr/bin/sh) Program xsltproc found: YES (/usr/bin/xsltproc) Configuring custom-entities.ent using configuration Message: Skipping bootctl.1 because ENABLE_EFI is false Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Message: Skipping journal-remote.conf.5 because HAVE_MICROHTTPD is false Message: Skipping journal-upload.conf.5 because HAVE_MICROHTTPD is false Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Message: Skipping loader.conf.5 because ENABLE_EFI is false Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) Program ln found: YES (/usr/bin/ln) ... Let's suffer one message only for each command. Hopefully we can silence even this when https://github.com/mesonbuild/meson/issues/8642 is resolved.
* meson: do not fail if rsync is not installed with meson 0.57.2Zbigniew Jędrzejewski-Szmek2021-04-121-11/+14
| | | | | | | https://github.com/mesonbuild/meson/issues/8641 Our CI started to fail. Even if the change is reverted in meson, we need a quick workaround here.
* meson: rename target to update-man-rulesZbigniew Jędrzejewski-Szmek2021-01-271-11/+0
| | | | Same justification as for update-dbus-docs.
* meson: rename target to update-dbus-docsZbigniew Jędrzejewski-Szmek2021-01-271-19/+0
| | | | | | | | | Very old versions of meson did not include the subdirectory name in the target name, so we started adding various "top-level" custom targets in subdirectories. This was nice because the main meson.build file wasn't as cluttered. But then meson started including the subdir name in the target name. So let's move the definition to the root so we can have all targets named uniformly.
* meson: Fix update-man-rules when the build dir is not a subdir of the ↵Daan De Meyer2021-01-241-10/+8
| | | | | | | | | | | | | project dir Until now, update-man-rules assumed that the build directory was a subdirectory of the project directory. When using mkosi, this is not the case. We use find instead of git ls-files because git ls-files does not seem to support outputting absolute paths. Also, this makes update-man-rules a bit more user-friendly as new manpages don't have to be added to the git staging area before they are processed by update-man-rules.py.
* license: LGPL-2.1+ -> LGPL-2.1-or-laterYu Watanabe2020-11-091-1/+1
|
* meson: convert developer_mode boolean to an enumZbigniew Jędrzejewski-Szmek2020-10-221-1/+1
| | | | | I initially changed this to add a third state. But even with two values having an explicit name instead of just 0/1 is mode descriptive.
* test: verify that dbus docs are freshZbigniew Jędrzejewski-Szmek2020-08-271-2/+8
| | | | | | | | | This makes use of the developer mode switch: the test is only done if the user opted-in into developer mode. Before the man/update-dbus-docs was using the argument form where we don't need to run find_command(), but that doesn't work with test(),, so find_command() is used and we get one more line in the config log.
* tools: move directive index template to separate fileZbigniew Jędrzejewski-Szmek2020-05-071-2/+2
| | | | | | | In the beginning, it was rather short, and reasonable to include inline. Now it is long and unwieldy, let's split it out. While at it, let's reindent and wrap using our current standards.
* meson: rename make-man-rules.py to update-man-rules.pyZbigniew Jędrzejewski-Szmek2020-05-071-1/+1
| | | | | | | The name of the helper didn't match the name of the meson target, which was always confusing me. With this change, we consistenly use "update" to re-generate things which we otherwise keep in vc, and "make" for things which are generated during each build.
* meson: add man/update-dbus-docs targetZbigniew Jędrzejewski-Szmek2020-05-051-1/+19
|
* meson: remove strange dep that causes meson to enter infinite loopZbigniew Jędrzejewski-Szmek2019-11-061-1/+0
| | | | | | | | | | | | | The value is obviously bogus, but didn't seem to cause problems so far. With meson-0.52.0, it causes a hang. The number of aliases is always rather small (usually just one or two, possibly up to a dozen in a few cases), so even if this causes some looping, it is strange that it has such a huge impact. But let's just remove it. Fixes #13742. Tested with meson-0.52.0-1.module_f31+6771+f5d842eb.noarch, meson-0.51.1-1.fc29.noarch.
* meson: add build/man/man and build/man/html to build and display pagesZbigniew Jędrzejewski-Szmek2019-05-091-0/+12
| | | | | | | | | | | Man page generation is generally very slow. I prefer to use -Dman=false when developing systemd, and only build specific pages when introducing changes. Those two little helper tools make it easy: $ build/man/man systemd.link $ build/man/html systemd.link will show systemd.link.8 and systemd.link.html from the build directory build/.
* meson: scope more git invocations with current_source_dir()Davide Cavalca2019-03-121-1/+1
|
* meson: remove workaround for old meson bug with command quotingZbigniew Jędrzejewski-Szmek2019-02-281-4/+1
| | | | | Those bugs were fixed a long time ago. Let's take advantage of this and use the usual $() syntax.
* meson: update bug referenceZbigniew Jędrzejewski-Szmek2018-10-111-1/+2
| | | | | | https://github.com/mesonbuild/meson/issues/1644 was resolved in 0.42: https://github.com/mesonbuild/meson/pull/2191/commits/be4428005dff8b17af5696c8f05567de9af1a8c5, but still no-go.
* meson: drop parens when appending to listZbigniew Jędrzejewski-Szmek2018-07-311-10/+10
| | | | | | Meson does not care either way, so let's use the simpler syntax. And files() already gives a list, so nesting this in a list wouldn't be necessary even if meson did not flatten everything.
* meson: allow systemd.directives and .index to be built if -Dman=falseZbigniew Jędrzejewski-Szmek2018-07-161-2/+2
| | | | See 559d215b6733bb46533a52080522a7feca183aa8 for justification.
* Drop my copyright headersZbigniew Jędrzejewski-Szmek2018-06-141-2/+0
| | | | | | | perl -i -0pe 's/\s*Copyright © .... Zbigniew Jędrzejewski.*?\n/\n/gms' man/*xml git grep -e 'Copyright.*Jędrzejewski' -l | xargs perl -i -0pe 's/(#\n)?# +Copyright © [0-9, -]+ Zbigniew Jędrzejewski.*?\n//gms' git grep -e 'Copyright.*Jędrzejewski' -l | xargs perl -i -0pe 's/\s*\/\*\*\*\s+Copyright © [0-9, -]+ Zbigniew Jędrzejewski[^\n]*?\s*\*\*\*\/\s*/\n\n/gms' git grep -e 'Copyright.*Jędrzejewski' -l | xargs perl -i -0pe 's/\s+Copyright © [0-9, -]+ Zbigniew Jędrzejewski[^\n]*//gms'
* tree-wide: beautify remaining copyright statementsLennart Poettering2018-06-141-1/+1
| | | | | | Let's unify an beautify our remaining copyright statements, with a unicode ©. This means our copyright statements are now always formatted the same way. Yay.
* tree-wide: drop license boilerplateZbigniew Jędrzejewski-Szmek2018-04-061-13/+0
| | | | | | | | | | Files which are installed as-is (any .service and other unit files, .conf files, .policy files, etc), are left as is. My assumption is that SPDX identifiers are not yet that well known, so it's better to retain the extended header to avoid any doubt. I also kept any copyright lines. We can probably remove them, but it'd nice to obtain explicit acks from all involved authors before doing that.
* meson: restore building of man pages on demand even if -Dman=falseZbigniew Jędrzejewski-Szmek2017-11-241-1/+1
| | | | | | | I want to configure -Dman=false for speed, but be able to build a specific man page sometimes to check my edits. Commit 5b316b9ea6c broke this by mistake. Let's adjust the condition to better match the logic of disabling tests only if xsltproc is really not found.
* Add license headers and SPDX identifiers to meson.build filesZbigniew Jędrzejewski-Szmek2017-11-191-0/+17
| | | | | | | So far I avoided adding license headers to meson files, but they are pretty big and important and should carry license headers like everything else. I added my own copyright, even though other people modified those files too. But this is mostly symbolic, so I hope that's OK.
* meson: do not include man/meson.build if xsltproc not foundYu Watanabe2017-10-311-3/+3
| | | | Fixes #7232.
* build-sys: use #if Y instead of #ifdef Y everywhereZbigniew Jędrzejewski-Szmek2017-10-041-1/+1
| | | | | | | | | | | | | | | The advantage is that is the name is mispellt, cpp will warn us. $ git grep -Ee "conf.set\('(HAVE|ENABLE)_" -l|xargs sed -r -i "s/conf.set\('(HAVE|ENABLE)_/conf.set10('\1_/" $ git grep -Ee '#ifn?def (HAVE|ENABLE)' -l|xargs sed -r -i 's/#ifdef (HAVE|ENABLE)/#if \1/; s/#ifndef (HAVE|ENABLE)/#if ! \1/;' $ git grep -Ee 'if.*defined\(HAVE' -l|xargs sed -i -r 's/defined\((HAVE_[A-Z0-9_]*)\)/\1/g' $ git grep -Ee 'if.*defined\(ENABLE' -l|xargs sed -i -r 's/defined\((ENABLE_[A-Z0-9_]*)\)/\1/g' + manual changes to meson.build squash! build-sys: use #if Y instead of #ifdef Y everywhere v2: - fix incorrect setting of HAVE_LIBIDN2
* build-sys: bump xslt maxdepth limit (#6863)Zbigniew Jędrzejewski-Szmek2017-09-191-0/+1
| | | | With libxslt-1.30, builds were failing on some recursion depth limit with systemd.index.xml. Bumping the limit fixes the issue.
* build-sys: fix invalid args detected by meson 0.42 (#6561)userwithuid2017-08-091-3/+4
| | | | | | | | | | | | some run_target() calls were using params from custom_target() example message: WARNING: Passed invalid keyword argument "input". This will become a hard error in the future. New way to call targets: ninja man/man ninja man/html ninja man/update-man-rules
* build-sys: drop support for generation of Makefile-man.amZbigniew Jędrzejewski-Szmek2017-07-181-1/+1
|
* Merge pull request #5842 from keszybz/meson-status-and-conditionalsMichael Biebl2017-05-031-1/+1
|\ | | | | Meson status and conditional simplification
| * meson: use booleans for conf.set and drop unecessary conditionalsZbigniew Jędrzejewski-Szmek2017-05-021-1/+1
| | | | | | | | | | | | | | | | | | Using conf.set() with a boolean argument does the right thing: either #ifdef or #undef. This means that conf.set can be used unconditionally. Previously I used '1' as the placeholder value, and that needs to be changed to 'true' for consistency (under meson 1 cannot be used in boolean context). All checks need to be adjusted.
* | meson: make sure html symlinks are also created in build directoryZbigniew Jędrzejewski-Szmek2017-05-011-23/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The symlinks should be created in the build directory in two cases: when configuration specifies -Dhtml=true, or when ninja html target is built. Normally install : {true,false} is used to decide if a target should be built, but in this case, we cannot use install : true, because, as described in 488477d101, that results in the target file being copied into the installation directory instead of a symlink. So we need a work-around. To achieve the first end, the commands to create the symlinks are added as dependencies of the command to create the html page. To the second end, they are added as dependencies of the html target. Follow-up for 488477d101 and 064d9ef0d7.
* | meson: create index.html symlink pointing at systemd.index.html (#5870)Michael Biebl2017-05-011-0/+15
| | | | | | | | | | | | Re-use bits from 488477d1011559078dbebfea18e22dcc1c9ca7ea to create the index.html symlink. Fixes #5862
* | meson: fix creation of html symlinksZbigniew Jędrzejewski-Szmek2017-05-011-1/+15
|/ | | | | | | | | | | | This adds two somewhat independent rules: 1. to create symlinks to html pages in the build directory 2. to create symlinks in the installation directory The second part needs to be coded separately, because telling meson to install the symlinks created in step 1. results in a copy of the target, instead of a symlink. So step 2. needs to ignore the result of 1. and create the symlink again. Fixes #5863.
* meson: fix 'clean'Zbigniew Jędrzejewski-Szmek2017-04-241-1/+3
|
* meson: add rule to regenerate man/rules/meson.buildZbigniew Jędrzejewski-Szmek2017-04-241-3/+15
|
* meson: use run_target instead of custom_target where appropriateZbigniew Jędrzejewski-Szmek2017-04-241-21/+22
| | | | This way a fake output does not need to be specified.
* meson: reindent all files with 8 spacesZbigniew Jędrzejewski-Szmek2017-04-241-94/+91
| | | | | | | The indentation for emacs'es meson-mode is added .dir-locals. All files are reindented automatically, using the lasest meson-mode from git. Indentation should now be fairly consistent.