[Libreoffice-commits] core.git: Branch 'feature/configure-disable-orcus' - config_host/config_orcus.h.in config_host.mk.in configure.ac liborcus/Module_liborcus.mk RepositoryExternal.mk
Kohei Yoshida
kohei.yoshida at collabora.com
Wed Sep 18 17:07:06 PDT 2013
RepositoryExternal.mk | 8 +++
config_host.mk.in | 1
config_host/config_orcus.h.in | 6 ++
configure.ac | 86 +++++++++++++++++++++++++-----------------
liborcus/Module_liborcus.mk | 2
5 files changed, 68 insertions(+), 35 deletions(-)
New commits:
commit 0fd617eae5b38b43841b6b602c0171d6d8aaeb4c
Author: Kohei Yoshida <kohei.yoshida at collabora.com>
Date: Wed Sep 18 19:06:20 2013 -0400
Add the configure bits to support --disable-orcus.
Change-Id: Ieeb1581187248875ca2e37278c62a382f6caa8e0
diff --git a/RepositoryExternal.mk b/RepositoryExternal.mk
index 8a8d06c..a0315f5 100644
--- a/RepositoryExternal.mk
+++ b/RepositoryExternal.mk
@@ -2475,6 +2475,8 @@ $(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO,\
endif # SYSTEM_PYTHON
# ORCUS
+ifeq ($(ENABLE_ORCUS),TRUE)
+
ifeq ($(SYSTEM_LIBORCUS),YES)
define gb_LinkTarget__use_orcus
@@ -2515,6 +2517,12 @@ endef
endif # SYSTEM_LIBORCUS
+else # ENABLE_ORCUS != TRUE
+
+gb_LinkTarget__use_orcus :=
+gb_LinkTarget__use_orcus-parser :=
+
+endif
### X11 stuff ###
diff --git a/config_host.mk.in b/config_host.mk.in
index 6b9768f..9699d58 100644
--- a/config_host.mk.in
+++ b/config_host.mk.in
@@ -120,6 +120,7 @@ export ENABLE_GCONF=@ENABLE_GCONF@
export ENABLE_GIO=@ENABLE_GIO@
export ENABLE_GNOMEVFS=@ENABLE_GNOMEVFS@
export ENABLE_GRAPHITE=@ENABLE_GRAPHITE@
+export ENABLE_ORCUS=@ENABLE_ORCUS@
export ENABLE_HARFBUZZ=@ENABLE_HARFBUZZ@
export ENABLE_GSTREAMER=@ENABLE_GSTREAMER@
export ENABLE_GSTREAMER_0_10=@ENABLE_GSTREAMER_0_10@
diff --git a/config_host/config_orcus.h.in b/config_host/config_orcus.h.in
new file mode 100644
index 0000000..68e3757
--- /dev/null
+++ b/config_host/config_orcus.h.in
@@ -0,0 +1,6 @@
+#ifndef CONFIG_ORCUS_H
+#define CONFIG_ORCUS_H
+
+#define ENABLE_ORCUS 0
+
+#endif
diff --git a/configure.ac b/configure.ac
index fda58df..141d0e1 100644
--- a/configure.ac
+++ b/configure.ac
@@ -729,6 +729,11 @@ AC_ARG_ENABLE(graphite,
[Enables the compilation of Graphite smart font rendering.])
)
+AC_ARG_ENABLE(orcus,
+ AS_HELP_STRING([--enable-orcus],
+ [Enables orcus for extra file import filters for Calc.])
+)
+
AC_ARG_ENABLE(fetch-external,
AS_HELP_STRING([--disable-fetch-external],
[Disables fetching external tarballs from web sources.])
@@ -8941,6 +8946,52 @@ fi
AC_SUBST(ENABLE_GRAPHITE)
dnl ===================================================================
+dnl Orcus
+dnl ===================================================================
+
+AC_MSG_CHECKING([whether to enable orcus])
+if test $_os != Darwin -a $_os != Android -a $_os != iOS -a \( -z "$enable_orcus" -o "$enable_orcus" != no \); then
+ AC_MSG_RESULT([yes])
+ ENABLE_ORCUS="TRUE"
+ AC_DEFINE(ENABLE_ORCUS)
+
+ libo_CHECK_SYSTEM_MODULE([orcus],[ORCUS],[liborcus-0.6 >= 0.5.0])
+ if test "$with_system_orcus" != "yes"; then
+ if test "$SYSTEM_BOOST" = "YES"; then
+ # ===========================================================
+ # Determine if we are going to need to link with Boost.System
+ # ===========================================================
+ dnl This seems to be necessary since boost 1.50 (1.48 does not need it,
+ dnl 1.49 is untested). The macro BOOST_THREAD_DONT_USE_SYSTEM mentioned
+ dnl in documentation has no effect.
+ AC_MSG_CHECKING([if we need to link with Boost.System])
+ AC_LANG_PUSH([C++])
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
+ @%:@include <boost/version.hpp>
+ ]],[[
+ #if BOOST_VERSION >= 105000
+ # error yes, we need to link with Boost.System
+ #endif
+ ]])],[
+ AC_MSG_RESULT([no])
+ ],[
+ AC_MSG_RESULT([yes])
+ AX_BOOST_SYSTEM
+ ])
+ AC_LANG_POP([C++])
+ fi
+ fi
+ dnl FIXME by renaming SYSTEM_LIBORCUS to SYSTEM_ORCUS in the build system world
+ SYSTEM_LIBORCUS=$SYSTEM_ORCUS
+ AC_SUBST([BOOST_SYSTEM_LIB])
+ AC_SUBST(SYSTEM_LIBORCUS)
+
+else
+ AC_MSG_RESULT([no])
+fi
+AC_SUBST(ENABLE_ORCUS)
+
+dnl ===================================================================
dnl HarfBuzz
dnl ===================================================================
AC_MSG_CHECKING([whether to enable HarfBuzz support])
@@ -9210,40 +9261,6 @@ AC_SUBST(RASQAL_MAJOR)
AC_SUBST(REDLAND_MAJOR)
dnl ===================================================================
-dnl Check for system orcus
-dnl ===================================================================
-libo_CHECK_SYSTEM_MODULE([orcus],[ORCUS],[liborcus-0.6 >= 0.5.0])
-if test "$with_system_orcus" != "yes"; then
- if test "$SYSTEM_BOOST" = "YES"; then
- # ===========================================================
- # Determine if we are going to need to link with Boost.System
- # ===========================================================
- dnl This seems to be necessary since boost 1.50 (1.48 does not need it,
- dnl 1.49 is untested). The macro BOOST_THREAD_DONT_USE_SYSTEM mentioned
- dnl in documentation has no effect.
- AC_MSG_CHECKING([if we need to link with Boost.System])
- AC_LANG_PUSH([C++])
- AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
- @%:@include <boost/version.hpp>
- ]],[[
- #if BOOST_VERSION >= 105000
- # error yes, we need to link with Boost.System
- #endif
- ]])],[
- AC_MSG_RESULT([no])
- ],[
- AC_MSG_RESULT([yes])
- AX_BOOST_SYSTEM
- ])
- AC_LANG_POP([C++])
- fi
-fi
-dnl FIXME by renaming SYSTEM_LIBORCUS to SYSTEM_ORCUS in the build system world
-SYSTEM_LIBORCUS=$SYSTEM_ORCUS
-AC_SUBST([BOOST_SYSTEM_LIB])
-AC_SUBST(SYSTEM_LIBORCUS)
-
-dnl ===================================================================
dnl Check for system hunspell
dnl ===================================================================
AC_MSG_CHECKING([which libhunspell to use])
@@ -12571,6 +12588,7 @@ AC_CONFIG_HEADERS([config_host/config_global.h])
AC_CONFIG_HEADERS([config_host/config_graphite.h])
AC_CONFIG_HEADERS([config_host/config_lgpl.h])
AC_CONFIG_HEADERS([config_host/config_mpl.h])
+AC_CONFIG_HEADERS([config_host/config_orcus.h])
AC_CONFIG_HEADERS([config_host/config_kde4.h])
AC_CONFIG_HEADERS([config_host/config_mingw.h])
AC_CONFIG_HEADERS([config_host/config_oox.h])
diff --git a/liborcus/Module_liborcus.mk b/liborcus/Module_liborcus.mk
index 78e90d9..d290e86 100644
--- a/liborcus/Module_liborcus.mk
+++ b/liborcus/Module_liborcus.mk
@@ -9,7 +9,7 @@
$(eval $(call gb_Module_Module,liborcus))
-ifeq ($(SYSTEM_LIBORCUS),NO)
+ifeq ($(ENABLE_ORCUS)-$(SYSTEM_LIBORCUS),TRUE-NO)
$(eval $(call gb_Module_add_targets,liborcus,\
ExternalProject_liborcus \
More information about the Libreoffice-commits
mailing list