Build media and live-kit in test-mode on non-MacOS (#6859)
Build media and live-kit in test-mode on non-MacOS (Related to https://github.com/zed-industries/zed/issues/5391 https://github.com/zed-industries/zed/issues/5395 https://github.com/zed-industries/zed/issues/5394) This makes it possible to build the media and live-kit crates on non-MacOS Release Notes: - N/A
This commit is contained in:
parent
e69e6f5586
commit
2c834c24a3
8 changed files with 68 additions and 6 deletions
40
script/linux
Executable file
40
script/linux
Executable file
|
@ -0,0 +1,40 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
# if not on Linux, do nothing
|
||||
[[ $(uname) == "Linux" ]] || exit 0
|
||||
|
||||
# if sudo is not installed, define an empty alias
|
||||
maysudo=$(command -v sudo || true)
|
||||
export maysudo
|
||||
|
||||
# Ubuntu, Debian, etc.
|
||||
apt=$(command -v apt-get || true)
|
||||
deps=(
|
||||
libasound2-dev
|
||||
)
|
||||
if [[ -n $apt ]]; then
|
||||
$maysudo "$apt" install -y "${deps[@]}"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# Fedora, CentOS, RHEL, etc.
|
||||
dnf=$(command -v dnf || true)
|
||||
deps=(
|
||||
alsa-lib-devel
|
||||
)
|
||||
if [[ -n $dnf ]]; then
|
||||
$maysudo "$dnf" install -y "${deps[@]}"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# Arch, Manjaro, etc.
|
||||
pacman=$(command -v pacman || true)
|
||||
deps=(
|
||||
alsa-lib
|
||||
)
|
||||
if [[ -n $pacman ]]; then
|
||||
$maysudo "$pacman" -S --noconfirm "${deps[@]}"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
echo "Unsupported Linux distribution in script/linux"
|
Loading…
Add table
Add a link
Reference in a new issue