From: Tomas Krizek Date: Fri, 25 Jan 2019 13:22:36 +0000 (+0100) Subject: meson: move etc_dir to config X-Git-Tag: v4.0.0~24^2~237 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=c6773da5775f9e1e828f65e8bc8a7cafaebf8d58;p=thirdparty%2Fknot-resolver.git meson: move etc_dir to config --- diff --git a/daemon/lua/trust_anchors.lua.in b/daemon/lua/trust_anchors.lua.in index 6fe8d4775..324c65c76 100644 --- a/daemon/lua/trust_anchors.lua.in +++ b/daemon/lua/trust_anchors.lua.in @@ -622,7 +622,7 @@ trust_anchors = { keep_removed = 0, bootstrap_url = 'https://data.iana.org/root-anchors/root-anchors.xml', - bootstrap_ca = '@ETCDIR@/icann-ca.pem', + bootstrap_ca = '@etc_dir@/icann-ca.pem', -- change empty string to nil keyfile_default = ('@keyfile_default@' ~= '' and '@keyfile_default@') or nil, diff --git a/daemon/meson.build b/daemon/meson.build index cefd0bfbf..89d9e2c52 100644 --- a/daemon/meson.build +++ b/daemon/meson.build @@ -31,7 +31,7 @@ luajit_has_setfuncs = run_command( # daemon CFLAGS c_args = [ '-fPIE', # TODO pie=true since 0.49.0 - '-DROOTHINTS="@0@/root.hints"'.format(etc_dir), + '-DROOTHINTS="@0@/root.hints"'.format(config.get('etc_dir')), '-DLIBEXT="@0@"'.format(lib_suffix), '-Dlibzscanner_SONAME="@0@"'.format(libzscanner.get_pkgconfig_variable('soname')), '-Dlibknot_SONAME="@0@"'.format(libknot.get_pkgconfig_variable('soname')), diff --git a/doc/build.rst b/doc/build.rst index c7e6e0294..a4e49e54c 100644 --- a/doc/build.rst +++ b/doc/build.rst @@ -188,6 +188,8 @@ Default paths The default installation follows FHS with several custom paths for configuration and modules. All paths are prefixed with ``PREFIX`` variable by default if not specified otherwise. +TODO: rewrite/update entire section + .. csv-table:: :header: "Component", "Variable", "Default", "Notes" diff --git a/meson.build b/meson.build index 734d7c974..b13fb0ab0 100644 --- a/meson.build +++ b/meson.build @@ -15,10 +15,10 @@ else endif message('modules_dir: ' + modules_dir) -etc_dir = join_paths(get_option('prefix'), get_option('sysconfdir'), 'knot-resolver') - config = configuration_data() config.set('keyfile_default', get_option('keyfile_default')) +config.set('etc_dir', + join_paths(get_option('prefix'), get_option('sysconfdir'), 'knot-resolver')) # Project-wide dependencies @@ -188,4 +188,4 @@ install_data( # etc -install_data(sources: 'etc/root.hints', install_dir: etc_dir) +install_data(sources: 'etc/root.hints', install_dir: config.get('etc_dir'))