From 58912f68c2489bcee787599837447e0d64dfd61a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Wed, 24 May 2017 21:03:56 +0200 Subject: New upstream version 1.0.27 --- acinclude.m4 | 156 +++++++++++++++++++---------------------------------------- 1 file changed, 50 insertions(+), 106 deletions(-) (limited to 'acinclude.m4') diff --git a/acinclude.m4 b/acinclude.m4 index 7a86a0b..476d536 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -1,16 +1,15 @@ dnl dnl Contains the following macros -dnl SANE_SET_CFLAGS(is_release) +dnl SANE_SET_AM_CFLAGS(is_release) dnl SANE_CHECK_MISSING_HEADERS -dnl SANE_SET_LDFLAGS +dnl SANE_SET_AM_LDFLAGS dnl SANE_CHECK_DLL_LIB dnl SANE_EXTRACT_LDFLAGS(LIBS, LDFLAGS) dnl SANE_CHECK_JPEG dnl SANE_CHECK_IEEE1284 dnl SANE_CHECK_PTHREAD dnl SANE_CHECK_LOCKING -dnl JAPHAR_GREP_CFLAGS(flag, cmd_if_missing, cmd_if_present) -dnl SANE_LINKER_RPATH +dnl JAPHAR_GREP_AM_CFLAGS(flag, cmd_if_missing, cmd_if_present) dnl SANE_CHECK_U_TYPES dnl SANE_CHECK_GPHOTO2 dnl SANE_CHECK_IPV6 @@ -19,61 +18,38 @@ dnl SANE_PROTOTYPES dnl AC_PROG_LIBTOOL dnl -# SANE_SET_CFLAGS(is_release) -# Set CFLAGS. Enable/disable compilation warnings if we gcc is used. -# Warnings are enabled by default when in development cycle but disabled -# when a release is made. The argument is_release is either yes or no. -AC_DEFUN([SANE_SET_CFLAGS], +# SANE_SET_AM_CFLAGS(is_release) +# Set default AM_CFLAGS if gcc is used. Enable/disable additional +# compilation warnings. The extra warnings are enabled by default +# during the development cycle but disabled for official releases. +# The argument is_release is either yes or no. +AC_DEFUN([SANE_SET_AM_CFLAGS], [ if test "${ac_cv_c_compiler_gnu}" = "yes"; then - NORMAL_CFLAGS="\ - -W \ + DEFAULT_CFLAGS="\ -Wall" - WARN_CFLAGS="\ - -W \ - -Wall \ - -Wcast-align \ - -Wcast-qual \ - -Wmissing-declarations \ - -Wmissing-prototypes \ - -Wpointer-arith \ - -Wreturn-type \ - -Wstrict-prototypes \ + EXTRA_WARNINGS="\ + -Wextra \ -pedantic" - # Some platforms are overly strict with -ansi enabled. Exclude those. - ANSI_FLAG=-ansi - case "${host_os}" in - solaris* | hpux* | os2* | darwin* | cygwin* | mingw*) - ANSI_FLAG= - ;; - esac - NORMAL_CFLAGS="${NORMAL_CFLAGS} ${ANSI_FLAG}" - WARN_CFLAGS="${WARN_CFLAGS} ${ANSI_FLAG}" + for flag in $DEFAULT_CFLAGS; do + JAPHAR_GREP_AM_CFLAGS($flag, [ AM_CFLAGS="$AM_CFLAGS $flag" ]) + done AC_ARG_ENABLE(warnings, - AC_HELP_STRING([--enable-warnings], + AS_HELP_STRING([--enable-warnings], [turn on tons of compiler warnings (GCC only)]), [ if eval "test x$enable_warnings = xyes"; then - for flag in $WARN_CFLAGS; do - JAPHAR_GREP_CFLAGS($flag, [ CFLAGS="$CFLAGS $flag" ]) - done - else - for flag in $NORMAL_CFLAGS; do - JAPHAR_GREP_CFLAGS($flag, [ CFLAGS="$CFLAGS $flag" ]) + for flag in $EXTRA_WARNINGS; do + JAPHAR_GREP_AM_CFLAGS($flag, [ AM_CFLAGS="$AM_CFLAGS $flag" ]) done fi ], [if test x$1 = xno; then # Warnings enabled by default (development) - for flag in $WARN_CFLAGS; do - JAPHAR_GREP_CFLAGS($flag, [ CFLAGS="$CFLAGS $flag" ]) - done - else - # Warnings disabled by default (release) - for flag in $NORMAL_CFLAGS; do - JAPHAR_GREP_CFLAGS($flag, [ CFLAGS="$CFLAGS $flag" ]) + for flag in $EXTRA_WARNINGS; do + JAPHAR_GREP_AM_CFLAGS($flag, [ AM_CFLAGS="$AM_CFLAGS $flag" ]) done fi]) fi # ac_cv_c_compiler_gnu @@ -106,9 +82,9 @@ AC_DEFUN([SANE_CHECK_MISSING_HEADERS], fi ]) -# SANE_SET_LDFLAGS -# Add special LDFLAGS -AC_DEFUN([SANE_SET_LDFLAGS], +# SANE_SET_AM_LDFLAGS +# Add special AM_LDFLAGS +AC_DEFUN([SANE_SET_AM_LDFLAGS], [ # Define stricter linking policy on GNU systems. This is not # added to global LDFLAGS because we may want to create convenience @@ -123,7 +99,7 @@ AC_DEFUN([SANE_SET_LDFLAGS], AC_SUBST(STRICT_LDFLAGS) case "${host_os}" in aix*) #enable .so libraries, disable archives - LDFLAGS="$LDFLAGS -Wl,-brtl" + AM_LDFLAGS="$AM_LDFLAGS -Wl,-brtl" ;; darwin*) #include frameworks LIBS="$LIBS -framework CoreFoundation -framework IOKit" @@ -203,10 +179,10 @@ AC_DEFUN([SANE_CHECK_IEEE1284], [ AC_CHECK_HEADER(ieee1284.h, [ AC_CACHE_CHECK([for libieee1284 >= 0.1.5], sane_cv_use_libieee1284, [ - AC_TRY_COMPILE([#include ], [ + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include ]], [[ struct parport p; char *buf; ieee1284_nibble_read(&p, 0, buf, 1); - ], + ]])], [sane_cv_use_libieee1284="yes"; IEEE1284_LIBS="-lieee1284" ],[sane_cv_use_libieee1284="no"]) ],) @@ -236,7 +212,7 @@ AC_DEFUN([SANE_CHECK_PTHREAD], # the user AC_ARG_ENABLE([pthread], - AC_HELP_STRING([--enable-pthread], + AS_HELP_STRING([--enable-pthread], [use pthread instead of fork (default=yes for Linux/MacOS X/MINGW, no for everything else)]), [ if test $enableval = yes ; then @@ -256,7 +232,7 @@ AC_DEFUN([SANE_CHECK_PTHREAD], AC_CHECK_FUNCS([pthread_create pthread_kill pthread_join pthread_detach pthread_cancel pthread_testcancel], ,[ have_pthread=no; use_pthread=no ]) LIBS="$save_LIBS" - ],) + ],[ have_pthread=no; use_pthread=no ]) fi if test $use_pthread = yes ; then @@ -267,7 +243,7 @@ AC_DEFUN([SANE_CHECK_PTHREAD], PTHREAD_LIBS="" fi if test "$have_pthread" = "yes" ; then - CPPFLAGS="${CPPFLAGS} -D_REENTRANT" + AM_CPPFLAGS="${AM_CPPFLAGS} -D_REENTRANT" fi AC_SUBST(PTHREAD_LIBS) AC_MSG_CHECKING([whether to enable pthread support]) @@ -341,7 +317,7 @@ AC_DEFUN([SANE_CHECK_LOCKING], # # we check the user AC_ARG_ENABLE( [locking], - AC_HELP_STRING([--enable-locking], + AS_HELP_STRING([--enable-locking], [activate device locking (default=yes, but only used by some backends)]), [ if test $enableval = yes ; then @@ -352,7 +328,7 @@ AC_DEFUN([SANE_CHECK_LOCKING], ]) if test $use_locking = yes ; then AC_ARG_WITH([group], - AC_HELP_STRING([--with-group], + AS_HELP_STRING([--with-group], [use the specified group for lock dir @<:@default=uucp@:>@]), [LOCKPATH_GROUP="$withval"] ) @@ -384,12 +360,12 @@ AC_DEFUN([SANE_CHECK_LOCKING], ]) dnl -dnl JAPHAR_GREP_CFLAGS(flag, cmd_if_missing, cmd_if_present) +dnl JAPHAR_GREP_AM_CFLAGS(flag, cmd_if_missing, cmd_if_present) dnl dnl From Japhar. Report changes to japhar@hungry.com dnl -AC_DEFUN([JAPHAR_GREP_CFLAGS], -[case "$CFLAGS" in +AC_DEFUN([JAPHAR_GREP_AM_CFLAGS], +[case "$AM_CFLAGS" in "$1" | "$1 "* | *" $1" | *" $1 "* ) ifelse($#, 3, [$3], [:]) ;; @@ -399,42 +375,6 @@ AC_DEFUN([JAPHAR_GREP_CFLAGS], esac ]) -dnl -dnl SANE_LINKER_RPATH -dnl -dnl Detect how to set runtime link path (rpath). Set variable -dnl LINKER_RPATH. Typical content will be '-Wl,-rpath,' or '-R '. If -dnl set, add '${LINKER_RPATH}${libdir}' to $LDFLAGS -dnl - -AC_DEFUN([SANE_LINKER_RPATH], -[dnl AC_REQUIRE([AC_SUBST])dnl This line resulted in an empty AC_SUBST() !! - AC_MSG_CHECKING([whether runtime link path should be used]) - AC_ARG_ENABLE([rpath], - [AS_HELP_STRING([--enable-rpath], - [use runtime library search path @<:@default=yes@:>@])]) - - LINKER_RPATH= - AS_IF([test "x$enable_rpath" != xno], - AC_MSG_RESULT([yes]) - [AC_CACHE_CHECK([linker parameter to set runtime link path], my_cv_LINKER_RPATH, - [my_cv_LINKER_RPATH= - case "$host_os" in - linux* | freebsd* | netbsd* | openbsd* | irix*) - # I believe this only works with GNU ld [pere 2001-04-16] - my_cv_LINKER_RPATH="-Wl,-rpath," - ;; - solaris*) - my_cv_LINKER_RPATH="-R " - ;; - esac - ]) - LINKER_RPATH="$my_cv_LINKER_RPATH"], - [AC_MSG_RESULT([no]) - LINKER_RPATH=]) - AC_SUBST(LINKER_RPATH)dnl -]) - dnl dnl SANE_CHECK_U_TYPES dnl @@ -452,7 +392,7 @@ AC_CHECK_TYPES([u_char, u_short, u_int, u_long],,,) AC_DEFUN([SANE_CHECK_GPHOTO2], [ AC_ARG_WITH(gphoto2, - AC_HELP_STRING([--with-gphoto2], + AS_HELP_STRING([--with-gphoto2], [include the gphoto2 backend @<:@default=yes@:>@]), [# If --with-gphoto2=no or --without-gphoto2, disable backend # as "$with_gphoto2" will be set to "no"]) @@ -491,6 +431,10 @@ AC_DEFUN([SANE_CHECK_GPHOTO2], GPHOTO2_LIBS="" else SANE_EXTRACT_LDFLAGS(GPHOTO2_LIBS, GPHOTO2_LDFLAGS) + if pkg-config --atleast-version=2.5.0 libgphoto2; then + AC_DEFINE([GPLOGFUNC_NO_VARGS], [1], + [Define if GPLogFunc does not take a va_list.]) + fi fi fi fi @@ -506,7 +450,7 @@ AC_DEFUN([SANE_CHECK_IPV6], [ AC_MSG_CHECKING([whether to enable IPv6]) AC_ARG_ENABLE(ipv6, - AC_HELP_STRING([--disable-ipv6],[disable IPv6 support]), + AS_HELP_STRING([--disable-ipv6],[disable IPv6 support]), [ if test "$enableval" = "no" ; then AC_MSG_RESULT([no, manually disabled]) ipv6=no @@ -514,16 +458,16 @@ AC_DEFUN([SANE_CHECK_IPV6], ]) if test "$ipv6" != "no" ; then - AC_TRY_COMPILE([ + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ #define INET6 #include - #include ], [ + #include ]], [[ /* AF_INET6 available check */ if (socket(AF_INET6, SOCK_STREAM, 0) < 0) exit(1); else exit(0); - ],[ + ]])],[ AC_MSG_RESULT(yes) AC_DEFINE([ENABLE_IPV6], 1, [Define to 1 if the system supports IPv6]) ipv6=yes @@ -535,27 +479,27 @@ AC_DEFUN([SANE_CHECK_IPV6], if test "$ipv6" != "no" ; then AC_MSG_CHECKING([whether struct sockaddr_storage has an ss_family member]) - AC_TRY_COMPILE([ + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ #define INET6 #include - #include ], [ + #include ]], [[ /* test if the ss_family member exists in struct sockaddr_storage */ struct sockaddr_storage ss; ss.ss_family = AF_INET; exit (0); - ], [ + ]])], [ AC_MSG_RESULT(yes) AC_DEFINE([HAS_SS_FAMILY], 1, [Define to 1 if struct sockaddr_storage has an ss_family member]) ], [ - AC_TRY_COMPILE([ + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ #define INET6 #include - #include ], [ + #include ]], [[ /* test if the __ss_family member exists in struct sockaddr_storage */ struct sockaddr_storage ss; ss.__ss_family = AF_INET; exit (0); - ], [ + ]])], [ AC_MSG_RESULT([no, but __ss_family exists]) AC_DEFINE([HAS___SS_FAMILY], 1, [Define to 1 if struct sockaddr_storage has __ss_family instead of ss_family]) ], [ @@ -627,7 +571,7 @@ for be in ${BACKENDS}; do gphoto2) if test "${HAVE_GPHOTO2}" != "true" \ - -o "${sane_cv_use_libjpeg}" != "yes"; then + || test "${sane_cv_use_libjpeg}" != "yes"; then echo "*** $be backend requires gphoto2 and JPEG libraries - $DISABLE_MSG" backend_supported="no" fi -- cgit v1.2.3 From 1687222e1b9e74c89cafbb5910e72d8ec7bfd40f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Wed, 31 Jul 2019 16:59:49 +0200 Subject: New upstream version 1.0.28 --- acinclude.m4 | 122 ++++++++++++++++++++++++++++++++++++++--------------------- 1 file changed, 78 insertions(+), 44 deletions(-) (limited to 'acinclude.m4') diff --git a/acinclude.m4 b/acinclude.m4 index 476d536..1bc3b74 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -26,23 +26,25 @@ dnl AC_DEFUN([SANE_SET_AM_CFLAGS], [ if test "${ac_cv_c_compiler_gnu}" = "yes"; then - DEFAULT_CFLAGS="\ + DEFAULT_WARNINGS="\ -Wall" EXTRA_WARNINGS="\ -Wextra \ -pedantic" - for flag in $DEFAULT_CFLAGS; do + for flag in $DEFAULT_WARNINGS; do JAPHAR_GREP_AM_CFLAGS($flag, [ AM_CFLAGS="$AM_CFLAGS $flag" ]) + JAPHAR_GREP_AM_CXXFLAGS($flag, [ AM_CXXFLAGS="$AM_CXXFLAGS $flag" ]) done AC_ARG_ENABLE(warnings, AS_HELP_STRING([--enable-warnings], [turn on tons of compiler warnings (GCC only)]), [ - if eval "test x$enable_warnings = xyes"; then + if eval "test x$enable_warnings = xyes"; then for flag in $EXTRA_WARNINGS; do JAPHAR_GREP_AM_CFLAGS($flag, [ AM_CFLAGS="$AM_CFLAGS $flag" ]) + JAPHAR_GREP_AM_CXXFLAGS($flag, [ AM_CXXFLAGS="$AM_CXXFLAGS $flag" ]) done fi ], @@ -50,6 +52,7 @@ if test "${ac_cv_c_compiler_gnu}" = "yes"; then # Warnings enabled by default (development) for flag in $EXTRA_WARNINGS; do JAPHAR_GREP_AM_CFLAGS($flag, [ AM_CFLAGS="$AM_CFLAGS $flag" ]) + JAPHAR_GREP_AM_CXXFLAGS($flag, [ AM_CXXFLAGS="$AM_CXXFLAGS $flag" ]) done fi]) fi # ac_cv_c_compiler_gnu @@ -97,7 +100,7 @@ AC_DEFUN([SANE_SET_AM_LDFLAGS], esac fi AC_SUBST(STRICT_LDFLAGS) - case "${host_os}" in + case "${host_os}" in aix*) #enable .so libraries, disable archives AM_LDFLAGS="$AM_LDFLAGS -Wl,-brtl" ;; @@ -180,7 +183,7 @@ AC_DEFUN([SANE_CHECK_IEEE1284], AC_CHECK_HEADER(ieee1284.h, [ AC_CACHE_CHECK([for libieee1284 >= 0.1.5], sane_cv_use_libieee1284, [ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include ]], [[ - struct parport p; char *buf; + struct parport p; char *buf; ieee1284_nibble_read(&p, 0, buf, 1); ]])], [sane_cv_use_libieee1284="yes"; IEEE1284_LIBS="-lieee1284" @@ -234,7 +237,25 @@ AC_DEFUN([SANE_CHECK_PTHREAD], LIBS="$save_LIBS" ],[ have_pthread=no; use_pthread=no ]) fi - + + # Based on a similar test for pthread_key_t from the Python project. + # See https://bugs.python.org/review/25658/patch/19209/75870 + AC_MSG_CHECKING(whether pthread_t is integer) + AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM([[#include ]], [[pthread_t k; k * 1;]])], + [ac_pthread_t_is_integer=yes], + [ac_pthread_t_is_integer=no] + ) + AC_MSG_RESULT($ac_pthread_t_is_integer) + if test "$ac_pthread_t_is_integer" = yes ; then + AC_DEFINE(PTHREAD_T_IS_INTEGER, 1, + [Define if pthread_t is integer.]) + else + # Until the sanei_thread implementation is fixed. + have_pthread=no + use_pthread=no + fi + if test $use_pthread = yes ; then AC_DEFINE_UNQUOTED(USE_PTHREAD, "$use_pthread", [Define if pthreads should be used instead of forked processes.]) @@ -257,9 +278,9 @@ AC_DEFUN([SANE_CHECK_PTHREAD], # GPHOTO2 and dell1600n_net backends. AC_DEFUN([SANE_CHECK_JPEG], [ - AC_CHECK_LIB(jpeg,jpeg_start_decompress, + AC_CHECK_LIB(jpeg,jpeg_start_decompress, [ - AC_CHECK_HEADER(jconfig.h, + AC_CHECK_HEADER(jconfig.h, [ AC_MSG_CHECKING([for jpeglib - version >= 61 (6a)]) AC_EGREP_CPP(sane_correct_jpeg_lib_version_found, @@ -268,7 +289,7 @@ AC_DEFUN([SANE_CHECK_JPEG], #if JPEG_LIB_VERSION >= 61 sane_correct_jpeg_lib_version_found #endif - ], [sane_cv_use_libjpeg="yes"; JPEG_LIBS="-ljpeg"; + ], [sane_cv_use_libjpeg="yes"; JPEG_LIBS="-ljpeg"; AC_MSG_RESULT(yes)],[AC_MSG_RESULT(no)]) ],) ],) @@ -281,9 +302,9 @@ AC_DEFUN([SANE_CHECK_JPEG], # Checks for tiff library dell1600n_net backend. AC_DEFUN([SANE_CHECK_TIFF], [ - AC_CHECK_LIB(tiff,TIFFFdOpen, + AC_CHECK_LIB(tiff,TIFFFdOpen, [ - AC_CHECK_HEADER(tiffio.h, + AC_CHECK_HEADER(tiffio.h, [sane_cv_use_libtiff="yes"; TIFF_LIBS="-ltiff"],) ],) AC_SUBST(TIFF_LIBS) @@ -345,7 +366,7 @@ AC_DEFUN([SANE_CHECK_LOCKING], fi if test $use_locking = yes ; then INSTALL_LOCKPATH=install-lockpath - AC_DEFINE([ENABLE_LOCKING], 1, + AC_DEFINE([ENABLE_LOCKING], 1, [Define to 1 if device locking should be enabled.]) else INSTALL_LOCKPATH= @@ -375,6 +396,20 @@ AC_DEFUN([JAPHAR_GREP_AM_CFLAGS], esac ]) +dnl +dnl JAPHAR_GREP_AM_CXXFLAGS(flag, cmd_if_missing, cmd_if_present) +dnl +AC_DEFUN([JAPHAR_GREP_AM_CXXFLAGS], +[case "$AM_CXXFLAGS" in +"$1" | "$1 "* | *" $1" | *" $1 "* ) + ifelse($#, 3, [$3], [:]) + ;; +*) + $2 + ;; +esac +]) + dnl dnl SANE_CHECK_U_TYPES dnl @@ -397,13 +432,13 @@ AC_DEFUN([SANE_CHECK_GPHOTO2], [# If --with-gphoto2=no or --without-gphoto2, disable backend # as "$with_gphoto2" will be set to "no"]) - # If --with-gphoto2=yes (or not supplied), first check if + # If --with-gphoto2=yes (or not supplied), first check if # pkg-config exists, then use it to check if libgphoto2 is # present. If all that works, then see if we can actually link - # a program. And, if that works, then add the -l flags to - # GPHOTO2_LIBS and any other flags to GPHOTO2_LDFLAGS to pass to + # a program. And, if that works, then add the -l flags to + # GPHOTO2_LIBS and any other flags to GPHOTO2_LDFLAGS to pass to # sane-config. - if test "$with_gphoto2" != "no" ; then + if test "$with_gphoto2" != "no" ; then AC_CHECK_TOOL(HAVE_GPHOTO2, pkg-config, false) if test ${HAVE_GPHOTO2} != "false" ; then @@ -427,8 +462,8 @@ AC_DEFUN([SANE_CHECK_GPHOTO2], HAVE_GPHOTO2=false fi if test "${HAVE_GPHOTO2}" = "false"; then - GPHOTO2_CPPFLAGS="" - GPHOTO2_LIBS="" + GPHOTO2_CPPFLAGS="" + GPHOTO2_LIBS="" else SANE_EXTRACT_LDFLAGS(GPHOTO2_LIBS, GPHOTO2_LDFLAGS) if pkg-config --atleast-version=2.5.0 libgphoto2; then @@ -448,31 +483,31 @@ AC_DEFUN([SANE_CHECK_GPHOTO2], # Check for ss_family member in struct sockaddr_storage AC_DEFUN([SANE_CHECK_IPV6], [ - AC_MSG_CHECKING([whether to enable IPv6]) - AC_ARG_ENABLE(ipv6, + AC_MSG_CHECKING([whether to enable IPv6]) + AC_ARG_ENABLE(ipv6, AS_HELP_STRING([--disable-ipv6],[disable IPv6 support]), [ if test "$enableval" = "no" ; then - AC_MSG_RESULT([no, manually disabled]) - ipv6=no + AC_MSG_RESULT([no, manually disabled]) + ipv6=no fi ]) if test "$ipv6" != "no" ; then AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ - #define INET6 - #include + #define INET6 + #include #include ]], [[ - /* AF_INET6 available check */ - if (socket(AF_INET6, SOCK_STREAM, 0) < 0) - exit(1); - else - exit(0); + /* AF_INET6 available check */ + if (socket(AF_INET6, SOCK_STREAM, 0) < 0) + exit(1); + else + exit(0); ]])],[ - AC_MSG_RESULT(yes) - AC_DEFINE([ENABLE_IPV6], 1, [Define to 1 if the system supports IPv6]) + AC_MSG_RESULT(yes) + AC_DEFINE([ENABLE_IPV6], 1, [Define to 1 if the system supports IPv6]) ipv6=yes ],[ - AC_MSG_RESULT([no (couldn't compile test program)]) + AC_MSG_RESULT([no (couldn't compile test program)]) ipv6=no ]) fi @@ -507,7 +542,7 @@ AC_DEFUN([SANE_CHECK_IPV6], ipv6=no ]) ]) - fi + fi ]) # @@ -527,14 +562,14 @@ for be in ${BACKENDS}; do case $be in plustek_pp) case "$host_os" in - gnu*) + gnu*) echo "*** $be backend not supported on GNU/Hurd - $DISABLE_MSG" backend_supported="no" ;; esac ;; - dc210|dc240) + dc210|dc240|pixma) if test "${sane_cv_use_libjpeg}" != "yes"; then echo "*** $be backend requires JPEG library - $DISABLE_MSG" backend_supported="no" @@ -548,6 +583,13 @@ for be in ${BACKENDS}; do fi ;; + genesys) + if test "${HAVE_CXX11}" != "1"; then + echo "*** $be backend requires C++11 support - $DISABLE_MSG" + backend_supported="no" + fi + ;; + mustek_pp) if test "${sane_cv_use_libieee1284}" != "yes" && test "${enable_parport_directio}" != "yes"; then echo "*** $be backend requires libieee1284 or parport-directio libraries - $DISABLE_MSG" @@ -555,7 +597,7 @@ for be in ${BACKENDS}; do fi ;; - dell1600n_net) + dell1600n_net) if test "${sane_cv_use_libjpeg}" != "yes" || test "${sane_cv_use_libtiff}" != "yes"; then echo "*** $be backend requires JPEG and TIFF library - $DISABLE_MSG" backend_supported="no" @@ -666,12 +708,6 @@ const char * inet_ntop (int af, const void *src, char *dst, size_t cnt); int inet_pton (int af, const char *src, void *dst); #endif -/* Prototype for isfdtype */ -#ifndef HAVE_ISFDTYPE -#define isfdtype sanei_isfdtype -int isfdtype(int fd, int fdtype); -#endif - /* Prototype for sigprocmask */ #ifndef HAVE_SIGPROCMASK #define sigprocmask sanei_sigprocmask @@ -724,6 +760,4 @@ void vsyslog(int priority, const char *format, va_list args); ]) ]) -m4_include([m4/libtool.m4]) m4_include([m4/byteorder.m4]) -m4_include([m4/stdint.m4]) -- cgit v1.2.3 From ffa8801644a7d53cc1c785e3450f794c07a14eb0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sun, 2 Feb 2020 17:13:01 +0100 Subject: New upstream version 1.0.29 --- acinclude.m4 | 35 ++++++++++++++++++++++++++++------- 1 file changed, 28 insertions(+), 7 deletions(-) (limited to 'acinclude.m4') diff --git a/acinclude.m4 b/acinclude.m4 index 1bc3b74..7c90c64 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -252,21 +252,22 @@ AC_DEFUN([SANE_CHECK_PTHREAD], [Define if pthread_t is integer.]) else # Until the sanei_thread implementation is fixed. - have_pthread=no use_pthread=no fi + if test "$have_pthread" = "yes" ; then + AM_CPPFLAGS="${AM_CPPFLAGS} -D_REENTRANT" + fi + AC_SUBST(PTHREAD_LIBS) + if test $use_pthread = yes ; then AC_DEFINE_UNQUOTED(USE_PTHREAD, "$use_pthread", [Define if pthreads should be used instead of forked processes.]) + SANEI_THREAD_LIBS=$PTHREAD_LIBS else - dnl Reset library in case it was found but we are not going to use it. - PTHREAD_LIBS="" + SANEI_THREAD_LIBS="" fi - if test "$have_pthread" = "yes" ; then - AM_CPPFLAGS="${AM_CPPFLAGS} -D_REENTRANT" - fi - AC_SUBST(PTHREAD_LIBS) + AC_SUBST(SANEI_THREAD_LIBS) AC_MSG_CHECKING([whether to enable pthread support]) AC_MSG_RESULT([$have_pthread]) AC_MSG_CHECKING([whether to use pthread instead of fork]) @@ -611,6 +612,26 @@ for be in ${BACKENDS}; do fi ;; + escl) + if test "x${enable_avahi}" != "xyes"; then + echo "*** $be backend requires AVAHI library - $DISABLE_MSG" + backend_supported="no" + fi + if test "x${with_libcurl}" != "xyes"; then + echo "*** $be backend requires cURL library - $DISABLE_MSG" + backend_supported="no" + fi + if test "x${have_libxml}" != "xyes"; then + echo "*** $be backend requires XML library - $DISABLE_MSG" + backend_supported="no" + fi + # FIXME: Remove when PNG and/or PDF support have been added. + if test "x${sane_cv_use_libjpeg}" != "xyes"; then + echo "*** $be backend currently requires JPEG library - $DISABLE_MSG" + backend_supported="no" + fi + ;; + gphoto2) if test "${HAVE_GPHOTO2}" != "true" \ || test "${sane_cv_use_libjpeg}" != "yes"; then -- cgit v1.2.3