]> Pileus Git - ~andy/gtk/blob - configure.in
59370a7ae95d4ba8ae19954d1d1a26ddb796197e
[~andy/gtk] / configure.in
1 # Process this file with autoconf to produce a configure script.
2 AC_INIT(gdk/gdktypes.h)
3
4 #
5 # For each of the libraries we build, we define the following
6 # substituted variables:
7 #
8 # foo_PACKAGES:     pkg-config packages this library requires
9 # foo_EXTRA_LIBS:   Libraries this module requires not pulled in by pkg-config
10 # foo_EXTRA_CFLAGS: cflags this module requires not pulled in by pkg-config
11 # foo_DEP_LIBS:     All libraries this module requires
12 # foo_DEP_CFLAGS:   All cflags this module requires
13
14
15 ## We could have pkg-config uniquify the ldflags and cflags by calling
16 ## it once with both the GLib and Pango package names, but we don't,
17 ## someone should fix that.
18
19
20 # Save this value here, since automake will set cflags later
21 cflags_set=${CFLAGS+set}
22
23 dnl we to AC_DIVERT_PUSH/AC_DIVERT_POP these variable definitions so they
24 dnl are available for $ac_help expansion (don't we all *love* autoconf?)
25 GLIB_AC_DIVERT_BEFORE_HELP([
26 #
27 # Making releases:
28 #   GTK_MICRO_VERSION += 1;
29 #   GTK_INTERFACE_AGE += 1;
30 #   GTK_BINARY_AGE += 1;
31 # if any functions have been added, set GTK_INTERFACE_AGE to 0.
32 # if backwards compatibility has been broken,
33 # set GTK_BINARY_AGE and GTK_INTERFACE_AGE to 0.
34 #
35 GTK_MAJOR_VERSION=1
36 GTK_MINOR_VERSION=3
37 GTK_MICRO_VERSION=10
38 GTK_INTERFACE_AGE=0
39 GTK_BINARY_AGE=0
40 GTK_VERSION=$GTK_MAJOR_VERSION.$GTK_MINOR_VERSION.$GTK_MICRO_VERSION
41 dnl
42 ])dnl
43
44 AC_SUBST(GTK_MAJOR_VERSION)
45 AC_SUBST(GTK_MINOR_VERSION)
46 AC_SUBST(GTK_MICRO_VERSION)
47 AC_SUBST(GTK_INTERFACE_AGE)
48 AC_SUBST(GTK_BINARY_AGE)
49 AC_SUBST(GTK_VERSION)
50
51 # libtool versioning
52 LT_RELEASE=$GTK_MAJOR_VERSION.$GTK_MINOR_VERSION
53 LT_CURRENT=`expr $GTK_MICRO_VERSION - $GTK_INTERFACE_AGE`
54 LT_REVISION=$GTK_INTERFACE_AGE
55 LT_AGE=`expr $GTK_BINARY_AGE - $GTK_INTERFACE_AGE`
56 AC_SUBST(LT_RELEASE)
57 AC_SUBST(LT_CURRENT)
58 AC_SUBST(LT_REVISION)
59 AC_SUBST(LT_AGE)
60
61 # Define a string for the earliest version that this release has
62 # binary compatibility with. This is used for module locations.
63 #
64 GTK_BINARY_VERSION=$GTK_MAJOR_VERSION.$GTK_MINOR_VERSION.$LT_CURRENT
65 AC_SUBST(GTK_BINARY_VERSION)
66
67 #
68 # gdk-pixbuf gets versioned separately, and for now, using standard
69 # libtool versioning, not GTK+-style versioning
70 #
71 GDK_PIXBUF_MAJOR=$GTK_MAJOR_VERSION
72 GDK_PIXBUF_MINOR=$GTK_MINOR_VERSION
73 GDK_PIXBUF_MICRO=$GTK_MICRO_VERSION
74 GDK_PIXBUF_VERSION="${GDK_PIXBUF_MAJOR}.${GDK_PIXBUF_MINOR}.${GDK_PIXBUF_MICRO}"
75 AC_SUBST(GDK_PIXBUF_MAJOR)
76 AC_SUBST(GDK_PIXBUF_MINOR)
77 AC_SUBST(GDK_PIXBUF_MICRO)
78 AC_SUBST(GDK_PIXBUF_VERSION)
79
80 ## Versions of dependencies
81 GLIB_REQUIRED_VERSION=1.3.10
82 PANGO_REQUIRED_VERSION=0.20
83 ATK_REQUIRED_VERSION=0.5
84
85 # For automake.
86 VERSION=$GTK_VERSION
87 PACKAGE=gtk+
88
89 GETTEXT_PACKAGE=gtk20
90 AC_SUBST(GETTEXT_PACKAGE)
91 AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE")
92
93 # Save this value here, since automake will set cflags later
94 cflags_set=${CFLAGS+set}
95
96 dnl Initialize automake stuff
97 AM_INIT_AUTOMAKE($PACKAGE, $VERSION, no-define)
98
99 # Specify a configuration file
100 AM_CONFIG_HEADER(config.h)
101
102 dnl Initialize libtool
103 AM_PROG_LIBTOOL
104
105 dnl Set AS and ASFLAGS so that automake 1.5 will be happy
106 AS="\${CC}"
107 ASFLAGS="\${CFLAGS}"
108 AC_SUBST(AS)
109 AC_SUBST(ASFLAGS)
110
111 dnl Initialize maintainer mode
112 AM_MAINTAINER_MODE
113
114 AC_CANONICAL_HOST
115
116 dnl figure debugging default, prior to $ac_help setup
117 dnl
118 GLIB_AC_DIVERT_BEFORE_HELP([
119 if test `expr $GTK_MINOR_VERSION \% 2` = 1 ; then
120         debug_default=yes
121 else
122         debug_default=minimum
123 fi
124 ])dnl
125
126 dnl declare --enable-* args and collect ac_help strings
127 AC_ARG_ENABLE(debug, [  --enable-debug=[no/minimum/yes] turn on debugging [default=$debug_default]],,enable_debug=$debug_default)
128 AC_ARG_ENABLE(shm, [  --enable-shm            support shared memory if available [default=yes]],
129                    echo $enable_shm, enable_shm="yes")
130 AC_ARG_ENABLE(ansi, [  --enable-ansi           turn on strict ansi [default=no]],
131                     , enable_ansi=no)
132 AC_ARG_ENABLE(xim, [  --enable-xim            support XIM [default=yes]],
133                         , enable_xim="yes")
134 AC_ARG_ENABLE(xim_inst, [  --disable-xim-inst      does not use xim instantiate callback],
135                         , enable_xim_inst="maybe")
136 AC_ARG_ENABLE(xkb, [  --enable-xkb            support XKB [default=maybe]],
137                         , enable_xkb="maybe")
138 AC_ARG_ENABLE(rebuilds, [  --disable-rebuilds      disable all source autogeneration rules],,enable_rebuilds=yes)
139
140 AC_ARG_WITH(xinput, [  --with-xinput=[no/gxi/xfree] support XInput ])
141
142 gdktarget=x11
143 gdktargetlib=libgdk-x11-1.3.la
144 gtktargetlib=libgtk-x11-1.3.la
145 AC_ARG_WITH(gdktarget, [  --with-gdktarget=[x11/linux-fb] select GDK target [default=x11] ],
146         gdktarget=$with_gdktarget)
147
148 AC_SUBST(gdktarget)
149 case $gdktarget in
150   x11|linux-fb) ;;
151   *) AC_MSG_ERROR([Invalid target for GDK: use x11 or linux-fb.]);;
152 esac
153
154 AC_ARG_ENABLE(shadowfb, [  --disable-shadowfb      disable shadowfb support for linux-fb],,enable_shadowfb=yes)
155
156 AC_ARG_ENABLE(fbmanager, [  --enable-fbmanager      enable framebuffer manager support (GtkFB)],enable_fbmanager=yes,enable_fbmanager=no)
157         
158 if test "x$enable_debug" = "xyes"; then
159   test "$cflags_set" = set || CFLAGS="$CFLAGS -g"
160   GTK_DEBUG_FLAGS="-DG_ENABLE_DEBUG"
161 else
162   if test "x$enable_debug" = "xno"; then
163     GTK_DEBUG_FLAGS="-DG_DISABLE_ASSERT -DG_DISABLE_CHECKS -DG_DISABLE_CAST_CHECKS"
164   else
165     GTK_DEBUG_FLAGS="-DG_DISABLE_CAST_CHECKS"
166   fi
167 fi
168
169 AC_DEFINE_UNQUOTED(GTK_COMPILED_WITH_DEBUGGING, "${enable_debug}")
170
171                         
172 # Build time sanity check...
173 AM_SANITY_CHECK
174
175 # Checks for programs.
176 AC_PROG_CC
177 AC_ISC_POSIX
178 AM_PROG_CC_STDC
179 AC_PROG_INSTALL
180 AC_PROG_MAKE_SET
181
182 changequote(,)dnl
183 if test "x$GCC" = "xyes"; then
184   case " $CFLAGS " in
185   *[\ \ ]-Wall[\ \      ]*) ;;
186   *) CFLAGS="$CFLAGS -Wall" ;;
187   esac
188
189   if test "x$enable_ansi" = "xyes"; then
190     case " $CFLAGS " in
191     *[\ \       ]-ansi[\ \      ]*) ;;
192     *) CFLAGS="$CFLAGS -ansi" ;;
193     esac
194
195     case " $CFLAGS " in
196     *[\ \       ]-pedantic[\ \  ]*) ;;
197     *) CFLAGS="$CFLAGS -pedantic" ;;
198     esac
199   fi
200 fi
201 changequote([,])dnl
202
203 # Honor aclocal flags
204 ACLOCAL="$ACLOCAL $ACLOCAL_FLAGS"
205
206 ## Initial sanity check, done here so that users get told they 
207 ## have the wrong dependencies as early in the process as possible.
208 ## Later on we actually use the cflags/libs from separate pkg-config
209 ## calls. Oh, also the later pkg-config calls don't include 
210 ## the version requirements since those make the module lists 
211 ## annoying to construct
212 PKG_CHECK_MODULES(BASE_DEPENDENCIES, glib-2.0 >= $GLIB_REQUIRED_VERSION atk >= $ATK_REQUIRED_VERSION pango >= $PANGO_REQUIRED_VERSION)
213
214 # libtool option to control which symbols are exported
215 # right now, symbols starting with _ are not exported
216 LIBTOOL_EXPORT_OPTIONS='-export-symbols-regex "^[[^_]].*"'
217 AC_SUBST(LIBTOOL_EXPORT_OPTIONS)
218
219 # define a MAINT-like variable REBUILD which is set if Perl
220 # and awk are found, so autogenerated sources can be rebuilt
221
222 AC_PROG_AWK
223 AC_CHECK_PROGS(PERL, perl5 perl)
224
225 # We would like indent, but don't require it.
226 AC_CHECK_PROG(INDENT, indent, indent)
227
228 REBUILD=\#
229 if test "x$enable_rebuilds" = "xyes" && \
230      test -n "$PERL" && \
231      $PERL -e 'exit !($] >= 5.002)' > /dev/null 2>&1 && \
232      test -n "$AWK" ; then
233   REBUILD=
234 fi
235 AC_SUBST(REBUILD)
236
237 AC_CHECK_FUNCS(lstat mkstemp sigsetjmp bind_textdomain_codeset)
238
239 AC_MSG_CHECKING(whether make is GNU Make)
240 STRIP_BEGIN=
241 STRIP_END=
242 if $ac_make --version 2>/dev/null | grep '^GNU Make ' >/dev/null ; then
243         STRIP_BEGIN='$(strip $(STRIP_DUMMY)'
244         STRIP_END=')'
245         AC_MSG_RESULT(yes)
246 else
247         AC_MSG_RESULT(no)
248 fi
249 STRIP_DUMMY=
250 AC_SUBST(STRIP_DUMMY)
251 AC_SUBST(STRIP_BEGIN)
252 AC_SUBST(STRIP_END)
253
254 # i18n stuff
255 ALL_LINGUAS="az ca cs da de el en_GB en@IPA es et eu fa fi fr ga gl he hr hu ia it ja ko lt nl nn no pl pt pt_BR ro ru sk sl sp sr sv tr uk vi wa zh_TW zh_CN"
256 AM_GLIB_GNU_GETTEXT
257 LIBS="$LIBS $INTLLIBS"
258
259 # AM_GLIB_GNU_GETTEXT above substs $DATADIRNAME
260 # this is the directory where the *.{mo,gmo} files are installed
261 gtklocaledir='${prefix}/${DATADIRNAME}/locale'
262 AC_SUBST(gtklocaledir)
263
264 dnl The DU4 header files don't provide library prototypes unless 
265 dnl -std1 is given to the native cc.
266 AC_MSG_CHECKING([for extra flags to get ANSI library prototypes])
267
268 gtk_save_LIBS=$LIBS
269 LIBS="$LIBS -lm"
270 AC_TRY_RUN([#include <math.h>
271              int main (void) { return (log(1) != log(1.)); }],
272      AC_MSG_RESULT(none needed),
273      gtk_save_CFLAGS="$CFLAGS"
274      CFLAGS="$CFLAGS -std1"
275      AC_TRY_RUN([#include <math.h>
276                  int main (void) { return (log(1) != log(1.)); }],
277          AC_MSG_RESULT(-std1),
278          AC_MSG_RESULT()
279          CFLAGS="$gtk_save_CFLAGS"
280          AC_MSG_WARN(
281                 [No ANSI prototypes found in library. (-std1 didn't work.)]),
282          true
283      ),
284      AC_MSG_RESULT(none needed)
285 )
286 LIBS=$gtk_save_LIBS
287
288 MATH_LIB=-lm
289 AC_MSG_CHECKING(for the BeOS)
290 case $host in
291   *-*-beos*)
292     AC_MSG_RESULT(yes)
293     MATH_LIB=
294   ;;
295   *)
296     AC_MSG_RESULT(no)
297   ;;
298 esac
299
300 dnl NeXTStep cc seems to need this
301 AC_MSG_CHECKING([for extra flags for POSIX compliance])
302 AC_TRY_COMPILE([#include <dirent.h>], [DIR *dir;],
303   AC_MSG_RESULT(none needed),
304   gtk_save_CFLAGS="$CFLAGS"
305   CFLAGS="$CFLAGS -posix"
306   AC_TRY_COMPILE([#include <dirent.h>], [DIR *dir;],
307     AC_MSG_RESULT(-posix),
308     AC_MSG_RESULT()
309     CFLAGS="$gtk_save_CFLAGS"
310     AC_MSG_WARN([Could not determine POSIX flag. (-posix didn't work.)])))
311
312 #
313 # Run AM_PATH_GLIB_2_0 to make sure that GLib is installed and working
314
315
316 GLIB_PACKAGES="gobject-2.0 gmodule-2.0"
317
318 AM_PATH_GLIB_2_0($GLIB_REQUIRED_VERSION, :,
319   AC_MSG_ERROR([
320 *** GLIB $GLIB_REQUIRED_VERSION or better is required. The latest version of 
321 *** GLIB is always available from ftp://ftp.gtk.org/.]),
322   gobject gmodule gthread)
323
324 AC_CHECK_HEADERS(dirent.h, AC_DEFINE(HAVE_DIRENT_H))
325 AC_CHECK_HEADERS(pwd.h, AC_DEFINE(HAVE_PWD_H))
326 AC_CHECK_HEADERS(sys/time.h, AC_DEFINE(HAVE_SYS_TIME_H))
327 AC_CHECK_HEADERS(unistd.h, AC_DEFINE(HAVE_UNISTD_H))
328
329 saved_cflags="$CFLAGS"
330 saved_ldflags="$LDFLAGS"
331
332
333 # Checks for header files.
334 AC_HEADER_STDC
335
336 # Checks for typedefs, structures, and compiler characteristics.
337 AC_C_CONST
338
339 # Checks for library functions.
340 AC_TYPE_SIGNAL
341 AC_FUNC_MMAP
342
343 AC_CHECK_FUNCS(getresuid)
344 AC_TYPE_UID_T
345
346 # Check if <sys/select.h> needs to be included for fd_set
347 AC_MSG_CHECKING([for fd_set])
348 AC_TRY_COMPILE([#include <sys/types.h>],
349         [fd_set readMask, writeMask;], gtk_ok=yes, gtk_ok=no)
350 if test $gtk_ok = yes; then
351     AC_MSG_RESULT([yes, found in sys/types.h])
352 else
353     AC_HEADER_EGREP(fd_mask, sys/select.h, gtk_ok=yes)
354     if test $gtk_ok = yes; then
355         AC_DEFINE(HAVE_SYS_SELECT_H)
356         AC_MSG_RESULT([yes, found in sys/select.h])
357     else
358         AC_DEFINE(NO_FD_SET)
359         AC_MSG_RESULT(no)
360     fi
361 fi
362
363 # `widechar' tests for gdki18n.h
364 AC_MSG_CHECKING(for wchar.h)
365 AC_TRY_CPP([#include <wchar.h>], gdk_wchar_h=yes, gdk_wchar_h=no)
366 if test $gdk_wchar_h = yes; then
367    AC_DEFINE(HAVE_WCHAR_H,1,[Have wchar.h include file])
368 fi
369 AC_MSG_RESULT($gdk_wchar_h)
370
371 # Check for wctype.h (for iswalnum)
372 AC_MSG_CHECKING(for wctype.h)
373 AC_TRY_CPP([#include <wctype.h>], gdk_wctype_h=yes, gdk_wctype_h=no)
374 if test $gdk_wctype_h = yes; then
375    AC_DEFINE(HAVE_WCTYPE_H,1,[Have wctype.h include file])
376 fi
377 AC_MSG_RESULT($gdk_wctype_h)
378
379 # in Solaris 2.5, `iswalnum' is in -lw
380 GDK_WLIBS=
381 AC_CHECK_FUNC(iswalnum,,[AC_CHECK_LIB(w,iswalnum,GDK_WLIBS=-lw)])
382
383 oLIBS="$LIBS"
384 LIBS="$LIBS $GDK_WLIBS"
385 # The following is necessary for Linux libc-5.4.38
386 AC_MSG_CHECKING(if iswalnum() and friends are properly defined)
387 AC_TRY_LINK([#include <stdlib.h>],[
388 #if (defined(HAVE_WCTYPE_H) || defined(HAVE_WCHAR_H))
389 #  ifdef HAVE_WCTYPE_H
390 #    include <wctype.h>
391 #  else
392 #    ifdef HAVE_WCHAR_H
393 #      include <wchar.h>
394 #    endif
395 #  endif
396 #else
397 #  define iswalnum(c) ((wchar_t)(c) <= 0xFF && isalnum(c))
398 #endif
399 iswalnum((wchar_t) 0);
400 ], gdk_working_wctype=yes, gdk_working_wctype=no)
401 LIBS="$oLIBS"
402
403 if test $gdk_working_wctype = no; then
404    AC_DEFINE(HAVE_BROKEN_WCTYPE,1,[Is the wctype implementation broken])
405    GDK_WLIBS=
406 fi
407 AC_MSG_RESULT($gdk_working_wctype)
408 AC_SUBST(GDK_WLIBS)
409
410
411
412 ##################################################
413 # Checks for gdk-pixbuf
414 ##################################################
415
416 AC_MSG_CHECKING(whether to build gmodulized gdk-pixbuf)
417
418 AC_ARG_ENABLE(modules, [  --disable-modules       Disables dynamic module loading],[
419         if test x$withval = xyes; then 
420             with_modules=yes
421         else
422             with_modules=no
423         fi
424 ])
425
426 dynworks=false
427 deps=
428 if test x$with_modules = xno; then
429     AC_MSG_RESULT(no)
430 else
431     AC_MSG_RESULT(yes)
432     AC_MSG_CHECKING(whether dynamic modules work)
433     ## for loop is to strip newline 
434     tmp=`pkg-config --variable=gmodule_supported gmodule-2.0`
435     for I in $tmp; do
436         dynworks=$I
437     done
438 fi
439
440 dnl Now we check to see if our libtool supports shared lib deps
441 dnl (in a rather ugly way even)
442 if $dynworks; then
443    pixbuf_libtool_config="${CONFIG_SHELL-/bin/sh} libtool --config"
444    pixbuf_deplibs_check=`$pixbuf_libtool_config | \
445       grep '^[[a-z_]]*check[[a-z_]]*_method=[['\''"]]' | \
446       sed 's/.*[['\''"]]\(.*\)[['\''"]]$/\1/'`
447    if test "x$pixbuf_deplibs_check" = "xnone" || \
448       test "x$pixbuf_deplibs_check" = "xunknown" || \
449       test "x$pixbuf_deplibs_check" = "x"; then
450       dynworks=false
451    fi
452 fi
453
454 if $dynworks; then
455    AC_DEFINE(USE_GMODULE)
456    AC_MSG_RESULT(yes)
457 else
458    AC_MSG_RESULT(no)
459 fi
460
461 dnl Test for libtiff
462   if test -z "$LIBTIFF"; then
463     AC_CHECK_LIB(tiff, TIFFReadScanline,
464       AC_CHECK_HEADER(tiffio.h,
465         TIFF='tiff'; LIBTIFF='-ltiff',
466         AC_MSG_WARN(*** TIFF loader will not be built (TIFF header files not found) ***)),
467       AC_CHECK_LIB(tiff, TIFFWriteScanline,
468         AC_CHECK_HEADER(tiffio.h,
469           TIFF='tiff'; LIBTIFF='-ltiff -ljpeg -lz',
470           AC_MSG_WARN(*** TIFF loader will not be built (TIFF header files not found) ***)),
471         AC_CHECK_LIB(tiff34, TIFFFlushData,
472           AC_CHECK_HEADER(tiffio.h,
473             TIFF='tiff'; LIBTIFF='-ltiff34 -ljpeg -lz',
474             AC_MSG_WARN(*** TIFF loader will not be built (TIFF header files not found) ***)),
475         AC_MSG_WARN(*** TIFF plug-in will not be built (TIFF library not found) ***), -ljpeg -lz -lm), -ljpeg -lz -lm), -lm)
476   fi
477
478 dnl Test for libjpeg
479   if test -z "$LIBJPEG"; then
480     AC_CHECK_LIB(jpeg, jpeg_destroy_decompress,
481       jpeg_ok=yes,
482       jpeg_ok=no
483       AC_MSG_WARN(*** JPEG loader will not be built (JPEG library not found) ***))
484     if test "$jpeg_ok" = yes; then
485       AC_MSG_CHECKING([for jpeglib.h])
486       AC_TRY_CPP(
487 [#include <stdio.h>
488 #undef PACKAGE
489 #undef VERSION
490 #include <jpeglib.h>],
491         jpeg_ok=yes,
492         jpeg_ok=no)
493       AC_MSG_RESULT($jpeg_ok)
494       if test "$jpeg_ok" = yes; then
495         LIBJPEG='-ljpeg'
496         AC_CHECK_LIB(jpeg, jpeg_simple_progression,     
497           AC_DEFINE(HAVE_PROGRESSIVE_JPEG),
498           AC_MSG_WARN(JPEG library does not support progressive saving.))
499       else
500           AC_MSG_WARN(*** JPEG loader will not be built (JPEG header file not found) ***)
501       fi
502     fi
503   fi
504
505 dnl Test for libpng
506   if test -z "$LIBPNG"; then
507     AC_CHECK_LIB(png, png_read_info,
508       AC_CHECK_HEADER(png.h,
509         png_ok=yes,
510         png_ok=no),
511       AC_MSG_WARN(*** PNG loader will not be built (PNG library not found) ***), -lz -lm)
512     if test "$png_ok" = yes; then
513       AC_MSG_CHECKING([for png_structp in png.h])
514       AC_TRY_COMPILE([#include <png.h>],
515         [png_structp pp; png_infop info; png_colorp cmap; png_create_read_struct;],
516         png_ok=yes,
517         png_ok=no)
518       AC_MSG_RESULT($png_ok)
519       if test "$png_ok" = yes; then
520         PNG='png'; LIBPNG='-lpng -lz'
521       else
522         AC_MSG_WARN(*** PNG loader will not be built (PNG library is too old) ***)
523       fi
524     else
525      AC_MSG_WARN(*** PNG loader will not be built (PNG header file not found) ***)
526     fi
527   fi
528
529 AC_SUBST(LIBTIFF)
530 AC_SUBST(LIBJPEG)
531 AC_SUBST(LIBPNG)
532
533 AM_CONDITIONAL(BUILD_DYNAMIC_MODULES, $dynworks)
534
535 #
536 # Allow building some or all gdk-pixbuf loaders included
537 #
538 AC_MSG_CHECKING(pixbuf loaders to build)
539
540 AC_ARG_WITH(included_loaders, [  --with-included-loaders=LOADER1,LOADER2,... Build the specified loaders into gdk-pixbuf (only used if module loading disabled)])
541
542 if $dynworks; then 
543         :
544 else
545    ## if the option was specified, leave it; otherwise disable included loaders
546    if test x$with_included_loaders = xno; then
547            with_included_loaders=yes
548    fi
549 fi
550
551 all_loaders="png,bmp,wbmp,gif,ico,jpeg,pnm,ras,tiff,xpm,tga"
552 included_loaders=""
553 # If no loaders specified, include all
554 if test "x$with_included_loaders" = xyes ; then
555   included_loaders="$all_loaders"
556 else
557   included_loaders="$with_included_loaders"
558 fi
559
560 AC_MSG_RESULT($included_loaders)
561
562 INCLUDED_LOADER_OBJ=
563 INCLUDED_LOADER_DEFINE=
564
565 IFS="${IFS=     }"; gtk_save_ifs="$IFS"; IFS=","
566 for loader in $included_loaders; do
567  if echo "$all_loaders" | grep "\(^\|\,\)$loader\(\$\|\,\)" > /dev/null; then
568    :
569  else
570    AC_MSG_ERROR([the specified loader $loader does not exist])
571  fi
572
573  INCLUDED_LOADER_OBJ="$INCLUDED_LOADER_OBJ libpixbufloader-static-$loader.la"
574  INCLUDED_LOADER_DEFINE="$INCLUDED_LOADER_DEFINE -DINCLUDE_$loader"
575 done
576 IFS="$gtk_save_ifs"
577 AC_SUBST(INCLUDED_LOADER_OBJ)
578 AC_SUBST(INCLUDED_LOADER_DEFINE)
579
580 AC_HEADER_DIRENT
581 AC_HEADER_SYS_WAIT
582
583 AC_TYPE_SIGNAL
584
585 AM_CONDITIONAL(HAVE_TIFF, test "x$LIBTIFF" != x)
586 AM_CONDITIONAL(HAVE_PNG, test "x$LIBPNG" != x)
587 AM_CONDITIONAL(HAVE_JPEG, test "x$LIBJPEG" != x)
588
589 if $dynworks ; then
590   STATIC_LIB_DEPS=
591   if echo "$included_loaders" | grep "\(^\|\,\)tiff\(\$\|\,\)" > /dev/null; then
592     STATIC_LIB_DEPS="$STATIC_LIB_DEPS $LIBTIFF"
593   fi
594   if echo "$included_loaders" | grep "\(^\|\,\)jpeg\(\$\|\,\)" > /dev/null; then
595     STATIC_LIB_DEPS="$STATIC_LIB_DEPS $LIBJPEG"
596   fi
597   if echo "$included_loaders" | grep "\(^\|\,\)png\(\$\|\,\)" > /dev/null; then
598     STATIC_LIB_DEPS="$STATIC_LIB_DEPS $LIBPNG"
599   fi
600 else
601   STATIC_LIB_DEPS="$LIBTIFF $LIBJPEG $LIBPNG"
602 fi
603
604 # Checks to see if we should compile in MMX support (there will be
605 # a runtime test when the code is actually run to see if it should
606 # be used - this just checks if we can compile it.)
607 #
608 # This code is partially taken from Mesa
609 #
610 AC_MSG_CHECKING(for x86 platform)
611 case $host_cpu in
612   i386|i486|i586|i686|i786|k6|k7)
613         use_x86_asm=yes
614         ;;
615    *)
616         use_x86_asm=no
617 esac
618 AC_MSG_RESULT($use_x86_asm)
619
620 use_mmx_asm=no
621 if test $use_x86_asm = yes; then
622     save_ac_ext=$ac_ext
623     ac_ext=S
624     
625     AC_MSG_CHECKING(compiler support for MMX)
626     cp $srcdir/gdk-pixbuf/pixops/scale_line_22_33_mmx.S conftest.S
627     if AC_TRY_EVAL(ac_compile); then
628         use_mmx_asm=yes
629     fi
630
631     rm -rf conftest*
632
633     ac_ext=$save_ac_ext
634     if test $use_mmx_asm = yes; then
635       AC_DEFINE(USE_MMX)
636       AC_MSG_RESULT(yes)
637     else
638       AC_MSG_RESULT(no)
639     fi
640 fi
641
642 AM_CONDITIONAL(USE_MMX, test x$use_mmx_asm = xyes)
643
644
645 GDK_PIXBUF_PACKAGES="gmodule-2.0 gobject-2.0"
646 GDK_PIXBUF_EXTRA_LIBS="$STATIC_LIB_DEPS $MATH_LIB"
647 GDK_PIXBUF_EXTRA_CFLAGS= 
648 GDK_PIXBUF_DEP_LIBS="`$PKG_CONFIG --libs $GDK_PIXBUF_PACKAGES` $GDK_PIXBUF_EXTRA_LIBS"
649 GDK_PIXBUF_DEP_CFLAGS="`$PKG_CONFIG --cflags $GDK_PIXBUF_PACKAGES` $GDK_PIXBUF_EXTRA_CFLAGS"
650
651 AC_SUBST(GDK_PIXBUF_PACKAGES)
652 AC_SUBST(GDK_PIXBUF_EXTRA_LIBS)
653 AC_SUBST(GDK_PIXBUF_EXTRA_CFLAGS)
654 AC_SUBST(GDK_PIXBUF_DEP_LIBS)
655 AC_SUBST(GDK_PIXBUF_DEP_CFLAGS)
656
657
658 ########################################
659 # Windowing system checks
660 ########################################
661
662 GDK_EXTRA_LIBS=$GDK_WLIBS
663 GDK_EXTRA_CFLAGS= 
664
665 if test "x$gdktarget" = "xx11"; then
666   # We start off with the libraries from Pango
667
668   ## be sure we also have Pango built with xft support
669   if $PKG_CONFIG --exists pangoxft ; then
670     PANGO_PACKAGES="pangox pangoxft"
671     have_xft=true
672     AC_DEFINE(HAVE_XFT)
673   else
674     PANGO_PACKAGES="pangox"
675     have_xft=false
676   fi
677
678   AM_CONDITIONAL(HAVE_XFT, $have_xft)
679
680   x_libs="`$PKG_CONFIG --libs $PANGO_PACKAGES`"
681   x_cflags="`$PKG_CONFIG --cflags $PANGO_PACKAGES`"
682   x_extra_libs=
683
684   ## Strip the .la files
685  
686   x_libs_for_checks=""
687   for I in $x_libs ; do
688     case $I in 
689       *.la) ;;
690       *) x_libs_for_checks="$x_libs_for_checks $I" ;;
691     esac
692   done
693
694   # Sanity check for the X11 library
695   AC_CHECK_LIB(X11, XOpenDisplay, :,
696             AC_MSG_ERROR([*** libX11 not found. Check 'config.log' for more details.]),
697             $x_libs_for_checks)
698
699   if test "x$enable_shm" = "xyes"; then
700     # Check for the Xext library (needed for XShm extention)
701     AC_CHECK_LIB(Xext, XShmAttach,
702         if test -z "`echo $x_libs | grep "\-lXext" 2> /dev/null`"; then
703           x_extra_libs="-lXext"
704         fi,
705         # On AIX, it is in XextSam instead, but we still need -lXext
706         AC_CHECK_LIB(XextSam, XShmAttach, 
707             if test -z "`echo $x_libs | grep "\-lXext" 2> /dev/null`"; then
708                x_extra_libs="-lXextSam -lXext"
709             else
710                x_extra_libs="-lXextSam"
711             fi, , $x_libs_for_checks),
712         $x_libs_for_checks)
713   fi
714
715   GDK_PIXBUF_XLIB_EXTRA_CFLAGS="$x_cflags"
716   # Don't ever pull in the pangoxft libraries for gdk-pixbuf-x11
717   GDK_PIXBUF_XLIB_EXTRA_LIBS="$x_extra_libs `$PKG_CONFIG --libs pangox`"
718
719   # Check for shaped window extension
720
721   AC_CHECK_LIB(Xext, XShapeCombineMask,
722       if test -z "`echo $x_extra_libs $x_libs | grep "\-lXext" 2> /dev/null`"; then
723            x_extra_libs="-lXext $x_extra_libs"
724       fi
725       AC_DEFINE(HAVE_SHAPE_EXT),
726       ,
727       $x_libs_for_checks)
728
729   # Check for XConvertCase (X11R6 specific)
730
731   AC_CHECK_LIB(X11, XConvertCase,
732       AC_DEFINE(HAVE_XCONVERTCASE),
733       ,
734       $x_libs_for_checks)
735
736   # Check for XIM support.
737
738   AC_CHECK_LIB(X11, XUnregisterIMInstantiateCallback,
739             : ,
740             enable_xim_inst="no",
741             $x_libs_for_checks)
742
743   # On Solaris, calling XRegisterIMInstantiateCallback seems to
744   # cause an immediate segfault, so we disable it, unless
745   # the user specifically forces it to be on.
746
747   if test x$enable_xim_inst = xmaybe ; then
748     case host in
749           *-*-solaris*)
750             enable_xim_inst="no"
751             ;;
752           *)
753             enable_xim_inst="yes"
754             ;;
755     esac
756   fi
757
758   if test "x$enable_xim" = "xyes"; then
759     GTK_XIM_FLAGS="-DUSE_XIM"
760     if test "x$enable_xim_inst" = "xyes"; then
761       AC_DEFINE(USE_X11R6_XIM)
762     fi
763   fi
764
765   # Check for XKB support.
766
767   if test "x$enable_xkb" = "xyes"; then
768         AC_MSG_WARN(XKB support explicitly enabled)
769         AC_DEFINE(HAVE_XKB)
770   elif test "x$enable_xkb" = "xmaybe"; then
771         AC_CHECK_LIB(X11, XkbQueryExtension,
772                      AC_DEFINE(HAVE_XKB),
773                      ,
774                      $x_libs_for_checks)
775   else
776         AC_MSG_WARN(XKB support explicitly disabled)
777   fi
778
779   x_cflags="$X_CFLAGS"
780   x_ldflags="$X_LDFLAGS"
781
782   # set up things for XInput
783
784   if test "x$with_xinput" = "xgxi" || test "x$with_xinput" = "xyes"; then
785     AC_DEFINE(XINPUT_GXI)
786     xinput_progs=gxid
787     x_extra_libs="-lXi $x_extra_libs"
788   elif test "x$with_xinput" = "xxfree"; then
789     AC_DEFINE(XINPUT_XFREE)
790     x_extra_libs="-lXi $x_extra_libs"
791   else
792     AC_DEFINE(XINPUT_NONE)
793   fi
794
795   AM_CONDITIONAL(XINPUT_GXI, test x$with_xinput = xgxi)
796   AM_CONDITIONAL(XINPUT_XFREE, test x$with_xinput = xxfree)
797
798   if test "x$enable_shm" = "xyes"; then
799     # Check for shared memory
800     AC_CHECK_HEADER(sys/ipc.h, AC_DEFINE(HAVE_IPC_H), no_sys_ipc=yes)
801     AC_CHECK_HEADER(sys/shm.h, AC_DEFINE(HAVE_SHM_H), no_sys_shm=yes)
802
803     # Check for the X shared memory extension header file
804     have_xshm=no 
805     AC_MSG_CHECKING(X11/extensions/XShm.h)
806     if test "x$no_xext_lib" = "xyes"; then
807       :
808     else
809       gtk_save_CFLAGS="$CFLAGS"
810       CFLAGS="$CFLAGS $x_cflags"
811       AC_TRY_COMPILE([
812 #include <stdlib.h>
813 #include <sys/types.h>
814 #include <sys/ipc.h>
815 #include <sys/shm.h>
816 #include <X11/Xlib.h>
817 #include <X11/Xutil.h>
818 #include <X11/extensions/XShm.h>
819 ], [XShmSegmentInfo *x_shm_info;], have_xshm=yes)
820       CFLAGS="$gtk_save_CFLAGS"
821     fi
822     AC_MSG_RESULT($have_xshm)
823     if test $have_xshm = yes ; then
824       AC_DEFINE(HAVE_XSHM_H)
825     fi
826   fi
827
828   GDK_EXTRA_CFLAGS=
829   GDK_EXTRA_LIBS="$x_extra_libs"
830
831   # these are already defined above
832   #gdktargetlib = "libgdk-x11-1.3.la"
833   #gtktargetlib = "libgtk-x11-1.3.la"
834
835   AM_CONDITIONAL(USE_X11, true)
836 else
837   AM_CONDITIONAL(USE_X11, false)
838 fi
839
840 AC_SUBST(xinput_progs)
841
842 GDK_PIXBUF_XLIB_PACKAGES=
843 GDK_PIXBUF_XLIB_DEP_LIBS="`$PKG_CONFIG --libs $GDK_PIXBUF_PACKAGES $GDK_PIXBUF_XLIB_PACKAGES` $GDK_PIXBUF_XLIB_EXTRA_LIBS $GDK_PIXBUF_EXTRA_LIBS"
844 GDK_PIXBUF_XLIB_DEP_CFLAGS="`$PKG_CONFIG --cflags  $GDK_PIXBUF_PACKAGES $GDK_PIXBUF_XLIB_PACKAGES` $GDK_PIXBUF_EXTRA_CFLAGS $GDK_PIXBUF_XLIB_EXTRA_CFLAGS"
845
846 AC_SUBST(GDK_PIXBUF_XLIB_PACKAGES)
847 AC_SUBST(GDK_PIXBUF_XLIB_EXTRA_LIBS)
848 AC_SUBST(GDK_PIXBUF_XLIB_EXTRA_CFLAGS)
849 AC_SUBST(GDK_PIXBUF_XLIB_DEP_LIBS)
850 AC_SUBST(GDK_PIXBUF_XLIB_DEP_CFLAGS)
851
852 if test "x$gdktarget" = "xlinux-fb"; then
853   gdktargetlib="libgdk-linux-fb-1.3.la"
854   gtktargetlib="libgtk-linux-fb-1.3.la"
855
856   AC_PATH_PROG(FREETYPE_CONFIG, freetype-config, no)
857   if test x$FREETYPE_CONFIG = xno ; then
858     AC_MSG_ERROR([*** freetype-config not found])
859   fi
860
861   FREETYPE_CFLAGS="`$FREETYPE_CONFIG --cflags`"
862   FREETYPE_LIBS="`$FREETYPE_CONFIG --libs`"
863   CFLAGS="$CFLAGS $FREETYPE_CFLAGS"
864
865   if test x$enable_shadowfb = xyes ; then
866     AC_DEFINE(ENABLE_SHADOW_FB)
867   fi
868
869   if test x$enable_fbmanager = xyes ; then
870     AC_DEFINE(ENABLE_FB_MANAGER)
871     AM_CONDITIONAL(ENABLE_FB_MANAGER, true)
872   else
873     AM_CONDITIONAL(ENABLE_FB_MANAGER, false)
874   fi
875   
876   GDK_EXTRA_CFLAGS="$FREETYPE_CFLAGS"
877   GDK_EXTRA_LIBS="$FREETYPE_LIBS $GDK_EXTRA_LIBS"
878
879   AM_CONDITIONAL(USE_LINUX_FB, true)
880 else
881   AM_CONDITIONAL(USE_LINUX_FB, false)
882   AM_CONDITIONAL(ENABLE_FB_MANAGER, false)
883 fi
884
885 AC_SUBST(gdktargetlib)
886 AC_SUBST(gtktargetlib)
887
888 #
889 # Pick correct Pango packages to use
890 #
891
892 if test "x$gdktarget" = "xx11"; then
893         if $have_xft = true ; then
894             PANGO_PACKAGES="pangox pangoxft"
895         else
896             PANGO_PACKAGES=pangox
897         fi
898 elif test "x$gdktarget" = "xlinux-fb"; then
899         PANGO_PACKAGES=pangoft2
900 else
901         PANGO_PACKAGES=pango
902 fi
903
904 # Check for Pango flags
905
906 AC_MSG_CHECKING(Pango flags)
907 if $PKG_CONFIG --exists $PANGO_PACKAGES ; then
908         PANGO_CFLAGS=`$PKG_CONFIG --cflags $PANGO_PACKAGES`
909         PANGO_LIBS=`$PKG_CONFIG --libs $PANGO_PACKAGES`
910
911         AC_MSG_RESULT($PANGO_CFLAGS $PANGO_LIBS)
912 else
913         AC_MSG_ERROR([
914 *** Pango not found. Pango is required to build GTK+.
915 *** See http://www.pango.org for Pango information.
916 *** For the framebuffer target, you will need to build 
917 *** Pango with freetype support.
918 ])
919 fi
920
921 CFLAGS="$CFLAGS $PANGO_CFLAGS"
922
923 if $PKG_CONFIG --uninstalled $PANGO_PACKAGES; then
924         :
925 else
926         AC_CHECK_LIB(pango, pango_context_new, :, AC_MSG_ERROR([
927 *** Can't link to Pango. Pango is required to build
928 *** GTK+. For more information see http://www.pango.org]), $PANGO_LIBS)
929 fi
930
931 CFLAGS="$saved_cflags"
932 LDFLAGS="$saved_ldflags"
933
934 GDK_PACKAGES=$PANGO_PACKAGES
935 GDK_DEP_LIBS="$GDK_EXTRA_LIBS `$PKG_CONFIG --libs $GDK_PIXBUF_PACKAGES $GDK_PACKAGES` $GDK_PIXBUF_EXTRA_LIBS"
936 GDK_DEP_CFLAGS="`$PKG_CONFIG --cflags $GDK_PIXBUF_PACKAGES $GDK_PACKAGES` $GDK_PIXBUF_EXTRA_CFLAGS $GDK_EXTRA_CFLAGS"
937
938 AC_SUBST(GDK_PACKAGES)
939 AC_SUBST(GDK_EXTRA_LIBS)
940 AC_SUBST(GDK_EXTRA_CFLAGS)
941 AC_SUBST(GDK_DEP_LIBS)
942 AC_SUBST(GDK_DEP_CFLAGS)
943
944
945 ########################################
946 # Check for Accessibility Toolkit flags
947 ########################################
948
949 ATK_PACKAGES=atk
950 AC_MSG_CHECKING(ATK flags)
951 if $PKG_CONFIG --exists $ATK_PACKAGES ; then
952         ATK_CFLAGS=`$PKG_CONFIG --cflags $ATK_PACKAGES`
953         ATK_LIBS=`$PKG_CONFIG --libs $ATK_PACKAGES`
954
955         AC_MSG_RESULT($ATK_CFLAGS $ATK_LIBS)
956 else
957         AC_MSG_ERROR([
958 *** Accessibility Toolkit not found. Accessibility Toolkit is required
959 *** to build GTK+.
960 ])
961 fi
962
963 if $PKG_CONFIG --uninstalled $ATK_PACKAGES; then
964         :
965 else
966         AC_CHECK_LIB(atk, atk_object_get_type, : , AC_MSG_ERROR([
967                 *** Cannot link to Accessibility Toolkit. Accessibility Toolkit is required
968                 *** to build GTK+]), $ATK_LIBS $GLIB_LIBS)
969 fi
970
971 GTK_PACKAGES=atk
972 GTK_EXTRA_LIBS=
973 GTK_EXTRA_CFLAGS= 
974 GTK_DEP_LIBS="$GDK_EXTRA_LIBS `$PKG_CONFIG --libs $GTK_PIXBUF_PACKAGES $GDK_PACKAGES $GTK_PACKAGES` $GTK_EXTRA_LIBS $GDK_PIXBUF_EXTRA_LIBS"
975 GTK_DEP_CFLAGS="`$PKG_CONFIG --cflags  $GTK_PIXBUF_PACKAGES $GDK_PACKAGES $GTK_PACKAGES` $GDK_PIXBUF_EXTRA_CFLAGS $GDK_EXTRA_CFLAGS $GTK_EXTRA_CFLAGS"
976
977 AC_SUBST(GTK_PACKAGES)
978 AC_SUBST(GTK_EXTRA_LIBS)
979 AC_SUBST(GTK_EXTRA_CFLAGS)
980 AC_SUBST(GTK_DEP_LIBS)
981 AC_SUBST(GTK_DEP_CFLAGS)
982
983
984 AC_SUBST(GTK_DEBUG_FLAGS)
985 AC_SUBST(GTK_XIM_FLAGS)
986
987 ##################################################
988 # Checks for gtk-doc and docbook-tools
989 ##################################################
990
991 AC_ARG_WITH(html-dir, [  --with-html-dir=PATH    path to installed docs ])
992
993 if test "x$with_html_dir" = "x" ; then
994   HTML_DIR='${datadir}/gtk-doc/html'
995 else
996   HTML_DIR=$with_html_dir
997 fi
998
999 AC_SUBST(HTML_DIR)
1000
1001 AC_CHECK_PROG(GTKDOC, gtkdoc-mkdb, true, false)
1002
1003 gtk_doc_min_version=0.6
1004 if $GTKDOC ; then 
1005     gtk_doc_version=`gtkdoc-mkdb --version`
1006     AC_MSG_CHECKING([gtk-doc version ($gtk_doc_version) >= $gtk_doc_min_version])
1007     if perl <<EOF ; then
1008       exit (("$gtk_doc_version" =~ /^[[0-9]]+\.[[0-9]]+$/) &&
1009             ("$gtk_doc_version" >= "$gtk_doc_min_version") ? 0 : 1);
1010 EOF
1011       AC_MSG_RESULT(yes)
1012    else
1013       AC_MSG_RESULT(no)
1014       GTKDOC=false
1015    fi
1016 fi
1017
1018 AC_CHECK_PROG(DB2HTML, db2html, true, false)
1019 AM_CONDITIONAL(HAVE_DOCBOOK, $DB2HTML)
1020
1021 dnl Let people disable the gtk-doc stuff.
1022 AC_ARG_ENABLE(gtk-doc, [  --enable-gtk-doc        Use gtk-doc to build documentation [default=auto]], enable_gtk_doc="$enableval", enable_gtk_doc=auto)
1023
1024 if test x$enable_gtk_doc = xauto ; then
1025   if test x$GTKDOC = xtrue ; then
1026     enable_gtk_doc=yes
1027   else
1028     enable_gtk_doc=no 
1029   fi
1030 fi
1031
1032 dnl NOTE: We need to use a separate automake conditional for this
1033 dnl       to make this work with the tarballs.
1034 AM_CONDITIONAL(ENABLE_GTK_DOC, test x$enable_gtk_doc = xyes)
1035
1036
1037 ##################################################
1038 # Output commands
1039 ##################################################
1040
1041 AC_OUTPUT_COMMANDS([
1042
1043 ## Generate `gdk/gdkconfig.h' in two cases
1044 ## 1. `config.status' is run either explicitly, or via configure.
1045 ##     Esp. not when it is run in `Makefile' to generate makefiles and
1046 ##     config.h
1047 ## 2. CONFIG_OTHER is set explicitly
1048 ##
1049 ## Case 1 is difficult.  We know that `automake' sets one of
1050 ## CONFIG_FILES or CONFIG_HEADERS to empty.  This heuristic works
1051 ## only when AM_CONFIG_HEADER is set, however.
1052
1053 if test -n "${CONFIG_FILES}" && test -n "${CONFIG_HEADERS}"; then
1054   # Both CONFIG_FILES and CONFIG_HEADERS are non-empty ==> Case 1
1055   CONFIG_OTHER=${CONFIG_OTHER:-gdk/gdkconfig.h}
1056 fi
1057 case "$CONFIG_OTHER" in
1058 *gdk/gdkconfig.h*)
1059         echo creating gdk/gdkconfig.h
1060         outfile=gdkconfig.h-tmp
1061         cat > $outfile <<\_______EOF
1062 /* gdkconfig.h
1063  *
1064  * This is a generated file.  Please modify `configure.in'
1065  */
1066
1067 #ifndef GDKCONFIG_H
1068 #define GDKCONFIG_H
1069
1070 #ifdef __cplusplus
1071 extern "C" {
1072 #endif /* __cplusplus */
1073
1074 _______EOF
1075
1076         cat >>$outfile <<_______EOF
1077 $gdk_windowing
1078 $gdk_wc
1079 _______EOF
1080
1081         cat >>$outfile <<_______EOF
1082
1083 #ifdef __cplusplus
1084 }
1085 #endif /* __cplusplus */
1086
1087 #endif /* GDKCONFIG_H */
1088 _______EOF
1089
1090
1091         if cmp -s $outfile gdk/gdkconfig.h; then
1092           echo gdk/gdkconfig.h is unchanged
1093           rm -f $outfile
1094         else
1095           mv $outfile gdk/gdkconfig.h
1096         fi ;;
1097 esac
1098 ],[
1099 if test "x$gdktarget" = "xx11" ; then
1100   gdk_windowing='
1101 #define GDK_WINDOWING_X11'
1102 elif test "x$gdktarget" = "xlinux-fb" ; then
1103   gdk_windowing='
1104 #define GDK_WINDOWING_FB
1105 #define GDK_NATIVE_WINDOW_POINTER'
1106 fi
1107
1108 if test x$gdk_wchar_h = xyes; then
1109   gdk_wc='
1110 #define GDK_HAVE_WCHAR_H 1'
1111 fi
1112 if test x$gdk_wctype_h = xyes; then
1113   gdk_wc="\$gdk_wc
1114 #define GDK_HAVE_WCTYPE_H 1"
1115 fi
1116 if test x$gdk_working_wctype = xno; then
1117   gdk_wc="\$gdk_wc
1118 #define GDK_HAVE_BROKEN_WCTYPE 1"
1119 fi
1120
1121
1122 ])
1123
1124 AC_PATH_PROG(SGML2HTML, sgml2html, no)
1125 AM_CONDITIONAL(HAVE_SGML2HTML, ! test x$SGML2HTML = xno)
1126
1127 AC_OUTPUT([
1128 config.h.win32
1129 gtk+.spec
1130 Makefile
1131 gdk-pixbuf-2.0.pc
1132 gdk-2.0.pc
1133 gtk+-2.0.pc
1134 gdk-pixbuf-2.0-uninstalled.pc
1135 gdk-2.0-uninstalled.pc
1136 gtk+-2.0-uninstalled.pc
1137 m4macros/Makefile
1138 po/Makefile.in
1139 build/Makefile
1140 build/win32/Makefile
1141 build/win32/dirent/Makefile
1142 demos/Makefile
1143 demos/gtk-demo/Makefile
1144 tests/Makefile
1145 docs/Makefile
1146 docs/reference/Makefile
1147 docs/reference/gdk-pixbuf/Makefile
1148 docs/reference/gdk/Makefile
1149 docs/reference/gtk/Makefile
1150 docs/faq/Makefile
1151 docs/tutorial/Makefile
1152 gdk-pixbuf/Makefile
1153 gdk-pixbuf/makefile.mingw
1154 gdk-pixbuf/gdk-pixbuf-features.h
1155 gdk-pixbuf/pixops/Makefile
1156 gdk-pixbuf/pixops/makefile.mingw
1157 gdk/Makefile
1158 gdk/makefile.mingw
1159 gdk/x11/Makefile
1160 gdk/win32/Makefile
1161 gdk/win32/makefile.mingw
1162 gdk/win32/rc/Makefile
1163 gdk/win32/rc/gdk.rc
1164 gdk/linux-fb/Makefile
1165 gtk/Makefile
1166 gtk/makefile.mingw
1167 gtk/makefile.msc
1168 gtk/gtkversion.h
1169 gtk/gtk-win32.rc
1170 gtk/stock-icons/Makefile
1171 modules/Makefile
1172 modules/input/Makefile
1173 contrib/Makefile
1174 contrib/gdk-pixbuf-xlib/Makefile
1175 contrib/gdk-pixbuf-xlib/gdk-pixbuf-xlib-2.0.pc
1176 ])