mirror of
https://github.com/ciphervance/supercell-wx.git
synced 2025-10-30 08:10:05 +00:00
Setup script cleanup for Linux
This commit is contained in:
parent
3de270c2a1
commit
6fca723404
10 changed files with 80 additions and 20 deletions
22
tools/lib/setup-common.sh
Normal file → Executable file
22
tools/lib/setup-common.sh
Normal file → Executable file
|
|
@ -2,26 +2,36 @@
|
|||
script_dir="$(dirname "$(readlink -f "$0")")"
|
||||
|
||||
# Import common paths
|
||||
source ./common-paths.sh
|
||||
source ${script_dir}/common-paths.sh
|
||||
|
||||
IN_VENV=$(python -c 'import sys; print(sys.prefix != getattr(sys, "base_prefix", sys.prefix))')
|
||||
|
||||
if [ "${IN_VENV}" = "True" ]; then
|
||||
# In a virtual environment, don't use --user
|
||||
PIP_FLAGS="--upgrade"
|
||||
else
|
||||
# Not in a virtual environment, use --user
|
||||
PIP_FLAGS="--upgrade --user"
|
||||
fi
|
||||
|
||||
# Install Python packages
|
||||
pip install --upgrade --user ${script_dir}/../../requirements.txt
|
||||
pip install ${PIP_FLAGS} -r ${script_dir}/../../requirements.txt
|
||||
|
||||
if [[ -n "${build_type}" ]]; then
|
||||
# Install Conan profile and packages
|
||||
./setup-conan.sh
|
||||
${script_dir}/setup-conan.sh
|
||||
else
|
||||
# Install Conan profile and debug packages
|
||||
export build_type=Debug
|
||||
./setup-conan.sh
|
||||
${script_dir}/setup-conan.sh
|
||||
|
||||
# Install Conan profile and release packages
|
||||
export build_type=Release
|
||||
./setup-conan.sh
|
||||
${script_dir}/setup-conan.sh
|
||||
|
||||
# Unset build_type
|
||||
unset build_type
|
||||
fi
|
||||
|
||||
# Run CMake Configure
|
||||
./run-cmake-configure.sh
|
||||
${script_dir}/run-cmake-configure.sh
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue