From 00a7fd8f00b7ff671574557b4638451d1141b8b1 Mon Sep 17 00:00:00 2001 From: Olaf Meeuwissen Date: Mon, 23 Mar 2020 21:59:41 +0900 Subject: [PATCH 1/2] Add linker flags for JPEG library when checking for functions --- configure.ac | 3 +++ 1 file changed, 3 insertions(+) diff --git a/configure.ac b/configure.ac index 5ce16a263..d927f8b2b 100644 --- a/configure.ac +++ b/configure.ac @@ -697,7 +697,10 @@ fi if test "${sane_cv_use_libjpeg}" = "yes"; then SANEI_SANEI_JPEG_LO="../sanei/sanei_jpeg.lo" + saved_LIBS="${LIBS}" + LIBS="${JPEG_LIBS}" AC_CHECK_FUNCS(jpeg_crop_scanline jpeg_skip_scanlines) + LIBS="${saved_LIBS}" fi AM_CONDITIONAL(HAVE_JPEG, test x$sane_cv_use_libjpeg = xyes) AC_SUBST(SANEI_SANEI_JPEG_LO) From 56522b6a35853025c46bdf14a2a252f8748d3dc6 Mon Sep 17 00:00:00 2001 From: Olaf Meeuwissen Date: Mon, 23 Mar 2020 22:00:16 +0900 Subject: [PATCH 2/2] Fix references to function check results --- acinclude.m4 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/acinclude.m4 b/acinclude.m4 index edc7eccc0..e10f8ceb2 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -630,8 +630,8 @@ for be in ${BACKENDS}; do echo "*** $be backend currently requires JPEG library - $DISABLE_MSG" backend_supported="no" else - if test "x${have_jpeg_crop_scanline}" != "xyes" \ - || test "x${have_jpeg_skip_scanline}" != "xyes"; then + if test "x${ac_cv_func_jpeg_crop_scanline}" != "xyes" \ + || test "x${ac_cv_func_jpeg_skip_scanlines}" != "xyes"; then echo "*** $be backend requires a newer JPEG library - $DISABLE_MSG" backend_supported="no" fi