Commit 3dee74a5 authored by Sebastian Ramacher's avatar Sebastian Ramacher
Browse files

Cairo is always needed

parent 743e59b0
......@@ -34,8 +34,8 @@ ifeq (,${PLUGINDIR})
PLUGINDIR = ${LIBDIR}/zathura
endif
INCS = ${GIRARA_INC} ${GLIB_INC} ${DJVU_INC} ${ZATHURA_INC}
LIBS = ${GIRARA_LIB} ${GLIB_LIB} ${DJVU_LIB}
INCS = ${GIRARA_INC} ${GLIB_INC} ${DJVU_INC} ${CAIRO_INC} ${ZATHURA_INC}
LIBS = ${GIRARA_LIB} ${GLIB_LIB} ${DJVU_LIB} ${CAIRO_LIB}
# pre-processor flags
CPPFLAGS += -D_FILE_OFFSET_BITS=64
......@@ -49,9 +49,6 @@ LDFLAGS += -fPIC
# debug
DFLAGS ?= -g
# build with cairo support?
WITH_CAIRO ?= 1
# compiler
CC ?= gcc
LD ?= ld
......
......@@ -31,9 +31,7 @@ register_functions(zathura_plugin_functions_t* functions)
functions->page_get_text = (zathura_plugin_page_get_text_t) djvu_page_get_text;
functions->page_links_get = (zathura_plugin_page_links_get_t) djvu_page_links_get;
functions->page_render = (zathura_plugin_page_render_t) djvu_page_render;
#ifdef HAVE_CAIRO
functions->page_render_cairo = (zathura_plugin_page_render_cairo_t) djvu_page_render_cairo;
#endif
}
ZATHURA_PLUGIN_REGISTER(
......@@ -491,7 +489,6 @@ error_ret:
return NULL;
}
#ifdef HAVE_CAIRO
zathura_error_t
djvu_page_render_cairo(zathura_page_t* page, void* UNUSED(data), cairo_t* cairo,
bool GIRARA_UNUSED(printing))
......@@ -547,7 +544,6 @@ djvu_page_render_cairo(zathura_page_t* page, void* UNUSED(data), cairo_t* cairo,
return ZATHURA_ERROR_OK;
}
#endif
zathura_image_buffer_t*
djvu_page_render(zathura_page_t* page, void* UNUSED(data), zathura_error_t* error)
......
......@@ -6,9 +6,7 @@
#include <stdbool.h>
#include <zathura/plugin-api.h>
#include <libdjvu/ddjvuapi.h>
#ifdef HAVE_CAIRO
#include <cairo.h>
#endif
/**
* DjVu document
......@@ -122,7 +120,6 @@ girara_list_t* djvu_page_links_get(zathura_page_t* page, void* data,
*/
zathura_image_buffer_t* djvu_page_render(zathura_page_t* page, void* data, zathura_error_t* error);
#ifdef HAVE_CAIRO
/**
* Renders a page onto a cairo object
*
......@@ -133,6 +130,5 @@ zathura_image_buffer_t* djvu_page_render(zathura_page_t* page, void* data, zathu
* zathura_error_t
*/
zathura_error_t djvu_page_render_cairo(zathura_page_t* page, void* data, cairo_t* cairo, bool printing);
#endif
#endif // DJVU_H
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment