configure check of OpenOffice.org 1.1.4 or 1.9 with system DB patchset won't find system's DB db4-2.jar because it does not follow FHS standard where there jar files belong to /usr/share/... in general storing jar files into /usr/share/java could be very cool of any package except filenames would conflict. thanks! :) Reproducible: Always Steps to Reproduce: 1. compiling OOo with system DB support Actual Results: errors out Expected Results: that DB follows FHS standard it is not the problem here that OOo breaks on configure. it is the problem that DB package does not follow FHS standard. part of config_office/configure and see where it looks for db*.jar + if test -z $DB_VERSION && test -z $DB_VERSION_MAJOR; then + AC_CHECK_FILE(/usr/lib/libdb.so, [], + [AC_MSG_ERROR(no. install db)]) + # (almost) all db packages (rpm/deb) I saw have this link pointing to + # libdb-cxx_X.so where X is the first two digits of the db version .. + # tell me if there is some other type... + DB_VERSION=$(readlink /usr/lib/libdb.so \ + | $SED -e s/libdb-// | $SED -e s/\.so//) + DB_VERSION_MAJOR=$(echo $DB_VERSION | cut -d"." -f1) + DB_VERSION_MINOR=$(echo $DB_VERSION | cut -d"." -f2) + fi + AC_MSG_CHECKING([db version]) + if test "$DB_VERSION_MAJOR" -lt "4"; then + AC_MSG_ERROR([$DB_VERSION, you need db 4.x, x >= 1]) + elif test "$DB_VERSION_MINOR" -lt "1"; then + AC_MSG_ERROR([$DB_VERSION, you need db 4.x, x >= 1]) + else + AC_MSG_RESULT([$DB_VERSION, ok]) + fi + AC_CHECK_HEADER(db.h, [ DB_INCLUDES=/usr/include ], + [ + CFLAGS=-I/usr/include/db$DB_VERSION_MAJOR + AC_CHECK_HEADER(db$DB_VERSION_MAJOR/db_cxx.h, + [ DB_INCLUDES=/usr/include/db$DB_VERSION_MAJOR ], + [ AC_MSG_ERROR(no. install the dbDB_VERSION_MAJOR libraries) ], []+ ) + ], [] + ) + # does not work :/ + #AC_CHECK_LIB(db, db_create, [], + # [AC_MSG_ERROR([db library not installed or functional])], []) + AC_HAVE_LIBRARY(db, [], + [AC_MSG_ERROR([db not installed or functional])], []) + if test "$enable_java" != "no"; then + if test -z $DB_JAR; then + # three different naming methods *grumble* Are there even more? + AC_CHECK_FILE(/usr/share/java/db.jar, [ JARVER=0 ], + [ + AC_CHECK_FILE(/usr/share/java/db-$DB_VERSION.jar, [ JARVER=1 ], + [ AC_CHECK_FILE(/usr/share/java/libdb$DB_VERSION-java.jar, + [ JARVER_LONGSTYLE=1 ], + [ AC_MSG_ERROR(db$DB_VERSION_MAJOR Java bindings not found)] + ) + ] + ) + ] + ) + if test "$JARVER" = "1"; then + DB_JAR=jar-$DB_VERSION.jar + else + DB_JAR=db.jar + fi + if test "$JARVER_LONGSTYLE" = "1"; then + DB_JAR=libdb$DB_VERSION-java.jar + fi + fi + fi anomalie ~ # emerge info Portage 2.0.51-r10 (default-linux/x86/2004.3, gcc-3.4.3, glibc-2.3.4.20041102-r0, 2.6.10-ano1 i686) ================================================================= System uname: 2.6.10-ano1 i686 Intel(R) Pentium(R) 4 CPU 2.80GHz Gentoo Base System version 1.6.8 Python: dev-lang/python-2.4 [2.4 (#1, Dec 21 2004, 18:16:26)] dev-lang/python: 2.4 sys-devel/autoconf: 2.13, 2.59-r6 sys-devel/automake: 1.4_p6, 1.8.5-r2, 1.6.3, 1.9.4, 1.5, 1.7.9 sys-devel/binutils: 2.15.94.0.1, 2.15.94.0.2 sys-devel/libtool: 1.5.10-r2 virtual/os-headers: 2.6.8.1-r2 ACCEPT_KEYWORDS="x86 ~x86" AUTOCLEAN="yes" CFLAGS="-O2 -mtune=pentium4 -march=pentium4 -pipe -fforce-addr -fforce-mem -momit-leaf-frame-pointer -fomit-frame-pointer -fweb -ftracer -frename-registers" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.3/env /usr/kde/3.3/share/config /usr/kde/3.3/shutdown /usr/kde/3/share/config /usr/lib/X11/xkb /usr/share/config /var/qmail/control" CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d" CXXFLAGS="-O2 -mtune=pentium4 -march=pentium4 -pipe -fforce-addr -fforce-mem -momit-leaf-frame-pointer -fomit-frame-pointer -fweb -ftracer -frename-registers -fvisibility-inlines-hidden" DISTDIR="/usr/portage/distfiles" FEATURES="autoaddcvs autoconfig ccache distlocks sandbox sfperms" GENTOO_MIRRORS="http://ftp.uni-erlangen.de/pub/mirrors/gentoo http://linux.rz.ruhr-uni-bochum.de/download/gentoo-mirror/ http://gentoo.inode.at/ ftp://gentoo.inode.at/source/" LDFLAGS="-Wl,-O1 -Wl,--enable-new-dtags -Wl,--sort-common -s" MAKEOPTS="-j3" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="/usr/local/portage" SYNC="rsync://rsync.gentoo.org/gentoo-portage" USE="X aalib acpi alsa apache2 avi berkdb bitmap-fonts cdr cups curl dga dts dvd dvdr dvdread fastcgi fbcon gcj gd gif glx gpm gtk gtk2 hardenedphp icq imap imlib ipv6 java jpeg ldap lesstif libwww mad mbox mmx mmx2 motif mpeg multislot mysql ncurses nls nptl nptlonly nvidia oggvorbis opengl pam pdflib perl png python qt quicktime readline sasl sdl sse sse2 ssl tcltk tcpd tiff truetype truetype-fonts type1-fonts unicode usb userlocales vhosts videos wmf wxwindows x86 xface xinerama xml xml2 xmms xprint xv xvid zlib video_cards_nvidia linguas_de" thanks for supporting FHS standard :)
/usr/lib http://www.pathname.com/fhs/pub/fhs-2.3.html#USRLIBLIBRARIESFORPROGRAMMINGANDPA /usr/share http://www.pathname.com/fhs/pub/fhs-2.3.html#USRSHAREARCHITECTUREINDEPENDENTDATA latter one sounds better to me
Well, in my opinion this is another gap in the FHS. /usr/share is for data. The jar file is not data, it is a library. However, it is also machine independent. Also that leaves the "choice" on where to put the data. Jar libraries are not bound to an application, so should not receive an application specific directory, but would overflow /usr/share/misc. /usr/share/java would indeed be a good candidate, but is nowhere mandated or suggested by the FHS. In absense of clear guidelines, I opt to leave the file where the upstream authors put it, as that is the clearest option. I am however in favour of getting a central location for gentoo to put all jar files. If I look at the output of "locate *.jar" I now see that all jar files are all over the place. For your (beta) openoffice ebuild I suggest that you add a patch to have it look in /usr/lib too, as that is the place where the file is installed by default. We don't put things at a certain location just because some other distributor does so. If you look at the FHS, the best fit I can found would be something along the lines of /usr/libjava http://www.pathname.com/fhs/pub/fhs-2.3.html#USRLIBLTQUALGTALTERNATEFORMATLIBRARI