build: resolve deprecated 'copy' key argument in configure_file warning
Resolves the following warning:
NOTICE: Future-deprecated features used:
* 0.64.0: {'copy arg in configure_file'}
copy arg was deprecated in meson version 0.64. Hence, use
fs.copyfile() that is also introduced in 0.64, in versions
since 0.64 and use the old approach for older versions.
This commit is contained in:
committed by
Aleksander Morgado
parent
19b3e59151
commit
7c23c3db2f
+15
-6
@@ -11,12 +11,21 @@ service_conf = {
|
||||
}
|
||||
|
||||
# DBus Service file
|
||||
configure_file(
|
||||
input: 'org.freedesktop.ModemManager1.conf.@0@polkit'.format(enable_polkit ? '' : 'no'),
|
||||
output: '@BASENAME@',
|
||||
copy: true,
|
||||
install_dir: dbus_policy_dir,
|
||||
)
|
||||
if meson_version.version_compare('>=0.64')
|
||||
fs.copyfile(
|
||||
'org.freedesktop.ModemManager1.conf.@0@polkit'.format(enable_polkit ? '' : 'no'),
|
||||
'@BASENAME@',
|
||||
install: true,
|
||||
install_dir: dbus_policy_dir,
|
||||
)
|
||||
else
|
||||
configure_file(
|
||||
input: 'org.freedesktop.ModemManager1.conf.@0@polkit'.format(enable_polkit ? '' : 'no'),
|
||||
output: '@BASENAME@',
|
||||
copy: true,
|
||||
install_dir: dbus_policy_dir,
|
||||
)
|
||||
endif
|
||||
|
||||
# DBus Activation file
|
||||
configure_file(
|
||||
|
||||
Reference in New Issue
Block a user