Skip to content

Commit

Permalink
fix(libgcrypt): update getentropy for old Linux devices (#102)
Browse files Browse the repository at this point in the history
LX01 and S12 do not support the getentropy function (kernel version too low).
  • Loading branch information
firedevel authored Jan 1, 2025
1 parent e06ba0c commit 3ae0849
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion packages/libgcrypt/package.mk
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,19 @@ PACKAGE_SRC="https://www.gnupg.org/ftp/gcrypt/libgcrypt/libgcrypt-${PACKAGE_VERS


configure_package() {
CC="${BUILD_CC}" CXX="${BUILD_CXX}" CFLAGS="${BUILD_CFLAGS}" CXXFLAGS="${BUILD_CFLAGS}" CPPFLAGS="${BUILD_CFLAGS}" LDFLAGS="${BUILD_LDFLAGS}" PKG_CONFIG_LIBDIR="${BUILD_PKG_CONFIG_LIBDIR}" PKG_CONFIG_SYSROOT_DIR="${BUILD_PKG_CONFIG_SYSROOT_DIR}" ./configure --prefix=${INSTALL_PREFIX} --build=${MACHTYPE} --host=${BUILD_TARGET} --with-libgpg-error-prefix=${STAGING_DIR}/${INSTALL_PREFIX} ${extra_flags}
# LX01 and S12 do not support the getentropy function (kernel version too low).
# This affects shairport-sync AirPlay2 feature, issue #97
EXTRA_FLAGS=""
if [ "$BUILD_MODEL" = "LX01" ] || [ "$BUILD_MODEL" = "S12" ]; then
EXTRA_FLAGS="--enable-random=linux"
fi

CC="${BUILD_CC}" CXX="${BUILD_CXX}" CFLAGS="${BUILD_CFLAGS}" \
CXXFLAGS="${BUILD_CFLAGS}" CPPFLAGS="${BUILD_CFLAGS}" LDFLAGS="${BUILD_LDFLAGS}" \
PKG_CONFIG_LIBDIR="${BUILD_PKG_CONFIG_LIBDIR}" PKG_CONFIG_SYSROOT_DIR="${BUILD_PKG_CONFIG_SYSROOT_DIR}" \
./configure --prefix=${INSTALL_PREFIX} --build=${MACHTYPE} --host=${BUILD_TARGET} \
--with-libgpg-error-prefix=${STAGING_DIR}/${INSTALL_PREFIX} \
${EXTRA_FLAGS}
}

make_package() {
Expand Down

0 comments on commit 3ae0849

Please sign in to comment.