1 AC_INIT(cairomm/cairomm.h)
4 GENERIC_MAJOR_VERSION=1
5 GENERIC_MINOR_VERSION=2
6 GENERIC_MICRO_VERSION=4
7 GENERIC_VERSION=$GENERIC_MAJOR_VERSION.$GENERIC_MINOR_VERSION.$GENERIC_MICRO_VERSION
8 AC_SUBST(GENERIC_MAJOR_VERSION)
9 AC_SUBST(GENERIC_MINOR_VERSION)
10 AC_SUBST(GENERIC_MICRO_VERSION)
11 AC_SUBST(GENERIC_VERSION)
13 #shared library versioning
14 GENERIC_LIBRARY_VERSION=1:0:0
18 # current:revision:age
20 # | | +- increment if interfaces have been added
21 # | | set to zero if interfaces have been removed
23 # | +- increment if source code has changed
24 # | set to zero if current is incremented
25 # +- increment if interfaces have been added, removed or changed
26 AC_SUBST(GENERIC_LIBRARY_VERSION)
29 VERSION=$GENERIC_VERSION
32 AM_INIT_AUTOMAKE(cairomm, $GENERIC_VERSION)
41 dnl Used for enabling the "-no-undefined" and "-export-all-symbols" flags
42 dnl while generating DLLs. Borrowed from the official gtk+-2 configure.in
43 AC_MSG_CHECKING([for some Win32 platform])
45 *-*-mingw*|*-*-cygwin*)
52 AC_MSG_RESULT([$platform_win32])
53 AM_CONDITIONAL(PLATFORM_WIN32, test "$platform_win32" = "yes")
55 # Ensure MSVC-compatible struct packing convention is used when
56 # compiling for Win32 with gcc.
57 # What flag to depends on gcc version: gcc3 uses "-mms-bitfields", while
58 # gcc2 uses "-fnative-struct".
59 if test x"$platform_win32" = xyes; then
60 if test x"$GCC" = xyes; then
62 AC_MSG_CHECKING([how to get MSVC-compatible struct packing])
63 if test -z "$ac_cv_prog_CC"; then
66 our_gcc="$ac_cv_prog_CC"
68 case `$our_gcc --version | sed -e 's,\..*,.,' -e q` in
70 if $our_gcc -v --help 2>/dev/null | grep fnative-struct >/dev/null; then
71 msnative_struct='-fnative-struct'
75 if $our_gcc -v --help 2>/dev/null | grep ms-bitfields >/dev/null; then
76 msnative_struct='-mms-bitfields'
80 if test x"$msnative_struct" = x ; then
81 AC_MSG_RESULT([no way])
82 AC_MSG_WARN([produced libraries might be incompatible with MSVC-compiled code])
84 CXXFLAGS="$CXXFLAGS $msnative_struct"
85 AC_MSG_RESULT([${msnative_struct}])
90 AC_CHECK_HEADERS(string list map, , exit)
92 PKG_CHECK_MODULES(CAIROMM, cairo >= 1.2.0)
95 dnl Check whether to build the documentation directory
96 DOCS_SUBDIR="" dnl set DOCS_SUBDIR initially blank
97 AC_ARG_ENABLE(docs, [AC_HELP_STRING([--enable-docs],
98 [build the included docs [default=yes]])],,
100 if test "x$enable_docs" = "xyes"; then
101 dnl check if doxygen is installed
102 AC_CHECK_PROGS(DOXYGEN, [doxygen], no)
103 if test x$DOXYGEN = xno; then
104 AC_MSG_WARN([Doxygen not found, documentation will not be rebuilt])
106 dnl check if graphviz / dot is installed (used by doxygen)
107 AC_CHECK_PROGS(DOT, [dot], no)
108 if test x$DOT = xno; then
109 AC_MSG_WARN([graphviz / dot not found, documentation graphs will not be rebuilt])
116 docs/reference/Makefile
117 docs/reference/Doxyfile
120 AC_SUBST(DOCS_SUBDIR)
128 examples/png_file/Makefile
129 examples/pdf-surface/Makefile
130 examples/ps-surface/Makefile
131 examples/svg-surface/Makefile
132 examples/text-rotate/Makefile
140 MSVC/cairomm/Makefile
141 MSVC/cairomm/cairomm.rc
142 MSVC/examples/Makefile
143 MSVC/examples/pdf-surface/Makefile
144 MSVC/examples/png_file/Makefile
145 MSVC/examples/ps-surface/Makefile
146 MSVC/examples/svg-surface/Makefile
147 MSVC/examples/text-rotate/Makefile