From fc792709a9c0fabc4edd3778d5d076b0d7b77186 Mon Sep 17 00:00:00 2001 From: Marc Kleine-Budde Date: Sun, 8 Mar 2009 14:30:27 +0100 Subject: [PATCH] use AC_CHECK_HEADER to find headers The original m4/libjpeg.m4 used AC_FIND_FILE to look for jpeg header file. This test is not cross-compiling save. This patch uses the autoconf function AC_CHECK_HEADER to look for the jpeg header, which works in the native and the cross compiling scenaria. Signed-off-by: Marc Kleine-Budde --- m4/libjpeg.m4 | 3 +-- 1 files changed, 1 insertions(+), 2 deletions(-) diff --git a/m4/libjpeg.m4 b/m4/libjpeg.m4 index 580dd78..505abc2 100644 --- a/m4/libjpeg.m4 +++ b/m4/libjpeg.m4 @@ -68,8 +68,7 @@ KDE_FIND_JPEG_HELPER(6b, 6b, dnl then search the headers (can't use simply AC_TRY_xxx, as jpeglib.h dnl requires system dependent includes loaded before it) -jpeg_incdirs="`eval echo $includedir` /usr/include /usr/local/include /mingw/include" -AC_FIND_FILE(jpeglib.h, $jpeg_incdirs, jpeg_incdir) +AC_CHECK_HEADER([jpeglib.h], [jpeg_incdir=yes], [jpeg_incdir=NO]) test "x$jpeg_incdir" = xNO && jpeg_incdir= dnl if headers _and_ libraries are missing, this is no error, and we -- 1.5.6.3