summaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
authorsb <sb@openoffice.org>2010-04-21 22:01:20 +0200
committersb <sb@openoffice.org>2010-04-21 22:01:20 +0200
commitdfa0a43bdbf10edec4dc5307f97d6274b5c6b825 (patch)
treebe687eaab60999ebda22374b3504e2b03f27fc99 /configure.in
parent804a0f3d882f888c7b3b33d63118e735283617e9 (diff)
parenta0de0def4a49a63c6675a622123b793da8b4c78d (diff)
sb120: merged in DEV300_m77
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in125
1 files changed, 105 insertions, 20 deletions
diff --git a/configure.in b/configure.in
index 1a3786d68ae9..34e9c206b8c8 100644
--- a/configure.in
+++ b/configure.in
@@ -35,6 +35,13 @@ AC_ARG_ENABLE(ldap,
[ --disable-ldap Disables the use of LDAP backend via Netscape/Mozilla
or OpenLDAP LDAP SDK
],,)
+AC_ARG_ENABLE(fetch-external,
+[ --disable-fetch-external Disables fetching external tarballs from web sources.
+],,)
+AC_ARG_WITH(external-tar,
+[ --with-external-tar=<TARFILE PATH> Specify path to tarfiles manually ],
+[ TARFILE_LOCATION="$withval"
+])
AC_ARG_WITH(openldap,
[ --with-openldap Enables the use of the OpenLDAP LDAP SDK instead
of the Netscape/Mozilla one
@@ -370,7 +377,7 @@ AC_ARG_ENABLE(mysql-connector,
AC_ARG_WITH(system-mysql,
[ --with-system-mysql Use MySQL libraries already on system, for building the MySQL Connector/OOo extension.
Requires MYSQLCONFIG to point to the mysql_config executable.
-],,with_system_mysql="no")
+],,)
AC_ARG_WITH(libmysql-path,
[ --with-libmysql-path Use Connector/C (libmysql) installation for building the MySQL Connector/OOo extension.
@@ -1193,6 +1200,19 @@ else
fi
AC_SUBST(ENABLE_FONTCONFIG)
+dnl ===================================================================
+dnl find external tarballs.
+dnl ===================================================================
+if test -z $TARFILE_LOCATION; then
+ TARFILE_LOCATION="DEFAULT"
+fi
+AC_SUBST(TARFILE_LOCATION)
+
+if test -z "$enable_fetch_external" || test "$enable_fetch_external" = "yes" \
+ && test -z "$with_system_libs" -a "$with_system_jars" != "no"; then
+ DO_FETCH_TARBALLS="yes"
+fi
+AC_SUBST(DO_FETCH_TARBALLS)
dnl ===================================================================
dnl Disable legacy binary file formats filters
@@ -3933,13 +3953,6 @@ int main(int argc, char **argv) {
], [AC_MSG_RESULT(OK)], [AC_MSG_ERROR([not suitable, we need >= 1.0.6])])
AC_LANG_POP([C++])
- AC_MSG_CHECKING([STL compatibility])
- if test "$WITH_STLPORT" != "no"; then
- AC_MSG_ERROR([to use system mysqlcppconn you need to use --without-stlport])
- else
- AC_MSG_RESULT([OK])
- fi
-
else
AC_MSG_RESULT([internal])
AC_MSG_CHECKING([for mysqlcppconn module])
@@ -4056,6 +4069,70 @@ if test -n "$with_system_saxon" -o -n "$with_system_libs" && \
[AC_MSG_ERROR(serializer.jar not found.)], [])
AC_SUBST(SERIALIZER_JAR)
fi
+
+dnl Saxon comes in two practically available versions, the out-of-date saxonb which
+dnl supports the java extensions that OOo uses, and the up-to-date saxon he
+dnl "home edition" version, which is crippled to not support those java extensions.
+dnl And as an aside the he one also needs to be tweaked to include
+dnl a META-INF/services to broadcast that it supports the jaxp transform factory
+
+ AC_MSG_CHECKING([if saxon works])
+ cat > saxontest.java <<_ACEOF
+[import javax.xml.transform.TransformerFactory;
+import javax.xml.transform.Transformer;
+import javax.xml.transform.stream.StreamSource;
+import java.io.*;
+
+import net.sf.saxon.FeatureKeys;
+
+class saxontest {
+ public static void main(String[] args) {
+ System.setProperty("javax.xml.transform.TransformerFactory",
+ "net.sf.saxon.TransformerFactoryImpl");
+ try {
+ TransformerFactory tfactory = TransformerFactory.newInstance();
+ // some external saxons (Debian, Ubuntu, ...) have this disabled
+ // per default
+ tfactory.setAttribute(FeatureKeys.ALLOW_EXTERNAL_FUNCTIONS, new Boolean(true));
+ System.out.println("TransformerFactory is" +
+ tfactory.getClass().getName());
+ Transformer transformer = tfactory.newTransformer(
+ new StreamSource(new File(args[0])));
+ } catch(Exception e){
+ e.printStackTrace(System.err);
+ System.exit(-1);
+ }
+ System.exit(0);
+ }
+}
+]
+_ACEOF
+ cat > saxontest.xsl<<_ACEOF
+[<?xml version="1.0" encoding="UTF-8"?>
+<xsl:stylesheet version="2.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
+ <xsl:template match="/">
+ <xsl:value-of select="math:sqrt(1)" xmlns:math="java:java.lang.Math"/>
+ </xsl:template>
+</xsl:stylesheet>
+]
+_ACEOF
+ javac_cmd="$JAVACOMPILER -cp $SAXON_JAR saxontest.java 1>&2"
+ AC_TRY_EVAL(javac_cmd)
+ if test $? = 0 && test -f ./saxontest.class ; then
+ java_cmd="$JAVAINTERPRETER -cp $SAXON_JAR:. saxontest saxontest.xsl 1>&2"
+ AC_TRY_EVAL(java_cmd)
+ if test $? = 0; then
+ AC_MSG_RESULT([yes])
+ else
+ cat saxontest.java >&5
+ AC_MSG_RESULT([no])
+ AC_MSG_ERROR([Non-functional saxon jar, e.g. crippled saxon-he instead of saxonb])
+ fi
+ else
+ AC_MSG_RESULT([no])
+ cat saxontest.java >&5
+ AC_MSG_ERROR([saxontest could not be compiled, non-functional saxon jar])
+ fi
else
AC_MSG_RESULT([internal])
SYSTEM_SAXON=NO
@@ -4448,26 +4525,34 @@ if test "$BUILD_MOZAB" = "TRUE"; then
MOZILLA_VERSION=1.1.14
fi
MOZILLA_SOURCE_VERSION="seamonkey-${MOZILLA_VERSION}.source"
- for e in gz bz2; do
- AC_MSG_CHECKING([for $MOZILLA_SOURCE_VERSION.tar.$e])
- if test ! -e "moz/download/$MOZILLA_SOURCE_VERSION.tar.$e" && test "$HAVE_MOZILLA_TARBALL" != "y"; then
- AC_MSG_RESULT([not found])
- HAVE_MOZILLA_TARBALL=n
+ MOZILLA_FETCH_FILE=`grep $MOZILLA_SOURCE_VERSION ooo.lst`
+ AC_MSG_CHECKING([for mozilla sources])
+ if test -z "$MOZILLA_FETCH_FILE"; then
+ AC_MSG_RESULT([not found])
+ HAVE_MOZILLA_TARBALL=n
+ else
+ AC_MSG_CHECKING([for $MOZILLA_FETCH_FILE])
+ if test ! -e "$TARFILE_LOCATION/$MOZILLA_FETCH_FILE"; then
+ if test -z "$DO_FETCH"; then
+ AC_MSG_RESULT([will be fetched])
+ HAVE_MOZILLA_TARBALL=y
+ else
+ AC_MSG_RESULT([not found])
+ HAVE_MOZILLA_TARBALL=n
+ fi
else
AC_MSG_RESULT([found])
HAVE_MOZILLA_TARBALL=y
fi
- done
+ fi
if test "$HAVE_MOZILLA_TARBALL" != "y"; then
- AC_MSG_ERROR([Mozilla/SeaMonkey source archive not found.
-Please copy $MOZILLA_SOURCE_VERSION.tar.bz2 or $MOZILLA_SOURCE_VERSION.tar.gz to moz/download/.
-The archives can be found here:
-ftp://ftp.mozilla.org/pub/mozilla.org/seamonkey/releases/$MOZILLA_VERSION/])
+ AC_MSG_ERROR([Mozilla/SeaMonkey source archive not found.
+Use "./fetch_tarballs.sh ooo.lst" to download.])
fi
if test "$_os" = "WINNT"; then
AC_MSG_CHECKING([for moztools binaries])
- if test ! -e "moz/download/vc8-moztools.zip" ; then
- AC_MSG_ERROR([The following file is missing in moz/download: vc8-moztools.zip
+ if test ! -e "$TARFILE_LOCATION/vc8-moztools.zip" ; then
+ AC_MSG_ERROR([The following file is missing in $TARFILE_LOCATION: vc8-moztools.zip
(from ftp://ftp.mozilla.org/pub/mozilla.org/mozilla/libraries/win32/historic/vc8/)])
else
AC_MSG_RESULT([ok])