-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathinit.sh
More file actions
executable file
·31 lines (28 loc) · 1.12 KB
/
init.sh
File metadata and controls
executable file
·31 lines (28 loc) · 1.12 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#!/bin/bash
# Setup python (see https://github.com/indygreg/python-build-standalone/releases/tag/20241016 for available versions)
PYTHON_VERSION="3.13.0"
ARCH="$(arch)"
if [ "$ARCH" == "" ]; then
ARCH="$(uname -m)"
fi
PYTHON_URL="https://github.com/indygreg/python-build-standalone/releases/download/20241016/cpython-$PYTHON_VERSION+20241016-$ARCH-unknown-linux-gnu-install_only_stripped.tar.gz"
echo "Downloading Python from '$PYTHON_URL' ..."
curl -L -o python.tar.gz $PYTHON_URL
mkdir tmp
mkdir -p ./bin/
rm -rf ./bin/python3
echo "Extracting Python (IGNORE ERRORS, IT'll STILL WORK :D)..."
tar -xzf python.tar.gz -C ./tmp/
mv ./tmp/python/ ./bin/python3
# Cleanup
rm -rf tmp python.tar.gz
# Setup rust (MUST HAVE RUST INSTALLED THORUGH RUSTUP ALREADY)
cp -r $HOME/.rustup/toolchains/stable-*-linux-gnu bin/rust
# Removes unnecessary files
rm -rf bin/rust/share/
if [ ! -d "vcpkg" ]; then
git clone https://github.com/microsoft/vcpkg.git --depth 1
bash vcpkg/bootstrap-vcpkg.sh -disableMetrics
fi
vcpkg/vcpkg install crow spdlog nlohmann-json
cmake -DCMAKE_TOOLCHAIN_FILE=vcpkg/scripts/buildsystems/vcpkg.cmake -S . -B build