1 # configure script for pywebkitgtk
3 # Version numbers. This follows the upstream WebKit versioning
4 # If there is a discrepancy, please file a defect report against pywebkitgtk
5 m4_define([pywebkitgtk_major_version], [1])
6 m4_define([pywebkitgtk_minor_version], [0])
7 m4_define([pywebkitgtk_micro_version], [2])
9 # Set some build info. Right now it's a string and datetime
10 # format: snapshot-yymmdd
11 m4_define(pywebkitgtk_build_info, [080812])
13 m4_define([pywebkitgtk_version],
14 [pywebkitgtk_major_version.pywebkitgtk_minor_version.pywebkitgtk_micro_version.pywebkitgtk_build_info])
16 AC_INIT([pywebkitgtk],
17 [pywebkitgtk_version],
18 [http://code.google.com/p/pywebkitgtk/issues])
21 AC_CONFIG_MACRO_DIR([m4])
22 AC_SUBST(ACLOCAL_AMFLAGS, "-I m4 -I .")
24 AC_CONFIG_SRCDIR([configure.ac])
25 AC_CONFIG_HEADERS([config.h])
27 AC_DEFINE_UNQUOTED(PYWEBKITGTK_VERSION, pywebkitgtk_version,
28 [The release version of Python WebKit Gtk+])
29 AC_DEFINE_UNQUOTED(PYWEBKITGTK_MAJOR_VERSION, pywebkitgtk_major_version,
30 [The major version of Python WebKit Gtk+.])
31 AC_DEFINE_UNQUOTED(PYWEBKITGTK_MINOR_VERSION, pywebkitgtk_minor_version,
32 [The minor version of Python WebKit Gtk+.])
33 AC_DEFINE_UNQUOTED(PYWEBKITGTK_MICRO_VERSION, pywebkitgtk_micro_version,
34 [The micro version of Python WebKit Gtk+.])
36 AM_INIT_AUTOMAKE([foreign subdir-objects])
43 AM_CHECK_PYTHON_HEADERS(,[AC_MSG_ERROR(could not find Python headers)])
44 py_prefix=`$PYTHON -c "import sys; print sys.prefix"`
45 PYTHON_INCLUDES="-I${py_prefix}/include/python${PYTHON_VERSION}"
47 dnl from pygtk: get rid of -export-dynamic stuff from the configure flags...
48 export_dynamic=`(./libtool --config; echo eval echo \\$export_dynamic_flag_spec) | sh`
50 dnl check for dependencies
51 dnl Check for libxslt until upstream WebKit checks for it as this is a webkit
52 dnl dep and not pywebkitgtk's.
53 PKG_CHECK_MODULES(DEPS,
59 AC_SUBST(DEPS_CPPFLAGS)
62 AC_PATH_PROG(PYGTK_CODEGEN, pygtk-codegen-2.0, no)
63 if test "x$PYGTK_CODEGEN" = xno; then
64 AC_MSG_ERROR(could not find pygtk-codegen-2.0 script)
67 dnl check for pygtk defsdir
68 AC_MSG_CHECKING(for pygtk defs)
69 PYGTK_DEFSDIR=`$PKG_CONFIG --variable=defsdir pygtk-2.0`
70 AC_SUBST(PYGTK_DEFSDIR)
71 AC_MSG_RESULT($PYGTK_DEFSDIR)
76 pywebkitgtk-1.0.pc:pywebkitgtk.pc.in