Files
deskflow/scripts/install_deps.sh
Nick Bolton 735fb0e8c4 Add --config-toml arg for TOML config file (#7489)
* Add CLI11 lib

* Use newer arg parser for to add --config-toml arg

* Fix bug where coco doesn't run in elevated console

* Improve macro names

* Fixed incorrect macro name

* Improve coverage for TOML config load

* Allow legacy args and use toml config arg in launch.json

* Update ChangeLog

* Fail coverage workflow on integ test fail

* Remove line break
2024-09-06 21:03:19 +01:00

77 lines
1.5 KiB
Bash
Executable File

#!/usr/bin/env sh
SUDO=$(which sudo > /dev/null 2>&1 && echo "sudo" || echo "")
install_deps() {
uname_out="$(uname -s)"
case "${uname_out}" in
FreeBSD*) install_freebsd ;;
OpenBSD*) install_openbsd ;;
NetBSD*) install_netbsd ;;
DragonFly*) install_dragonfly ;;
SunOS*) install_solaris ;;
*) install_other $@ ;;
esac
}
install_freebsd() {
run_cmd pkg install -y \
cmake \
ninja \
gmake \
gcc10 \
openssl \
glib \
gdk-pixbuf2 \
libX11 \
libXtst \
libnotify \
libxkbfile \
qt6-base \
qt6-tools \
gtk3 \
googletest \
pugixml
}
install_openbsd() {
# Patches welcome!
# pkg_add error:
# Can't find libX11
# Can't find libXtst
echo "Sorry, OpenBSD is not supported yet."
}
install_netbsd() {
# Patches welcome!
# pkg_add error:
# pkg_add: no pkg found for 'libX11', sorry.
# pkg_add: no pkg found for 'libXtst', sorry.
echo "Sorry, NetBSD is not supported yet."
}
install_dragonfly() {
# Patches welcome!
# The C++ version on DragonFly BSD seems to be too old.
echo "Sorry, DragonFly BSD is not supported yet."
}
install_solaris() {
# Patches welcome!
echo "Sorry, Solaris is not supported yet."
}
install_other() {
# TODO: Port the .py script to shell script to make the deps installation lighter on
# Linux and macOS. The .py script is probably only really needed to deal with Windows.
./scripts/install_deps.py $@
}
run_cmd() {
cmd="${SUDO:+$SUDO }$@"
echo "Running: $cmd"
$cmd
}
install_deps $@