+ if test "x$enable_dvi" = "xyes"; then
+ AC_DEFINE([ENABLE_DVI], [1], [Enable dvi viewer support.])
+ else
+ AC_MSG_WARN("Dvi support is disabled since kpathsea library is not found. Check your TeX installation.")
+ fi
+fi
+AM_CONDITIONAL(ENABLE_DVI, test x$enable_dvi = xyes)
+
+if test "x$enable_dvi" = "xyes"; then
+ if test "x$enable_type1_fonts" = "xyes"; then
+ AC_CHECK_LIB([t1],T1_InitLib,enable_type1_fonts=yes,enable_type1_fonts=no,[-lm])
+ fi
+
+ if test "x$enable_type1_fonts" = xyes; then
+ AC_DEFINE([WITH_TYPE1_FONTS], [1], [Enable t1lib support in dvi.])
+ fi
+else
+ enable_type1_fonts=no
+fi
+AM_CONDITIONAL(WITH_TYPE1_FONTS, test x$enable_type1_fonts = xyes)
+
+dnl ================== End of dvi checks ===================================================
+
+dnl ================== pixbuf checks ===================================================
+
+AC_ARG_ENABLE(pixbuf,
+ [AC_HELP_STRING([--enable-pixbuf], [Compile with support of pixbuf])],enable_pixbuf="$enableval",enable_pixbuf=no)
+if test "x$enable_pixbuf" = "xyes"; then
+ AC_DEFINE([ENABLE_PIXBUF], [1], [Enable pixbuf support.])
+fi
+AM_CONDITIONAL(ENABLE_PIXBUF, test x$enable_pixbuf = xyes)
+
+dnl ================== End of pixbuf checks ===================================================
+
+dnl ================== comic book checks ===================================================
+
+AC_ARG_ENABLE(comics,
+ [AC_HELP_STRING([--enable-comics], [Compile with support for comic book archives])],enable_comics=yes,enable_comics=no)
+if test "x$enable_comics" = "xyes"; then
+ AC_DEFINE([ENABLE_COMICS], [1], [Enable support for comics.])
+
+fi
+AM_CONDITIONAL(ENABLE_COMICS, test x$enable_comics = xyes)
+
+AC_PATH_PROG(UPDATE_MIME_DB, update-mime-database, no)
+AC_SUBST(UPDATE_MIME_DB)
+
+AC_ARG_ENABLE(update-mimedb,
+ AC_HELP_STRING([--disable-update-mimedb],
+ [disable the update-mime-database after install [default=no]]),,
+ enable_update_mimedb=yes)
+AM_CONDITIONAL(ENABLE_UPDATE_MIMEDB, test x$enable_update_mimedb = xyes)
+
+dnl ================== End of comic book checks ============================================
+
+dnl =================== Mime types list ====================================================
+
+EVINCE_MIME_TYPES="application/pdf;application/postscript;application/x-gzpostscript"
+
+if test "x$enable_dvi" = "xyes"; then
+ EVINCE_MIME_TYPES="$EVINCE_MIME_TYPES;application/x-dvi"
+fi
+if test "x$enable_djvu" = "xyes"; then
+ EVINCE_MIME_TYPES="$EVINCE_MIME_TYPES;image/vnd.djvu"
+fi
+if test "x$enable_tiff" = "xyes"; then
+ EVINCE_MIME_TYPES="$EVINCE_MIME_TYPES;image/tiff"
+fi
+if test "x$enable_comics" = "xyes"; then
+ EVINCE_MIME_TYPES="$EVINCE_MIME_TYPES;application/cbr;application/cbz"
+fi
+AC_SUBST(EVINCE_MIME_TYPES)
+
+AC_CONFIG_FILES([