Update install-dependencies.sh and setup-variables.sh

This commit is contained in:
Andrea Cavalli 2021-03-16 12:50:22 +01:00
parent 1541968c58
commit 746e87a0cf
2 changed files with 4 additions and 4 deletions

View File

@ -5,7 +5,7 @@ if [[ "$OPERATING_SYSTEM_NAME" == "linux" ]]; then
echo "==Linux===="
sudo apt install -y make git zlib1g-dev libssl-dev gperf cmake \
ccache maven python3 python3-pip php7.4-cli
if { [[ "$IMPLEMENTATION_NAME" = "tdlib" ]]; } && { [[ "$CPU_ARCHITECTURE_NAME" = "386" ]] || [[ "$CPU_ARCHITECTURE_NAME" = "armv6" ]] || [[ "$CPU_ARCHITECTURE_NAME" = "armv7" ]]; }; then
if { [[ "$IMPLEMENTATION_NAME" == "tdlib" ]]; } && { [[ "$CPU_ARCHITECTURE_NAME" == "386" ]] || [[ "$CPU_ARCHITECTURE_NAME" == "armv6" ]] || [[ "$CPU_ARCHITECTURE_NAME" == "armv7" ]]; }; then
sudo apt install -y build-essential
else
sudo apt install -y clang-11 libc++-11-dev libc++abi-11-dev

View File

@ -80,19 +80,19 @@ elif [[ "$OPERATING_SYSTEM_NAME" == "osx" ]]; then
export CPU_CORES=" -- -j${CPU_CORES_NUM}"
elif [[ "$OPERATING_SYSTEM_NAME" == "linux" ]]; then
export BUILD_TYPE=MinSizeRel
if [[ "$CPU_ARCHITECTURE_NAME" = "aarch64" ]]; then
if [[ "$CPU_ARCHITECTURE_NAME" == "aarch64" ]]; then
export CMAKE_EXTRA_ARGUMENTS=""
else
export CMAKE_EXTRA_ARGUMENTS="-DOPENSSL_USE_STATIC_LIBS=ON -DCMAKE_FIND_LIBRARY_SUFFIXES=\".a\""
fi
if [[ "$CPU_ARCHITECTURE_NAME" = "386" ]] || [[ "$CPU_ARCHITECTURE_NAME" = "armv6" ]] || [[ "$CPU_ARCHITECTURE_NAME" = "armv7" ]]; then
if [[ "$CPU_ARCHITECTURE_NAME" == "386" ]] || [[ "$CPU_ARCHITECTURE_NAME" == "armv6" ]] || [[ "$CPU_ARCHITECTURE_NAME" == "armv7" ]]; then
export CMAKE_EXE_LINKER_FLAGS="$CMAKE_EXE_LINKER_FLAGS -latomic"
export LDFLAGS="$LDFLAGS -latomic"
export CXXFLAGS="$CXXFLAGS -latomic"
fi
if { [[ "$IMPLEMENTATION_NAME" = "tdlib" ]]; } && { [[ "$CPU_ARCHITECTURE_NAME" = "386" ]] || [[ "$CPU_ARCHITECTURE_NAME" = "armv6" ]] || [[ "$CPU_ARCHITECTURE_NAME" = "armv7" ]]; }; then
if { [[ "$IMPLEMENTATION_NAME" == "tdlib" ]]; } && { [[ "$CPU_ARCHITECTURE_NAME" == "386" ]] || [[ "$CPU_ARCHITECTURE_NAME" == "armv6" ]] || [[ "$CPU_ARCHITECTURE_NAME" == "armv7" ]]; }; then
export CXXFLAGS="$CXXFLAGS"
else
export CXXFLAGS="$CXXFLAGS -static-libgcc -static-libstdc++"