[100489] trunk/dports/databases/db46/Portfile
blair at macports.org
blair at macports.org
Fri Dec 14 00:01:53 PST 2012
Revision: 100489
https://trac.macports.org/changeset/100489
Author: blair at macports.org
Date: 2012-12-14 00:01:53 -0800 (Fri, 14 Dec 2012)
Log Message:
-----------
db46-java: set JAVA_HOME to JDK 1.5 to ensure dependent ports can compile.
Modified Paths:
--------------
trunk/dports/databases/db46/Portfile
Modified: trunk/dports/databases/db46/Portfile
===================================================================
--- trunk/dports/databases/db46/Portfile 2012-12-14 07:37:20 UTC (rev 100488)
+++ trunk/dports/databases/db46/Portfile 2012-12-14 08:01:53 UTC (rev 100489)
@@ -74,8 +74,26 @@
subport ${name}-java {
depends_lib-append port:${name}
+ # Compile BerkeleyDB's Java bindings with Java 1.5 as this is the
+ # oldest version of Java that the bindings are known to compile
+ # with. This is done because ports that depend upon db46-java may
+ # be compiled with Apache Ant and Ant explicitly sets JAVA_HOME to
+ # /System/Library/Frameworks/JavaVM.framework/Home if JAVA_HOME is
+ # not already set. If Oracle's JDK 7 is installed on the Mac and
+ # is set as the default Java version, then when BerkeleyDB's Java
+ # bindings are compiled the *.class files will be a newer format
+ # then the older Java in $JAVA_HOME can read. So just compile
+ # BerkeleyDB with the oldest version of Java that can compile it.
+ # There is no harm in doing so as at application run time newer
+ # JVMs can read older class files and optimize them as if they
+ # were compiled with a newer version of Java. The only
+ # performance loss may be a slightly longer class loading time,
+ # which is optimized in newer versions of Java.
+ configure.env JAVA_HOME=/System/Library/Frameworks/JavaVM.framework/Versions/1.5/Home
configure.args-append --enable-java
+ build.env JAVA_HOME=/System/Library/Frameworks/JavaVM.framework/Versions/1.5/Home
+
platform macosx {
pre-configure {
if {![file isfile "/System/Library/Frameworks/JavaVM.framework/Headers/jni.h"]} {
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20121214/6a59defc/attachment.html>
More information about the macports-changes
mailing list