diff options
author | Ashod Nakashian <ashod.nakashian@collabora.co.uk> | 2019-03-06 22:06:35 -0500 |
---|---|---|
committer | Andras Timar <andras.timar@collabora.com> | 2019-06-15 11:01:56 +0200 |
commit | 296389eab0263e88a311856c10813cd2bec54d1d (patch) | |
tree | 8008966358a673b9d243099f224c215b1a3feaa1 /configure.ac | |
parent | 6af55390f1ef542e408e32e9c273075a2671b81b (diff) |
build: support disabling poppler
This adds --enable-poppler configure option.
Poppler can be enabled/disabled by setting this
parameter to yes or no.
Change-Id: I42ba2d27de7b5014d28523394310616d20073b71
Reviewed-on: https://gerrit.libreoffice.org/68602
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 51 |
1 files changed, 36 insertions, 15 deletions
diff --git a/configure.ac b/configure.ac index bd432e0b2a36..91b66203b936 100644 --- a/configure.ac +++ b/configure.ac @@ -1720,6 +1720,11 @@ AC_ARG_WITH(system-openldap, [Use the OpenLDAP LDAP SDK already on system.]),, [with_system_openldap="$with_system_libs"]) +libo_FUZZ_ARG_ENABLE(poppler, + AS_HELP_STRING([--disable-poppler], + [Disable building Poppler.]) +) + AC_ARG_WITH(system-poppler, AS_HELP_STRING([--with-system-poppler], [Use system poppler (only needed for PDF import).]),, @@ -10491,6 +10496,33 @@ AC_SUBST([DCONF_CFLAGS]) AC_SUBST([DCONF_LIBS]) AC_SUBST([ENABLE_DCONF]) +# Pdfium? +AC_MSG_CHECKING([whether to build PDFium]) +ENABLE_PDFIUM= +if test -z "$enable_pdfium" -o "$enable_pdfium" = yes; then + AC_MSG_RESULT([yes]) + ENABLE_PDFIUM=TRUE + AC_DEFINE(HAVE_FEATURE_PDFIUM) + BUILD_TYPE="$BUILD_TYPE PDFIUM" +else + AC_MSG_RESULT([no]) +fi +AC_SUBST(ENABLE_PDFIUM) + +dnl =================================================================== +dnl Check for poppler +dnl =================================================================== +ENABLE_POPPLER= +AC_MSG_CHECKING([enable poppler]) +if test -z "$enable_poppler" -o "$enable_poppler" = yes; then + AC_MSG_RESULT([yes]) + ENABLE_POPPLER=TRUE + AC_DEFINE(HAVE_FEATURE_POPPLER) +else + AC_MSG_RESULT([no]) +fi +AC_SUBST(ENABLE_POPPLER) + # pdf import? AC_MSG_CHECKING([whether to build the PDF import feature]) ENABLE_PDFIMPORT= @@ -10498,7 +10530,11 @@ if test $_os != Android -a $_os != iOS -a \( -z "$enable_pdfimport" -o "$enable_ AC_MSG_RESULT([yes]) ENABLE_PDFIMPORT=TRUE AC_DEFINE(HAVE_FEATURE_PDFIMPORT) +else + AC_MSG_RESULT([no]) +fi +if test $ENABLE_PDFIMPORT == TRUE -a $ENABLE_POPPLER == TRUE; then dnl =================================================================== dnl Check for system poppler dnl =================================================================== @@ -10529,27 +10565,12 @@ if test $_os != Android -a $_os != iOS -a \( -z "$enable_pdfimport" -o "$enable_ AC_DEFINE([HAVE_POPPLER_VERSION_H], 1) fi AC_DEFINE([ENABLE_PDFIMPORT],1) -else - AC_MSG_RESULT([no]) fi AC_SUBST(ENABLE_PDFIMPORT) AC_SUBST(SYSTEM_POPPLER) AC_SUBST(POPPLER_CFLAGS) AC_SUBST(POPPLER_LIBS) -# pdf import? -AC_MSG_CHECKING([whether to build PDFium]) -ENABLE_PDFIUM= -if test -z "$enable_pdfium" -o "$enable_pdfium" = yes; then - AC_MSG_RESULT([yes]) - ENABLE_PDFIUM=TRUE - AC_DEFINE(HAVE_FEATURE_PDFIUM) - BUILD_TYPE="$BUILD_TYPE PDFIUM" -else - AC_MSG_RESULT([no]) -fi -AC_SUBST(ENABLE_PDFIUM) - SYSTEM_GPGMEPP= if test "$build_for_ios" = "YES"; then |