Some implementations of ln (toybox, busybox) typically only support the
short option format, so use it consistently.
The short options are already used in other places and it's usually
supported on more implementations: -s and -f are POSIX and the few
ln that support --relative understand -r. Which are GNU coreutils,
the Rust uutils coreutils, toybox (-r only) and there is an old
patch for busybox (-r only). The BSDs and MacOS don't seem to
support --relative at all.
Signed-off-by: Hendrik Donner <hd@os-cillation.de>
Link: https://github.com/kmod-project/kmod/pull/303
Signed-off-by: Lucas De Marchi <lucas.de.marchi@gmail.com>
mkdir_p = 'mkdir -p "$DESTDIR@0@"'
meson.add_install_script('sh', '-c', mkdir_p.format(sbindir))
- ln_s = 'ln --symbolic --force --relative "$DESTDIR@0@/kmod" "$DESTDIR@1@"'
+ ln_s = 'ln -sfr "$DESTDIR@0@/kmod" "$DESTDIR@1@"'
foreach tool : _tools
meson.add_install_script('sh', '-c', ln_s.format(bindir, sbindir / tool))
endforeach