Oxygen 7.2 and Berkeley DBXML (32/64 bit)

Having trouble installing Oxygen? Got a bug to report? Post it all here.
marclijour
Posts: 3
Joined: Mon Oct 16, 2006 1:52 am
Location: Toronto, ON, Canada

Oxygen 7.2 and Berkeley DBXML (32/64 bit)

Post by marclijour »

Hi,

I run oxygen on linux 64 bit, both as standalone and within Eclipse. I try to run a XQuery which runs perfectly from outside oxygen (via dbxml command line).

1) oXygen standalone
When I run oxygen with a 32bit jvm I find this error:
SystemID: /tmp/Jetty__8080__mmonitor/webapp/WEB-INF/bdbxml_containers/Untitled1.xquery
Description: /usr/local/dbxml-2.2.13-32bit/install/lib/libdb_java-4.3.so: /usr/local/dbxml-2.2.13-32bit/install/lib/libdb_java-4.3.so: cannot open shared object file: No such file or directory
---
These files exist though, and they have been compiled with the -b 32 bit switch and --enable-java. LD_LIBRARY_PATH is set to /usr/local/dbxml-2.2.13-32bit/install/lib .

When I run oxygen with a 64bit jvm (and db.jar dbxml.jar compiled for 64 bit), the application crashes with this error.
#
# An unexpected error has been detected by HotSpot Virtual Machine:
#
# SIGSEGV (0xb) at pc=0x0000000000000000, pid=530, tid=1090312544
#
# Java VM: Java HotSpot(TM) 64-Bit Server VM (1.5.0_08-b03 mixed mode)
# Problematic frame:
# C 0x0000000000000000
#
# An error report file with more information is saved as hs_err_pid530.log
#
# If you would like to submit a bug report, please visit:
# http://java.sun.com/webapps/bugreport/crash.jsp
#
oxygen/oxygen.sh: line 37: 530 Aborted java -Xmx256m "-Dcom.oxygenxml.editor.plugins.dir=$p/plugins" -Dcom.oxygenxml.MultipleInstances=true -cp "$CP" ro.sync.exml.Oxygen "$@"
(I can provide the log file on demand)

2) oXygen Eclipse plugin
I have to run Eclipse with a 32-bit jvm otherwise it crashes when I browse the file system and I wouldn't have the browser widget as well. I copied the jars in [Eclipse-install-folder]/plugins/com.oxygenxml.editor_7.2.0/lib. I have the same kind of error: /usr/local/dbxml-2.2.13-32bit/install/lib/libdb_java-4.3.so: /usr/local/dbxml-2.2.13-32bit/install/lib/libdb_java-4.3.so: cannot open shared object file: No such file or directory
Do you have an idea why it is so?
I ran oxygen before and it worked fine with BDB XML but I can't seem to figure out this one.

I followed all the indications from http://www.oxygenxml.com/doc/ug-oxygenE ... pport.html. However, I have still a question. Is this correct:
"On UNIX: Create a file called oxygen7.0.vmoptions (in case it is not already created) in the OXY_DIR."
As I understand that the plugin runs within eclipse -from the plugins directory- and I don't see what OXY_DIR is doing here. Do you mean [Eclipse-install-folder]/plugins/com.oxygenxml.editor_7.2.0/ ? Is the name of this file different for 7.2?
sorin_ristache
Posts: 4141
Joined: Fri Mar 28, 2003 2:12 pm

Re: Oxygen 7.2 and Berkeley DBXML (32/64 bit)

Post by sorin_ristache »

Hello,
marclijour wrote:Description: /usr/local/dbxml-2.2.13-32bit/install/lib/libdb_java-4.3.so: /usr/local/dbxml-2.2.13-32bit/install/lib/libdb_java-4.3.so: cannot open shared object file: No such file or directory
---
These files exist though, and they have been compiled with the -b 32 bit switch and --enable-java. LD_LIBRARY_PATH is set to /usr/local/dbxml-2.2.13-32bit/install/lib .
Does the Linux user who runs oXygen have read permission for the file /usr/local/dbxml-2.2.13-32bit/install/lib/libdb_java-4.3.so ? If not you have to allow this permission. If the permission is fine and the error is the same make sure that the SUID bit of the Java virtual machine executable is reset. The Java virtual machine executable is the file called java located in the bin subdirectory of the directory listed in the java.home property which you can find in oXygen by going to menu Help -> About -> System properties -> java.home.
I ran oxygen before and it worked fine with BDB XML but I can't seem to figure out this one.
Did you run oXygen logged in as a different Linux user when it worked fine ?
I have still a question. Is this correct:
"On UNIX: Create a file called oxygen7.0.vmoptions (in case it is not already created) in the OXY_DIR."
As I understand that the plugin runs within eclipse -from the plugins directory- and I don't see what OXY_DIR is doing here.
That instruction is valid only for oXygen standalone. We will correct it in the User Manual.


Regards,
Sorin
marclijour
Posts: 3
Joined: Mon Oct 16, 2006 1:52 am
Location: Toronto, ON, Canada

Compilation issue

Post by marclijour »

Hi,

first of all, thank you for your reply.

I could solve the issue when I remembered how I did to compile it the first time. I had to manually change all the configuration files to remove -O2 optimization for -O0. For example:

Code: Select all


#CFLAGS="-g -O2"
CFLAGS="-g -O"
It is not smart but it works with a minimum amount of (tedious) work.

Last time I came across an announcement for a bug with the SUN JDK or something similar. The point is that using -O solves the problem.
$ gcc -v
Using built-in specs.
Target: x86_64-mandriva-linux-gnu
Configured with: ../configure --prefix=/usr --libexecdir=/usr/lib --with-slibdir=/lib64 --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --disable-checking --enable-languages=c,c++,ada,f95,objc,java --host=x86_64-mandriva-linux-gnu --with-system-zlib --enable-long-long --enable-__cxa_atexit --enable-clocale=gnu --disable-libunwind-exceptions --enable-java-awt=gtk --with-java-home=/usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre --enable-gtk-cairo --disable-libjava-multilib
Thread model: posix
gcc version 4.0.1 (4.0.1-5mdk for Mandriva Linux release 2006.0)

(I make SUN javac available on the path when I compile)

I still have the issue with oxygen standalone and specially the plugin.
I made the standalone work but I don't remember how....:(


[/code]
sorin_ristache
Posts: 4141
Joined: Fri Mar 28, 2003 2:12 pm

Re: Compilation issue

Post by sorin_ristache »

Hello,
marclijour wrote:I could solve the issue when I remembered how I did to compile it the first time. I had to manually change all the configuration files to remove -O2 optimization for -O0.
marclijour wrote:I still have the issue with oxygen standalone and specially the plugin. I made the standalone work but I don't remember how....:(
I am sorry, I do not understand. Does the Berkeley DB access work correctly now in <oXygen/> standalone or you still get the error that libdb_java-4.3.so cannot be opened ? If it does not work did you check the permission bits which I specified ?


Regards,
Sorin
marclijour
Posts: 3
Joined: Mon Oct 16, 2006 1:52 am
Location: Toronto, ON, Canada

Post by marclijour »

The -O switch works well enough to produce BDB XML libraries which make the command line interface dbxml work correctly.

I configured LD_LIBRARY_PATH to include the lib directory:

Code: Select all


$ echo $LD_LIBRARY_PATH
:/usr/local/dbxml-2.2.13/install/lib
(these libraries are compiled with gcc with 64 bit options:

Code: Select all


$ gcc -v
Using built-in specs.
Target: x86_64-mandriva-linux-gnu
Configured with: ../configure --prefix=/usr --libexecdir=/usr/lib --with-slibdir=/lib64 --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --disable-checking --enable-languages=c,c++,ada,f95,objc,java --host=x86_64-mandriva-linux-gnu --with-system-zlib --enable-long-long --enable-__cxa_atexit --enable-clocale=gnu --disable-libunwind-exceptions --enable-java-awt=gtk --with-java-home=/usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre --enable-gtk-cairo --disable-libjava-multilib
Thread model: posix
gcc version 4.0.1 (4.0.1-5mdk for Mandriva Linux release 2006.0)
)

STANDALONE
-----------------------
The standalone version works under certain conditions (I can do more testing later but I don't want to touch it while it works, at least for a couple of weeks more).

ECLIPSE PLUGIN
----------------------------
Error message I get:
"Berkeley DB XML libraries are not present in file:/home/marc/eclipse-config/eclipse/plugins/com.oxygenxml.editor_7.2.0/lib/ directory. Please check the XQuery section from the user manual for instructions."

Code: Select all


$ ll /home/marc/eclipse-config/eclipse/plugins/com.oxygenxml.editor_7.2.0/lib/ | grep db
-r--r--r-- 1 marc marc 193713 Oct 17 06:16 db.jar
-r--r--r-- 1 marc marc 44683 Oct 17 06:40 dbxml.jar
I also added these 2 lines in plugin.xml, in the runtime section:

Code: Select all


    <library name="lib/db.jar"/>
<library name="lib/dbxml.jar"/>
I performed all other steps as mentioned in http://www.oxygenxml.com/doc/ug-oxygenE ... pport.html. Why are the files not seen by Eclipse?

At first I thought it could be some sort of binary compatibility issue. However, the problem persists when I run Eclipse with a java 32bit jvm or a java 64bit jvm (the latter is not fully supported on linux ; more specifically it crashes when opening some GTK-based windows ; I get around running Eclipse as 32bit but using 64bit jvm as the compiler in the IDE).

Is there some diagnostic I can run to determine the possible cause(s) of the problem? Did I miss some important configuration step?[/code]
Post Reply