diff --git a/configure b/configure index b44f96a..6e2c973 100755 --- a/configure +++ b/configure @@ -8013,6 +8013,52 @@ else $as_nop fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tjInitDecompress in -lturbojpeg" >&5 +printf %s "checking for tjInitDecompress in -lturbojpeg... " >&6; } +if test ${ac_cv_lib_turbojpeg_tjInitDecompress+y} +then : + printf %s "(cached) " >&6 +else $as_nop + ac_check_lib_save_LIBS=$LIBS +LIBS="-lturbojpeg $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +char tjInitDecompress (); +int +main (void) +{ +return tjInitDecompress (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO" +then : + ac_cv_lib_turbojpeg_tjInitDecompress=yes +else $as_nop + ac_cv_lib_turbojpeg_tjInitDecompress=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_turbojpeg_tjInitDecompress" >&5 +printf "%s\n" "$ac_cv_lib_turbojpeg_tjInitDecompress" >&6; } +if test "x$ac_cv_lib_turbojpeg_tjInitDecompress" = xyes +then : + printf "%s\n" "#define HAVE_LIBTURBOJPEG 1" >>confdefs.h + + LIBS="-lturbojpeg $LIBS" + +else $as_nop + as_fn_error $? "Can not find libturbojpeg0." "$LINENO" 5 +fi + + ac_config_files="$ac_config_files Makefile quick_quicklisp.sh po/Makefile.in src/config.lisp.in" diff --git a/configure.ac b/configure.ac index 1a15f1a..5a70e95 100644 --- a/configure.ac +++ b/configure.ac @@ -164,6 +164,8 @@ AC_CHECK_LIB([ncurses], [initscr], [], AC_MSG_ERROR([Can not find ncurses.])) AC_CHECK_LIB([sqlite3], [sqlite3_libversion], [], AC_MSG_ERROR([Can not find libsqlite3.])) +AC_CHECK_LIB([turbojpeg], [tjInitDecompress], [], AC_MSG_ERROR([Can not find libturbojpeg0.])) + AC_CONFIG_FILES([Makefile quick_quicklisp.sh po/Makefile.in src/config.lisp.in]) AC_OUTPUT