scripts: add a one command development environment setup
build / client (Debug, map[cc:gcc cxx:g++], libdecor) (push) Failing after 20s
build / client (Debug, map[cc:clang cxx:clang++], libdecor) (push) Failing after 21s
build / client (Debug, map[cc:clang cxx:clang++], xdg-shell) (push) Failing after 21s
build / client (Release, map[cc:clang cxx:clang++], libdecor) (push) Failing after 20s
build / client (Debug, map[cc:gcc cxx:g++], xdg-shell) (push) Failing after 20s
build / client (Release, map[cc:clang cxx:clang++], xdg-shell) (push) Failing after 21s
build / module (push) Failing after 18s
build / client (Release, map[cc:gcc cxx:g++], libdecor) (push) Failing after 22s
build / client (Release, map[cc:gcc cxx:g++], xdg-shell) (push) Failing after 22s
build / host-linux (push) Failing after 21s
build / host-windows-cross (push) Failing after 21s
build / obs (clang) (push) Failing after 21s
build / docs (push) Failing after 4s
build / obs (gcc) (push) Failing after 22s
build / host-windows-native (push) Canceled after 0s
build / idd (push) Canceled after 0s
build / client (Debug, map[cc:gcc cxx:g++], libdecor) (push) Failing after 20s
build / client (Debug, map[cc:clang cxx:clang++], libdecor) (push) Failing after 21s
build / client (Debug, map[cc:clang cxx:clang++], xdg-shell) (push) Failing after 21s
build / client (Release, map[cc:clang cxx:clang++], libdecor) (push) Failing after 20s
build / client (Debug, map[cc:gcc cxx:g++], xdg-shell) (push) Failing after 20s
build / client (Release, map[cc:clang cxx:clang++], xdg-shell) (push) Failing after 21s
build / module (push) Failing after 18s
build / client (Release, map[cc:gcc cxx:g++], libdecor) (push) Failing after 22s
build / client (Release, map[cc:gcc cxx:g++], xdg-shell) (push) Failing after 22s
build / host-linux (push) Failing after 21s
build / host-windows-cross (push) Failing after 21s
build / obs (clang) (push) Failing after 21s
build / docs (push) Failing after 4s
build / obs (gcc) (push) Failing after 22s
build / host-windows-native (push) Canceled after 0s
build / idd (push) Canceled after 0s
Records the exact packages needed to build the client, the Linux host, the test suite and the Windows cross compiler, so a fresh machine can bootstrap without rediscovering them.
This commit is contained in:
1 parent
9a1efd34df
commit
b73ffa1b33
1 file changed
+66
Executable
+66
@@ -0,0 +1,66 @@
|
||||
#!/bin/bash
|
||||
# Installs everything needed to build and test this fork on a Debian or
|
||||
# Ubuntu based system, including the multi-monitor test suite and the
|
||||
# Windows cross compiler.
|
||||
#
|
||||
# Usage: scripts/setup-dev.sh [--minimal]
|
||||
#
|
||||
# --minimal only what is needed to build the client and Linux host,
|
||||
# skipping the test and cross compilation tooling
|
||||
|
||||
set -eu
|
||||
|
||||
MINIMAL=0
|
||||
[ "${1:-}" = "--minimal" ] && MINIMAL=1
|
||||
|
||||
# build the client and the Linux host
|
||||
CORE=(
|
||||
cmake gcc g++ make pkg-config
|
||||
libegl-dev libgl-dev libgles-dev
|
||||
libfontconfig-dev libgmp-dev libspice-protocol-dev nettle-dev
|
||||
binutils-dev
|
||||
libx11-dev libxfixes-dev libxi-dev libxinerama-dev libxss-dev
|
||||
libxcursor-dev libxpresent-dev
|
||||
libxkbcommon-dev libwayland-bin libwayland-dev
|
||||
libpipewire-0.3-dev libsamplerate0-dev libpulse-dev
|
||||
fonts-dejavu-core
|
||||
)
|
||||
|
||||
# the Linux host's XCB capture backend, which is what enumerates monitors
|
||||
CORE+=(libxcb1-dev libxcb-shm0-dev libxcb-xfixes0-dev libxcb-randr0-dev)
|
||||
|
||||
# host/tests: Xvfb renders the client headlessly, ImageMagick samples it
|
||||
TESTS=(xvfb imagemagick x11-xserver-utils gdb)
|
||||
|
||||
# cross compile the Windows host from Linux, which type checks the DXGI
|
||||
# and D12 backends without a Windows machine
|
||||
CROSS=(mingw-w64 nsis)
|
||||
|
||||
PKGS=("${CORE[@]}")
|
||||
if [ $MINIMAL -eq 0 ]; then
|
||||
PKGS+=("${TESTS[@]}" "${CROSS[@]}")
|
||||
fi
|
||||
|
||||
echo "installing ${#PKGS[@]} packages..."
|
||||
sudo apt-get update -qq
|
||||
sudo DEBIAN_FRONTEND=noninteractive apt-get install -y "${PKGS[@]}"
|
||||
|
||||
cat <<'EOF'
|
||||
|
||||
Done. To build:
|
||||
|
||||
# client
|
||||
mkdir -p client/build && cd client/build && cmake .. && make -j$(nproc)
|
||||
|
||||
# Linux host (needed for the live test)
|
||||
mkdir -p host/build && cd host/build && cmake .. && make -j$(nproc)
|
||||
|
||||
# Windows host, cross compiled
|
||||
mkdir -p host/build-win && cd host/build-win
|
||||
cmake -DCMAKE_TOOLCHAIN_FILE=../toolchain-mingw64.cmake .. && make -j$(nproc)
|
||||
|
||||
To run the multi-monitor tests:
|
||||
|
||||
host/tests/run-tests.sh
|
||||
|
||||
EOF
|
||||
Reference in new issue
Block a user