mirror of
https://github.com/systemd/systemd.git
synced 2024-12-25 01:34:28 +03:00
63554ed907
The ninja binary is deployed as `ninja-build` in older distros such as RHEL 7/CentOS 7. Detect that and use `ninja-build` instead of `ninja` when it's available.
19 lines
316 B
Bash
Executable File
19 lines
316 B
Bash
Executable File
#!/bin/sh
|
|
set -eux
|
|
|
|
src="$1"
|
|
dst="$2"
|
|
target="$3"
|
|
options="$4"
|
|
|
|
[ -d "$dst" ] || meson "$src" "$dst" $options
|
|
|
|
# Locate ninja binary, on CentOS 7 it is called ninja-build, so
|
|
# use that name if available.
|
|
ninja=ninja
|
|
if which ninja-build >/dev/null 2>&1 ; then
|
|
ninja=ninja-build
|
|
fi
|
|
|
|
"$ninja" -C "$dst" "$target"
|