1
0
mirror of https://github.com/PDP-10/its.git synced 2026-01-11 23:53:12 +00:00
PDP-10.its/build/dependencies.sh
Lars Brinkhoff 4dbbdba7d0 The dependencies.sh script is only for CI.
Removed the text about dependencies.sh because it's only to aid
continuous integration builds.  We don't want the maintenance burden
of keeping this up to date for everyone's operating system release.
2024-06-15 19:01:32 +02:00

60 lines
2.2 KiB
Bash

# This is script is mainly for installing dependencies for continuous
# integration builds. It's not meant to support many kinds of
# operating system or releases.
if test -n "$GITLAB_CI" -o -n "$CIRCLECI"; then
sudo() {
"$@"
}
fi
install_linux() {
sudo apt-get update -myq
sudo apt-get install -my expect
# For GitLab CI
sudo apt-get install -my git make gcc libncurses-dev autoconf
case "$EMULATOR" in
simh*) sudo apt-get install -y libegl1-mesa-dev libgles2-mesa-dev
sudo apt-get install -y libsdl2-dev;;
pdp10-k?) sudo apt-get install -y libegl1-mesa-dev libgles2-mesa-dev
sudo apt-get install -y libx11-dev libxt-dev libsdl2-dev
sudo apt-get install -y libsdl2-image-dev libpcap-dev
sudo apt-get install -y libssl-dev libsdl2-ttf-dev
sudo apt-get install -y libgtk-3-dev libsdl2-net-dev;;
klh10) sudo apt-get install -y libusb-1.0-0-dev;;
esac
}
install_freebsd() {
pkg upgrade -y
pkg install -y gmake git expect
case "$EMULATOR" in
pdp10-ka) pkg install -y sdl2 sdl2_image sdl2_net pkgconf gtk3;;
pdp10-kl) pkg install -y sdl2 pkgconf gtk3 autoconf;;
klh10) pkg install -y pkgconf autotools;;
esac
}
install_osx() {
if [ -x /opt/local/bin/port ]; then
echo "Using macports under sudo - your password may be required"
case "$EMULATOR" in
simh*) sudo port install vde2 automake libsdl2 libsdl2_image libsdl2_net pkgconfig;;
pdp10-*) sudo port install vde2 automake libsdl2 libsdl2_image libsdl2_net pkgconfig;;
klh10) sudo port install vde2 automake libsdl2 libsdl2_image libsdl2_net pkgconfig;;
esac
elif [ -x /opt/homebrew/bin/homebrew ]; then
brew update
case "$EMULATOR" in
simh*) brew install automake sdl2 sdl2_image sdl2_net pkg-config;;
pdp10-*) brew install automake sdl2 sdl2_image sdl2_net pkg-config;;
klh10) brew install automake sdl2 sdl2_image sdl2_net pkg-config;;
esac
else
echo "Either MacPorts or Homebrew must be installed to /opt first"
exit 1
fi
}
"$1"