diff options
author | Pascal Junck <pjunck@openoffice.org> | 2004-10-27 15:14:53 +0000 |
---|---|---|
committer | Pascal Junck <pjunck@openoffice.org> | 2004-10-27 15:14:53 +0000 |
commit | 157d22babb277a9e7bc750a74737cd60e84dfee8 (patch) | |
tree | d81786ef08f44cf635aeb1df967eda542f3f65f1 /config_office | |
parent | 6f3438351c82ce34fba6a7dcd7224ac38888136a (diff) |
INTEGRATION: CWS rodarvus01 (1.66.6); FILE MERGED
2004/10/14 18:47:13 rodarvus 1.66.6.7: RESYNC: (1.69-1.72); FILE MERGED
2004/10/14 13:33:30 rodarvus 1.66.6.6: Issue number: #i26571# - make sure GTK/KDE are *really* wanted, before we
attempt to search for one of them (meaning --enable-gtk=no
will not enable GTK support)
Submitted by: rodarvus
2004/10/06 20:33:33 rodarvus 1.66.6.5: Issue number: #i12892# - check if $JAVA_HOME is valid
Submitted by: rodarvus
2004/09/23 12:55:54 rodarvus 1.66.6.4: Issue number: #i34431#: fix configure WRT system expat support
Submitted by: waratah
Reviewed by: rodarvus
2004/09/21 17:25:36 rodarvus 1.66.6.3: RESYNC: (1.66-1.69); FILE MERGED
2004/09/21 14:46:37 rodarvus 1.66.6.2: Issue number: i26571
Submitted by: kendy
Reviewed by: rodarvus
2004/09/14 13:40:07 rodarvus 1.66.6.1: Issue number: i26571
Submitted by: kendy
Reviewed by: rodarvus
Diffstat (limited to 'config_office')
-rw-r--r-- | config_office/configure.in | 157 |
1 files changed, 144 insertions, 13 deletions
diff --git a/config_office/configure.in b/config_office/configure.in index 5810b37cb9a8..1611769d4569 100644 --- a/config_office/configure.in +++ b/config_office/configure.in @@ -3,7 +3,7 @@ dnl * vi:set sw=3 ts=3 et: dnl * dnl * Name: configure.in dnl * Auth: Willem van Dorp, Ross Nicholson, Oisin Boydell - Sun Microsystems Ireland -dnl * Date: $Date: 2004-10-27 15:22:48 $ +dnl * Date: $Date: 2004-10-27 16:14:53 $ dnl * dnl * Desc: This file serves as input for the GNU autoconf package dnl * in order to create a configure script. @@ -12,7 +12,7 @@ dnl * necessary to build OpenOffice.org dnl * dnl * dnl ******************************************************************/ -AC_REVISION( $Revision: 1.73 $ ) +AC_REVISION( $Revision: 1.74 $ ) AC_PREREQ(2.50) AC_INIT() echo "$@" >config.parms @@ -99,11 +99,19 @@ AC_ARG_ENABLE(vctk, [ --enable-vctk Tell configure to check for the MS VC Toolkit 2003. ( This is experimental! ) ],,) +AC_ARG_ENABLE(gtk, +[ --enable-gtk Determines whether to use Gtk+ vclplug on platforms + where Gtk+ is available. +],,) AC_ARG_ENABLE(static-gtk, [ --enable-static-gtk: Modules that are linked against gtk libraries use the static libraries instead of the dynamic ones. (enables -Bstatic linker flag for gtk libraries) ],,) +AC_ARG_ENABLE(kde, +[ --enable-kde Determines whether to use Qt/KDE vclplug on platforms + where Qt and KDE are available. +],,) AC_ARG_ENABLE(rpath, [ --disable-rpath: Disable the use of relative paths in shared libraries ],,) @@ -419,11 +427,13 @@ case "$_os" in "SunOS") test_x=yes test_gtk=yes + test_kde=yes test_cups=yes ;; "Linux") test_x=yes test_gtk=yes + test_kde=yes test_cups=yes ;; "GNU") @@ -441,6 +451,7 @@ case "$_os" in "FreeBSD") test_x=yes test_gtk=yes + test_kde=yes test_cups=no AC_MSG_CHECKING([the FreeBSD operating system release]) if test -n "$with_os_version"; then @@ -465,6 +476,7 @@ case "$_os" in "NetBSD") test_x=yes test_gtk=yes + test_kde=yes test_cups=no PTHREAD_CFLAGS="-pthread" PTHREAD_LIBS="-pthread -lpthread" @@ -1589,6 +1601,22 @@ else AC_MSG_ERROR([xsltproc is required when building with --disable-java.]) fi fi +# check if JAVA_HOME was (maybe incorrectly?) set automatically to /usr +if test "$JAVA_HOME" == "/usr" -a "x$with_jdk_home" == "x"; then + AC_MSG_WARN([JAVA_HOME is set to /usr - this is very likely to be incorrect]) + AC_MSG_WARN([if this is the case, please inform the correct JAVA_HOME with --with-jdk-home]) + echo "JAVA_HOME is set to /usr - this is very likely to be incorrect" >> warn + echo "if this is the case, please inform the correct JAVA_HOME with --with-jdk-home" >> warn +fi +# now check if $JAVA_HOME is really valid +if test ! -d "$JAVA_HOME/jre" -a "x$with_jdk_home" == "x"; then + AC_MSG_WARN([JAVA_HOME was not explicitly informed with --with-jdk-home. the configure script]) + AC_MSG_WARN([attempted to find JAVA_HOME automatically, but apparently it failed]) + AC_MSG_WARN([in case JAVA_HOME is incorrectly set, some projects with not be built correctly]) + echo "JAVA_HOME was not explicitly informed with --with-jdk-home. the configure script" >> warn + echo "attempted to find JAVA_HOME automatically, but apparently it failed" >> warn + echo "in case JAVA_HOME is incorrectly set, some projects with not be built correctly" >> warn +fi AC_SUBST(JAVA_HOME) AC_SUBST(JDK) AC_SUBST(XSLTPROC) @@ -1935,17 +1963,6 @@ AC_SUBST(SYSTEM_GENBRK) AC_SUBST(SYSTEM_GENCCODE) dnl =================================================================== -dnl Check whether the gtk 2.0 libraries are available. -dnl =================================================================== -if test -n "$ENABLE_CRASHDUMP" ; then - - if test "$test_gtk" = "yes"; then - pkg_modules="gtk+-2.0 >= 1.3.13" - PKG_CHECK_MODULES( GTK, [$pkg_modules] ) - fi -fi - -dnl =================================================================== dnl Checks for libraries. dnl =================================================================== dnl Check for Mac OS X native GUI, which may be used instead of X11. @@ -2430,6 +2447,120 @@ AC_SUBST(LIBART_LIBS) AC_SUBST(WITH_GPC) dnl =================================================================== +dnl Test which vclplugs have to be built. +dnl =================================================================== + +ENABLE_GTK="" +if test "x$enable_gtk" == "xyes"; then + ENABLE_GTK="TRUE" +fi +AC_SUBST(ENABLE_GTK) + +ENABLE_KDE="" +if test "x$enable_kde" == "xyes"; then + ENABLE_KDE="TRUE" +fi +AC_SUBST(ENABLE_KDE) + +dnl =================================================================== +dnl Check whether the gtk 2.0 libraries are available. +dnl =================================================================== + +GTK_CFLAGS="" +GTK_LIBS="" +if test "$test_gtk" = "yes"; then + + if test "$ENABLE_GTK" = "TRUE" ; then + PKG_CHECK_MODULES(GTK, gtk+-2.0 >= 2.2) + PKG_CHECK_MODULES(GDKPIXBUF, gdk-pixbuf-xlib-2.0 >= 2.2) + GTK_CFLAGS="$GTK_CFLAGS $GDKPIXBUF_CFLAGS" + GTK_LIBS="$GTK_LIBS $GDKPIXBUF_LIBS" + elif test -n "$ENABLE_CRASHDUMP" ; then + pkg_modules="gtk+-2.0 >= 1.3.13" + PKG_CHECK_MODULES( GTK, [$pkg_modules] ) + fi + +fi +AC_SUBST(GTK_CFLAGS) +AC_SUBST(GTK_LIBS) + +dnl =================================================================== +dnl Check whether the Qt and KDE libraries are available. +dnl =================================================================== + +KDE_CFLAGS="" +KDE_LIBS="" +if test "$test_kde" = "yes" -a "$ENABLE_KDE" = "TRUE" ; then + dnl Search paths for Qt and KDE + qt_incdirs="$QTINC /usr/local/qt/include /usr/include/qt /usr/include /usr/X11R6/include/X11/qt /usr/X11R6/include/qt /usr/lib/qt3/include /usr/lib/qt/include /usr/share/qt3/include $x_includes" + if test -n "$QTDIR" ; then + qt_incdirs="$QTDIR/include $qt_incdirs" + fi + kde_incdirs="/usr/lib/kde/include /usr/local/kde/include /usr/local/include /usr/kde/include /usr/include/kde /usr/include /opt/kde3/include /opt/kde/include $x_includes" + kde_libdirs="/usr/lib/kde/lib /usr/local/kde/lib /usr/kde/lib /usr/lib/kde /usr/lib/kde3 /usr/lib /usr/X11R6/lib /usr/local/lib /opt/kde3/lib /opt/kde/lib /usr/X11R6/kde/lib" + if test -n "$KDEDIR" ; then + kde_incdirs="$KDEDIR/include $kde_incdirs" + kde_libdirs="$KDEDIR/lib $kde_libdirs" + fi + + dnl What to test + qt_test_include="qstyle.h" + kde_test_include="ksharedptr.h" + kde_test_library="libkdeui.la" + + dnl Check for Qt headers + AC_MSG_CHECKING([for Qt headers]) + qt_incdir="no" + for kde_check in $qt_incdirs ; do + if test -r "$kde_check/$qt_test_include" ; then + qt_incdir="$kde_check" + break + fi + done + AC_MSG_RESULT([$qt_incdir]) + if test "x$qt_incdir" == "xno" ; then + AC_MSG_ERROR([Qt headers not found. Please specify the root of +your Qt installation by exporting QTDIR before running "configure".]) + fi + + dnl Check for KDE headers + AC_MSG_CHECKING([for KDE headers]) + kde_incdir="no" + for kde_check in $kde_incdirs ; do + if test -r "$kde_check/$kde_test_include" ; then + kde_incdir="$kde_check" + break + fi + done + AC_MSG_RESULT([$kde_incdir]) + if test "x$kde_incdir" == "xno" ; then + AC_MSG_ERROR([KDE headers not found. Please specify the root of +your KDE installation by exporting KDEDIR before running "configure".]) + fi + + dnl Check for KDE libraries + AC_MSG_CHECKING([for KDE libraries]) + kde_libdir="no" + for kde_check in $kde_libdirs ; do + if test -r "$kde_check/$kde_test_library" ; then + kde_libdir="$kde_check" + break + fi + done + AC_MSG_RESULT([$kde_libdir]) + if test "x$kde_libdir" == "xno" ; then + AC_MSG_ERROR([KDE libraries not found. Please specify the root of +your KDE installation by exporting KDEDIR before running "configure".]) + fi + + dnl Set the variables + KDE_CFLAGS="-I$qt_incdir -I$kde_incdir -DQT_CLEAN_NAMESPACE -DQT_NO_EMIT -DQT_THREAD_SUPPORT" + KDE_LIBS="-L$kde_libdir -lkdeui" +fi +AC_SUBST(KDE_CFLAGS) +AC_SUBST(KDE_LIBS) + +dnl =================================================================== dnl Test for the presence of libstartup-notification dnl =================================================================== |