From: Daniel Wagner Date: Wed, 29 Mar 2023 15:14:05 +0000 (+0200) Subject: doc: Do not hardcode default location for config files X-Git-Tag: v1.4~4 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=f712c279ef54874cedbc466f906fb1a45fc423a2;p=users%2Fsagi%2Flibnvme.git doc: Do not hardcode default location for config files The location of the config files is depending of the configuration. Because we ship pre-compiled documentation the SYSCONFDIR might not be correct. Avoid confusion and just point out they live under SYSCONFDIR. Signed-off-by: Daniel Wagner --- diff --git a/doc/meson.build b/doc/meson.build index 60a92ed4..edbc3be1 100644 --- a/doc/meson.build +++ b/doc/meson.build @@ -53,24 +53,17 @@ test('kdoc', kernel_doc_check, args: api_paths) if want_docs != 'false' - conf = configuration_data() - conf.set('SYSCONFDIR', sysconfdir) - if want_docs == 'all' or want_docs == 'man' mandir = join_paths(get_option('mandir'), 'man2') list_man_pages = find_program('list-man-pages.sh') if want_docs_build foreach apif : api_paths - subst = configure_file( - input: apif, - output: '@BASENAME@.subst', - configuration: conf) - c = run_command(list_man_pages, subst, check: true) + c = run_command(list_man_pages, apif, check: true) man_pages = c.stdout().split() foreach page : man_pages custom_target( page.underscorify() + '_man', - input: subst, + input: apif, output: page + '.2', capture: true, command: [kernel_doc, @@ -78,7 +71,7 @@ if want_docs != 'false' '-man', '-function', page, - subst], + apif], install: true, install_dir: mandir) endforeach diff --git a/src/nvme/fabrics.h b/src/nvme/fabrics.h index 9298f7b3..3664a858 100644 --- a/src/nvme/fabrics.h +++ b/src/nvme/fabrics.h @@ -257,7 +257,11 @@ char *nvmf_hostnqn_generate(); /** * nvmf_hostnqn_from_file() - Reads the host nvm qualified name from the config - * default location in @SYSCONFDIR@/nvme/ + * default location + * + * Retrieve the qualified name from the config file located in $SYSCONFIDR/nvme. + * $SYSCONFDIR is usually /etc. + * * Return: The host nqn, or NULL if unsuccessful. If found, the caller * is responsible to free the string. */ @@ -265,7 +269,11 @@ char *nvmf_hostnqn_from_file(); /** * nvmf_hostid_from_file() - Reads the host identifier from the config default - * location in @SYSCONFDIR@/nvme/. + * location + * + * Retrieve the host idenditifer from the config file located in $SYSCONFDIR/nvme/. + * $SYSCONFDIR is usually /etc. + * * Return: The host identifier, or NULL if unsuccessful. If found, the caller * is responsible to free the string. */