1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207
|
dnl ***************************************************************************
dnl *** configure.in for GLUNARCLOCK (mostly stolen from gnome-applets) ***
dnl ***************************************************************************
AC_INIT([glunarclock],[0.34.1])
AC_PREREQ(2.59)
AC_CONFIG_HEADERS([config.h])
AM_INIT_AUTOMAKE(1.8)
AC_CONFIG_MACRO_DIR([m4])
dnl ***************************************************************************
dnl *** Minimum library versions for GLUNARCLOCK ***
dnl ***************************************************************************
GTK_REQUIRED=2.14.0
GLIB_REQUIRED=2.12.0
GCONF_REQUIRED=2.8.0
SCROLLKEEPER_REQUIRED=0.1.4
LIBPANEL_REQUIRED=2.12.0
dnl ***************************************************************************
AM_MAINTAINER_MODE
IT_PROG_INTLTOOL([0.35.0])
PKG_PROG_PKG_CONFIG([0.19])
AC_PROG_CC
AC_ISC_POSIX
AC_STDC_HEADERS
AM_PROG_LIBTOOL
AC_PATH_XTRA
X_LIBS="$X_LIBS $X_PRE_LIBS -lX11 $X_EXTRA_LIBS"
AC_SUBST(X_LIBS)
GNOME_COMPILE_WARNINGS
dnl ***************************************************************************
dnl *** --enable-more-warnings turns on more compiler warnings ***
dnl ***************************************************************************
AC_ARG_ENABLE(more-warnings,
[ --enable-more-warnings Maximum compiler warnings],
set_more_warnings="$enableval",[
set_more_warnings=no
])
AC_MSG_CHECKING(for more warnings, including -Werror)
if test "$GCC" = "yes" -a "$set_more_warnings" != "no"; then
AC_MSG_RESULT(yes)
CFLAGS="\
-Wall \
-Wchar-subscripts -Wmissing-declarations -Wmissing-prototypes \
-Wnested-externs -Wpointer-arith \
-Wcast-align -Wsign-compare \
-std=gnu89 \
$CFLAGS"
for option in -Wno-strict-aliasing -Wno-sign-compare; do
SAVE_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS $option"
AC_MSG_CHECKING([whether gcc understands $option])
AC_TRY_COMPILE([], [],
has_option=yes,
has_option=no,)
if test $has_option = no; then
CFLAGS="$SAVE_CFLAGS"
fi
AC_MSG_RESULT($has_option)
unset has_option
unset SAVE_CFLAGS
done
unset option
else
AC_MSG_RESULT(no)
fi
dnl ******************************************
dnl ** pkg-config dependency checks **
dnl ******************************************
dnl -- Check for GTK+ 2.0 (required) ------------------------------------------
PKG_CHECK_MODULES(GTK, gtk+-2.0 >= $GTK_REQUIRED)
AC_SUBST(GTK_FLAGS)
AC_SUBST(GTK_LIBS)
dnl -- check for libpanelapplet (required) ------------------------------------
PKG_CHECK_MODULES(GNOME_APPLETS, libpanelapplet-2.0 >= $LIBPANEL_REQUIRED)
AC_SUBST(GNOME_APPLETS_CFLAGS)
AC_SUBST(GNOME_APPLETS_LIBS)
dnl ***************************************************************************
dnl *** find paths to installed binaries ***
dnl ***************************************************************************
dnl -- gdk-pixbuf-csource -----------------------------------------------------
AC_PATH_PROG(GDK_PIXBUF_CSOURCE, gdk-pixbuf-csource, no)
if test x"$GDK_PIXBUF_CSOURCE" = xno; then
AC_MSG_ERROR([gdk-pixbuf-csource executable not found in your path - should be installed with GTK])
fi
AC_SUBST(GDK_PIXBUF_CSOURCE)
dnl -- glib-genmarshal --------------------------------------------------------
AC_PATH_PROG(GLIB_GENMARSHAL, glib-genmarshal)
dnl -- gconftool-2 ------------------------------------------------------------
AC_PATH_PROG(GCONFTOOL, gconftool-2, no)
if test x"$GCONFTOOL" = xno; then
AC_MSG_ERROR([gconftool-2 executable not found in your path - should be installed with GConf])
fi
dnl -- scrollkeeper -----------------------------------------------------------
AC_PATH_PROG(SCROLLKEEPER_CONFIG, scrollkeeper-config, no)
if test x$SCROLLKEEPER_CONFIG = xno; then
AC_MSG_ERROR(Couldn't find scrollkeeper-config, please install the Scrollkeeper 0.1.4 package)
fi
AC_SUBST(SCROLLKEEPER_REQUIRED)
dnl -- xsltproc ---------------------------------------------------------------
AC_PATH_PROG(XSLTPROC, xsltproc, no)
if test x"$XSLTPROC" = xno; then
AC_MSG_ERROR([xsltproc executable not found in your path - should be installed with libxslt])
fi
dnl ***************************************************************************
dnl *** GConf ***
dnl ***************************************************************************
AM_GCONF_SOURCE_2
dnl ***************************************************************************
dnl *** Set up gettext ***
dnl ***************************************************************************
ALL_LINGUAS="ast_ES az bg br da de es fi fr ga gl hu id ja lv ms nl no pt_BR ro ru rw sk sr sv vi wa zh_CN zh_TW"
GETTEXT_PACKAGE=glunarclock
AC_SUBST(GETTEXT_PACKAGE)
AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE", [Gettext Package])
AC_DEFINE_DIR(GNOMELOCALEDIR, "${datadir}/locale", [locale directory])
AM_GLIB_GNU_GETTEXT
# this is the directory where the *.{mo,gmo} files are installed
gnomelocaledir='${prefix}/${DATADIRNAME}/locale'
AC_SUBST(gnomelocaledir)
dnl ***************************************************************************
dnl *** gnome-doc-utils ***
dnl ***************************************************************************
GNOME_DOC_INIT
case "$host" in
sparc-*-solaris*) gkb_type_sun=true;;
*) gkb_type_sun=false;;
esac
AM_CONDITIONAL(GKB_SUN, $gkb_type_sun)
dnl ***************************************************************************
dnl *** Honour aclocal flags ***
dnl ***************************************************************************
ACLOCAL_AMFLAGS="\${ACLOCAL_FLAGS}"
AC_SUBST(ACLOCAL_AMFLAGS)
dnl ***************************************************************************
dnl *** Set install directories ***
dnl ***************************************************************************
iconsdir="${datadir}/icons"
AC_SUBST(iconsdir)
pixmapsdir="${datadir}/pixmaps"
AC_SUBST(pixmapsdir)
pkgdatadir="${datadir}/gnome-applets"
AC_SUBST(pkgdatadir)
builderdir="${pkgdatadir}/builder"
AC_SUBST(builderdir)
AC_DEFINE_DIR(GNOME_ICONDIR, "${iconsdir}", [Gnome Icon Directory])
AC_DEFINE_DIR(GNOME_PIXMAPSDIR, "${pixmapsdir}", [Gnome Pixmaps Directory])
AC_DEFINE_DIR(GTK_BUILDERDIR, "${builderdir}", [GtkBuilder Resources Directory])
AC_DEFINE_DIR(DATADIR, "${datadir}", [datadir])
AC_DEFINE_DIR(SYSCONFDIR, "${sysconfdir}", [sysconfdir])
AC_DEFINE_DIR(LIBDIR, "${libdir}", [libdir])
AC_DEFINE_DIR(PREFIX, "$prefix", [install prefix])
AS_AC_EXPAND(DATADIR, "${datadir}")
AS_AC_EXPAND(PYTHONDIR, $pythondir)
AS_AC_EXPAND(BUILDERDIR, $builderdir)
AC_SUBST(VERSION)
AC_SUBST(PACKAGE)
AC_SUBST(DATADIR)
AC_SUBST(LIBDIR)
AC_SUBST(PYTHONDIR)
AC_SUBST(BUILDERDIR)
dnl ***************************************************************************
dnl *** Output Makefiles et al ***
dnl ***************************************************************************
AC_CONFIG_FILES([
Makefile
po/Makefile.in
src/Makefile
pixmaps/Makefile
help/Makefile
man/Makefile
])
AC_OUTPUT
|