openbsd-ports/editors/openoffice3/patches/patch-configure_in
robert 2e1e7acb0e update to openoffice-3.1.0
- introduce a no_java flavor because now we can build OOo w/o having jdk and
  other java dependencies installed
- introduce a parallel flavor that allows people to build OOo with parallel
  processes. to achieve this we use a so called "non-blocking" cat, so
  another distfile has been added in order two provide to pre-built static
  binaries with the needed modifications (for amd64 and i386)
  By default we run a parallel build with NCPU+1 processes.
- remove unneccessary patch files
- fix some dependencies
2009-05-08 15:43:50 +00:00

205 lines
9.8 KiB
Plaintext

--- configure.in.orig.port Wed Apr 15 16:46:34 2009
+++ configure.in Fri May 8 11:01:46 2009
@@ -1001,6 +1001,18 @@ case "$build_os" in
echo "AIX is an alpha port --- Use at own risk" >> warn
_os=AIX
;;
+ openbsd*)
+ test_x=yes
+ test_gtk=yes
+ build_cairo=yes
+ test_kde=yes
+ test_cups=yes
+ test_freetype=yes
+ test_randr=yes
+ PTHREAD_CFLAGS="-pthread -D_THREAD_SAFE"
+ PTHREAD_LIBS="-pthread"
+ _os=OpenBSD
+ ;;
*)
AC_MSG_ERROR([$_os operating system is not suitable to build OpenOffice.org!])
;;
@@ -2310,6 +2322,8 @@ dnl ==================================================
DEFAULT_TO_STLPORT="yes"
elif test "$_os" = "FreeBSD"; then
DEFAULT_TO_STLPORT="yes"
+ elif test "$_os" = "OpenBSD"; then
+ DEFAULT_TO_STLPORT="no"
fi
if test "$DEFAULT_TO_STLPORT" = "yes"; then
AC_MSG_RESULT([stlport])
@@ -3124,6 +3138,9 @@ if test "$_os" != "WINNT" -a \( "z$enable_epm" = "z" -
AIX)
PKGFORMAT=aix
;;
+ OpenBSD)
+ PKGFORMAT=portable
+ ;;
*BSD)
PKGFORMAT=bsd
;;
@@ -3453,7 +3470,7 @@ if test -n "$with_system_libwpd" -o -n "$with_system_l
test "$with_system_libwpd" != "no"; then
AC_MSG_RESULT([external])
SYSTEM_LIBWPD=YES
- PKG_CHECK_MODULES( LIBWPD, libwpd-0.8 )
+ PKG_CHECK_MODULES( LIBWPD, libwpd )
else
AC_MSG_RESULT([internal])
SYSTEM_LIBWPD=NO
@@ -3573,12 +3590,13 @@ if test -n "$with_system_python" -o -n "$with_system_l
python_include=`$PYTHON -c "import distutils.sysconfig; print distutils.sysconfig.get_config_var('INCLUDEPY');"`
python_version=`$PYTHON -c "import distutils.sysconfig; print distutils.sysconfig.get_config_var('VERSION');"`
+ python_libs=`$PYTHON -c "import distutils.sysconfig; print distutils.sysconfig.get_config_var('LIBS');"`
PYTHON_CFLAGS="-I$python_include"
if test "$_os" = "Darwin"; then
PYTHON_LIBS="-framework Python"
else
- PYTHON_LIBS="-lpython$python_version"
+ PYTHON_LIBS="-lpython$python_version $python_libs"
fi
dnl check if the headers really work:
@@ -3617,16 +3635,13 @@ if test -n "$with_system_db" -o -n "$with_system_libs"
test "$with_system_db" != "no"; then
SYSTEM_DB=YES
AC_MSG_RESULT([external])
- AC_CHECK_HEADER(db.h, [ DB_INCLUDES=/usr/include ],
- [
- CFLAGS=-I/usr/include/db4
- AC_CHECK_HEADER(db4/db.h,
- [ DB_INCLUDES=/usr/include/db4 ],
- [ AC_MSG_ERROR(no. install the db4 libraries) ], []+ )
- ], []
+ AC_CHECK_HEADER(db4/db.h, [ DB_INCLUDES=${prefix}/include/db4 ],
+ [ AC_MSG_ERROR(no. install the db4 libraries) ], []
)
AC_MSG_CHECKING([whether db is at least 4.1])
- for v in `seq 1 7`; do
+ save_CPPFLAGS=$CPPFLAGS
+ CPPFLAGS=-I$DB_INCLUDES
+ for v in `jot - 1 7 1`; do
AC_TRY_RUN([
#include <db.h>
@@ -3636,6 +3651,7 @@ int main(int argc, char **argv) {
}
], [DB_VERSION_MINOR=$v], [])
done
+ CPPFLAGS=$save_CPPFLAGS
if test "$DB_VERSION_MINOR" -gt "1"; then
AC_MSG_RESULT([OK])
DB_VERSION=4.$DB_VERSION_MINOR
@@ -4238,11 +4254,11 @@ if test -n "$with_system_icu" -o -n "$with_system_libs
if test -z "$SYSTEM_GENBRK"; then
AC_MSG_ERROR([\"genbrk\" not found in \$PATH, install the icu development tool \"genbrk"\])
fi
- AC_PATH_PROG(SYSTEM_GENCCODE, genccode, [], [$PATH:/usr/sbin:/sbin])
+ AC_PATH_PROG(SYSTEM_GENCCODE, genccode, [], [$PATH:/usr/sbin:/sbin:/usr/local/sbin])
if test -z "$SYSTEM_GENCCODE"; then
AC_MSG_ERROR([\"genccode\" not found in \$PATH, install the icu development tool \"genccode"\])
fi
- AC_PATH_PROG(SYSTEM_GENCMN, gencmn, [], [$PATH:/usr/sbin:/sbin])
+ AC_PATH_PROG(SYSTEM_GENCMN, gencmn, [], [$PATH:/usr/sbin:/sbin:/usr/local/sbin])
if test -z "$SYSTEM_GENCMN"; then
AC_MSG_ERROR([\"gencmn\" not found in \$PATH, install the icu development tool \"gencmn"\])
fi
@@ -4324,7 +4340,7 @@ elif test "$_os" != "WINNT" ; then
AC_MSG_ERROR([No X includes found]) # Exit
fi
CFLAGS=$X_CFLAGS
- LDFLAGS="$X_LDFLAGS $X_LIBS"
+ LDFLAGS="$LDFLAGS $X_LDFLAGS $X_LIBS"
AC_CHECK_LIB(X11, XOpenDisplay, x_libs="-lX11 $X_EXTRA_LIBS", [AC_MSG_ERROR([X Development libraries not found])])
dnl Check if the XauDisposeAuth symbol is provided by libXau.
AC_CHECK_LIB(Xau, XauDisposeAuth, XAU_LIBS="-lXau", [])
@@ -4495,7 +4511,7 @@ if test -n "$with_system_openssl" -o -n "$with_system_
AC_MSG_RESULT([external])
# Mac OS builds should get out without extra stuff is the Mac porters'
# wish. And pkg-config is although Xcode ships a .pc for openssl
- if test "$_os" = "Darwin"; then
+ if test "$_os" = "Darwin" || test "$_os" = "OpenBSD"; then
OPENSSL_CFLAGS=
OPENSSL_LIBS="-lssl -lcrypto"
else
@@ -5696,42 +5712,23 @@ KDE_LIBS=""
MOC="moc"
if test "$test_kde" = "yes" -a "$ENABLE_KDE" = "TRUE" ; then
dnl Search paths for Qt and KDE
- if test "$build_cpu" != "x86_64" ; then
- 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"
- qt_libdirs="$QTLIB /usr/local/qt/lib /usr/lib/qt /usr/lib /usr/X11R6/lib/X11/qt /usr/X11R6/lib/qt /usr/lib/qt3/lib /usr/lib/qt/lib /usr/share/qt3/lib $x_libraries"
- else
- qt_incdirs="$QTINC /usr/local/qt/include /usr/include/qt /usr/include /usr/X11R6/include/X11/qt /usr/X11R6/include/qt /usr/lib64/qt3/include /usr/lib64/qt/include /usr/share/qt3/include /usr/lib/qt3/include /usr/lib/qt/include $x_includes"
- qt_libdirs="$QTLIB /usr/local/qt/lib64 /usr/lib64/qt /usr/lib64 /usr/X11R6/lib64/X11/qt /usr/X11R6/lib64/qt /usr/lib64/qt3/lib64 /usr/lib64/qt/lib64 /usr/share/qt3/lib64 /usr/local/qt/lib /usr/lib/qt /usr/lib /usr/X11R6/lib/X11/qt /usr/X11R6/lib/qt /usr/lib/qt3/lib /usr/lib/qt/lib /usr/share/qt3/lib $x_libraries"
- fi
+ 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 /usr/lib/qt3/include /usr/lib/qt/include $x_includes"
+ qt_libdirs="$QTLIB /usr/local/qt/lib /usr/lib/qt /usr/lib /usr/X11R6/lib/X11/qt /usr/X11R6/lib/qt /usr/lib/qt3/lib /usr/lib/qt/lib /usr/share/qt3/lib /usr/local/qt/lib /usr/lib/qt /usr/lib /usr/X11R6/lib/X11/qt /usr/X11R6/lib/qt /usr/lib/qt3/lib /usr/lib/qt/lib /usr/share/qt3/lib $x_libraries"
if test -n "$QTDIR" ; then
qt_incdirs="$QTDIR/include $qt_incdirs"
- if test "$build_cpu" != "x86_64" ; then
- qt_libdirs="$QTDIR/lib $qt_libdirs"
- else
- qt_libdirs="$QTDIR/lib64 $QTDIR/lib $qt_libdirs"
- fi
+ qt_libdirs="$QTDIR/lib $qt_libdirs"
fi
- if test "$build_cpu" != "x86_64" ; then
- 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 $x_libraries"
- else
- kde_incdirs="/usr/lib64/kde/include /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/lib64/kde/lib64 /usr/local/kde/lib64 /usr/kde/lib64 /usr/lib64/kde /usr/lib64/kde3 /usr/lib64 /usr/X11R6/lib64 /usr/local/lib64 /opt/kde3/lib64 /opt/kde/lib64 /usr/X11R6/kde/lib64 /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 $x_libraries"
- 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/local/lib /usr/lib/kde/lib /usr/local/kde/lib /usr/kde/lib /usr/lib/kde /usr/lib/kde3 /usr/lib /usr/X11R6/lib /opt/kde3/lib /opt/kde/lib /usr/X11R6/kde/lib $x_libraries"
if test -n "$KDEDIR" ; then
- kde_incdirs="$KDEDIR/include $kde_incdirs"
- if test "$build_cpu" != "x86_64" ; then
- kde_libdirs="$KDEDIR/lib $kde_libdirs"
- else
- kde_libdirs="$KDEDIR/lib64 $KDEDIR/lib $kde_libdirs"
- fi
+ kde_libdirs="$KDEDIR/lib $kde_libdirs"
fi
dnl What to test
qt_test_include="qstyle.h"
- qt_test_library="libqt-mt.so"
+ qt_test_library="libqt-mt.so*"
kde_test_include="ksharedptr.h"
- kde_test_library="libkdeui.so"
+ kde_test_library="libkdeui.so*"
dnl Check for Qt headers
AC_MSG_CHECKING([for Qt headers])
@@ -5752,7 +5749,7 @@ your Qt installation by exporting QTDIR before running
AC_MSG_CHECKING([for Qt libraries])
qt_libdir="no"
for qt_check in $qt_libdirs ; do
- if test -r "$qt_check/$qt_test_library" ; then
+ if test -r "`ls $qt_check/$qt_test_library | head -1`" ; then
qt_libdir="$qt_check"
break
fi
@@ -5788,7 +5785,7 @@ your KDE installation by exporting KDEDIR before runni
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
+ if test -r "`ls $kde_check/$kde_test_library | head -1`" ; then
kde_libdir="$kde_check"
break
fi
@@ -5965,7 +5962,7 @@ AC_SUBST(WITHOUT_AFMS)
AC_SUBST(SCPDEFS)
AC_MSG_CHECKING([whether and how to use Xinerama])
-if test "$_os" = "Darwin"; then
+if test "$_os" = "Darwin" -o "$_os" = "OpenBSD"; then
USE_XINERAMA=YES
XINERAMA_LINK=dynamic
AC_MSG_RESULT([yes])