Package: libreoffice / 1:6.1.5-3

no-ant-check-if-unneeded.diff Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
From 0b583faeb72ce5391542923fa073e65f17e5448c Mon Sep 17 00:00:00 2001
From: Rene Engelhard <rene@rene-engelhard.de>
Date: Wed, 23 May 2018 17:30:04 +0200
Subject: [PATCH] micro-optimization: do not check for ant if we don't need it

Change-Id: I84644cddd8a318a2af23780ada9afc26fe23a9fe
---
 configure.ac | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/configure.ac b/configure.ac
index 95e2865017a8..4cc9c1f68b8e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -8503,6 +8503,7 @@ if test "$with_java" != "no"; then
         AC_MSG_RESULT([internal])
         SYSTEM_HSQLDB=
         BUILD_TYPE="$BUILD_TYPE HSQLDB"
+        NEED_ANT=TRUE
         AC_MSG_CHECKING([whether hsqldb should be built with JDBC 4.1])
         javanumver=`$JAVAINTERPRETER -version 2>&1 | $AWK -v num=true -f $SRC_ROOT/solenv/bin/getcompver.awk`
         if expr "$javanumver" '>=' 000100060000 > /dev/null; then
@@ -10619,6 +10620,7 @@ if test "$enable_report_builder" != "no" -a "$with_java" != "no"; then
         AC_MSG_RESULT([internal])
         SYSTEM_JFREEREPORT=
         BUILD_TYPE="$BUILD_TYPE JFREEREPORT"
+        NEED_ANT=TRUE
     fi
 else
     AC_MSG_RESULT([no])
@@ -10662,6 +10664,7 @@ if test "$ENABLE_REPORTBUILDER" = "TRUE"; then
         AC_MSG_RESULT([internal])
         SYSTEM_APACHE_COMMONS=
         BUILD_TYPE="$BUILD_TYPE APACHE_COMMONS"
+        NEED_ANT=TRUE
     fi
 fi
 AC_SUBST(SYSTEM_APACHE_COMMONS)
@@ -10724,6 +10727,7 @@ if test "${enable_scripting_javascript}" != "no" -a "x$with_java" != "xno"; then
         AC_MSG_RESULT([internal])
         SYSTEM_RHINO=
         BUILD_TYPE="$BUILD_TYPE RHINO"
+        NEED_ANT=TRUE
     fi
 else
     AC_MSG_RESULT([no])
@@ -11640,7 +11644,7 @@ dnl ===================================================================
 dnl Test for the presence of Ant and that it works
 dnl ===================================================================
 
-if test "$ENABLE_JAVA" != ""; then
+if test "$ENABLE_JAVA" != "" -a "$NEED_ANT" = "TRUE"; then
     ANT_HOME=; export ANT_HOME
     WITH_ANT_HOME=; export WITH_ANT_HOME
     if test -z "$with_ant_home" -a -n "$LODE_HOME" ; then
-- 
2.17.0