1 --- libgsf-1.14.10.orig/configure.in 2008-10-19 13:37:35.000000000 +0100
2 +++ libgsf-1.14.10.mingw/configure.in 2008-11-22 17:04:10.000000000 +0000
6 if test "x$test_bz2" = xtrue ; then
7 - AC_CHECK_LIB(bz2, BZ2_bzDecompressInit,
10 - AC_MSG_WARN(*** BZ2 support disabled (BZ2 library not found) ***))
12 - if test "$bz2_ok" = yes; then
13 - AC_MSG_CHECKING([for bzlib.h])
16 + dnl AC_CHECK_LIB doesn't work with the Windows port of libbz2 because
17 + dnl it uses the __stdcall calling convention where the callee cleans
18 + dnl up the stack. You have to include <bzlib.h> in order to get the
19 + dnl right calling convention, and the link fails if not. Since we
20 + dnl require both -lbz2 and <bzlib.h>, just test if a program which
21 + dnl uses both can be compiled.
30 - #undef HAVE_STDLIB_H
31 - #include <bzlib.h>]])],
34 - AC_MSG_RESULT($bz2_ok)
38 + #undef HAVE_STDLIB_H
42 + return BZ2_bzDecompressInit (NULL, 0, 0);
49 if test "$bz2_ok" = yes; then
50 AC_DEFINE(HAVE_BZ2, 1, [Is bzip2 available and enabled])
53 - AC_MSG_WARN(*** BZ2 support disabled (BZ2 header not found) ***)
54 + AC_MSG_WARN(*** BZ2 support disabled (BZ2 header or library not found) ***)
57 AC_MSG_WARN([BZ2 support disabled, as requested (Use --with-bz2 to enable)])