From 026c992024a37770d7acb3ef292503721977acd5 Mon Sep 17 00:00:00 2001 From: Zanie Blue Date: Sat, 28 Dec 2024 18:21:57 -0600 Subject: [PATCH 1/3] Include `libm` in statically linked sqlite3 builds --- cpython-unix/build-sqlite.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cpython-unix/build-sqlite.sh b/cpython-unix/build-sqlite.sh index 2d44dc83..9a9df486 100755 --- a/cpython-unix/build-sqlite.sh +++ b/cpython-unix/build-sqlite.sh @@ -12,6 +12,9 @@ export PATH=${TOOLS_PATH}/${TOOLCHAIN}/bin:${TOOLS_PATH}/host/bin:$PATH tar -xf sqlite-autoconf-${SQLITE_VERSION}.tar.gz pushd sqlite-autoconf-${SQLITE_VERSION} +if [[ "${TARGET_TRIPLE}" == *"linux"* ]]; then + export LIBS="${LIBS} -lm" +fi CONFIGURE_FLAGS="--build=${BUILD_TRIPLE} --host=${TARGET_TRIPLE}" CONFIGURE_FLAGS="${CONFIGURE_FLAGS} --prefix /tools/deps --disable-shared" From 9e0273a761450f64956caeaf80aff722c4d52086 Mon Sep 17 00:00:00 2001 From: Zanie Blue Date: Sat, 28 Dec 2024 19:28:00 -0600 Subject: [PATCH 2/3] Revert "Include `libm` in statically linked sqlite3 builds" This reverts commit 026c992024a37770d7acb3ef292503721977acd5. --- cpython-unix/build-sqlite.sh | 3 --- 1 file changed, 3 deletions(-) diff --git a/cpython-unix/build-sqlite.sh b/cpython-unix/build-sqlite.sh index 9a9df486..2d44dc83 100755 --- a/cpython-unix/build-sqlite.sh +++ b/cpython-unix/build-sqlite.sh @@ -12,9 +12,6 @@ export PATH=${TOOLS_PATH}/${TOOLCHAIN}/bin:${TOOLS_PATH}/host/bin:$PATH tar -xf sqlite-autoconf-${SQLITE_VERSION}.tar.gz pushd sqlite-autoconf-${SQLITE_VERSION} -if [[ "${TARGET_TRIPLE}" == *"linux"* ]]; then - export LIBS="${LIBS} -lm" -fi CONFIGURE_FLAGS="--build=${BUILD_TRIPLE} --host=${TARGET_TRIPLE}" CONFIGURE_FLAGS="${CONFIGURE_FLAGS} --prefix /tools/deps --disable-shared" From bafaac83016551736d2436e67b9af6d89584dfdf Mon Sep 17 00:00:00 2001 From: Zanie Blue Date: Sat, 28 Dec 2024 19:28:49 -0600 Subject: [PATCH 3/3] Display the pkg-config file --- cpython-unix/build-sqlite.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cpython-unix/build-sqlite.sh b/cpython-unix/build-sqlite.sh index 2d44dc83..92c2fa33 100755 --- a/cpython-unix/build-sqlite.sh +++ b/cpython-unix/build-sqlite.sh @@ -24,5 +24,8 @@ fi CFLAGS="${EXTRA_TARGET_CFLAGS} -DSQLITE_ENABLE_DBSTAT_VTAB -fPIC" CPPFLAGS="${EXTRA_TARGET_CFLAGS} -fPIC" LDFLAGS="${EXTRA_TARGET_LDFLAGS}" ./configure ${CONFIGURE_FLAGS} +# Debug the pkg-config +cat sqlite3.pc + make -j ${NUM_CPUS} make -j ${NUM_CPUS} install DESTDIR=${ROOT}/out