3
AC_INIT([gnome-menus], [2.30.3],
4
[http://bugzilla.gnome.org/enter_bug.cgi?product=gnome-menus])
5
AC_CONFIG_SRCDIR(libmenu/gmenu-tree.h)
7
AM_INIT_AUTOMAKE([1.9 foreign no-dist-gzip dist-bzip2])
8
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
9
AC_CONFIG_MACRO_DIR([m4])
10
AM_CONFIG_HEADER(config.h)
13
GNOME_MAINTAINER_MODE_DEFINES
15
# Before making a release, the LT_VERSION string should be modified.
16
# The string is of the form C:R:A.
17
# - If interfaces have been changed or added, but binary compatibility has
18
# been preserved, change to C+1:0:A+1
19
# - If binary compatibility has been broken (eg removed or changed interfaces)
21
# - If the interface is the same as the previous version, change to C:R+1:A
23
LIB_MENU_LT_VERSION=6:8:4
24
AC_SUBST(LIB_MENU_LT_VERSION)
26
GETTEXT_PACKAGE=gnome-menus
27
AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE", [Name of default gettext domain])
28
AC_SUBST(GETTEXT_PACKAGE)
32
IT_PROG_INTLTOOL([0.40.0])
41
dnl make sure we keep ACLOCAL_FLAGS around for maintainer builds to work
42
AC_SUBST(ACLOCAL_AMFLAGS, "$ACLOCAL_FLAGS")
44
PKG_CHECK_MODULES(GLIB, glib-2.0 >= 2.6.0 gio-2.0 >= 2.15.2)
48
GNOME_COMPILE_WARNINGS(yes)
50
AC_ARG_ENABLE(deprecations,
51
[AC_HELP_STRING([--enable-deprecations],
52
[warn about deprecated usages @<:@default=no@:>@])],,
53
[enable_deprecations=no])
55
DISABLE_DEPRECATED_CFLAGS=
56
if test "x$enable_deprecations" = "xyes"; then
57
DISABLE_DEPRECATED_CFLAGS=$DISABLE_DEPRECATED
59
AC_SUBST(DISABLE_DEPRECATED_CFLAGS)
61
dnl --enable-debug=(yes|minimum|no)
63
[AC_HELP_STRING([--enable-debug],
64
[turn on debugging @<:@default=minimum@:>@])],,
65
[enable_debug=minimum])
66
if test "$enable_debug" = "yes"; then
67
DEBUG_CFLAGS="-DG_ENABLE_DEBUG"
69
if test "x$enable_debug" = "xno"; then
70
DEBUG_CFLAGS="-DG_DISABLE_ASSERT -DG_DISABLE_CHECKS"
73
# make sure we have the right string for the configure summary
74
enable_debug="minimum"
77
AC_SUBST(DEBUG_CFLAGS)
80
[AC_HELP_STRING([--enable-python],
81
[build python bindings @<:@default=auto@:>@])],
82
[enable_deprecations=$enableval],
83
[enable_deprecations=auto])
85
# Detect if we can build Python bindings (need python and python headers)
86
if test "x$enable_python" = "xno" ; then
89
AC_MSG_NOTICE([Checking to see if we can build Python bindings])
93
if test "x$PYTHON" = "x" ; then
94
AC_MSG_WARN([Python not found])
96
AM_CHECK_PYTHON_HEADERS(have_python_headers=yes, have_python_headers=no)
97
if test "x$have_python_headers" = "xyes" ; then
102
if test "x$have_python" = "xno" ; then
103
if test "x$enable_python" = "xyes" ; then
104
AC_MSG_ERROR([Building python explicitly requested, but can't build python bindings])
106
AC_MSG_WARN([Couldn't find the Python headers, not building Python bindings])
111
AM_CONDITIONAL(HAVE_PYTHON, test x$have_python = xyes)
113
# Because of the way Python implements polymorphism, we get the following warning:
114
# "warning: dereferencing type-punned pointer will break strict-aliasing rules"
115
# -fno-strict-aliasing (as used in Python build) switches warnings off
116
NO_STRICT_ALIASING_CFLAGS=""
117
if test "x$GCC" = "xyes" ; then
118
AC_MSG_CHECKING(whether $CC accepts -fno-strict-aliasing)
120
CC="$CC -fno-strict-aliasing"
121
AC_TRY_RUN([int main() { return 0; }],
122
ac_cv_no_strict_aliasing_ok=yes,
123
ac_cv_no_strict_aliasing_ok=no,
124
ac_cv_no_strict_aliasing_ok=no)
126
AC_MSG_RESULT($ac_cv_no_strict_aliasing_ok)
127
if test "x$ac_cv_no_strict_aliasing_ok" = "xyes" ; then
128
NO_STRICT_ALIASING_CFLAGS="-fno-strict-aliasing"
131
AC_SUBST(NO_STRICT_ALIASING_CFLAGS)
133
GOBJECT_INTROSPECTION_CHECK([0.6.7])
138
libmenu/libgnome-menu.pc
139
libmenu/libgnome-menu-uninstalled.pc
141
desktop-directories/Makefile
144
simple-editor/Makefile
145
simple-editor/GMenuSimpleEditor/Makefile
149
dnl ---------------------------------------------------------------------------
151
dnl ---------------------------------------------------------------------------
155
`echo gnome-menus $VERSION | sed "s/./=/g"`
158
exec_prefix: ${exec_prefix}
162
sysconfdir: ${sysconfdir}
163
localstatedir: ${localstatedir}
165
source code location: ${srcdir}
168
Maintainer mode: ${USE_MAINTAINER_MODE}
169
Warn about deprecations: ${enable_deprecations}
171
Turn on debugging: ${enable_debug}
172
Build python bindings: ${have_python}
173
Build introspection support: ${found_introspection}