mirror of
https://github.com/systemd/systemd.git
synced 2025-01-21 16:03:42 +08:00
meson: revert the change to unquote commands in add_install_script
Old meson fails with: Element not a string: [<Holder: <ExternalProgram 'sh' -> ['/bin/sh']>>, '-c', 'test -n "$DESTDIR" || /bin/journalctl --update-catalog'] I'm doing it as a revert so that it's easy to undo the revert when we require newer meson. The effect is not so bad, maybe a dozen or so lines about finding 'sh'.
This commit is contained in:
parent
f86887af6e
commit
7c22f07cbd
@ -29,5 +29,5 @@ foreach file : in_files
|
||||
install_dir : catalogdir)
|
||||
endforeach
|
||||
|
||||
meson.add_install_script(sh, '-c',
|
||||
meson.add_install_script('sh', '-c',
|
||||
'test -n "$DESTDIR" || @0@/journalctl --update-catalog'.format(rootbindir))
|
||||
|
@ -47,9 +47,10 @@ if conf.get('ENABLE_HWDB') == 1
|
||||
install_dir : udevhwdbdir)
|
||||
|
||||
if install_sysconfdir
|
||||
meson.add_install_script(sh, '-c', mkdir_p.format(join_paths(sysconfdir, 'udev/hwdb.d')))
|
||||
meson.add_install_script('sh', '-c',
|
||||
mkdir_p.format(join_paths(sysconfdir, 'udev/hwdb.d')))
|
||||
|
||||
meson.add_install_script(sh, '-c',
|
||||
meson.add_install_script('sh', '-c',
|
||||
'test -n "$DESTDIR" || @0@/systemd-hwdb update'.format(rootbindir))
|
||||
endif
|
||||
|
||||
|
20
meson.build
20
meson.build
@ -612,7 +612,7 @@ git = find_program('git', required : false)
|
||||
env = find_program('env')
|
||||
perl = find_program('perl', required : false)
|
||||
rsync = find_program('rsync', required : false)
|
||||
meson_make_symlink = find_program('tools/meson-make-symlink.sh')
|
||||
meson_make_symlink = project_source_root + '/tools/meson-make-symlink.sh'
|
||||
test_efi_create_disk_sh = find_program('test/test-efi-create-disk.sh')
|
||||
|
||||
mkdir_p = 'mkdir -p $DESTDIR/@0@'
|
||||
@ -1870,7 +1870,7 @@ foreach tuple : [['myhostname', 'ENABLE_NSS_MYHOSTNAME'],
|
||||
|
||||
# We cannot use shared_module because it does not support version suffix.
|
||||
# Unfortunately shared_library insists on creating the symlink…
|
||||
meson.add_install_script(sh, '-c',
|
||||
meson.add_install_script('sh', '-c',
|
||||
'rm $DESTDIR@0@/libnss_@1@.so'
|
||||
.format(rootlibdir, module))
|
||||
|
||||
@ -2806,9 +2806,11 @@ if conf.get('ENABLE_BINFMT') == 1
|
||||
install : true,
|
||||
install_dir : rootlibexecdir)
|
||||
|
||||
meson.add_install_script(sh, '-c', mkdir_p.format(binfmtdir))
|
||||
meson.add_install_script('sh', '-c',
|
||||
mkdir_p.format(binfmtdir))
|
||||
if install_sysconfdir
|
||||
meson.add_install_script(sh, '-c', mkdir_p.format(join_paths(sysconfdir, 'binfmt.d')))
|
||||
meson.add_install_script('sh', '-c',
|
||||
mkdir_p.format(join_paths(sysconfdir, 'binfmt.d')))
|
||||
endif
|
||||
endif
|
||||
|
||||
@ -3272,9 +3274,11 @@ if conf.get('HAVE_KMOD') == 1
|
||||
install : true,
|
||||
install_dir : rootlibexecdir)
|
||||
|
||||
meson.add_install_script(sh, '-c', mkdir_p.format(modulesloaddir))
|
||||
meson.add_install_script('sh', '-c',
|
||||
mkdir_p.format(modulesloaddir))
|
||||
if install_sysconfdir
|
||||
meson.add_install_script(sh, '-c', mkdir_p.format(join_paths(sysconfdir, 'modules-load.d')))
|
||||
meson.add_install_script('sh', '-c',
|
||||
mkdir_p.format(join_paths(sysconfdir, 'modules-load.d')))
|
||||
endif
|
||||
endif
|
||||
|
||||
@ -3547,8 +3551,8 @@ install_data('LICENSE.GPL2',
|
||||
'docs/GVARIANT-SERIALIZATION.md',
|
||||
install_dir : docdir)
|
||||
|
||||
meson.add_install_script(sh, '-c', mkdir_p.format(systemdstatedir))
|
||||
meson.add_install_script(sh, '-c', 'touch $DESTDIR@0@'.format(prefixdir))
|
||||
meson.add_install_script('sh', '-c', mkdir_p.format(systemdstatedir))
|
||||
meson.add_install_script('sh', '-c', 'touch $DESTDIR@0@'.format(prefixdir))
|
||||
|
||||
############################################################
|
||||
|
||||
|
@ -11,7 +11,7 @@ if conf.get('ENABLE_NETWORKD') == 1
|
||||
install_dir : networkdir)
|
||||
|
||||
if install_sysconfdir
|
||||
meson.add_install_script(sh, '-c',
|
||||
meson.add_install_script('sh', '-c',
|
||||
mkdir_p.format(join_paths(sysconfdir, 'systemd/network')))
|
||||
endif
|
||||
endif
|
||||
|
@ -203,15 +203,15 @@ policy = configure_file(
|
||||
install_data(policy,
|
||||
install_dir : polkitpolicydir)
|
||||
|
||||
meson.add_install_script(sh, '-c', mkdir_p.format(systemshutdowndir))
|
||||
meson.add_install_script(sh, '-c', mkdir_p.format(systemsleepdir))
|
||||
meson.add_install_script(sh, '-c', mkdir_p.format(systemgeneratordir))
|
||||
meson.add_install_script(sh, '-c', mkdir_p.format(usergeneratordir))
|
||||
meson.add_install_script('sh', '-c', mkdir_p.format(systemshutdowndir))
|
||||
meson.add_install_script('sh', '-c', mkdir_p.format(systemsleepdir))
|
||||
meson.add_install_script('sh', '-c', mkdir_p.format(systemgeneratordir))
|
||||
meson.add_install_script('sh', '-c', mkdir_p.format(usergeneratordir))
|
||||
|
||||
if install_sysconfdir
|
||||
meson.add_install_script(sh, '-c', mkdir_p.format(join_paths(pkgsysconfdir, 'system')))
|
||||
meson.add_install_script(sh, '-c', mkdir_p.format(join_paths(pkgsysconfdir, 'user')))
|
||||
meson.add_install_script(sh, '-c', mkdir_p.format(join_paths(sysconfdir, 'xdg/systemd')))
|
||||
meson.add_install_script('sh', '-c', mkdir_p.format(join_paths(pkgsysconfdir, 'system')))
|
||||
meson.add_install_script('sh', '-c', mkdir_p.format(join_paths(pkgsysconfdir, 'user')))
|
||||
meson.add_install_script('sh', '-c', mkdir_p.format(join_paths(sysconfdir, 'xdg/systemd')))
|
||||
endif
|
||||
|
||||
############################################################
|
||||
|
@ -67,9 +67,9 @@ if conf.get('ENABLE_REMOTE') == 1 and conf.get('HAVE_MICROHTTPD') == 1
|
||||
install_dir : join_paths(pkgdatadir, 'gatewayd'))
|
||||
|
||||
if get_option('create-log-dirs')
|
||||
meson.add_install_script(sh, '-c',
|
||||
meson.add_install_script('sh', '-c',
|
||||
mkdir_p.format('/var/log/journal/remote'))
|
||||
meson.add_install_script(sh, '-c',
|
||||
meson.add_install_script('sh', '-c',
|
||||
'''chown 0:0 $DESTDIR/var/log/journal/remote &&
|
||||
chmod 755 $DESTDIR/var/log/journal/remote || :''')
|
||||
endif
|
||||
|
@ -56,17 +56,22 @@ if install_sysconfdir_samples
|
||||
endif
|
||||
|
||||
if get_option('create-log-dirs')
|
||||
meson.add_install_script(sh, '-c', mkdir_p.format('/var/log/journal'))
|
||||
meson.add_install_script(sh, '-c',
|
||||
'''chown 0:0 $DESTDIR/var/log/journal &&
|
||||
chmod 755 $DESTDIR/var/log/journal || :''')
|
||||
meson.add_install_script(
|
||||
'sh', '-c',
|
||||
mkdir_p.format('/var/log/journal'))
|
||||
meson.add_install_script(
|
||||
'sh', '-c',
|
||||
'''chown 0:0 $DESTDIR/var/log/journal &&
|
||||
chmod 755 $DESTDIR/var/log/journal || :''')
|
||||
if get_option('adm-group')
|
||||
meson.add_install_script(sh, '-c',
|
||||
'setfacl -nm g:adm:rx,d:g:adm:rx $DESTDIR/var/log/journal || :')
|
||||
meson.add_install_script(
|
||||
'sh', '-c',
|
||||
'setfacl -nm g:adm:rx,d:g:adm:rx $DESTDIR/var/log/journal || :')
|
||||
endif
|
||||
if get_option('wheel-group')
|
||||
meson.add_install_script(sh, '-c',
|
||||
'setfacl -nm g:wheel:rx,d:g:wheel:rx $DESTDIR/var/log/journal || :')
|
||||
meson.add_install_script(
|
||||
'sh', '-c',
|
||||
'setfacl -nm g:wheel:rx,d:g:wheel:rx $DESTDIR/var/log/journal || :')
|
||||
endif
|
||||
endif
|
||||
|
||||
|
@ -14,7 +14,7 @@ if want_kernel_install
|
||||
install_dir : kernelinstalldir)
|
||||
|
||||
if install_sysconfdir
|
||||
meson.add_install_script(sh, '-c',
|
||||
meson.add_install_script('sh', '-c',
|
||||
mkdir_p.format(join_paths(sysconfdir, 'kernel/install.d')))
|
||||
endif
|
||||
|
||||
|
@ -165,7 +165,8 @@ configure_file(
|
||||
install_dir : pkgconfigdatadir == 'no' ? '' : pkgconfigdatadir)
|
||||
|
||||
if install_sysconfdir
|
||||
meson.add_install_script(sh, '-c', mkdir_p.format(join_paths(sysconfdir, 'udev/rules.d')))
|
||||
meson.add_install_script('sh', '-c',
|
||||
mkdir_p.format(join_paths(sysconfdir, 'udev/rules.d')))
|
||||
endif
|
||||
|
||||
fuzzers += [
|
||||
|
@ -28,5 +28,6 @@ foreach file : in_files
|
||||
endforeach
|
||||
|
||||
if install_sysconfdir
|
||||
meson.add_install_script(sh, '-c', mkdir_p.format(join_paths(sysconfdir, 'sysctl.d')))
|
||||
meson.add_install_script('sh', '-c',
|
||||
mkdir_p.format(join_paths(sysconfdir, 'sysctl.d')))
|
||||
endif
|
||||
|
@ -57,5 +57,7 @@ foreach file : m4_files
|
||||
endforeach
|
||||
|
||||
if enable_tmpfiles and install_sysconfdir
|
||||
meson.add_install_script(sh, '-c', mkdir_p.format(join_paths(sysconfdir, 'tmpfiles.d')))
|
||||
meson.add_install_script(
|
||||
'sh', '-c',
|
||||
mkdir_p.format(join_paths(sysconfdir, 'tmpfiles.d')))
|
||||
endif
|
||||
|
@ -348,7 +348,7 @@ meson.add_install_script(meson_make_symlink,
|
||||
if conf.get('HAVE_SYSV_COMPAT') == 1
|
||||
foreach i : [1, 2, 3, 4, 5]
|
||||
meson.add_install_script(
|
||||
sh, '-c',
|
||||
'sh', '-c',
|
||||
mkdir_p.format(join_paths(systemunitdir, 'runlevel@0@.target.wants'.format(i))))
|
||||
endforeach
|
||||
endif
|
||||
|
Loading…
Reference in New Issue
Block a user