Extract package versions into a single versions.sh file

All hardcoded versions are now defined once in versions.sh and sourced
by build-toolchain.sh, download_prerequisites.sh, and build-libraries.sh,
eliminating the need to update multiple files when changing a version.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-02-18 10:07:30 +03:00
parent a2034926f8
commit 3bdde2147b
4 changed files with 32 additions and 16 deletions

View File

@@ -1,6 +1,8 @@
#!/bin/bash
set -e
source "$(dirname "$0")/versions.sh"
# Подготавливаем переменные
TOP="$(pwd)"
@@ -80,7 +82,7 @@ cd ${TOP}
export CFLAGS=""
export CXXFLAGS=""
cd "${LIB_BUILD_DIR}/zlib-1.2.13"
cd "${LIB_BUILD_DIR}/zlib-${ZLIB_VER}"
./configure --prefix=${SYSROOT_USR_DIR} --libdir=${SYSROOT_USR_DIR}/lib --static
make -j$(nproc)
make install
@@ -92,7 +94,7 @@ cd ${TOP}
export CFLAGS=""
export CXXFLAGS=""
cd "${LIB_BUILD_DIR}/openssl-3.0.13"
cd "${LIB_BUILD_DIR}/openssl-${OPENSSL_VER}"
./Configure linux-armv4 \
--prefix=${SYSROOT_USR_DIR} \
--libdir=${SYSROOT_USR_DIR}/lib \
@@ -110,7 +112,7 @@ make install_sw
# ==================================================================
cd "${LIB_BUILD_DIR}/LibVNCServer-0.9.14"
cd "${LIB_BUILD_DIR}/LibVNCServer-${LIBVNCSERVER_VER}"
rm -rf build
mkdir -p build && cd build
cmake -S .. -B . \
@@ -146,7 +148,7 @@ make install
# ==================================================================
cd "${LIB_BUILD_DIR}/freetype-2.13.2"
cd "${LIB_BUILD_DIR}/freetype-${FREETYPE_VER}"
[ -d "build" ] && rm -rf build
mkdir -p build && cd build
cmake -S .. -B . \