use fs.copyfile instead of deprecated copy
copy arg in configure_file API is deprecated since meson
version 0.64.0. As we moved to meson version 1.1.1 we can
leverage the filesystem module copyfile() to achive the
same result.
Tested:
1. With this change made sure that ninja install copied
the service file into the systemd unit directory on fedora.
```
[manojeda@fedora build]$ ninja install
[0/1] Installing files.
Installation failed due to insufficient permissions.
Attempt to use /usr/bin/sudo to gain elevated privileges? [y/n] y
[sudo] password for manojeda:
Installing xyz.openbmc_project.Time.Manager.service to /usr/lib/systemd/system
Installing phosphor-time-manager to /usr/local/bin
[manojeda@fedora build]$ cat /usr/lib/systemd/system/xyz.openbmc_project.Time.Manager.service
[Unit]
Description=Phosphor Time Manager daemon
Wants=mapper-wait@-xyz-openbmc_project-time-sync_method.service
After=mapper-wait@-xyz-openbmc_project-time-sync_method.service
[Service]
Restart=always
ExecStart=/usr/bin/phosphor-time-manager
Type=dbus
BusName=xyz.openbmc_project.Time.Manager
[Install]
WantedBy=multi-user.target
```
Change-Id: Ie95cd19e2f025ff6b564293fdb1b62a8898a8a40
Signed-off-by: Manojkiran Eda <manojkiran.eda@gmail.com>
diff --git a/meson.build b/meson.build
index 74fc139..b7fcebc 100644
--- a/meson.build
+++ b/meson.build
@@ -69,10 +69,11 @@
systemd_system_unit_dir = systemd.get_variable(
'systemdsystemunitdir',
pkgconfig_define: ['prefix', get_option('prefix')])
-configure_file(input : 'xyz.openbmc_project.Time.Manager.service',
- output : 'xyz.openbmc_project.Time.Manager.service',
- copy : true,
- install_dir : systemd_system_unit_dir)
+
+filesystem = import('fs')
+filesystem.copyfile('xyz.openbmc_project.Time.Manager.service',
+ install: true,
+ install_dir: systemd_system_unit_dir)
#############################################################################