mirror of
https://github.com/systemd/systemd.git
synced 2024-12-22 17:35:35 +03:00
meson: resurrect API documentation target
We had this functionality back in Automake times, let's resurrect it.
This commit is contained in:
parent
66baf8c644
commit
51b13863a2
@ -2556,6 +2556,14 @@ endif
|
||||
|
||||
############################################################
|
||||
|
||||
meson_check_api_docs_sh = find_program('tools/meson-check-api-docs.sh')
|
||||
run_target(
|
||||
'check-api-docs',
|
||||
depends : [man, libsystemd, libudev],
|
||||
command : [meson_check_api_docs_sh, libsystemd.full_path(), libudev.full_path()])
|
||||
|
||||
############################################################
|
||||
|
||||
status = [
|
||||
'@0@ @1@'.format(meson.project_name(), meson.project_version()),
|
||||
|
||||
|
11
tools/meson-check-api-docs.sh
Normal file
11
tools/meson-check-api-docs.sh
Normal file
@ -0,0 +1,11 @@
|
||||
#!/bin/sh
|
||||
|
||||
set -eu
|
||||
|
||||
for symbol in `nm -g --defined-only "$@" | grep " T " | cut -d" " -f3 | sort -u` ; do
|
||||
if test -f ${MESON_BUILD_ROOT}/man/$symbol.3 ; then
|
||||
echo "✓ Symbol $symbol() is documented."
|
||||
else
|
||||
printf " \x1b[1;31mSymbol $symbol() lacks documentation.\x1b[0m\n"
|
||||
fi
|
||||
done
|
Loading…
Reference in New Issue
Block a user