My experiences with building mlvm based on bsd-port: On missing machine/endian.h if build on linux (FC10 in my case): In jdk: replace with #include <endian.h>
On error: class file for com.sun.jmx.snmp.Timestamp not found: Build does not extract a few binary plug classes, fix jdk: make/common/internal/BinaryPlugs.gmk To-be-encountered :): on NullPointerException for jar tool w...@listoffilesparam: In jdk, src/share/classes/sun/tools/jar/Main.java: set new cwd property before any of the extract() method is called (not only in one extract() method) If using newly build openjdk-1.7.0 as ALT_BOOTDIR, javadoc vm crashes when building certain docs. seemed to happen randomly, no fix, just workaround: In jdk, make/common/shared/Defs-java.gmk: introduced new ALT_JAVADOC to use jdk 6 javadoc Patch files attached fyi, Jürgen 2009/4/24 Chanwit Kaewkasi <chan...@gmail.com> > More update, I am now stuck at this error, while compiling the bsd-port: > > error: class file for com.sun.jmx.snmp.Timestamp not found > 1 error > make[2]: *** [initial-image-jdk] Error 1 > make[2]: Leaving directory `/opt/openjdk/bsd-port/jdk/make' > make[1]: *** [jdk-build] Error 2 > make[1]: Leaving directory `/opt/openjdk/bsd-port' > > The bootstrap jdk I'm using is Sun JDK 1.6.0_04-b12. Not sure if it's > causing this error? > > Any suggestion would be great. > > Best regards, > > Chanwit > > On Thu, Apr 23, 2009 at 10:55 PM, Chanwit Kaewkasi <chan...@gmail.com> > wrote: > > Updated: > > I have managed to fix it per this: > > http://archives.neohapsis.com/archives/openbsd/2004-01/0356.html > > by simply commenting the include statements out. > > > > Cheers, > > > > Chanwit > > > > On Thu, Apr 23, 2009 at 9:34 PM, Tobias Ivarsson <tho...@gmail.com> > wrote: > >> > >> Yes, that is the same error I got when using the same build process that > >> worked for building the jdk7 branch for building the bsd-port branch. > >> Do anyone know if the bsd-port needs some different kind of hand holding > >> when building on linux, compared to the jdk7 branch? > >> > >> Cheers, > >> Tobias > >> > >> _______________________________________________ > >> mlvm-dev mailing list > >> mlvm-dev@openjdk.java.net > >> http://mail.openjdk.java.net/mailman/listinfo/mlvm-dev > >> > > > > > > -- > Chanwit Kaewkasi > PhD Candidate, > Centre for Novel Computing > School of Computer Science > The University of Manchester > Oxford Road > Manchester > M13 9PL, UK > _______________________________________________ > mlvm-dev mailing list > mlvm-dev@openjdk.java.net > http://mail.openjdk.java.net/mailman/listinfo/mlvm-dev >
fix machine/endian.h diff --git a/src/share/native/java/lang/fdlibm/include/fdlibm.h b/src/share/native/java/lang/fdlibm/include/fdlibm.h --- a/src/share/native/java/lang/fdlibm/include/fdlibm.h +++ b/src/share/native/java/lang/fdlibm/include/fdlibm.h @@ -27,7 +27,7 @@ #ifdef __OpenBSD__ #include <sys/types.h> #endif -#include <machine/endian.h> +#include <endian.h> #include "jfdlibm.h" #ifdef __NEWVALID /* special setup for Sun test regime */ diff --git a/src/share/native/sun/awt/medialib/mlib_image.h b/src/share/native/sun/awt/medialib/mlib_image.h --- a/src/share/native/sun/awt/medialib/mlib_image.h +++ b/src/share/native/sun/awt/medialib/mlib_image.h @@ -30,7 +30,7 @@ #ifdef __OpenBSD__ #include <sys/types.h> #endif -#include <machine/endian.h> +#include <endian.h> #include <mlib_types.h> #include <mlib_status.h> diff --git a/src/solaris/back/util_md.h b/src/solaris/back/util_md.h --- a/src/solaris/back/util_md.h +++ b/src/solaris/back/util_md.h @@ -31,7 +31,7 @@ #include <limits.h> #include <sys/types.h> -#include <machine/endian.h> +#include <endian.h> #ifdef _LP64 typedef unsigned long UNSIGNED_JLONG; diff --git a/src/solaris/native/sun/java2d/loops/mlib_ImageZoom_NN.c b/src/solaris/native/sun/java2d/loops/mlib_ImageZoom_NN.c --- a/src/solaris/native/sun/java2d/loops/mlib_ImageZoom_NN.c +++ b/src/solaris/native/sun/java2d/loops/mlib_ImageZoom_NN.c @@ -66,7 +66,7 @@ #ifdef __OpenBSD__ #include <sys/types.h> #endif -#include <machine/endian.h> +#include <endian.h> #include <mlib_image.h> #include <mlib_ImageZoom.h>
fix jmx.snmp binaryplugs diff --git a/make/common/internal/BinaryPlugs.gmk b/make/common/internal/BinaryPlugs.gmk --- a/make/common/internal/BinaryPlugs.gmk +++ b/make/common/internal/BinaryPlugs.gmk @@ -58,6 +58,12 @@ com/sun/jmx/snmp/SnmpTimeticks.class \ com/sun/jmx/snmp/SnmpVarBind.class \ com/sun/jmx/snmp/SnmpVarBindList.class \ +com/sun/jmx/snmp/Timestamp.class \ +com/sun/jmx/snmp/daemon/SnmpRequestCounter.class \ +com/sun/jmx/snmp/daemon/SnmpSocket.class \ +com/sun/jmx/snmp/daemon/SnmpQManager.class \ +com/sun/jmx/snmp/daemon/WaitQ.class \ +com/sun/jmx/snmp/daemon/SnmpResponseHandler.class \ com/sun/jmx/snmp/daemon/SendQ.class \ com/sun/jmx/snmp/daemon/SnmpInformRequest.class \ com/sun/jmx/snmp/daemon/SnmpSession.class
fix sun.tools.jar diff --git a/src/share/classes/sun/tools/jar/Main.java b/src/share/classes/sun/tools/jar/Main.java --- a/src/share/classes/sun/tools/jar/Main.java +++ b/src/share/classes/sun/tools/jar/Main.java @@ -241,6 +241,16 @@ } } else if (xflag) { replaceFSC(files); + // Current working directory + cwd = System.getProperty("user.dir"); + if (cwd == null) { + fatalError(getMsg("error.no.cwd")); + } + cwd = (new File(cwd)).getCanonicalPath(); + if (!cwd.endsWith(File.separator)) { + cwd += File.separator; + } + if (fname != null && files != null) { extract(fname, files); } else { @@ -802,17 +812,6 @@ * Extracts specified entries from JAR file. */ void extract(InputStream in, String files[]) throws IOException { - // Current working directory - - cwd = System.getProperty("user.dir"); - if (cwd == null) { - fatalError(getMsg("error.no.cwd")); - } - cwd = (new File(cwd)).getCanonicalPath(); - if (!cwd.endsWith(File.separator)) { - cwd += File.separator; - } - // Extract the files ZipInputStream zis = new ZipInputStream(in);
_______________________________________________ mlvm-dev mailing list mlvm-dev@openjdk.java.net http://mail.openjdk.java.net/mailman/listinfo/mlvm-dev