Hi Bryan, Thanks for digging into it. Some comments inline below.
On Mon, 2015-04-27 at 13:34 -0400, Bryan C. Everly wrote: > OK. It compiled for quite some time and then hit a warning that > caused the build to stop. Apparently there is a "treat warnings as > errors" flag set in the build scripts. > > > I found it in hotspot/bsd/makefiles/gcc.make and commented it out just > to keep moving. There's getting it to compile and then there's doing the porting work to address OpenBSD differences. I never treated the two steps separately and fixed each problem correctly as I hit them. Pushing forward and ignoring or patching away these problems will give you a result that doesn't work very well. Debugging issues from Java programs back to the C/C++ hotspot/jdk code can be difficult to say the least. If the compiler is telling there's a problem, it will save lots of time later if you address it upfront. In most cases you can just look at bsd-port/bsd-port (OpenJDK 7) for the solution. > Next error I hit was in os_posix.cpp on line 175 and 195. RLIMIT_AS > was not declared in this scope. From looking at the man page for > getrlimit() it looks like that is one that isn't available on OpenBSD. > While I should have spent more time looking for an analog (maybe > RLIMIT_RSS or RLIMIT_DATA?) I just put an #ifndef __OpenBSD__ around > the two code segments and pressed on. Please see bsd-port/bsd-port (OpenJDK 7) for the correct way to deal with this on OpenBSD: http://hg.openjdk.java.net/bsd-port/bsd-port/hotspot/file/cdc8d4039989/src/os/posix/vm/os_posix.cpp#l178 Memory management on OpenBSD is different then other operating systems due to ASLR and the use of mmap for malloc. I have incorporated those differences into the OpenJDK 7 port. You should port those OpenBSD specific parts forward instead of creating new solutions. The current ones have been tested over many years of use. Also, before posting any diffs here, please sign and submit the contributors agreement (OCA): http://openjdk.java.net/contribute/ I wont be able to accept any diffs from you unless you're listed in the OCA Signatories List: http://www.oracle.com/technetwork/community/oca-486395.html If you post diffs while not being a contributor, I will need to ignore them and independently develop my own corrections. Thanks for starting this effort. Regards, -Kurt