I use this package for work so I'm happy to maintain it. I've updated with a patch for building with Java 8.
Search Criteria
Package Details: java-berkeleydb 5.3.28-3
Package Actions
| Package Base: | java-berkeleydb |
|---|---|
| Description: | Java bindings for the Berkeley DB embedded database system |
| Upstream URL: | http://www.oracle.com/technology/software/products/berkeley-db/index.html |
| Category: | devel |
| Licenses: | |
| Submitter: | bfrog |
| Maintainer: | externl |
| Last Packager: | externl |
| Votes: | 13 |
| First Submitted: | 2008-09-07 19:41 |
| Last Updated: | 2015-06-05 16:41 |
Latest Comments
Comment by externl
Comment by Innominate8
This will only build under jdk7.
Comment by soker
@noctua @OttoA I tested with Oracle Java 8 and OpenJDK and I have the same problem.
Comment by noctua
@dape: I was getting the same error with jni, I just moved the .h-files to the current directory. Modifyingthe paths would work, too, but that would require more changes in other files than the PKGBUILD.
@OttoA: I'm also getting the same error as @soker. Note that I am doing this with Java 1.8 (openjdk).
Comment by OttoA
Bumped to recent version.
Couldn't replicate the errors by @soker and @dape though.
Comment by soker
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
env CLASSPATH="./classes" java -classpath ./classes \
com.sleepycat.persist.model.ClassEnhancer ./classes
java.lang.IllegalArgumentException
at com.sleepycat.asm.ClassReader.<init>(ClassReader.java:167)
at com.sleepycat.asm.ClassReader.<init>(ClassReader.java:153)
at com.sleepycat.persist.model.ClassEnhancer.enhanceBytes(ClassEnhancer.java:297)
at com.sleepycat.persist.model.ClassEnhancer.enhanceFile(ClassEnhancer.java:246)
at com.sleepycat.persist.model.ClassEnhancer.enhanceFile(ClassEnhancer.java:242)
at com.sleepycat.persist.model.ClassEnhancer.enhanceFile(ClassEnhancer.java:242)
at com.sleepycat.persist.model.ClassEnhancer.enhanceFile(ClassEnhancer.java:242)
at com.sleepycat.persist.model.ClassEnhancer.enhanceFile(ClassEnhancer.java:242)
at com.sleepycat.persist.model.ClassEnhancer.main(ClassEnhancer.java:108)
Exception in thread "main" java.lang.IllegalArgumentException
at com.sleepycat.asm.ClassReader.<init>(ClassReader.java:167)
at com.sleepycat.asm.ClassReader.<init>(ClassReader.java:153)
at com.sleepycat.persist.model.ClassEnhancer.enhanceBytes(ClassEnhancer.java:297)
at com.sleepycat.persist.model.ClassEnhancer.enhanceFile(ClassEnhancer.java:246)
at com.sleepycat.persist.model.ClassEnhancer.enhanceFile(ClassEnhancer.java:242)
at com.sleepycat.persist.model.ClassEnhancer.enhanceFile(ClassEnhancer.java:242)
at com.sleepycat.persist.model.ClassEnhancer.enhanceFile(ClassEnhancer.java:242)
at com.sleepycat.persist.model.ClassEnhancer.enhanceFile(ClassEnhancer.java:242)
at com.sleepycat.persist.model.ClassEnhancer.main(ClassEnhancer.java:108)
Makefile:973: recipe for target 'db.jar' failed
make: *** [db.jar] Error 1
==> ERROR: Se produjo un error en build().
Cancelando...
==> ERROR: Makepkg no ha podido compilar java-berkeleydb.
Comment by dape
/libtool --mode=compile cc -c -I. -I../src -D_FORTIFY_SOURCE=2 -D_GNU_SOURCE -D_REENTRANT -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector-strong --param=ssp-buffer-size=4 -fno-strict-aliasing ../lang/java/libdb_java/db_java_wrap.c
libtool: compile: cc -c -I. -I../src -D_FORTIFY_SOURCE=2 -D_GNU_SOURCE -D_REENTRANT -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector-strong --param=ssp-buffer-size=4 -fno-strict-aliasing ../lang/java/libdb_java/db_java_wrap.c -fPIC -DPIC -o .libs/db_java_wrap.o
../lang/java/libdb_java/db_java_wrap.c:137:17: fatal error: jni.h: No such file or directory
#include <jni.h>
^
compilation terminated.
Makefile:2449: recipe for target 'db_java_wrap.lo' failed
make: *** [db_java_wrap.lo] Error 1
==> ERROR: A failure occurred in build().
Aborting...
==> ERROR: Makepkg was unable to build java-berkeleydb.
Comment by ASzc
Patch for update to 5.3.21: http://ix.io/2Qf
Comment by ASzc
You can get a direct download link by dropping the /otn from the URLs provided on the Oracle pages.
Comment by OttoA
I bumped it to 5.3.15 and I don't pull from oracle anymore (requires some kind of signon)
Comment by Athemis
5.1.25 is no longer available for download. Latest release in the 5.1 series is 5.1.29.
Comment by OttoA
But ./configure should figure out where to put the files. I'll leave it as it is for the moment and look into it when I have the time.
Comment by ezzetabi
No, that was the point. First I simply installed your package (so the .la file only) for the Berkeley db java bindings. And hypergraphdb did not work (UnsatisfiedLinkError if I recall correctly); it started to work only when I copied libdb_java-5.1.so. Maybe the openjdk6 JNI needs the .so files?
Comment by OttoA
exactly, the .la file is an archive containing the .so file. Does your program still work when deleting the .so file while keeping the .la file?
Comment by ezzetabi
I was tring hypergraphdb; but the library cannot find its native implementation of java-berkeleydb related methods.
When I copied the libdb_java-5.1.so file in the /usr/lib directory it started to work.
I am not sure I understood, but you mean that the .la file should already contain the shared libraries. Right?
Comment by OttoA
Generally you only need to copy the files that end up in $pkgdir, which is among others usr/lib/libdb_java-5.1.la in this case.
The tests run fine on my machine, why do you think you need the .so file?
Comment by ezzetabi
You forgot to copy the .so file, just add this line in the package function.
install -Dm644 "$srcdir"/db-"$pkgver"/build_unix/.libs/libdb_java-5.1.so \
"$pkgdir"/usr/lib/libdb_java-5.1.so