fix: avoid arm64/amd64 -dev header conflicts, generate missing .pc files for zmq/psl
This commit is contained in:
@ -46,6 +46,8 @@ if command -v apt-get > /dev/null 2>&1; then
|
|||||||
binutils-aarch64-linux-gnu
|
binutils-aarch64-linux-gnu
|
||||||
|
|
||||||
# aarch64 dev libraries (provides the .pc files pkg-config needs)
|
# aarch64 dev libraries (provides the .pc files pkg-config needs)
|
||||||
|
# Note: packages that conflict with their amd64 -dev counterparts (shared headers)
|
||||||
|
# are installed as runtime-only :arm64 — the .so + .pc files are still present.
|
||||||
DEBIAN_FRONTEND=noninteractive apt-get install -y \
|
DEBIAN_FRONTEND=noninteractive apt-get install -y \
|
||||||
libmpg123-dev:arm64 libsndfile1-dev:arm64 libopenal-dev:arm64 libassimp-dev:arm64 \
|
libmpg123-dev:arm64 libsndfile1-dev:arm64 libopenal-dev:arm64 libassimp-dev:arm64 \
|
||||||
libglew-dev:arm64 libglfw3-dev:arm64 liburiparser-dev:arm64 \
|
libglew-dev:arm64 libglfw3-dev:arm64 liburiparser-dev:arm64 \
|
||||||
@ -56,7 +58,31 @@ if command -v apt-get > /dev/null 2>&1; then
|
|||||||
libxrandr-dev:arm64 libxinerama-dev:arm64 libxcursor-dev:arm64 libxi-dev:arm64 \
|
libxrandr-dev:arm64 libxinerama-dev:arm64 libxcursor-dev:arm64 libxi-dev:arm64 \
|
||||||
libpulse-dev:arm64 libudev-dev:arm64 libfreeimage-dev:arm64 \
|
libpulse-dev:arm64 libudev-dev:arm64 libfreeimage-dev:arm64 \
|
||||||
freeglut3-dev:arm64 libxxf86vm-dev:arm64 \
|
freeglut3-dev:arm64 libxxf86vm-dev:arm64 \
|
||||||
libcairo2-dev:arm64 libzmq3-dev:arm64
|
libcairo2-dev:arm64
|
||||||
|
|
||||||
|
# These conflict with amd64 -dev headers; install runtime-only for .so + .pc
|
||||||
|
DEBIAN_FRONTEND=noninteractive apt-get install -y \
|
||||||
|
libzmq5:arm64 libpsl5:arm64 || true
|
||||||
|
# Repair any partially-broken state from conflicts
|
||||||
|
apt-get -f install -y
|
||||||
|
|
||||||
|
# Generate minimal .pc files for runtime-only arm64 packages that lack one
|
||||||
|
if [ ! -f /usr/lib/aarch64-linux-gnu/pkgconfig/libzmq.pc ]; then
|
||||||
|
ZMQ_VER=$(dpkg -l libzmq5:arm64 2>/dev/null | awk '/^ii/{print $3}' | cut -d- -f1 || echo "4.3.5")
|
||||||
|
mkdir -p /usr/lib/aarch64-linux-gnu/pkgconfig
|
||||||
|
cat > /usr/lib/aarch64-linux-gnu/pkgconfig/libzmq.pc <<EOF
|
||||||
|
prefix=/usr
|
||||||
|
exec_prefix=\${prefix}
|
||||||
|
libdir=\${prefix}/lib/aarch64-linux-gnu
|
||||||
|
includedir=\${prefix}/include
|
||||||
|
|
||||||
|
Name: libzmq
|
||||||
|
Description: ZeroMQ messaging library
|
||||||
|
Version: $ZMQ_VER
|
||||||
|
Libs: -L\${libdir} -lzmq
|
||||||
|
Cflags: -I\${includedir}
|
||||||
|
EOF
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Install Node.js if missing
|
# Install Node.js if missing
|
||||||
|
|||||||
Reference in New Issue
Block a user