* configure.ac: Fix jpeg version check to work with gcc >= 5.

This commit is contained in:
Andreas Schwab 2015-03-23 11:55:24 +01:00
parent 90b46f5b54
commit ff3878d749
2 changed files with 15 additions and 7 deletions

View file

@ -1,3 +1,7 @@
2015-03-23 Andreas Schwab <schwab@suse.de>
* configure.ac: Fix jpeg version check to work with gcc >= 5.
2015-01-20 Eli Zaretskii <eliz@gnu.org> 2015-01-20 Eli Zaretskii <eliz@gnu.org>
* configure.ac (HAVE_W32): Abort with error message if * configure.ac (HAVE_W32): Abort with error message if

View file

@ -3075,9 +3075,11 @@ if test "${opsys}" = "mingw32"; then
AH_TEMPLATE(HAVE_JPEG, [Define to 1 if you have the jpeg library (-ljpeg).])dnl AH_TEMPLATE(HAVE_JPEG, [Define to 1 if you have the jpeg library (-ljpeg).])dnl
if test "${HAVE_JPEG}" = "yes"; then if test "${HAVE_JPEG}" = "yes"; then
AC_DEFINE(HAVE_JPEG) AC_DEFINE(HAVE_JPEG)
AC_EGREP_CPP([version= *(6[2-9]|[7-9][0-9])], AC_EGREP_CPP([version 6b or later],
[#include <jpeglib.h> [#include <jpeglib.h>
version=JPEG_LIB_VERSION #if JPEG_LIB_VERSION >= 62
version 6b or later
#endif
], ],
[AC_DEFINE(HAVE_JPEG)], [AC_DEFINE(HAVE_JPEG)],
[AC_MSG_WARN([libjpeg found, but not version 6b or later]) [AC_MSG_WARN([libjpeg found, but not version 6b or later])
@ -3094,9 +3096,11 @@ elif test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
AH_TEMPLATE(HAVE_JPEG, [Define to 1 if you have the jpeg library (-ljpeg).])dnl AH_TEMPLATE(HAVE_JPEG, [Define to 1 if you have the jpeg library (-ljpeg).])dnl
if test "${HAVE_JPEG}" = "yes"; then if test "${HAVE_JPEG}" = "yes"; then
AC_DEFINE(HAVE_JPEG) AC_DEFINE(HAVE_JPEG)
AC_EGREP_CPP([version= *(6[2-9]|[7-9][0-9])], AC_EGREP_CPP([version 6b or later],
[#include <jpeglib.h> [#include <jpeglib.h>
version=JPEG_LIB_VERSION #if JPEG_LIB_VERSION >= 62
version 6b or later
#endif
], ],
[AC_DEFINE(HAVE_JPEG)], [AC_DEFINE(HAVE_JPEG)],
[AC_MSG_WARN([libjpeg found, but not version 6b or later]) [AC_MSG_WARN([libjpeg found, but not version 6b or later])