1 dnl Process this file with autoconf to produce a configure script.
5 AM_INIT_AUTOMAKE(AC_PACKAGE_NAME, AC_PACKAGE_VERSION)
7 dnl make sure we keep ACLOCAL_FLAGS around for maintainer builds to work
8 AC_SUBST(ACLOCAL_AMFLAGS, "$ACLOCAL_FLAGS")
10 AM_CONFIG_HEADER(config.h)
26 ALL_LINGUAS="bg ca cs da de el en_CA en_GB fi fr ja no nb nl pt_BR sv zh_CN zh_TW"
30 GETTEXT_PACKAGE=AC_PACKAGE_NAME
31 AC_SUBST(GETTEXT_PACKAGE)
32 AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE", [Gettext package.])
34 PKG_CHECK_MODULES(LIBEVPRIVATE, gtk+-2.0 >= 2.4.0)
35 PKG_CHECK_MODULES(RECENT_FILES, gtk+-2.0 >= 2.4.0 libgnomeui-2.0 >= 2.4.0)
36 PKG_CHECK_MODULES(SHELL, gtk+-2.0 >= 2.6.0 libgnomeui-2.0 gnome-vfs-2.0 libgnomeprint-2.2 libgnomeprintui-2.2 libglade-2.0 gconf-2.0 poppler >= 0.1.1)
37 PKG_CHECK_MODULES(THUMBNAILER, gtk+-2.0 >= 2.6.0 gnome-vfs-2.0 poppler >= 0.1.1)
38 PKG_CHECK_MODULES(DVI, gtk+-2.0 >= 2.6.0)
39 PKG_CHECK_MODULES(GTK, gtk+-2.0 >= 2.6.0)
40 PKG_CHECK_MODULES(PS, gtk+-2.0 >= 2.6.0 gnome-vfs-2.0 libgnomeui-2.0)
41 PKG_CHECK_MODULES(POPPLER, poppler >= 0.1.1)
43 GLIB_GENMARSHAL=`$PKG_CONFIG --variable=glib_genmarshal glib-2.0`
44 AC_SUBST(GLIB_GENMARSHAL)
46 dnl Compile with disable-deprecated switches
48 AC_ARG_ENABLE(deprecated,
49 AC_HELP_STRING([--disable-deprecated],
50 [Don't allow any deprecated GTK+/etc. features.]),
51 set_enable_deprecated="$enableval",[
52 if test -f $srcdir/autogen.sh; then
54 set_enable_deprecated=no
56 set_enable_deprecated=yes
59 AC_MSG_CHECKING([whether to disable deprecated glib/gtk+/etc. features])
60 if test "$set_enable_deprecated" != "yes"; then
62 EVINCE_DISABLE_DEPRECATED="-DG_DISABLE_DEPRECATED -DGDK_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED -DGNOME_DISABLE_DEPRECATED -DBONOBO_DISABLE_DEPRECATED"
65 EVINCE_DISABLE_DEPRECATED=""
67 AC_SUBST(EVINCE_DISABLE_DEPRECATED)
71 AC_PATH_PROG([GCONFTOOL], [gconftool-2], [no])
72 if test "x$GCONFTOOL" = "xno"; then
73 AC_MSG_ERROR([gconftool-2 executable not found in your path - should be installed with GConf])
76 dnl ================== ggv checks ===================================================
78 [ --with-gs=dir Directory Where GhostScript package is installed.])
80 if test "x$with_gs" = "x"; then
81 AC_PATH_PROG(GS_PROG, gs)
82 if test -z "$GS_PROG"; then
83 AC_MSG_ERROR(Unable to find GhostScript in the PATH. Provide the full path for GhostScript(--with-gs=PATH). You need to have Ghostscript installed in order to run evince)
89 AC_DEFINE_UNQUOTED(GS_PATH, "$GS_PROG", [Path to the 'gs' executable.])
92 dnl check for GS version
93 AC_MSG_CHECKING(for Ghostscript version...)
94 GS_VERSION=`gs --version | head -n 1 | sed 's/\([[0-9]]*\)\.\([[0-9]]*\).*/\1/'`
95 AC_MSG_RESULT(found $GS_VERSION)
96 if test "$GS_VERSION" -lt "7"; then
97 AC_MSG_ERROR([You need Ghostscript version >= 7 in order to run evince])
99 AA_PARMS="-sDEVICE=x11alpha -dNOPLATFONTS"
100 AC_DEFINE_UNQUOTED(ALPHA_PARAMS, "$AA_PARMS", [Anti-aliasing parameters for Ghostscript.])
101 AC_MSG_RESULT(Antialiasing parameters for Ghostscript: $AA_PARMS)
104 dnl Turn on the additional warnings last, so -Werror doesn't affect other tests.
105 dnl stolen from nautilus and gnome-common
107 AC_ARG_ENABLE(more-warnings,
108 [ --enable-more-warnings Maximum compiler warnings],
109 set_more_warnings="$enableval",[
110 if test -f $srcdir/autogen.sh; then
112 set_more_warnings=yes
117 AC_MSG_CHECKING(for more warnings, including -Werror)
118 if test "$GCC" = "yes" -a "$set_more_warnings" != "no"; then
119 AC_MSG_RESULT([yes, using gcc])
122 -Wchar-subscripts -Wmissing-declarations -Wmissing-prototypes \
123 -Wnested-externs -Wpointer-arith \
124 -Wcast-align -Wsign-compare \
128 dnl case " $CFLAGS " in
129 dnl *[\ \ ]-ansi[\ \ ]*) ;;
130 dnl *) CFLAGS="$CFLAGS -ansi" ;;
132 dnl case " $CFLAGS " in
133 dnl *[\ \ ]-pedantic[\ \ ]*) ;;
134 dnl *) CFLAGS="$CFLAGS -pedantic" ;;
137 for option in -Wno-strict-aliasing -Wno-sign-compare; do
138 SAVE_CFLAGS="$CFLAGS"
139 CFLAGS="$CFLAGS $option"
140 AC_MSG_CHECKING([whether gcc understands $option])
141 AC_TRY_COMPILE([], [],
144 if test $has_option = no; then
145 CFLAGS="$SAVE_CFLAGS"
147 AC_MSG_RESULT($has_option)
156 dnl ======================== End of ggv checks =================================
161 cut-n-paste/recent-files/Makefile