1 dnl Process this file with autoconf to create configure.
7 [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
10 AM_INIT_AUTOMAKE([foreign dist-bzip2])
12 AM_CONFIG_HEADER(config.h)
14 # Require xorg-macros minimum of 1.10 for HAVE_STYLESHEETS in XORG_CHECK_SGML_DOCTOOLS
15 m4_ifndef([XORG_MACROS_VERSION],
16 [m4_fatal([must install xorg-macros 1.10 or later before running autoconf/autogen])])
17 XORG_MACROS_VERSION(1.10)
25 # Need to call this explicitly since the first call to PKG_CHECK_MODULES
26 # is in an if statement, and later calls would break if it's skipped.
31 XORG_WITH_XMLTO(0.0.20)
33 XORG_CHECK_SGML_DOCTOOLS(1.5)
36 # fix libtool to set SONAME to libXaw.so.$major
38 AC_CONFIG_COMMANDS([libtool_hack], [
39 cp -f libtool libtool_
40 test -z "$SED" && SED=sed
41 $SED '1,/^soname_spec/{
43 # X.Org hack to match monolithic Xaw SONAME\
44 xorglibxawname="libXaw"
45 /^soname_spec/s/libname/xorglibxawname/
50 # OSX/Win32 rules are different.
65 AM_CONDITIONAL(PLATFORM_WIN32, test "x$platform_win32" = "xyes")
66 AM_CONDITIONAL(PLATFORM_DARWIN, test "x$platform_darwin" = "xyes")
68 # Whether to build Xaw6
70 AC_ARG_ENABLE(xaw6, AC_HELP_STRING([--disable-xaw6],
71 [Disable building of libXaw.so.6]),
72 [build_v6=$enableval], [build_v6=yes])
74 if test "x$build_v6" = xyes; then
75 PKG_CHECK_MODULES(XAW6, xproto x11 xext xextproto xt xmu)
81 # Whether to build Xaw7
83 AC_ARG_ENABLE(xaw7, AC_HELP_STRING([--disable-xaw7],
84 [Disable building of libXaw.so.7]),
85 [build_v7=$enableval], [build_v7=yes])
87 if test "x$build_v7" = xyes; then
88 PKG_CHECK_MODULES(XAW7, xproto x11 xext xextproto xt xmu xpm)
94 AM_CONDITIONAL(BUILD_XAW6, [test x$build_v6 = xyes])
95 AM_CONDITIONAL(BUILD_XAW7, [test x$build_v7 = xyes])
97 # Checks for header files.
99 AC_CHECK_HEADER(wctype.h,
100 AC_DEFINE([HAS_WCTYPE_H],1,
101 [Define to 1 if you have the <wctype.h> header file.]))
102 AC_CHECK_HEADER(wchar.h,
103 AC_DEFINE([HAS_WCHAR_H],1,
104 [Define to 1 if you have the <wchar.h> header file.]))
105 AC_CHECK_HEADER(widec.h, [],
106 AC_DEFINE([NO_WIDEC_H],1,
107 [Define to 1 if you DO NOT have the <widec.h> header file.]))
109 # Checks for functions
110 AC_CHECK_FUNCS([iswalnum])
118 if test "x$build_v6" = xyes; then
122 if test "x$build_v7" = xyes; then