From jgibson at mitre.org Sat Oct 4 17:02:38 2008 From: jgibson at mitre.org (John Gibson) Date: Sat, 4 Oct 2008 20:02:38 -0400 Subject: Binaries Message-ID: <971E9FEF-9C88-41C2-8E0B-F8FF42085CED@mitre.org> Hi, Are OS X OpenJDK binaries available for download? I'm on 10.4 (and can't use XCode 3.1) so I can't build it myself. Thanks, John From mvfranz at gmail.com Sat Oct 4 20:15:49 2008 From: mvfranz at gmail.com (Michael Franz) Date: Sat, 4 Oct 2008 23:15:49 -0400 Subject: How to differentiate between BSD and OSX and POST_STRIP_PROCESS In-Reply-To: <48DFD810.9070701@sun.com> References: <48DFD810.9070701@sun.com> Message-ID: I have this small patch to fix the strip -g not being valid on OS X. diff -r 3057550cd8b4 make/common/Defs-bsd.gmk --- a/make/common/Defs-bsd.gmk Wed Aug 20 21:22:02 2008 -0700 +++ b/make/common/Defs-bsd.gmk Sat Oct 04 23:12:10 2008 -0400 @@ -209,8 +209,12 @@ AUTOMATIC_PCH_OPTION = # ifeq ($(VARIANT), OPT) ifneq ($(NO_STRIP), true) - # Debug 'strip -g' leaves local function Elf symbols (better stack traces) - POST_STRIP_PROCESS = $(STRIP) -g + ifneq ($(OS_VENDOR), Apple) + # Debug 'strip -g' leaves local function Elf symbols (better stack traces) + POST_STRIP_PROCESS = $(STRIP) -g + else + POST_STRIP_PROCESS = $(STRIP) + endif endif endif Michael On Sun, Sep 28, 2008 at 3:16 PM, Kelly O'Hair wrote: > Maybe something along the lines of this? > > UNAME_S := $(shell uname -s) > POST_STRIP_PROCESS-Darwin= ... > POST_STRIP_PROCESS-Linux= ... > POST_STRIP_PROCESS-SunOS= ... > ... > POST_STRIP_PROCESS=$(POST_STRIP_PROCESS-$(UNAME_S)) > > -kto > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081004/0136d776/attachment.html From mvfranz at gmail.com Sat Oct 4 20:16:53 2008 From: mvfranz at gmail.com (Michael Franz) Date: Sat, 4 Oct 2008 23:16:53 -0400 Subject: Binaries In-Reply-To: <971E9FEF-9C88-41C2-8E0B-F8FF42085CED@mitre.org> References: <971E9FEF-9C88-41C2-8E0B-F8FF42085CED@mitre.org> Message-ID: The only binaries that I know of can be downloaded here: http://landonf.bikemonkey.org/ On Sat, Oct 4, 2008 at 8:02 PM, John Gibson wrote: > Hi, > > Are OS X OpenJDK binaries available for download? I'm on 10.4 (and > can't use XCode 3.1) so I can't build it myself. > > Thanks, > > John > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081004/67adbda8/attachment.html From Kelly.Ohair at Sun.COM Sun Oct 5 12:27:03 2008 From: Kelly.Ohair at Sun.COM (Kelly O'Hair) Date: Sun, 05 Oct 2008 12:27:03 -0700 Subject: How to differentiate between BSD and OSX and POST_STRIP_PROCESS In-Reply-To: References: <48DFD810.9070701@sun.com> Message-ID: <48E91507.4090006@sun.com> Could we do something like this instead? ifeq ($(OS_VENDOR), Apple) STRIP_G_OPTION = else # strip option that leaves local function Elf symbols (better stack traces) STRIP_G_OPTION = -g endif ifeq ($(VARIANT), OPT) ifneq ($(NO_STRIP), true) # Debug 'strip -g' leaves local function Elf symbols (better stack traces) POST_STRIP_PROCESS = $(STRIP) $(STRIP_G_OPTION) endif endif -kto Michael Franz wrote: > I have this small patch to fix the strip -g not being valid on OS X. > > diff -r 3057550cd8b4 make/common/Defs-bsd.gmk > --- a/make/common/Defs-bsd.gmk Wed Aug 20 21:22:02 2008 -0700 > +++ b/make/common/Defs-bsd.gmk Sat Oct 04 23:12:10 2008 -0400 > @@ -209,8 +209,12 @@ AUTOMATIC_PCH_OPTION = > # > ifeq ($(VARIANT), OPT) > ifneq ($(NO_STRIP), true) > - # Debug 'strip -g' leaves local function Elf symbols (better stack > traces) > - POST_STRIP_PROCESS = $(STRIP) -g > + ifneq ($(OS_VENDOR), Apple) > + # Debug 'strip -g' leaves local function Elf symbols (better > stack traces) > + POST_STRIP_PROCESS = $(STRIP) -g > + else > + POST_STRIP_PROCESS = $(STRIP) > + endif > endif > endif > > Michael > > On Sun, Sep 28, 2008 at 3:16 PM, Kelly O'Hair > wrote: > > Maybe something along the lines of this? > > UNAME_S := $(shell uname -s) > POST_STRIP_PROCESS-Darwin= ... > POST_STRIP_PROCESS-Linux= ... > POST_STRIP_PROCESS-SunOS= ... > ... > POST_STRIP_PROCESS=$(POST_STRIP_PROCESS-$(UNAME_S)) > > -kto > > > ------------------------------------------------------------------------ > > From mvfranz at gmail.com Sun Oct 5 17:45:10 2008 From: mvfranz at gmail.com (Michael Franz) Date: Sun, 5 Oct 2008 20:45:10 -0400 Subject: How to differentiate between BSD and OSX and POST_STRIP_PROCESS In-Reply-To: <48E91507.4090006@sun.com> References: <48DFD810.9070701@sun.com> <48E91507.4090006@sun.com> Message-ID: That will work too. On Sun, Oct 5, 2008 at 3:27 PM, Kelly O'Hair wrote: > Could we do something like this instead? > > ifeq ($(OS_VENDOR), Apple) > STRIP_G_OPTION = > else > # strip option that leaves local function Elf symbols (better stack > traces) > STRIP_G_OPTION = -g > endif > > ifeq ($(VARIANT), OPT) > ifneq ($(NO_STRIP), true) > # Debug 'strip -g' leaves local function Elf symbols (better stack > traces) > POST_STRIP_PROCESS = $(STRIP) $(STRIP_G_OPTION) > endif > endif > > > > -kto > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081005/80a203a7/attachment.html From mvfranz at gmail.com Sun Oct 5 17:47:16 2008 From: mvfranz at gmail.com (Michael Franz) Date: Sun, 5 Oct 2008 20:47:16 -0400 Subject: Darwin OpenJDK 7 Binaries - Not Working With SWT In-Reply-To: <3B0CBA27-1463-426B-8AA1-E7B00D557E25@plausiblelabs.com> References: <6CB8264F-247A-4B48-A5D6-904263F92144@apple.com> <3B0CBA27-1463-426B-8AA1-E7B00D557E25@plausiblelabs.com> Message-ID: For the -XstartOnFirstThread patch, was files are relevant for the change? I started to look at src/os/bsd/launcher/java_md.c but not sure that is the correct place Michael On Sun, Sep 7, 2008 at 9:22 PM, Landon Fuller wrote: > > On Sep 7, 2008, at 1:08 PM, Michael Franz wrote: > > I changed the startup to not pass the flag. I was running this from >> inside eclipse, but eclipse must somehow pass the option as it did not show >> up in the command. >> > > There are two small patches from SoyLatte that need to be re-implemented > for OpenJDK, both of which you have run into: > > -XstartOnFirstThread: > > Soylatte by starts a Cocoa runloop on the first thread, and then run > the JVM main() function again on a separate thread > Setting -XstartOnFirstThread has the same behavior on Mac OS X, in > that Java is started directly on the first thread. > > dylib vs. jnilib (your current issue): > > Soylatte first searched for dylib, then fell back to jnilib. OpenJDK > only searches for .dylib, with no fallback. > > Apologies for radio silence on my part, I've been nose down on an iPhone > development contract these past two weeks. > > -landonf > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081005/0e4ea8f9/attachment.html From mvfranz at gmail.com Sun Oct 5 20:25:33 2008 From: mvfranz at gmail.com (Michael Franz) Date: Sun, 5 Oct 2008 23:25:33 -0400 Subject: Darwin OpenJDK 7 Binaries - Not Working With SWT In-Reply-To: References: <6CB8264F-247A-4B48-A5D6-904263F92144@apple.com> Message-ID: Hi, Do any other platforms support multiple dynamically load library extensions? I was thinking that the JNI_LIB_SUFFIX could be defined as a space (or comma) delimited list of extensions and then change Java_java_lang_System_mapLibraryName in jdk/src/share/native/java/lang/System.c to be able to handle the parsing of the JNI_LIB_SUFFIX string. The order in the list would specify the search order. Thoughts? Michael > > Sounds like OpenJDK is not recognizing .jnilib files as valid native > libraries. Another patch to SoyLatte also allowed it to recognize both > .dylib and .jnilib. We also made changes to Java in Mac OS X 10.5 Leopard to > recognize .dylib as well as .jnilib. > > I know it's sounds super-hacky, but I bet if you renamed all your .jnilib's > to .dylib's, it will probably work. > > Best of luck, > Mike Swingler > Java Runtime Engineer > Apple Inc. > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081005/a8b6de19/attachment.html From Dalibor.Topic at Sun.COM Mon Oct 6 04:34:47 2008 From: Dalibor.Topic at Sun.COM (Dalibor Topic) Date: Mon, 06 Oct 2008 13:34:47 +0200 Subject: Darwin OpenJDK 7 Binaries - Not Working With SWT In-Reply-To: References: <6CB8264F-247A-4B48-A5D6-904263F92144@apple.com> Message-ID: <48E9F7D7.8040403@sun.com> Michael Franz wrote: > Hi, > > Do any other platforms support multiple dynamically load library > extensions? I don't think there is another one, but on Windows you can have multiple prefixes, depending on the environment: nothing for MSVC++, cyg* for Cygwin, lib* for mingw32 & cegcc, and pw* for pw32. There are no specific ports to either of them, though, so it hasn't been an issue. Why Darwin has both jnilib and dylib is explained at http://markmail.org/message/nvmhqaimybukzg4l . cheers, dalibor topic -- ******************************************************************* Dalibor Topic Tel: (+49 40) 23 646 738 Java F/OSS Ambassador AIM: robiladonaim Sun Microsystems GmbH Mobile: (+49 177) 2664 192 Nagelsweg 55 http://openjdk.java.net D-20097 Hamburg mailto:Dalibor.Topic at sun.com Sitz der Gesellschaft: Sonnenallee 1, D-85551 Kirchheim-Heimstetten Amtsgericht M?nchen: HRB 161028 Gesch?ftsf?hrer: Thomas Schr?der, Wolfgang Engels, Dr. Roland B?mer Vorsitzender des Aufsichtsrates: Martin H?ring From dustinjordan1 at gmail.com Mon Oct 6 11:12:33 2008 From: dustinjordan1 at gmail.com (Dustin Jordan) Date: Mon, 06 Oct 2008 12:12:33 -0600 Subject: openbsd port for sparc64 Message-ID: <48EA5511.10203@gmail.com> Hey all, I'm glad you are here working on this. I wonder if there is a port available for OpenBSD sparc64. If not what can I do to help make this happen? -- Dustin Jordan Enterprise Software Engineering Web Consulting Rock and Roll (208) 412-8377 From kurt at intricatesoftware.com Mon Oct 6 12:41:39 2008 From: kurt at intricatesoftware.com (Kurt Miller) Date: Mon, 06 Oct 2008 15:41:39 -0400 Subject: openbsd port for sparc64 In-Reply-To: <48EA5511.10203@gmail.com> References: <48EA5511.10203@gmail.com> Message-ID: <48EA69F3.10809@intricatesoftware.com> Dustin Jordan wrote: > Hey all, > I'm glad you are here working on this. I wonder if there is a port > available for OpenBSD sparc64. If not what can I do to help make this > happen? > Hi Dustin, There isn't a sparc64 port yet. This is mostly due to the lack of a functional bootstrap method. There are methods to use remote tools to bootstrap but I've not tried them because that approach won't integrate with OpenBSD's ports & packages build process. My longer term goal has been to get gcj working well enough on OpenBSD to use IcedTea's bootstrap/build approach. I have made progress with some of the prerequisites for gcj like threaded boehm-gc and gcc4 pre-compiled headers support, but there is still quite a bit more to do. Of course you can work on sparc64 support and it would be much appreciated. Just be aware that it will be awhile before it could be bootstrap and built easily by regular users. Regards, -Kurt From mvfranz at gmail.com Mon Oct 6 18:44:18 2008 From: mvfranz at gmail.com (Michael Franz) Date: Mon, 6 Oct 2008 21:44:18 -0400 Subject: Java_java_lang_System_mapLibraryName Does this need to be native? Message-ID: Hi, After looking at Java_java_lang_System_mapLibraryName I am wondering why this has to be a native method? It seems that the only benefit to being native is that JNI_LIB_PREFIX and JNI_LIB_SUFFIX are defined using defines in the platform header files. Being a much stronger Java programmer than a C programmer, I would prefer to have a way to get the two values (JNI_LIB_PREFIX and JNI_LIB_SUFFIX) and manipulate the string building using StringBuilder. If that is not feasible I would try to create a new method that returns a String[] of the possible library names. Since I am interested in the OS X version a load of abc would return: return new String[] { "libabc.dylib", "libabc.jnilib" } Then ClassLoader.loadLibrary can loop over the string array when it is searching the sys_paths. This method would also work for cases where there are multiple choices for the JNI_LIB_PREFIX. Comments? Michael -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081006/653d1ac1/attachment.html From cstewart913 at gmail.com Mon Oct 6 19:42:34 2008 From: cstewart913 at gmail.com (Chris Stewart) Date: Mon, 6 Oct 2008 22:42:34 -0400 Subject: Starting point for contribution Message-ID: <8F71D968-1EA9-4BE9-B38E-57157CEE0B52@gmail.com> I've been following the conversation here for awhile and I have an interest in Java compatibility for OS X. My development knowledge is Java based with no background in C at all. With my background, what areas can I contribute to? Is there a starting point for someone like me that wants to get involved? Chris Stewart cstewart913 at gmail.com From mvfranz at gmail.com Tue Oct 7 18:15:00 2008 From: mvfranz at gmail.com (Michael Franz) Date: Tue, 7 Oct 2008 21:15:00 -0400 Subject: OpendJDK Darwin Binaries Unsupported GTK LookAndFeel Message-ID: Hi, I was fooling around with the look and feels to see what they look like and found that there are three installed but only two work. LookAndFeelInfo[] lf = UIManager.getInstalledLookAndFeels(); for (LookAndFeelInfo l : lf) { System.out.println(l.getClassName()); } prints: javax.swing.plaf.metal.MetalLookAndFeel com.sun.java.swing.plaf.motif.MotifLookAndFeel com.sun.java.swing.plaf.gtk.GTKLookAndFeel However, if I execute this line: UIManager.setLookAndFeel("com.sun.java.swing.plaf.gtk.GTKLookAndFeel"); I get the following exception: javax.swing.UnsupportedLookAndFeelException: [GTK look and feel - com.sun.java.swing.plaf.gtk.GTKLookAndFeel] not supported on this platform It seems that the static initializer of UIManger includes either the Windows LAF or the GTK LAF, since OS X is not Windows the GTK is included. Is there a way to check if GTK is installed on the system before including it as a valid LAF? Michael -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081007/41a0e268/attachment.html From glewis at eyesbeyond.com Wed Oct 8 21:42:11 2008 From: glewis at eyesbeyond.com (Greg Lewis) Date: Wed, 8 Oct 2008 21:42:11 -0700 Subject: openbsd port for sparc64 In-Reply-To: <48EA69F3.10809@intricatesoftware.com> References: <48EA5511.10203@gmail.com> <48EA69F3.10809@intricatesoftware.com> Message-ID: <20081009044211.GA45508@misty.eyesbeyond.com> On Mon, Oct 06, 2008 at 03:41:39PM -0400, Kurt Miller wrote: > Dustin Jordan wrote: > > Hey all, > > I'm glad you are here working on this. I wonder if there is a port > > available for OpenBSD sparc64. If not what can I do to help make this > > happen? > > There isn't a sparc64 port yet. This is mostly due to the lack of > a functional bootstrap method. There are methods to use remote > tools to bootstrap but I've not tried them because that approach > won't integrate with OpenBSD's ports & packages build process. > > My longer term goal has been to get gcj working well enough > on OpenBSD to use IcedTea's bootstrap/build approach. I have > made progress with some of the prerequisites for gcj like > threaded boehm-gc and gcc4 pre-compiled headers support, > but there is still quite a bit more to do. > > Of course you can work on sparc64 support and it would be > much appreciated. Just be aware that it will be awhile > before it could be bootstrap and built easily by regular > users. Assuming OpenJDK can bootstrap itself (I'm about to find that out :), if you get it compiling you should be able to distribute a OpenJDK bootstrap package by cutting out the binary plugs (I don't believe any would be required for the bootstrapping functionality and the rest is all GPL'ed now, meaning you can distribute it as long as you do so under those terms). If you want to work on sparc64 support I'd suggest starting with Landon Fuller's earlier patches for JDK 1.6 on FreeBSD. They should be somewhat close. I can either dig out the URL or dig them up as I was playing with them too at one point. -- Greg Lewis Email : glewis at eyesbeyond.com Eyes Beyond Web : http://www.eyesbeyond.com Information Technology FreeBSD : glewis at FreeBSD.org From glewis at eyesbeyond.com Wed Oct 8 21:59:51 2008 From: glewis at eyesbeyond.com (Greg Lewis) Date: Wed, 8 Oct 2008 21:59:51 -0700 Subject: Hit me with the mercurial clue bat... Message-ID: <20081009045951.GA45701@misty.eyesbeyond.com> G'day all, Okay, I've made some changes to get things working on my FreeBSD 7 box (since X isn't installed in /usr/X11R6 and it postdates the compat symlinks that were originally being made). I've committed them locally and now want to push them out. I assume I use fpush as per the pushing portion of section 7 of http://www.selenic.com/mercurial/wiki/index.cgi/ForestExtension ? Bonus points if you can provide exact commands and/or explain what the 'default' parameter is in the fpush command. Also I want to start catching up the BSD port to the changes happening in the mainstream port before we get too far behind, so any hints on that would be appreciated. cvs, p4, svn and now hg -- too many commands to remember! -- Greg Lewis Email : glewis at eyesbeyond.com Eyes Beyond Web : http://www.eyesbeyond.com Information Technology FreeBSD : glewis at FreeBSD.org From gnu_andrew at member.fsf.org Thu Oct 9 00:38:07 2008 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Thu, 9 Oct 2008 08:38:07 +0100 Subject: Hit me with the mercurial clue bat... In-Reply-To: <20081009045951.GA45701@misty.eyesbeyond.com> References: <20081009045951.GA45701@misty.eyesbeyond.com> Message-ID: <17c6771e0810090038h352eebccg31f1d5b1b3aee0ed@mail.gmail.com> 2008/10/9 Greg Lewis : > G'day all, > > Okay, I've made some changes to get things working on my FreeBSD 7 box > (since X isn't installed in /usr/X11R6 and it postdates the compat > symlinks that were originally being made). I've committed them locally > and now want to push them out. > > I assume I use fpush as per the pushing portion of section 7 of > http://www.selenic.com/mercurial/wiki/index.cgi/ForestExtension ? > Bonus points if you can provide exact commands and/or explain what > the 'default' parameter is in the fpush command. > > Also I want to start catching up the BSD port to the changes happening > in the mainstream port before we get too far behind, so any hints on that > would be appreciated. > > cvs, p4, svn and now hg -- too many commands to remember! > > -- > Greg Lewis Email : glewis at eyesbeyond.com > Eyes Beyond Web : http://www.eyesbeyond.com > Information Technology FreeBSD : glewis at FreeBSD.org > > I assume it uses the same default as standard push which is specified by paths.default in .hg/hgrc. A clone will create a copy of this file in the root of the checkout with the path cloned as the default e.g.: $ cat .hg/hgrc [paths] default = http://hg.openjdk.java.net/cvmi/cvmi/ -- Andrew :-) Support Free Java! Contribute to GNU Classpath and the OpenJDK http://www.gnu.org/software/classpath http://openjdk.java.net PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint: F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From diizzyy at gmail.com Thu Oct 9 00:54:58 2008 From: diizzyy at gmail.com (Daniel Engberg) Date: Thu, 09 Oct 2008 09:54:58 +0200 Subject: Trouble building OpenJDK on FreeBSD 7 Message-ID: <48EDB8D2.40003@gmail.com> Hi, I'm trying to get OpenJDK to build (checkout yesterday) on FreeBSD 7 but can't seem to get it to compile. It all works fine until it tries to find X11 libs/headers which it fails at. "/usr/bin/gcc -O2 -fno-strict-aliasing -fPIC -W -Wall -Wno-unused -Wno-parentheses -pipe -fno-omit-frame-pointer -D_LITTLE_ENDIAN -D__MEDIALIB_OLD_NAMES -D__USE_J2D_NAMES -DMLIB_NO_LIBSUNMATH -Damd64 -DARCH='"amd64"' -D_ALLBSD_SOURCE -DRELEASE='"1.7.0-internal"' -D_LARGEFILE64_SOURCE -D_GNU_SOURCE -D_REENTRANT -D_LP64=1 -I. -I/usr/home/diizzy/m002/bsd-port/build/bsd-amd64/tmp/sun/sun.awt/awt/CClassHeaders -I../../../src/solaris/javavm/export -I../../../src/share/javavm/export -I../../../src/share/javavm/include -I../../../src/solaris/javavm/include -I../../../src/share/native/common -I../../../src/solaris/native/common -I../../../src/share/native/sun/awt -I../../../src/solaris/native/sun/awt -I../../../src/solaris/native/sun/awt/font -I../../../src/share/native/sun/awt/debug -I../../../src/share/native/sun/awt/../font -I../../../src/solaris/native/sun/awt/../font -I../../../src/share/native/sun/awt/image -I../../../src/share/native/sun/awt/image/cvutils -I../../../src/share/native/sun/awt/shell -I../../../src/share/native/sun/awt/medialib -I../../../src/solaris/native/sun/awt/medialib -I../../../src/share/native/sun/awt/../java2d -I../../../src/solaris/native/sun/awt/../java2d -I../../../src/share/native/sun/awt/../java2d/loops -I../../../src/share/native/sun/awt/../java2d/pipe -I../../../src/share/native/sun/awt/../java2d/opengl -I../../../src/solaris/native/sun/awt/../java2d/opengl -I../../../src/solaris/native/sun/awt/../java2d/x11 -I../../../src/share/native/sun/awt/../dc/doe -I../../../src/share/native/sun/awt/../dc/path -I../../../src/solaris/native/sun/awt/../jdga -I../../../src/solaris/native/sun/awt -I/usr/X11R6/include -I/usr/X11R6/include/X11/extensions -c -o /usr/home/diizzy/m002/bsd-port/build/bsd-amd64/tmp/sun/sun.awt/awt/obj64/Region.o ../../../src/share/native/sun/awt/../java2d/pipe/Region.c In file included from ../../../src/share/native/sun/awt/../java2d/pipe/Region.h:34, from ../../../src/share/native/sun/awt/../java2d/pipe/Region.c:30: ../../../src/solaris/native/sun/awt/utility/rect.h:31:22: error: X11/Xlib.h: No such file or directory In file included from ../../../src/share/native/sun/awt/../java2d/pipe/Region.h:34, from ../../../src/share/native/sun/awt/../java2d/pipe/Region.c:30: ../../../src/solaris/native/sun/awt/utility/rect.h:32: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'RECT_T' In file included from ../../../src/share/native/sun/awt/../java2d/pipe/Region.c:30: ../../../src/share/native/sun/awt/../java2d/pipe/Region.h:211: error: expected declaration specifiers or '...' before 'RECT_T' ../../../src/share/native/sun/awt/../java2d/pipe/Region.c:243: error: expected declaration specifiers or '...' before 'RECT_T' ../../../src/share/native/sun/awt/../java2d/pipe/Region.c: In function 'RegionToYXBandedRectangles': ../../../src/share/native/sun/awt/../java2d/pipe/Region.c:254: error: 'pRect' undeclared (first use in this function) ../../../src/share/native/sun/awt/../java2d/pipe/Region.c:254: error: (Each undeclared identifier is reported only once ../../../src/share/native/sun/awt/../java2d/pipe/Region.c:254: error: for each function it appears in.) ../../../src/share/native/sun/awt/../java2d/pipe/Region.c:263: warning: comparison between signed and unsigned ../../../src/share/native/sun/awt/../java2d/pipe/Region.c:264: error: 'RECT_T' undeclared (first use in this function) ../../../src/share/native/sun/awt/../java2d/pipe/Region.c:264: error: expected expression before ')' token" Could it be that I need to wait on Greg's patches for FreeBSD 7 to make it compile? A bit of Googling got me here but I can't find the equal packages/ports in FreeBSD. http://today.java.net/pub/a/today/2007/11/29/building-the-jdk.html Main reason I'm even trying that is because I have a slight hope that Azureus will start working (again) on FreeBSD. If you already know its status it would save me some hassle, unfortunately I'm not a programmer so I cannot help in regards of debugging in case it doesnt work. Best regards, Daniel From Karen.Kinnear at Sun.COM Thu Oct 9 09:15:10 2008 From: Karen.Kinnear at Sun.COM (Karen Kinnear) Date: Thu, 09 Oct 2008 12:15:10 -0400 Subject: Anyone seen this SocketException? Message-ID: <4B18223C-B703-4C6F-ACE6-F1ED751BA5AD@Sun.COM> Folks, We were running JCK tests on the openjdk7-darwin-i386-20080820 binaries and ran into some failures that report: java.net.SocketException: Invalid argument Has anyone seen this? I've only tried Mac OS X 10.5, so I don't know if this is a generic BSD issue or Mac specific. Does this porting group have JCK access? http://openjdk.java.net/groups/conformance/JckAccess/index.html Specific details on the bug: Specific testlist to run: api/java_util/logging/SocketHandler/index.html Or: javasoft.sqe.tests.api.java.util.logging.SocketHandler.PublishTests Results: java.net.SocketException: Invalid argument at java.net.PlainSocketImpl.socketAccept(Native Method) at java.net.AbstractPlainSocketImpl.accept(AbstractPlainSocketImpl.java: 358) at java.net.ServerSocket.implAccept(ServerSocket.java:501) at java.net.ServerSocket.accept(ServerSocket.java:469) at javasoft.sqe.tests.api.java.util.logging.SocketHandler.PublishTests $1.run(PublishTests.java:114) at javasoft .sqe .jck.lib.SecurityTestRunner.runTestWithTCKSM(SecurityTestRunner.java: 278) at javasoft .sqe .jck .lib.SecurityTestRunner.runTestWithPermissions(SecurityTestRunner.java: 235) at javasoft .sqe .jck .lib .SecurityTestRunner.runTestWithAllPermissions(SecurityTestRunner.java: 157) at javasoft.sqe.jck.lib.AllPermissionSM.testRun(AllPermissionSM.java:86) at javasoft.sqe.jck.lib.AllPermissionSM.testRun(AllPermissionSM.java:133) at javasoft .sqe .tests .api .java .util.logging.SocketHandler.PublishTests.Publish0001(PublishTests.java: 154) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun .reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java: 57) at sun .reflect .DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java: 43) at java.lang.reflect.Method.invoke(Method.java:623) at javasoft.sqe.javatest.lib.MultiTest.invokeTestCase(MultiTest.java:406) at javasoft.sqe.javatest.lib.MultiTest.run(MultiTest.java:195) at javasoft.sqe.javatest.lib.MultiTest.run(MultiTest.java:127) at javasoft .sqe .tests .api .java.util.logging.SocketHandler.PublishTests.main(PublishTests.java:85) thanks, Karen From Kelly.Ohair at Sun.COM Thu Oct 9 09:17:41 2008 From: Kelly.Ohair at Sun.COM (Kelly O'Hair) Date: Thu, 09 Oct 2008 09:17:41 -0700 Subject: Hit me with the mercurial clue bat... In-Reply-To: <17c6771e0810090038h352eebccg31f1d5b1b3aee0ed@mail.gmail.com> References: <20081009045951.GA45701@misty.eyesbeyond.com> <17c6771e0810090038h352eebccg31f1d5b1b3aee0ed@mail.gmail.com> Message-ID: <48EE2EA5.9090905@sun.com> A few helpful bits of info... * Even though http://hg.openjdk.java.net/cvmi/cvmi/ is a Mercurial forest each repository inside that forest, and in your own forest clone has it's own .hg/hgrc file and it's own private repository settings. The .hg/hgrc file at the top of the forest does not have any influence on the .hg/hgrc file in the other repositories. A forest is a very loose confederation of repositories, doing a fclone-or-fpull-or-fpush is just an easy way of doing: foreach i in ( `find . -name .hg` ) ( cd ${i}/.. && hg clone-or-pull-or-push ) done So doing an 'fpush' is no different that doing a push in each of the repositories where you made changes. If you only make changes in say the 'hotspot' repository, all you really need is that one repository, and no forest commands. But pushing changes into any repository without making sure the entire forest builds might not be very co-worker friendly. ;^) * The .hg/hgrc file on each repository typically contains a [paths] section which defines the "default" path to the parent repository, usually the path to the repository used to create the initial clone. This .hg/hgrc file is NOT part of the permanent repository data and you can edit it. See http://www.selenic.com/mercurial/hgrc.5.html. You can have a "default-push" [paths] setting too, so that pulls by default come from one place and push by default goes to another. Or you can provide the path or the name of a path defined in [paths] to the actual 'hg pull' or 'hg push' commands. Lots of choices here. -kto Andrew John Hughes wrote: > 2008/10/9 Greg Lewis : >> G'day all, >> >> Okay, I've made some changes to get things working on my FreeBSD 7 box >> (since X isn't installed in /usr/X11R6 and it postdates the compat >> symlinks that were originally being made). I've committed them locally >> and now want to push them out. >> >> I assume I use fpush as per the pushing portion of section 7 of >> http://www.selenic.com/mercurial/wiki/index.cgi/ForestExtension ? >> Bonus points if you can provide exact commands and/or explain what >> the 'default' parameter is in the fpush command. >> >> Also I want to start catching up the BSD port to the changes happening >> in the mainstream port before we get too far behind, so any hints on that >> would be appreciated. >> >> cvs, p4, svn and now hg -- too many commands to remember! >> >> -- >> Greg Lewis Email : glewis at eyesbeyond.com >> Eyes Beyond Web : http://www.eyesbeyond.com >> Information Technology FreeBSD : glewis at FreeBSD.org >> >> > > I assume it uses the same default as standard push which is specified > by paths.default in .hg/hgrc. A clone will create a copy of this file in the > root of the checkout with the path cloned as the default e.g.: > > $ cat .hg/hgrc > [paths] > default = http://hg.openjdk.java.net/cvmi/cvmi/ > From glewis at eyesbeyond.com Thu Oct 9 11:06:44 2008 From: glewis at eyesbeyond.com (Greg Lewis) Date: Thu, 9 Oct 2008 11:06:44 -0700 Subject: Trouble building OpenJDK on FreeBSD 7 In-Reply-To: <48EDB8D2.40003@gmail.com> References: <48EDB8D2.40003@gmail.com> Message-ID: <20081009180644.GA58859@misty.eyesbeyond.com> On Thu, Oct 09, 2008 at 09:54:58AM +0200, Daniel Engberg wrote: > Hi, > > I'm trying to get OpenJDK to build (checkout yesterday) on FreeBSD 7 but > can't seem to get it to compile. It all works fine until it tries to > find X11 libs/headers which it fails at. I have patches for this. I'm just figuring out how to push them up to the main tree (or whatever the right mercurial term is :). You'll need to set ALT_X11_PATH to /usr/local and it will work. -- Greg Lewis Email : glewis at eyesbeyond.com Eyes Beyond Web : http://www.eyesbeyond.com Information Technology FreeBSD : glewis at FreeBSD.org From diizzyy at gmail.com Thu Oct 9 12:14:18 2008 From: diizzyy at gmail.com (Daniel Engberg) Date: Thu, 09 Oct 2008 21:14:18 +0200 Subject: Trouble building OpenJDK on FreeBSD 7 In-Reply-To: <20081009180644.GA58859@misty.eyesbeyond.com> References: <48EDB8D2.40003@gmail.com> <20081009180644.GA58859@misty.eyesbeyond.com> Message-ID: <48EE580A.9080704@gmail.com> Greg Lewis wrote: > On Thu, Oct 09, 2008 at 09:54:58AM +0200, Daniel Engberg wrote: > >> Hi, >> >> I'm trying to get OpenJDK to build (checkout yesterday) on FreeBSD 7 but >> can't seem to get it to compile. It all works fine until it tries to >> find X11 libs/headers which it fails at. >> > > I have patches for this. I'm just figuring out how to push them up to > the main tree (or whatever the right mercurial term is :). You'll need > to set ALT_X11_PATH to /usr/local and it will work. > Hi, I still get stuck at the same place :( I have all depends installed for the jdk16 port (which should be sufficient?) and of course Apache Ant. //Daniel From gnu_andrew at member.fsf.org Thu Oct 9 18:37:12 2008 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Fri, 10 Oct 2008 02:37:12 +0100 Subject: Hit me with the mercurial clue bat... In-Reply-To: <48EE2EA5.9090905@sun.com> References: <20081009045951.GA45701@misty.eyesbeyond.com> <17c6771e0810090038h352eebccg31f1d5b1b3aee0ed@mail.gmail.com> <48EE2EA5.9090905@sun.com> Message-ID: <17c6771e0810091837k3e758faeud6e2399b70327edd@mail.gmail.com> 2008/10/9 Kelly O'Hair : > A few helpful bits of info... > > So doing an 'fpush' is no different that doing a push in each of the > repositories where you made changes. So does it use the top-level setting as a global default for all the sub-pushes or does it use the local default for each? -- Andrew :-) Support Free Java! Contribute to GNU Classpath and the OpenJDK http://www.gnu.org/software/classpath http://openjdk.java.net PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint: F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From mvfranz at gmail.com Thu Oct 9 21:06:52 2008 From: mvfranz at gmail.com (Michael Franz) Date: Fri, 10 Oct 2008 00:06:52 -0400 Subject: Java_java_lang_System_mapLibraryName Does this need to be native? In-Reply-To: References: Message-ID: Hi, I have another plan that would create another native method called mapAltLibraryName. This would work the same way as mapLibraryName but use JNI_LIB_PREFIX and ALT_JNI_LIB_SUFFIX. On platforms that do not have an alternate suffix NULL would be returned. This method can then be called in ClassLoader.java when the library name created by mapLibraryName fails. The following files would be changed: jdk/src/solaris/javavm/export/jvm_md.h -- define ALT_JNI_LIB_SUFFIX for OS X jdk/src/share/native/java/lang/System.c -- implementation that uses ALT_JNI_LIB_SUFFIX jdk/src/share/classes/java/lang/ClassLoader.java -- use mapAltLibraryName jdk/src/share/classes/java/lang/System.java -- define package scope mapAltLibraryname I think this limits the changes and impact to other platforms. To be compatible with Apple's implementation JNI_LIB_SUFFIX should be defined as .jnilib and ALT_JNI_LIB_SUFFIX should be defined as .dylib Michael On Mon, Oct 6, 2008 at 9:44 PM, Michael Franz wrote: > Hi, > > After looking at Java_java_lang_System_mapLibraryName I am wondering why > this has to be a native method? It seems that the only benefit to being > native is that JNI_LIB_PREFIX and JNI_LIB_SUFFIX are defined using defines > in the platform header files. > > Being a much stronger Java programmer than a C programmer, I would prefer > to have a way to get the two values (JNI_LIB_PREFIX and JNI_LIB_SUFFIX) and > manipulate the string building using StringBuilder. > > If that is not feasible I would try to create a new method that returns a > String[] of the possible library names. Since I am interested in the OS X > version a load of abc would return: > > return new String[] { "libabc.dylib", "libabc.jnilib" } > > Then ClassLoader.loadLibrary can loop over the string array when it is > searching the sys_paths. This method would also work for cases where there > are multiple choices for the JNI_LIB_PREFIX. > > Comments? > > Michael > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081010/e837d238/attachment.html From glewis at eyesbeyond.com Thu Oct 9 21:47:53 2008 From: glewis at eyesbeyond.com (Greg Lewis) Date: Thu, 9 Oct 2008 21:47:53 -0700 Subject: Trouble building OpenJDK on FreeBSD 7 In-Reply-To: <48EE580A.9080704@gmail.com> References: <48EDB8D2.40003@gmail.com> <20081009180644.GA58859@misty.eyesbeyond.com> <48EE580A.9080704@gmail.com> Message-ID: <20081010044753.GA65546@misty.eyesbeyond.com> On Thu, Oct 09, 2008 at 09:14:18PM +0200, Daniel Engberg wrote: > Greg Lewis wrote: > > On Thu, Oct 09, 2008 at 09:54:58AM +0200, Daniel Engberg wrote: > > > >> Hi, > >> > >> I'm trying to get OpenJDK to build (checkout yesterday) on FreeBSD 7 but > >> can't seem to get it to compile. It all works fine until it tries to > >> find X11 libs/headers which it fails at. > >> > > > > I have patches for this. I'm just figuring out how to push them up to > > the main tree (or whatever the right mercurial term is :). You'll need > > to set ALT_X11_PATH to /usr/local and it will work. > > I still get stuck at the same place :( > I have all depends installed for the jdk16 port (which should be > sufficient?) and of course Apache Ant. I haven't pushed the patches up yet... -- Greg Lewis Email : glewis at eyesbeyond.com Eyes Beyond Web : http://www.eyesbeyond.com Information Technology FreeBSD : glewis at FreeBSD.org From glewis at eyesbeyond.com Thu Oct 9 22:15:12 2008 From: glewis at eyesbeyond.com (glewis at eyesbeyond.com) Date: Fri, 10 Oct 2008 05:15:12 +0000 Subject: hg: bsd-port/bsd-port/corba: . Allow the base location for X11 to be overridden, but continue to default Message-ID: <20081010051513.CC0E8DEFD@hg.openjdk.java.net> Changeset: 251ac9a519c2 Author: glewis at misty.eyesbeyond.com Date: 2008-10-08 21:47 -0700 URL: http://hg.openjdk.java.net/bsd-port/bsd-port/corba/rev/251ac9a519c2 . Allow the base location for X11 to be overridden, but continue to default to /usr/X11R6. ! make/common/Defs-bsd.gmk ! make/common/Defs-linux.gmk ! make/common/Defs.gmk From glewis at eyesbeyond.com Thu Oct 9 22:16:04 2008 From: glewis at eyesbeyond.com (glewis at eyesbeyond.com) Date: Fri, 10 Oct 2008 05:16:04 +0000 Subject: hg: bsd-port/bsd-port/jdk: . Allow the base location of X11 to be overridden, but continue to default Message-ID: <20081010051633.0E1DFDF08@hg.openjdk.java.net> Changeset: 390ec89a5d71 Author: glewis at misty.eyesbeyond.com Date: 2008-10-08 21:51 -0700 URL: http://hg.openjdk.java.net/bsd-port/bsd-port/jdk/rev/390ec89a5d71 . Allow the base location of X11 to be overridden, but continue to default to /usr/X11R6. . Allow the base location of third party packages to be overridden. Default to /usr on Linux and /usr/local everywhere else (I'd suggest there are some better choices for other than FreeBSD, but I'm not 100% sure what they are). . Use a BSD specific font path rather than hijacking the Linux one and configure it based on what I see on my FreeBSD box. Please feel free to add directories for Net, Open, DragonFly and Mac OS X. ! make/common/Defs-bsd.gmk ! make/common/Defs-linux.gmk ! make/common/Defs.gmk ! make/common/shared/Sanity-Settings.gmk ! make/sun/awt/mawt.gmk ! make/sun/font/Makefile ! make/sun/xawt/Makefile ! src/solaris/native/sun/awt/fontpath.c From Kelly.Ohair at Sun.COM Fri Oct 10 10:12:28 2008 From: Kelly.Ohair at Sun.COM (Kelly O'Hair) Date: Fri, 10 Oct 2008 10:12:28 -0700 Subject: Hit me with the mercurial clue bat... In-Reply-To: <17c6771e0810091837k3e758faeud6e2399b70327edd@mail.gmail.com> References: <20081009045951.GA45701@misty.eyesbeyond.com> <17c6771e0810090038h352eebccg31f1d5b1b3aee0ed@mail.gmail.com> <48EE2EA5.9090905@sun.com> <17c6771e0810091837k3e758faeud6e2399b70327edd@mail.gmail.com> Message-ID: <48EF8CFC.6080004@sun.com> Andrew John Hughes wrote: > 2008/10/9 Kelly O'Hair : >> A few helpful bits of info... >> >> So doing an 'fpush' is no different that doing a push in each of the >> repositories where you made changes. > > So does it use the top-level setting as a global default for all the sub-pushes > or does it use the local default for each? The local default. -kto From mvfranz at gmail.com Fri Oct 10 19:41:46 2008 From: mvfranz at gmail.com (Michael Franz) Date: Fri, 10 Oct 2008 22:41:46 -0400 Subject: -XstartOnFirstThread For OS X Message-ID: Hi, I have solved my other problems but am not sure where to start getting -XstartOnFirstThread to work to allow SWT to work correctly. Will the patches from SoyLatte be integrated into OpenJDK soon? Thanks Michael -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081010/ba24e9b5/attachment.html From mvfranz at gmail.com Sat Oct 11 18:14:26 2008 From: mvfranz at gmail.com (Michael Franz) Date: Sat, 11 Oct 2008 21:14:26 -0400 Subject: Darwin OpenJDK 7 Binaries - Not Working With SWT In-Reply-To: <3B0CBA27-1463-426B-8AA1-E7B00D557E25@plausiblelabs.com> References: <6CB8264F-247A-4B48-A5D6-904263F92144@apple.com> <3B0CBA27-1463-426B-8AA1-E7B00D557E25@plausiblelabs.com> Message-ID: Hi, On Sun, Sep 7, 2008 at 9:22 PM, Landon Fuller wrote: > > On Sep 7, 2008, at 1:08 PM, Michael Franz wrote: > > I changed the startup to not pass the flag. I was running this from >> inside eclipse, but eclipse must somehow pass the option as it did not show >> up in the command. >> > > There are two small patches from SoyLatte that need to be re-implemented > for OpenJDK, both of which you have run into: > > -XstartOnFirstThread: > > Soylatte by starts a Cocoa runloop on the first thread, and then run > the JVM main() function again on a separate thread > Setting -XstartOnFirstThread has the same behavior on Mac OS X, in > that Java is started directly on the first thread. > > Reading through the code and finding a few bugs on primordial threads and this blog entry[1] , I wonder if -XstartOnFirstThread is really OS X specific (I assumed it was). I was also reading through the Cocoa reference I have, my understanding is that it is possible to create a runloop on other threads, not just the first thread. Michael [1] http://blogs.sun.com/ksrini/entry/hotspot_primordial_thread_jni_stack -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081011/990c62a3/attachment.html From glewis at eyesbeyond.com Sat Oct 11 19:00:29 2008 From: glewis at eyesbeyond.com (glewis at eyesbeyond.com) Date: Sun, 12 Oct 2008 02:00:29 +0000 Subject: hg: bsd-port/bsd-port/jdk: . Replace hardcoded instances of /usr/local with $(PKG_PATH). Message-ID: <20081012020054.73239D082@hg.openjdk.java.net> Changeset: 29554abae9fa Author: glewis at misty.eyesbeyond.com Date: 2008-10-11 18:56 -0700 URL: http://hg.openjdk.java.net/bsd-port/bsd-port/jdk/rev/29554abae9fa . Replace hardcoded instances of /usr/local with $(PKG_PATH). . ICONV_DIR -> ICONV_PATH since that seems more consistent. ! make/common/shared/Defs-bsd.gmk ! make/java/instrument/Makefile ! make/java/jli/Makefile ! make/java/npt/Makefile ! make/sun/splashscreen/Makefile ! src/solaris/bin/java_md.c From glewis at eyesbeyond.com Sat Oct 11 19:43:19 2008 From: glewis at eyesbeyond.com (Greg Lewis) Date: Sat, 11 Oct 2008 19:43:19 -0700 Subject: Hit me with the mercurial clue bat... In-Reply-To: <48EE2EA5.9090905@sun.com> References: <20081009045951.GA45701@misty.eyesbeyond.com> <17c6771e0810090038h352eebccg31f1d5b1b3aee0ed@mail.gmail.com> <48EE2EA5.9090905@sun.com> Message-ID: <20081012024319.GA15028@misty.eyesbeyond.com> On Thu, Oct 09, 2008 at 09:17:41AM -0700, Kelly O'Hair wrote: > A few helpful bits of info... Thanks Kelly, these were indeed very helpful :). I'm still working my way through some of the finer details but I'm now up and running at least in terms of checking changes and pushing them out. > * Even though http://hg.openjdk.java.net/cvmi/cvmi/ is a Mercurial forest > each repository inside that forest, and in your own forest clone has it's > own .hg/hgrc file and it's own private repository settings. > The .hg/hgrc file at the top of the forest does not have any influence > on the .hg/hgrc file in the other repositories. > A forest is a very loose confederation of repositories, doing a > fclone-or-fpull-or-fpush is just an easy way of doing: > foreach i in ( `find . -name .hg` ) > ( cd ${i}/.. && hg clone-or-pull-or-push ) > done > So doing an 'fpush' is no different that doing a push in each of the > repositories where you made changes. So, to update the bsd-port forest I would do something like this: hg fpull http://hg.openjdk.java.net/cvmi/cvmi/ [is that the main forest?] hg fupdate [merging, fixing any problems this causes] hg ci [in each repository] hg fpush [would go to the default tree in .hg/hgrc which is the bsd-port tree] Or thats what it seems like to me :). > If you only make changes in say the 'hotspot' repository, all you really > need is that one repository, and no forest commands. But pushing changes > into any repository without making sure the entire forest builds might > not be very co-worker friendly. ;^) Well, I always make sure it builds on my current platform at least :). Detecting breakage for the other *BSDs is currently a little difficult, but that doesn't happen that often for the most part. > * The .hg/hgrc file on each repository typically contains a [paths] section > which defines the "default" path to the parent repository, usually the > path to the repository used to create the initial clone. > This .hg/hgrc file is NOT part of the permanent repository data and > you can edit it. See http://www.selenic.com/mercurial/hgrc.5.html. > You can have a "default-push" [paths] setting too, so that pulls by default > come from one place and push by default goes to another. > Or you can provide the path or the name of a path defined in [paths] to > the actual 'hg pull' or 'hg push' commands. Lots of choices here. Cool, so I can define a paths entry for the main forest to avoid having to remember it :). > Andrew John Hughes wrote: > > 2008/10/9 Greg Lewis : > >> G'day all, > >> > >> Okay, I've made some changes to get things working on my FreeBSD 7 box > >> (since X isn't installed in /usr/X11R6 and it postdates the compat > >> symlinks that were originally being made). I've committed them locally > >> and now want to push them out. > >> > >> I assume I use fpush as per the pushing portion of section 7 of > >> http://www.selenic.com/mercurial/wiki/index.cgi/ForestExtension ? > >> Bonus points if you can provide exact commands and/or explain what > >> the 'default' parameter is in the fpush command. > >> > >> Also I want to start catching up the BSD port to the changes happening > >> in the mainstream port before we get too far behind, so any hints on that > >> would be appreciated. > >> > >> cvs, p4, svn and now hg -- too many commands to remember! > >> > >> -- > >> Greg Lewis Email : glewis at eyesbeyond.com > >> Eyes Beyond Web : http://www.eyesbeyond.com > >> Information Technology FreeBSD : glewis at FreeBSD.org > >> > >> > > > > I assume it uses the same default as standard push which is specified > > by paths.default in .hg/hgrc. A clone will create a copy of this file in the > > root of the checkout with the path cloned as the default e.g.: > > > > $ cat .hg/hgrc > > [paths] > > default = http://hg.openjdk.java.net/cvmi/cvmi/ > > -- Greg Lewis Email : glewis at eyesbeyond.com Eyes Beyond Web : http://www.eyesbeyond.com Information Technology FreeBSD : glewis at FreeBSD.org From swingler at apple.com Sun Oct 12 08:21:06 2008 From: swingler at apple.com (Mike Swingler) Date: Sun, 12 Oct 2008 08:21:06 -0700 Subject: Darwin OpenJDK 7 Binaries - Not Working With SWT In-Reply-To: References: <6CB8264F-247A-4B48-A5D6-904263F92144@apple.com> <3B0CBA27-1463-426B-8AA1-E7B00D557E25@plausiblelabs.com> Message-ID: On Oct 11, 2008, at 6:14 PM, Michael Franz wrote: > Hi, > > On Sun, Sep 7, 2008 at 9:22 PM, Landon Fuller > wrote: > > On Sep 7, 2008, at 1:08 PM, Michael Franz wrote: > > I changed the startup to not pass the flag. I was running this from > inside eclipse, but eclipse must somehow pass the option as it did > not show up in the command. > > There are two small patches from SoyLatte that need to be re- > implemented for OpenJDK, both of which you have run into: > > -XstartOnFirstThread: > > Soylatte by starts a Cocoa runloop on the first thread, and > then run the JVM main() function again on a separate thread > Setting -XstartOnFirstThread has the same behavior on Mac OS > X, in that Java is started directly on the first thread. > > Reading through the code and finding a few bugs on primordial > threads and this blog entry[1] , I wonder if -XstartOnFirstThread is > really OS X specific (I assumed it was). > > I was also reading through the Cocoa reference I have, my > understanding is that it is possible to create a runloop on other > threads, not just the first thread. You can create runloops on other threads, but their sources will be setup by you. Only the runloop on Thread 0 receives keyboard and mouse events, which is why -XstartOnFirstThread is necessary when user-space code wants to pump the event loop. Otherwise, Thread 0 needs to be parked until it's time for the AWT to startup, and start running the show. Cheers, Mike Swingler Java Runtime Engineer Apple Inc. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081012/d34b1340/attachment.html From mvfranz at gmail.com Sun Oct 12 12:26:27 2008 From: mvfranz at gmail.com (Michael Franz) Date: Sun, 12 Oct 2008 15:26:27 -0400 Subject: Darwin OpenJDK 7 Binaries - Not Working With SWT In-Reply-To: References: <6CB8264F-247A-4B48-A5D6-904263F92144@apple.com> <3B0CBA27-1463-426B-8AA1-E7B00D557E25@plausiblelabs.com> Message-ID: On Sun, Oct 12, 2008 at 11:21 AM, Mike Swingler wrote: > On Oct 11, 2008, at 6:14 PM, Michael Franz wrote: > > Hi, > > On Sun, Sep 7, 2008 at 9:22 PM, Landon Fuller wrote: > >> >> On Sep 7, 2008, at 1:08 PM, Michael Franz wrote: >> >> I changed the startup to not pass the flag. I was running this from >>> inside eclipse, but eclipse must somehow pass the option as it did not show >>> up in the command. >>> >> >> There are two small patches from SoyLatte that need to be re-implemented >> for OpenJDK, both of which you have run into: >> >> -XstartOnFirstThread: >> >> Soylatte by starts a Cocoa runloop on the first thread, and then >> run the JVM main() function again on a separate thread >> Setting -XstartOnFirstThread has the same behavior on Mac OS X, in >> that Java is started directly on the first thread. >> >> Reading through the code and finding a few bugs on primordial threads and > this blog entry[1] , I wonder if -XstartOnFirstThread is really OS X > specific (I assumed it was). > > I was also reading through the Cocoa reference I have, my understanding is > that it is possible to create a runloop on other threads, not just the first > thread. > > > You can create runloops on other threads, but their sources will be setup > by you. Only the runloop on Thread 0 receives keyboard and mouse events, > which is why -XstartOnFirstThread is necessary when user-space code wants to > pump the event loop. Otherwise, Thread 0 needs to be parked until it's time > for the AWT to startup, and start running the show. > > Cheers, > Mike Swingler > Java Runtime Engineer > Apple Inc. > Is it possible to find Thread 0 from other threads? Michael -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081012/01900f03/attachment.html From swingler at apple.com Sun Oct 12 12:38:33 2008 From: swingler at apple.com (Mike Swingler) Date: Sun, 12 Oct 2008 12:38:33 -0700 Subject: Darwin OpenJDK 7 Binaries - Not Working With SWT In-Reply-To: References: <6CB8264F-247A-4B48-A5D6-904263F92144@apple.com> <3B0CBA27-1463-426B-8AA1-E7B00D557E25@plausiblelabs.com> Message-ID: On Oct 12, 2008, at 12:26 PM, Michael Franz wrote: > On Sun, Oct 12, 2008 at 11:21 AM, Mike Swingler > wrote: > > On Oct 11, 2008, at 6:14 PM, Michael Franz wrote: > >> Hi, >> >> On Sun, Sep 7, 2008 at 9:22 PM, Landon Fuller > > wrote: >> >> On Sep 7, 2008, at 1:08 PM, Michael Franz wrote: >> >> I changed the startup to not pass the flag. I was running this >> from inside eclipse, but eclipse must somehow pass the option as it >> did not show up in the command. >> >> There are two small patches from SoyLatte that need to be re- >> implemented for OpenJDK, both of which you have run into: >> >> -XstartOnFirstThread: >> >> Soylatte by starts a Cocoa runloop on the first thread, and >> then run the JVM main() function again on a separate thread >> Setting -XstartOnFirstThread has the same behavior on Mac OS >> X, in that Java is started directly on the first thread. >> >> Reading through the code and finding a few bugs on primordial >> threads and this blog entry[1] , I wonder if -XstartOnFirstThread >> is really OS X specific (I assumed it was). >> >> I was also reading through the Cocoa reference I have, my >> understanding is that it is possible to create a runloop on other >> threads, not just the first thread. > > You can create runloops on other threads, but their sources will be > setup by you. Only the runloop on Thread 0 receives keyboard and > mouse events, which is why -XstartOnFirstThread is necessary when > user-space code wants to pump the event loop. Otherwise, Thread 0 > needs to be parked until it's time for the AWT to startup, and start > running the show. > > Is it possible to find Thread 0 from other threads? I'm not sure what you mean by "find"? Like, with the pthread API? Once a runloop is pumping on it, most other API can deliver work to it via - performSelectorOnMainThread:, or other CFRunLoop API - but if user- space code never starts a runloop on Thread 0, those API's in AppKit, Carbon, etc will not work. Mike Swingler Java Runtime Engineer Apple Inc. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081012/36b1fba0/attachment.html From mvfranz at gmail.com Sun Oct 12 14:25:07 2008 From: mvfranz at gmail.com (Michael Franz) Date: Sun, 12 Oct 2008 17:25:07 -0400 Subject: Darwin OpenJDK 7 Binaries - Not Working With SWT In-Reply-To: References: <6CB8264F-247A-4B48-A5D6-904263F92144@apple.com> <3B0CBA27-1463-426B-8AA1-E7B00D557E25@plausiblelabs.com> Message-ID: On Sun, Oct 12, 2008 at 3:38 PM, Mike Swingler wrote: > On Oct 12, 2008, at 12:26 PM, Michael Franz wrote: > > On Sun, Oct 12, 2008 at 11:21 AM, Mike Swingler wrote: > > > On Oct 11, 2008, at 6:14 PM, Michael Franz wrote: >> >> Hi, >> >> On Sun, Sep 7, 2008 at 9:22 PM, Landon Fuller wrote: >> >>> >>> On Sep 7, 2008, at 1:08 PM, Michael Franz wrote: >>> >>> I changed the startup to not pass the flag. I was running this from >>>> inside eclipse, but eclipse must somehow pass the option as it did not show >>>> up in the command. >>>> >>> >>> There are two small patches from SoyLatte that need to be re-implemented >>> for OpenJDK, both of which you have run into: >>> >>> -XstartOnFirstThread: >>> >>> Soylatte by starts a Cocoa runloop on the first thread, and then >>> run the JVM main() function again on a separate thread >>> Setting -XstartOnFirstThread has the same behavior on Mac OS X, in >>> that Java is started directly on the first thread. >>> >>> Reading through the code and finding a few bugs on primordial threads and >> this blog entry[1] , I wonder if -XstartOnFirstThread is really OS X >> specific (I assumed it was). >> >> I was also reading through the Cocoa reference I have, my understanding is >> that it is possible to create a runloop on other threads, not just the first >> thread. >> >> >> You can create runloops on other threads, but their sources will be setup >> by you. Only the runloop on Thread 0 receives keyboard and mouse events, >> which is why -XstartOnFirstThread is necessary when user-space code wants to >> pump the event loop. Otherwise, Thread 0 needs to be parked until it's time >> for the AWT to startup, and start running the show. >> > > Is it possible to find Thread 0 from other threads? > > > I'm not sure what you mean by "find"? Like, with the pthread API? Once a > runloop is pumping on it, most other API can deliver work to it via > -performSelectorOnMainThread:, or other CFRunLoop API - but if user-space > code never starts a runloop on Thread 0, those API's in AppKit, Carbon, etc > will not work. > > Mike Swingler > Java Runtime Engineer > Apple Inc. > What I meant, is can thread 1 find thread 0 where find is obtain a reference to it. That is probably not necessary as you state work can be assigned to thread 0 from other threads. What I see the current startup logic doing is creating the JVM in a new thread and waiting for that thread to die. If we need thread 0 to create the runloop, how does it know when the JVM has exited? I was thinking that maybe the jvm creation thread could send a message to the runloop that when it finishes. This would mean that there would be no need to -XstartOnFirstThread as thread 0 would always create the runloop. Michael -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081012/0fd8e33d/attachment.html From swingler at apple.com Sun Oct 12 14:46:47 2008 From: swingler at apple.com (Mike Swingler) Date: Sun, 12 Oct 2008 14:46:47 -0700 Subject: Darwin OpenJDK 7 Binaries - Not Working With SWT In-Reply-To: References: <6CB8264F-247A-4B48-A5D6-904263F92144@apple.com> <3B0CBA27-1463-426B-8AA1-E7B00D557E25@plausiblelabs.com> Message-ID: <73ACE6E8-7C0D-4086-84A3-9184392C15E6@apple.com> On Oct 12, 2008, at 2:25 PM, Michael Franz wrote: > On Sun, Oct 12, 2008 at 3:38 PM, Mike Swingler > wrote: > > On Oct 12, 2008, at 12:26 PM, Michael Franz wrote: > >> On Sun, Oct 12, 2008 at 11:21 AM, Mike Swingler >> wrote: >> >> On Oct 11, 2008, at 6:14 PM, Michael Franz wrote: >> >>> Hi, >>> >>> On Sun, Sep 7, 2008 at 9:22 PM, Landon Fuller >> > wrote: >>> >>> On Sep 7, 2008, at 1:08 PM, Michael Franz wrote: >>> >>> I changed the startup to not pass the flag. I was running this >>> from inside eclipse, but eclipse must somehow pass the option as >>> it did not show up in the command. >>> >>> There are two small patches from SoyLatte that need to be re- >>> implemented for OpenJDK, both of which you have run into: >>> >>> -XstartOnFirstThread: >>> >>> Soylatte by starts a Cocoa runloop on the first thread, and >>> then run the JVM main() function again on a separate thread >>> Setting -XstartOnFirstThread has the same behavior on Mac >>> OS X, in that Java is started directly on the first thread. >>> >>> Reading through the code and finding a few bugs on primordial >>> threads and this blog entry[1] , I wonder if -XstartOnFirstThread >>> is really OS X specific (I assumed it was). >>> >>> I was also reading through the Cocoa reference I have, my >>> understanding is that it is possible to create a runloop on other >>> threads, not just the first thread. >> >> You can create runloops on other threads, but their sources will be >> setup by you. Only the runloop on Thread 0 receives keyboard and >> mouse events, which is why -XstartOnFirstThread is necessary when >> user-space code wants to pump the event loop. Otherwise, Thread 0 >> needs to be parked until it's time for the AWT to startup, and >> start running the show. >> >> Is it possible to find Thread 0 from other threads? > > I'm not sure what you mean by "find"? Like, with the pthread API? > Once a runloop is pumping on it, most other API can deliver work to > it via -performSelectorOnMainThread:, or other CFRunLoop API - but > if user-space code never starts a runloop on Thread 0, those API's > in AppKit, Carbon, etc will not work. > > What I meant, is can thread 1 find thread 0 where find is obtain a > reference to it. That is probably not necessary as you state work > can be assigned to thread 0 from other threads. > > What I see the current startup logic doing is creating the JVM in a > new thread and waiting for that thread to die. If we need thread 0 > to create the runloop, how does it know when the JVM has exited? I > was thinking that maybe the jvm creation thread could send a message > to the runloop that when it finishes. This would mean that there > would be no need to -XstartOnFirstThread as thread 0 would always > create the runloop. Perhaps the SWT guys could chime in here, since their plans might be changing for SWT/Cocoa, but for the current implementation, the SWT main() has to be run on Thread 0. As I understand the architecture, they don't actually create a permanent runloop, but rather pump events themselves. Since Thread 0 is the only place these events get delivered, their main() has a hard requirement to be run on Thread 0, at least on the Mac. When we know the AWT is running the show, we do send a shutdown message to the Cocoa runloop when JVM has detected it is exiting naturally. Since SWT controls their own lifecycle we know not to shutdown the runloop from under them (which is just like the embedded case, like plugins inside say, Safari). Cheers, Mike Swingler Java Runtime Engineer Apple Inc. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081012/1521f529/attachment.html From mvfranz at gmail.com Sun Oct 12 15:44:55 2008 From: mvfranz at gmail.com (Michael Franz) Date: Sun, 12 Oct 2008 18:44:55 -0400 Subject: OpendJDK Darwin Binaries Unable to convolve src image Message-ID: Hi, I create a test program from here: http://java.sun.com/developer/JDCTechTips/2004/tt0210.html and get the following stacktrace. Exception in thread "main" java.awt.image.ImagingOpException: Unable to convolve src image at java.awt.image.ConvolveOp.filter(ConvolveOp.java:197) at test.BrightnessChanger.setBrightnessFactor(BrightnessChanger.java:54) at test.BrightnessChanger.createBufferedImages(BrightnessChanger.java:37) at test.BrightnessChanger.(BrightnessChanger.java:24) at test.BrightnessChanger.main(BrightnessChanger.java:70) error in dlopen: dlopen(libmlib_image.so, 1): image not found I am not sure why the error message states that the library ends in .so when there is the library with .dylib extension. Michael -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081012/e2e8ac4d/attachment.html From Christopher.Campbell at Sun.COM Sun Oct 12 16:37:17 2008 From: Christopher.Campbell at Sun.COM (Chris Campbell) Date: Sun, 12 Oct 2008 16:37:17 -0700 Subject: OpendJDK Darwin Binaries Unable to convolve src image In-Reply-To: References: Message-ID: <3330430A-F70B-463D-94D2-8AB9DE750E33@sun.com> The problem is in: jdk/src/solaris/native/sun/awt/awt_Mlib.c There's some code in there that dlopen's libmlib_image and assumes a .so suffix; this will need to be updated to account for the .dylib suffix on Mac OS X. A minimal fix would look like: #if defined(__APPLE__) handle = dlopen("libmlib_image.dylib", RTLD_LAZY); #else handle = dlopen("libmlib_image.so", RTLD_LAZY); #endif Thanks, Chris On Oct 12, 2008, at 3:44 PM, Michael Franz wrote: > Hi, > > I create a test program from here: http://java.sun.com/developer/JDCTechTips/2004/tt0210.html > and get the following stacktrace. > > Exception in thread "main" java.awt.image.ImagingOpException: Unable > to convolve src image > at java.awt.image.ConvolveOp.filter(ConvolveOp.java:197) > at > test.BrightnessChanger.setBrightnessFactor(BrightnessChanger.java:54) > at > test.BrightnessChanger.createBufferedImages(BrightnessChanger.java:37) > at test.BrightnessChanger.(BrightnessChanger.java:24) > at test.BrightnessChanger.main(BrightnessChanger.java:70) > error in dlopen: dlopen(libmlib_image.so, 1): image not found > > I am not sure why the error message states that the library ends > in .so when there is the library with .dylib extension. > > Michael > From mvfranz at gmail.com Sun Oct 12 17:10:44 2008 From: mvfranz at gmail.com (Michael Franz) Date: Sun, 12 Oct 2008 20:10:44 -0400 Subject: OpendJDK Darwin Binaries Unable to convolve src image In-Reply-To: <3330430A-F70B-463D-94D2-8AB9DE750E33@sun.com> References: <3330430A-F70B-463D-94D2-8AB9DE750E33@sun.com> Message-ID: Is it possible to use JNI_LIB_SUFFIX as it is defined jvm*.h? Or use the System.loadLibrary? Michael On Sun, Oct 12, 2008 at 7:37 PM, Chris Campbell < Christopher.Campbell at sun.com> wrote: > The problem is in: > jdk/src/solaris/native/sun/awt/awt_Mlib.c > > There's some code in there that dlopen's libmlib_image and assumes a .so > suffix; this will need to be updated to account for the .dylib suffix on Mac > OS X. A minimal fix would look like: > > #if defined(__APPLE__) > handle = dlopen("libmlib_image.dylib", RTLD_LAZY); > #else > handle = dlopen("libmlib_image.so", RTLD_LAZY); > #endif > > Thanks, > Chris > > > On Oct 12, 2008, at 3:44 PM, Michael Franz wrote: > >> Hi, >> >> I create a test program from here: >> http://java.sun.com/developer/JDCTechTips/2004/tt0210.html >> and get the following stacktrace. >> >> Exception in thread "main" java.awt.image.ImagingOpException: Unable to >> convolve src image >> at java.awt.image.ConvolveOp.filter(ConvolveOp.java:197) >> at >> test.BrightnessChanger.setBrightnessFactor(BrightnessChanger.java:54) >> at >> test.BrightnessChanger.createBufferedImages(BrightnessChanger.java:37) >> at test.BrightnessChanger.(BrightnessChanger.java:24) >> at test.BrightnessChanger.main(BrightnessChanger.java:70) >> error in dlopen: dlopen(libmlib_image.so, 1): image not found >> >> I am not sure why the error message states that the library ends in .so >> when there is the library with .dylib extension. >> >> Michael >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081012/702a6ddc/attachment.html From mvfranz at gmail.com Mon Oct 13 09:54:33 2008 From: mvfranz at gmail.com (Michael Franz) Date: Mon, 13 Oct 2008 12:54:33 -0400 Subject: OpendJDK Darwin Binaries Unable to convolve src image In-Reply-To: References: <3330430A-F70B-463D-94D2-8AB9DE750E33@sun.com> Message-ID: Would this be a workable solution? (see attachment) I re-use the definition of JNI_LIB_PREFIX and JNI_LIB_SUFFIX to create the correct name for the platform. I think that the sun4v logic could be in a sun block but it still works without one. Michael -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081013/318c4c72/attachment.html -------------- next part -------------- A non-text attachment was scrubbed... Name: awt_Mlib.patch Type: application/octet-stream Size: 1563 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081013/318c4c72/attachment.obj From Kelly.Ohair at Sun.COM Mon Oct 13 11:03:54 2008 From: Kelly.Ohair at Sun.COM (Kelly O'Hair) Date: Mon, 13 Oct 2008 11:03:54 -0700 Subject: Hit me with the mercurial clue bat... In-Reply-To: <20081012024319.GA15028@misty.eyesbeyond.com> References: <20081009045951.GA45701@misty.eyesbeyond.com> <17c6771e0810090038h352eebccg31f1d5b1b3aee0ed@mail.gmail.com> <48EE2EA5.9090905@sun.com> <20081012024319.GA15028@misty.eyesbeyond.com> Message-ID: <48F38D8A.6090404@sun.com> Greg Lewis wrote: > On Thu, Oct 09, 2008 at 09:17:41AM -0700, Kelly O'Hair wrote: >> A few helpful bits of info... > > Thanks Kelly, these were indeed very helpful :). I'm still working my > way through some of the finer details but I'm now up and running at least > in terms of checking changes and pushing them out. > >> * Even though http://hg.openjdk.java.net/cvmi/cvmi/ is a Mercurial forest >> each repository inside that forest, and in your own forest clone has it's >> own .hg/hgrc file and it's own private repository settings. >> The .hg/hgrc file at the top of the forest does not have any influence >> on the .hg/hgrc file in the other repositories. >> A forest is a very loose confederation of repositories, doing a >> fclone-or-fpull-or-fpush is just an easy way of doing: >> foreach i in ( `find . -name .hg` ) >> ( cd ${i}/.. && hg clone-or-pull-or-push ) >> done >> So doing an 'fpush' is no different that doing a push in each of the >> repositories where you made changes. > > So, to update the bsd-port forest I would do something like this: > > hg fpull http://hg.openjdk.java.net/cvmi/cvmi/ > [is that the main forest?] > hg fupdate > [merging, fixing any problems this causes] > hg ci > [in each repository] > hg fpush > [would go to the default tree in .hg/hgrc which is the bsd-port tree] > > Or thats what it seems like to me :). I don 't know exactly how your cvmi area has been setup. The openjdk areas I use need a different push path than the default pull path, e.g. I pull from the http:// path but push into a ssh://ohair at ... path. > >> If you only make changes in say the 'hotspot' repository, all you really >> need is that one repository, and no forest commands. But pushing changes >> into any repository without making sure the entire forest builds might >> not be very co-worker friendly. ;^) > > Well, I always make sure it builds on my current platform at least :). > Detecting breakage for the other *BSDs is currently a little difficult, but > that doesn't happen that often for the most part. Detecting build breakage on systems you don't have is a bit tricky. ;^) > >> * The .hg/hgrc file on each repository typically contains a [paths] section >> which defines the "default" path to the parent repository, usually the >> path to the repository used to create the initial clone. >> This .hg/hgrc file is NOT part of the permanent repository data and >> you can edit it. See http://www.selenic.com/mercurial/hgrc.5.html. >> You can have a "default-push" [paths] setting too, so that pulls by default >> come from one place and push by default goes to another. >> Or you can provide the path or the name of a path defined in [paths] to >> the actual 'hg pull' or 'hg push' commands. Lots of choices here. > > Cool, so I can define a paths entry for the main forest to avoid having to > remember it :). Yes, definitely setup your default-push, it's very handy. -kto > >> Andrew John Hughes wrote: >>> 2008/10/9 Greg Lewis : >>>> G'day all, >>>> >>>> Okay, I've made some changes to get things working on my FreeBSD 7 box >>>> (since X isn't installed in /usr/X11R6 and it postdates the compat >>>> symlinks that were originally being made). I've committed them locally >>>> and now want to push them out. >>>> >>>> I assume I use fpush as per the pushing portion of section 7 of >>>> http://www.selenic.com/mercurial/wiki/index.cgi/ForestExtension ? >>>> Bonus points if you can provide exact commands and/or explain what >>>> the 'default' parameter is in the fpush command. >>>> >>>> Also I want to start catching up the BSD port to the changes happening >>>> in the mainstream port before we get too far behind, so any hints on that >>>> would be appreciated. >>>> >>>> cvs, p4, svn and now hg -- too many commands to remember! >>>> >>>> -- >>>> Greg Lewis Email : glewis at eyesbeyond.com >>>> Eyes Beyond Web : http://www.eyesbeyond.com >>>> Information Technology FreeBSD : glewis at FreeBSD.org >>>> >>>> >>> I assume it uses the same default as standard push which is specified >>> by paths.default in .hg/hgrc. A clone will create a copy of this file in the >>> root of the checkout with the path cloned as the default e.g.: >>> >>> $ cat .hg/hgrc >>> [paths] >>> default = http://hg.openjdk.java.net/cvmi/cvmi/ >>> > From mvfranz at gmail.com Mon Oct 13 15:34:50 2008 From: mvfranz at gmail.com (Michael Franz) Date: Mon, 13 Oct 2008 18:34:50 -0400 Subject: NetBeans on OpenJDK-BSD Port Message-ID: Hi, I have two changes that get NetBeans to run under OpenJDK-BSD for OS X. What are the steps to get them out in the wild? NetBeans related patches * mlib loading - change the library name to be created using the same logic as mapLibraryName * -Xdock parameter - ignore this parameter, the correct implementation will be deferred. Although I can run NetBeans with the new JVM, it seems that I cannot run my programs from within NetBeans. If I start NB with another JVM, my local build works within NB. Michael -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081013/606e99e2/attachment.html From glewis at eyesbeyond.com Mon Oct 13 20:14:37 2008 From: glewis at eyesbeyond.com (Greg Lewis) Date: Mon, 13 Oct 2008 20:14:37 -0700 Subject: OpendJDK Darwin Binaries Unable to convolve src image In-Reply-To: References: <3330430A-F70B-463D-94D2-8AB9DE750E33@sun.com> Message-ID: <20081014031437.GA56892@misty.eyesbeyond.com> G'day Michael, On Mon, Oct 13, 2008 at 12:54:33PM -0400, Michael Franz wrote: > Would this be a workable solution? (see attachment) > > I re-use the definition of JNI_LIB_PREFIX and JNI_LIB_SUFFIX to create the > correct name for the platform. I think that the sun4v logic could be in a > sun block but it still works without one. I don't think you need to do what you're doing in the patch. Just replacing "libmlib_image.so" with JNI_LIB_PREFIX "mlib_image" JNI_LIB_SUFFIX will work just fine since they're all string literals and the compiler will concatenate them together. Let me do a pass through the code and look for all the calls to dlopen to see if there are any others that need doing. I haven't got the compile set up on my MacBook at work yet, but hopefully shortly. -- Greg Lewis Email : glewis at eyesbeyond.com Eyes Beyond Web : http://www.eyesbeyond.com Information Technology FreeBSD : glewis at FreeBSD.org From mvfranz at gmail.com Mon Oct 13 20:38:30 2008 From: mvfranz at gmail.com (Michael Franz) Date: Mon, 13 Oct 2008 23:38:30 -0400 Subject: OpendJDK Darwin Binaries Unable to convolve src image In-Reply-To: <20081014031437.GA56892@misty.eyesbeyond.com> References: <3330430A-F70B-463D-94D2-8AB9DE750E33@sun.com> <20081014031437.GA56892@misty.eyesbeyond.com> Message-ID: Greg, I had looked into creating a macro to do the concatenation, but that did not work. What you suggest makes sense from what I did read, just never figured it out. Having it put the string together at compile time is a better solution. Michael On Mon, Oct 13, 2008 at 11:14 PM, Greg Lewis wrote: > G'day Michael, > > On Mon, Oct 13, 2008 at 12:54:33PM -0400, Michael Franz wrote: > > Would this be a workable solution? (see attachment) > > > > I re-use the definition of JNI_LIB_PREFIX and JNI_LIB_SUFFIX to create > the > > correct name for the platform. I think that the sun4v logic could be in > a > > sun block but it still works without one. > > I don't think you need to do what you're doing in the patch. Just > replacing > > "libmlib_image.so" > > with > > JNI_LIB_PREFIX "mlib_image" JNI_LIB_SUFFIX > > will work just fine since they're all string literals and the compiler > will concatenate them together. Let me do a pass through the code and look > for all the calls to dlopen to see if there are any others that need > doing. > > I haven't got the compile set up on my MacBook at work yet, but hopefully > shortly. > > -- > Greg Lewis Email : glewis at eyesbeyond.com > Eyes Beyond Web : http://www.eyesbeyond.com > Information Technology FreeBSD : glewis at FreeBSD.org > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081013/dd4352c9/attachment.html From diizzyy at gmail.com Mon Oct 13 23:19:48 2008 From: diizzyy at gmail.com (Daniel Engberg) Date: Tue, 14 Oct 2008 08:19:48 +0200 Subject: Trouble building OpenJDK on FreeBSD 7 In-Reply-To: <20081010044753.GA65546@misty.eyesbeyond.com> References: <48EDB8D2.40003@gmail.com> <20081009180644.GA58859@misty.eyesbeyond.com> <48EE580A.9080704@gmail.com> <20081010044753.GA65546@misty.eyesbeyond.com> Message-ID: <48F43A04.3050303@gmail.com> Greg Lewis wrote: > On Thu, Oct 09, 2008 at 09:14:18PM +0200, Daniel Engberg wrote: > >> Greg Lewis wrote: >> >>> On Thu, Oct 09, 2008 at 09:54:58AM +0200, Daniel Engberg wrote: >>> >>> >>>> Hi, >>>> >>>> I'm trying to get OpenJDK to build (checkout yesterday) on FreeBSD 7 but >>>> can't seem to get it to compile. It all works fine until it tries to >>>> find X11 libs/headers which it fails at. >>>> >>>> >>> I have patches for this. I'm just figuring out how to push them up to >>> the main tree (or whatever the right mercurial term is :). You'll need >>> to set ALT_X11_PATH to /usr/local and it will work. >>> >> I still get stuck at the same place :( >> I have all depends installed for the jdk16 port (which should be >> sufficient?) and of course Apache Ant. >> > > I haven't pushed the patches up yet... > Now that Greg pushed his patches I can build OpenJDK but unfortunately Azureus (which in my case was the program I wanted to get working) doesn't work. It fails at binding network interfaces which is a bit of a drawback compared to earlier JRE's which at least starts Azureus. As I've said earlier I'm not a developer not I can't help with coding (i.e fixing the issue) but keep up the good work. For those who are wondering here's the error message I get: StartServer ERROR: unable to bind to 127.0.0.1:6880 for passed torrent info StartSocket: passing startup args to already-running process. java.net.SocketException: Invalid argument at java.net.PlainSocketImpl.socketConnect(Native Method) at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:310) at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:176) at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:163) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:380) at java.net.Socket.connect(Socket.java:569) at java.net.Socket.connect(Socket.java:519) at java.net.Socket.(Socket.java:416) at java.net.Socket.(Socket.java:199) at org.gudy.azureus2.ui.common.Main$StartSocket.(Main.java:370) at org.gudy.azureus2.ui.common.Main.main(Main.java:155) Best regards, Daniel From glewis at eyesbeyond.com Wed Oct 15 20:15:45 2008 From: glewis at eyesbeyond.com (Greg Lewis) Date: Wed, 15 Oct 2008 20:15:45 -0700 Subject: Trouble building OpenJDK on FreeBSD 7 In-Reply-To: <48F43A04.3050303@gmail.com> References: <48EDB8D2.40003@gmail.com> <20081009180644.GA58859@misty.eyesbeyond.com> <48EE580A.9080704@gmail.com> <20081010044753.GA65546@misty.eyesbeyond.com> <48F43A04.3050303@gmail.com> Message-ID: <20081016031545.GB76826@misty.eyesbeyond.com> On Tue, Oct 14, 2008 at 08:19:48AM +0200, Daniel Engberg wrote: > Now that Greg pushed his patches I can build OpenJDK but unfortunately > Azureus (which in my case was the program I wanted to get working) > doesn't work. It fails at binding network interfaces which is a bit of a > drawback compared to earlier JRE's which at least starts Azureus. As > I've said earlier I'm not a developer not I can't help with coding (i.e > fixing the issue) but keep up the good work. For those who are wondering > here's the error message I get: > > StartServer ERROR: unable to bind to 127.0.0.1:6880 for passed torrent info > StartSocket: passing startup args to already-running process. > java.net.SocketException: Invalid argument Can you try to boil it down to a simpler test case? Azureus is a pretty complex app. > at java.net.PlainSocketImpl.socketConnect(Native Method) > at > java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:310) > at > java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:176) > at > java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:163) > at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:380) > at java.net.Socket.connect(Socket.java:569) > at java.net.Socket.connect(Socket.java:519) > at java.net.Socket.(Socket.java:416) > at java.net.Socket.(Socket.java:199) > at > org.gudy.azureus2.ui.common.Main$StartSocket.(Main.java:370) > at org.gudy.azureus2.ui.common.Main.main(Main.java:155) > > Best regards, > Daniel -- Greg Lewis Email : glewis at eyesbeyond.com Eyes Beyond Web : http://www.eyesbeyond.com Information Technology FreeBSD : glewis at FreeBSD.org From glewis at eyesbeyond.com Wed Oct 15 20:16:57 2008 From: glewis at eyesbeyond.com (Greg Lewis) Date: Wed, 15 Oct 2008 20:16:57 -0700 Subject: NetBeans on OpenJDK-BSD Port Message-ID: <20081016031657.GA76941@misty.eyesbeyond.com> [Oops, meant to send this to the list too] G'day Michael, On Mon, Oct 13, 2008 at 06:34:50PM -0400, Michael Franz wrote: > I have two changes that get NetBeans to run under OpenJDK-BSD for OS X. > What are the steps to get them out in the wild? > > NetBeans related patches > * mlib loading - change the library name to be created using the same logic > as mapLibraryName I've got the fix for this, it needs a little more testing before I commit it though. > * -Xdock parameter - ignore this parameter, the correct implementation will > be deferred. > > Although I can run NetBeans with the new JVM, it seems that I cannot run my > programs from within NetBeans. There is currently a problem with the way OpenJDK exec's external programmes on BSD. > If I start NB with another JVM, my local build works within NB. -- Greg Lewis Email : glewis at eyesbeyond.com Eyes Beyond Web : http://www.eyesbeyond.com Information Technology FreeBSD : glewis at FreeBSD.org From emilian.bold at gmail.com Wed Oct 15 22:18:36 2008 From: emilian.bold at gmail.com (Emilian Bold) Date: Thu, 16 Oct 2008 07:18:36 +0200 Subject: OpenJDK7 libfreetype.6.dylib UnsatisfiedLinkError on OSX 10.5.5 Message-ID: <7aa7e3d90810152218i1459c2aao7c90f6eccca6f77a@mail.gmail.com> Hy, I've downloaded Landon Fuller's openjdk7 build (aka openjdk7-darwin-i386-20080820.tar.bz2 from here http://landonf.bikemonkey.org/code/java/OpenJDK_7_Binaries.20080820.html ) and it seems to reference a nonexisting library. JAVA_HOME & PATH is set properly as well as DISPLAY. The stacktrace I get is: Exception in thread "main" java.lang.UnsatisfiedLinkError: /Users/user/Downloads/openjdk7-darwin-i386-20080820/jre/lib/i386/libfontmanager.dylib: dlopen(/Users/user/Downloads/openjdk7-darwin-i386-20080820/jre/lib/i386/libfontmanager.dylib, 1): Library not loaded: /opt/local/lib/libfreetype.6.dylib Referenced from: /Users/user/Downloads/openjdk7-darwin-i386-20080820/jre/lib/i386/libfontmanager.dylib Reason: image not found at java.lang.ClassLoader$NativeLibrary.load(Native Method) at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1773) at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1691) at java.lang.Runtime.loadLibrary0(Runtime.java:840) at java.lang.System.loadLibrary(System.java:1066) at sun.font.FontManagerNativeLibrary$1.run(FontManagerNativeLibrary.java:61) at java.security.AccessController.doPrivileged(Native Method) at sun.font.FontManagerNativeLibrary.(FontManagerNativeLibrary.java:32) at sun.font.FontManager$1.run(FontManager.java:233) at java.security.AccessController.doPrivileged(Native Method) at sun.font.FontManager.(FontManager.java:230) at sun.font.FcFontConfiguration.init(FcFontConfiguration.java:92) at sun.font.FcFontConfiguration.(FcFontConfiguration.java:73) at sun.awt.X11GraphicsEnvironment.createFontConfiguration(X11GraphicsEnvironment.java:942) at sun.java2d.SunGraphicsEnvironment$2.run(SunGraphicsEnvironment.java:269) at java.security.AccessController.doPrivileged(Native Method) at sun.java2d.SunGraphicsEnvironment.(SunGraphicsEnvironment.java:164) at sun.awt.X11GraphicsEnvironment.(X11GraphicsEnvironment.java:220) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:539) at java.lang.Class.newInstance0(Class.java:372) at java.lang.Class.newInstance(Class.java:325) at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:82) at sun.awt.X11.XToolkit.(XToolkit.java:110) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:186) at java.awt.Toolkit$2.run(Toolkit.java:863) at java.security.AccessController.doPrivileged(Native Method) at java.awt.Toolkit.getDefaultToolkit(Toolkit.java:855) at javax.swing.JFileChooser.installShowFilesListener(JFileChooser.java:383) at javax.swing.JFileChooser.setup(JFileChooser.java:368) at javax.swing.JFileChooser.(JFileChooser.java:347) at javax.swing.JFileChooser.(JFileChooser.java:300) More info: $ uname -a Darwin macbook-pro.local 9.5.0 Darwin Kernel Version 9.5.0: Wed Sep 3 11:29:43 PDT 2008; root:xnu-1228.7.58~1/RELEASE_I386 i386 $ java -version openjdk version "1.7.0-internal" OpenJDK Runtime Environment (build 1.7.0-internal-landonf_2008_08_20_14_13-b00) OpenJDK Server VM (build 14.0-b01, mixed mode) $ ls /opt ls: /opt: No such file or directory Thanks for your work guys -- especially Landon Fuller, whose java6 build on OSX I used until the Apple guys released the official version. It was a close call to switch to Windows but your build solved the problem ! --emi -- Emilian Bold +40 740235562 http://www.emilianbold.ro Java and NetBeans Platform-loving consulting services from Timisoara, Romania. From diizzyy at gmail.com Thu Oct 16 12:09:10 2008 From: diizzyy at gmail.com (Daniel Engberg) Date: Thu, 16 Oct 2008 21:09:10 +0200 Subject: Trouble building OpenJDK on FreeBSD 7 In-Reply-To: <20081016031545.GB76826@misty.eyesbeyond.com> References: <48EDB8D2.40003@gmail.com> <20081009180644.GA58859@misty.eyesbeyond.com> <48EE580A.9080704@gmail.com> <20081010044753.GA65546@misty.eyesbeyond.com> <48F43A04.3050303@gmail.com> <20081016031545.GB76826@misty.eyesbeyond.com> Message-ID: <48F79156.6050008@gmail.com> Greg Lewis wrote: > On Tue, Oct 14, 2008 at 08:19:48AM +0200, Daniel Engberg wrote: > >> Now that Greg pushed his patches I can build OpenJDK but unfortunately >> Azureus (which in my case was the program I wanted to get working) >> doesn't work. It fails at binding network interfaces which is a bit of a >> drawback compared to earlier JRE's which at least starts Azureus. As >> I've said earlier I'm not a developer not I can't help with coding (i.e >> fixing the issue) but keep up the good work. For those who are wondering >> here's the error message I get: >> >> StartServer ERROR: unable to bind to 127.0.0.1:6880 for passed torrent info >> StartSocket: passing startup args to already-running process. >> java.net.SocketException: Invalid argument >> > > Can you try to boil it down to a simpler test case? Azureus is a pretty > complex app. > > >> at java.net.PlainSocketImpl.socketConnect(Native Method) >> at >> java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:310) >> at >> java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:176) >> at >> java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:163) >> at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:380) >> at java.net.Socket.connect(Socket.java:569) >> at java.net.Socket.connect(Socket.java:519) >> at java.net.Socket.(Socket.java:416) >> at java.net.Socket.(Socket.java:199) >> at >> org.gudy.azureus2.ui.common.Main$StartSocket.(Main.java:370) >> at org.gudy.azureus2.ui.common.Main.main(Main.java:155) >> >> Best regards, >> Daniel >> Hi, I've made some research and this issue seems to be (Free)BSD-specific and occurs when you dont have an IPv6 interface configured. You can get around this by adding -Djava.net.preferIPv4Stack=true but you'll still have the same old issues (slow downloads and no upload at all) as before. This two links have a lot more to tell regarding this issue (this is beyond my abilitiy to debug). http://lists.freebsd.org/pipermail/freebsd-java/2008-September/007656.html http://lists.freebsd.org/pipermail/freebsd-java/2008-October/007705.html Best regards, Daniel From glewis at eyesbeyond.com Thu Oct 16 15:03:00 2008 From: glewis at eyesbeyond.com (Greg Lewis) Date: Thu, 16 Oct 2008 15:03:00 -0700 Subject: OpenJDK7 libfreetype.6.dylib UnsatisfiedLinkError on OSX 10.5.5 In-Reply-To: <7aa7e3d90810152218i1459c2aao7c90f6eccca6f77a@mail.gmail.com> References: <7aa7e3d90810152218i1459c2aao7c90f6eccca6f77a@mail.gmail.com> Message-ID: <20081016220300.GA15082@misty.eyesbeyond.com> On Thu, Oct 16, 2008 at 07:18:36AM +0200, Emilian Bold wrote: > I've downloaded Landon Fuller's openjdk7 build (aka > openjdk7-darwin-i386-20080820.tar.bz2 from here > http://landonf.bikemonkey.org/code/java/OpenJDK_7_Binaries.20080820.html > ) and it seems to reference a nonexisting library. > > JAVA_HOME & PATH is set properly as well as DISPLAY. The stacktrace I get is: > > Exception in thread "main" java.lang.UnsatisfiedLinkError: > /Users/user/Downloads/openjdk7-darwin-i386-20080820/jre/lib/i386/libfontmanager.dylib: > dlopen(/Users/user/Downloads/openjdk7-darwin-i386-20080820/jre/lib/i386/libfontmanager.dylib, > 1): Library not loaded: /opt/local/lib/libfreetype.6.dylib So, libfontmanager is linked against libfreetype as this suggests. I wonder if the path is being hardcoded because of the way the linking is done? This looks like the path for libfreetype is you installed it from MacPorts? For me its in /usr/X11R6/lib/libfreetype.6.dylib. You could always create /opt/local/lib and symlink the version in /usr/X11R6/lib. > Referenced from: > /Users/user/Downloads/openjdk7-darwin-i386-20080820/jre/lib/i386/libfontmanager.dylib > Reason: image not found > at java.lang.ClassLoader$NativeLibrary.load(Native Method) > at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1773) > at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1691) > at java.lang.Runtime.loadLibrary0(Runtime.java:840) > at java.lang.System.loadLibrary(System.java:1066) > at sun.font.FontManagerNativeLibrary$1.run(FontManagerNativeLibrary.java:61) > at java.security.AccessController.doPrivileged(Native Method) > at sun.font.FontManagerNativeLibrary.(FontManagerNativeLibrary.java:32) > at sun.font.FontManager$1.run(FontManager.java:233) > at java.security.AccessController.doPrivileged(Native Method) > at sun.font.FontManager.(FontManager.java:230) > at sun.font.FcFontConfiguration.init(FcFontConfiguration.java:92) > at sun.font.FcFontConfiguration.(FcFontConfiguration.java:73) > at sun.awt.X11GraphicsEnvironment.createFontConfiguration(X11GraphicsEnvironment.java:942) > at sun.java2d.SunGraphicsEnvironment$2.run(SunGraphicsEnvironment.java:269) > at java.security.AccessController.doPrivileged(Native Method) > at sun.java2d.SunGraphicsEnvironment.(SunGraphicsEnvironment.java:164) > at sun.awt.X11GraphicsEnvironment.(X11GraphicsEnvironment.java:220) > at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) > at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) > at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) > at java.lang.reflect.Constructor.newInstance(Constructor.java:539) > at java.lang.Class.newInstance0(Class.java:372) > at java.lang.Class.newInstance(Class.java:325) > at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:82) > at sun.awt.X11.XToolkit.(XToolkit.java:110) > at java.lang.Class.forName0(Native Method) > at java.lang.Class.forName(Class.java:186) > at java.awt.Toolkit$2.run(Toolkit.java:863) > at java.security.AccessController.doPrivileged(Native Method) > at java.awt.Toolkit.getDefaultToolkit(Toolkit.java:855) > at javax.swing.JFileChooser.installShowFilesListener(JFileChooser.java:383) > at javax.swing.JFileChooser.setup(JFileChooser.java:368) > at javax.swing.JFileChooser.(JFileChooser.java:347) > at javax.swing.JFileChooser.(JFileChooser.java:300) > > > More info: > > $ uname -a > Darwin macbook-pro.local 9.5.0 Darwin Kernel Version 9.5.0: Wed Sep 3 > 11:29:43 PDT 2008; root:xnu-1228.7.58~1/RELEASE_I386 i386 > > $ java -version > openjdk version "1.7.0-internal" > OpenJDK Runtime Environment (build 1.7.0-internal-landonf_2008_08_20_14_13-b00) > OpenJDK Server VM (build 14.0-b01, mixed mode) > > $ ls /opt > ls: /opt: No such file or directory > > Thanks for your work guys -- especially Landon Fuller, whose java6 > build on OSX I used until the Apple guys released the official > version. It was a close call to switch to Windows but your build > solved the problem ! > > > --emi > > -- > Emilian Bold > +40 740235562 > http://www.emilianbold.ro > > Java and NetBeans Platform-loving consulting services from Timisoara, Romania. -- Greg Lewis Email : glewis at eyesbeyond.com Eyes Beyond Web : http://www.eyesbeyond.com Information Technology FreeBSD : glewis at FreeBSD.org From mvfranz at gmail.com Thu Oct 16 18:31:13 2008 From: mvfranz at gmail.com (Michael Franz) Date: Thu, 16 Oct 2008 21:31:13 -0400 Subject: NetBeans on OpenJDK-BSD Port In-Reply-To: <20081016031433.GA76826@misty.eyesbeyond.com> References: <20081016031433.GA76826@misty.eyesbeyond.com> Message-ID: Do you have any details on what this issue is? > There is currently a problem with the way OpenJDK exec's external > programmes on BSD. > > > If I start NB with another JVM, my local build works within NB. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081016/4eff5efe/attachment.html From mvfranz at gmail.com Thu Oct 16 21:04:37 2008 From: mvfranz at gmail.com (Michael Franz) Date: Fri, 17 Oct 2008 00:04:37 -0400 Subject: Bootstrapping with OpenJDK 7 In-Reply-To: References: Message-ID: It seems that I was wrong on this. I do have a Queens.java file. The problem is that the JVM does not startup correctly to compile the class and then cannot find the class file when it tries to run the test. I cannot figure out why the JVM does not run correctly during the build. If I run the steps manually it works. What I don't understand is that it is pointing to the version I specify in the ALT_BOOT_DIR or ALT_JDK_IMPORT_PATH (I have them set the same) and not the version that I just built. Michael On Sun, Sep 21, 2008 at 5:54 PM, Michael Franz wrote: > My next problem is this: > All done. > cd bsd_i486_compiler2/product && ./test_gamma > openjdk full version "1.7.0-internal-landonf_2008_08_20_14_13-b00" > Error occurred during initialization of VM > java/lang/NoClassDefFoundError: java/lang/Object > openjdk version "1.7.0-internal" > OpenJDK Runtime Environment (build > 1.7.0-internal-landonf_2008_08_20_14_13-b00) > OpenJDK Server VM (build 14.0-b01, mixed mode) > > Exception in thread "main" java.lang.NoClassDefFoundError: Queens > Caused by: java.lang.ClassNotFoundException: Queens > at java.net.URLClassLoader$1.run(URLClassLoader.java:220) > at java.net.URLClassLoader$1.run(URLClassLoader.java:209) > at java.security.AccessController.doPrivileged(Native Method) > at java.net.URLClassLoader.findClass(URLClassLoader.java:208) > at java.lang.ClassLoader.loadClass(ClassLoader.java:325) > at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294) > at java.lang.ClassLoader.loadClass(ClassLoader.java:270) > at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:338) > make[4]: *** [product] Error 1 > make[3]: *** [generic_build2] Error 2 > make[2]: *** [product] Error 2 > make[1]: *** [hotspot-build] Error 2 > make: *** [build_product_image] Error 2 > > I cannot find any reference to a 'Queens' class. > > Michael > > > On Sun, Sep 21, 2008 at 4:57 PM, Michael Franz wrote: > >> Hi, >> >> It seems that I need to set both ALT_BOOTDIR and ALT_JDK_IMPORT_PATH to >> get the build to run with the OpenJDK Darwin binaries. >> >> For people that did not have this problem, is there some other variable >> that is set that makes ALT_JDK_IMPORT_PATH unnecessary? >> >> Michael >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081017/2bdea5a2/attachment.html From glewis at eyesbeyond.com Fri Oct 17 20:58:20 2008 From: glewis at eyesbeyond.com (glewis at eyesbeyond.com) Date: Sat, 18 Oct 2008 03:58:20 +0000 Subject: hg: bsd-port/bsd-port/jdk: . Introduce macros to construct the name of shared libraries that take into Message-ID: <20081018035839.4E486D574@hg.openjdk.java.net> Changeset: 383454a2b95a Author: glewis at misty.eyesbeyond.com Date: 2008-10-17 20:59 -0700 URL: http://hg.openjdk.java.net/bsd-port/bsd-port/jdk/rev/383454a2b95a . Introduce macros to construct the name of shared libraries that take into account the differences between how these names are constructed on MacOS X vs. other Unixes. . Use these macros consistently in the construction of shared library names for dlopen(3). . Fix misspellings of NULL as 0. ! src/solaris/bin/java_md.c ! src/solaris/javavm/export/jvm_md.h ! src/solaris/native/sun/awt/CUPSfuncs.c ! src/solaris/native/sun/awt/awt_GraphicsEnv.c ! src/solaris/native/sun/awt/awt_Mlib.c ! src/solaris/native/sun/awt/fontpath.c ! src/solaris/native/sun/awt/gtk2_interface.c ! src/solaris/native/sun/java2d/opengl/OGLFuncs_md.h ! src/solaris/native/sun/java2d/x11/X11SurfaceData.c ! src/solaris/native/sun/jdga/dgalock.c ! src/solaris/native/sun/net/spi/DefaultProxySelector.c ! src/solaris/native/sun/nio/ch/FileChannelImpl.c ! src/solaris/native/sun/xawt/awt_Desktop.c ! src/solaris/npt/npt_md.h From glewis at eyesbeyond.com Fri Oct 17 22:45:04 2008 From: glewis at eyesbeyond.com (glewis at eyesbeyond.com) Date: Sat, 18 Oct 2008 05:45:04 +0000 Subject: hg: bsd-port/bsd-port/hotspot: . When we're testing whether the system version of clock_gettime is Message-ID: <20081018054507.882BAD579@hg.openjdk.java.net> Changeset: 2ebedfae3e0a Author: glewis at misty.eyesbeyond.com Date: 2008-10-17 22:42 -0700 URL: http://hg.openjdk.java.net/bsd-port/bsd-port/hotspot/rev/2ebedfae3e0a . When we're testing whether the system version of clock_gettime is functional make sure we scope references to it appropriately to avoid calling the local version and then mistakenly not using the system version. Reported by: truk@, Scot Loach ! src/os/bsd/vm/os_bsd.cpp From mvfranz at gmail.com Sat Oct 18 12:31:58 2008 From: mvfranz at gmail.com (Michael Franz) Date: Sat, 18 Oct 2008 15:31:58 -0400 Subject: How to differentiate between BSD and OSX and POST_STRIP_PROCESS In-Reply-To: References: <48DFD810.9070701@sun.com> <48E91507.4090006@sun.com> Message-ID: I attached a patch that will accomplish this. On Sun, Oct 5, 2008 at 8:45 PM, Michael Franz wrote: > That will work too. > > On Sun, Oct 5, 2008 at 3:27 PM, Kelly O'Hair wrote: > >> Could we do something like this instead? >> >> ifeq ($(OS_VENDOR), Apple) >> STRIP_G_OPTION = >> else >> # strip option that leaves local function Elf symbols (better stack >> traces) >> STRIP_G_OPTION = -g >> endif >> >> ifeq ($(VARIANT), OPT) >> ifneq ($(NO_STRIP), true) >> # Debug 'strip -g' leaves local function Elf symbols (better stack >> traces) >> POST_STRIP_PROCESS = $(STRIP) $(STRIP_G_OPTION) >> endif >> endif >> >> >> >> -kto >> >> -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081018/d1536043/attachment.html -------------- next part -------------- A non-text attachment was scrubbed... Name: strip.patch Type: application/octet-stream Size: 785 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081018/d1536043/attachment.obj From mvfranz at gmail.com Sat Oct 18 14:02:24 2008 From: mvfranz at gmail.com (Michael Franz) Date: Sat, 18 Oct 2008 17:02:24 -0400 Subject: hg: bsd-port/bsd-port/jdk: . Introduce macros to construct the name of shared libraries that take into In-Reply-To: <20081018035839.4E486D574@hg.openjdk.java.net> References: <20081018035839.4E486D574@hg.openjdk.java.net> Message-ID: Hi, I tried to build on OS X and get the following link error: Undefined symbols: "_JNI_LIB_NAME", referenced from: _Agent_OnLoad in hprof_init.o I am not sure what file is causing this problem. Michael On Fri, Oct 17, 2008 at 11:58 PM, wrote: > Changeset: 383454a2b95a > Author: glewis at misty.eyesbeyond.com > Date: 2008-10-17 20:59 -0700 > URL: > http://hg.openjdk.java.net/bsd-port/bsd-port/jdk/rev/383454a2b95a > > . Introduce macros to construct the name of shared libraries that take into > account the differences between how these names are constructed on MacOS X > vs. other Unixes. > . Use these macros consistently in the construction of shared library names > for dlopen(3). > . Fix misspellings of NULL as 0. > > ! src/solaris/bin/java_md.c > ! src/solaris/javavm/export/jvm_md.h > ! src/solaris/native/sun/awt/CUPSfuncs.c > ! src/solaris/native/sun/awt/awt_GraphicsEnv.c > ! src/solaris/native/sun/awt/awt_Mlib.c > ! src/solaris/native/sun/awt/fontpath.c > ! src/solaris/native/sun/awt/gtk2_interface.c > ! src/solaris/native/sun/java2d/opengl/OGLFuncs_md.h > ! src/solaris/native/sun/java2d/x11/X11SurfaceData.c > ! src/solaris/native/sun/jdga/dgalock.c > ! src/solaris/native/sun/net/spi/DefaultProxySelector.c > ! src/solaris/native/sun/nio/ch/FileChannelImpl.c > ! src/solaris/native/sun/xawt/awt_Desktop.c > ! src/solaris/npt/npt_md.h > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081018/423862a4/attachment.html From mvfranz at gmail.com Sat Oct 18 20:52:05 2008 From: mvfranz at gmail.com (Michael Franz) Date: Sat, 18 Oct 2008 23:52:05 -0400 Subject: hg: bsd-port/bsd-port/jdk: . Introduce macros to construct the name of shared libraries that take into In-Reply-To: References: <20081018035839.4E486D574@hg.openjdk.java.net> Message-ID: I had to add the include to jvm_md.h to the following files to get this to compile M jdk/src/share/demo/jvmti/hprof/hprof_init.c M jdk/src/solaris/native/sun/awt/CUPSfuncs.c M jdk/src/solaris/native/sun/awt/awt_Mlib.c M jdk/src/solaris/native/sun/awt/fontpath.c M jdk/src/solaris/native/sun/awt/gtk2_interface.c M jdk/src/solaris/native/sun/java2d/opengl/OGLFuncs_md.h M jdk/src/solaris/native/sun/xawt/awt_Desktop.c On Sat, Oct 18, 2008 at 5:02 PM, Michael Franz wrote: > Hi, > > I tried to build on OS X and get the following link error: > Undefined symbols: > "_JNI_LIB_NAME", referenced from: > _Agent_OnLoad in hprof_init.o > > > I am not sure what file is causing this problem. > > Michael > > > On Fri, Oct 17, 2008 at 11:58 PM, wrote: > >> Changeset: 383454a2b95a >> Author: glewis at misty.eyesbeyond.com >> Date: 2008-10-17 20:59 -0700 >> URL: >> http://hg.openjdk.java.net/bsd-port/bsd-port/jdk/rev/383454a2b95a >> >> . Introduce macros to construct the name of shared libraries that take >> into >> account the differences between how these names are constructed on MacOS >> X >> vs. other Unixes. >> . Use these macros consistently in the construction of shared library >> names >> for dlopen(3). >> . Fix misspellings of NULL as 0. >> >> ! src/solaris/bin/java_md.c >> ! src/solaris/javavm/export/jvm_md.h >> ! src/solaris/native/sun/awt/CUPSfuncs.c >> ! src/solaris/native/sun/awt/awt_GraphicsEnv.c >> ! src/solaris/native/sun/awt/awt_Mlib.c >> ! src/solaris/native/sun/awt/fontpath.c >> ! src/solaris/native/sun/awt/gtk2_interface.c >> ! src/solaris/native/sun/java2d/opengl/OGLFuncs_md.h >> ! src/solaris/native/sun/java2d/x11/X11SurfaceData.c >> ! src/solaris/native/sun/jdga/dgalock.c >> ! src/solaris/native/sun/net/spi/DefaultProxySelector.c >> ! src/solaris/native/sun/nio/ch/FileChannelImpl.c >> ! src/solaris/native/sun/xawt/awt_Desktop.c >> ! src/solaris/npt/npt_md.h >> >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081018/03c1d98b/attachment.html From glewis at eyesbeyond.com Sun Oct 19 00:11:40 2008 From: glewis at eyesbeyond.com (Greg Lewis) Date: Sun, 19 Oct 2008 00:11:40 -0700 Subject: hg: bsd-port/bsd-port/jdk: . Introduce macros to construct the name of shared libraries that take into In-Reply-To: References: <20081018035839.4E486D574@hg.openjdk.java.net> Message-ID: <20081019071140.GA50638@misty.eyesbeyond.com> On Sat, Oct 18, 2008 at 11:52:05PM -0400, Michael Franz wrote: > I had to add the include to jvm_md.h to the following files to get this to > compile > M jdk/src/share/demo/jvmti/hprof/hprof_init.c > M jdk/src/solaris/native/sun/awt/CUPSfuncs.c > M jdk/src/solaris/native/sun/awt/awt_Mlib.c > M jdk/src/solaris/native/sun/awt/fontpath.c > M jdk/src/solaris/native/sun/awt/gtk2_interface.c > M jdk/src/solaris/native/sun/java2d/opengl/OGLFuncs_md.h > M jdk/src/solaris/native/sun/xawt/awt_Desktop.c Hmmm, I'm surprised that FreeBSD uses different includes than Mac OS X. I guess adding an explicit include may be better than relying on it being pulled in by another header file anyway, so maybe this is a good thing. Anyway, sorry about that. Thanks for testing things on Mac OS X. > On Sat, Oct 18, 2008 at 5:02 PM, Michael Franz wrote: > > > Hi, > > > > I tried to build on OS X and get the following link error: > > Undefined symbols: > > "_JNI_LIB_NAME", referenced from: > > _Agent_OnLoad in hprof_init.o > > > > > > I am not sure what file is causing this problem. > > > > Michael > > > > > > On Fri, Oct 17, 2008 at 11:58 PM, wrote: > > > >> Changeset: 383454a2b95a > >> Author: glewis at misty.eyesbeyond.com > >> Date: 2008-10-17 20:59 -0700 > >> URL: > >> http://hg.openjdk.java.net/bsd-port/bsd-port/jdk/rev/383454a2b95a > >> > >> . Introduce macros to construct the name of shared libraries that take > >> into > >> account the differences between how these names are constructed on MacOS > >> X > >> vs. other Unixes. > >> . Use these macros consistently in the construction of shared library > >> names > >> for dlopen(3). > >> . Fix misspellings of NULL as 0. > >> > >> ! src/solaris/bin/java_md.c > >> ! src/solaris/javavm/export/jvm_md.h > >> ! src/solaris/native/sun/awt/CUPSfuncs.c > >> ! src/solaris/native/sun/awt/awt_GraphicsEnv.c > >> ! src/solaris/native/sun/awt/awt_Mlib.c > >> ! src/solaris/native/sun/awt/fontpath.c > >> ! src/solaris/native/sun/awt/gtk2_interface.c > >> ! src/solaris/native/sun/java2d/opengl/OGLFuncs_md.h > >> ! src/solaris/native/sun/java2d/x11/X11SurfaceData.c > >> ! src/solaris/native/sun/jdga/dgalock.c > >> ! src/solaris/native/sun/net/spi/DefaultProxySelector.c > >> ! src/solaris/native/sun/nio/ch/FileChannelImpl.c > >> ! src/solaris/native/sun/xawt/awt_Desktop.c > >> ! src/solaris/npt/npt_md.h > >> > >> > >> > > -- Greg Lewis Email : glewis at eyesbeyond.com Eyes Beyond Web : http://www.eyesbeyond.com Information Technology FreeBSD : glewis at FreeBSD.org From mvfranz at gmail.com Sun Oct 19 09:25:35 2008 From: mvfranz at gmail.com (Michael Franz) Date: Sun, 19 Oct 2008 12:25:35 -0400 Subject: hg: bsd-port/bsd-port/jdk: . Introduce macros to construct the name of shared libraries that take into In-Reply-To: <20081019071140.GA50638@misty.eyesbeyond.com> References: <20081018035839.4E486D574@hg.openjdk.java.net> <20081019071140.GA50638@misty.eyesbeyond.com> Message-ID: On Sun, Oct 19, 2008 at 3:11 AM, Greg Lewis wrote: > On Sat, Oct 18, 2008 at 11:52:05PM -0400, Michael Franz wrote: > > I had to add the include to jvm_md.h to the following files to get this > to > > compile > > M jdk/src/share/demo/jvmti/hprof/hprof_init.c > > M jdk/src/solaris/native/sun/awt/CUPSfuncs.c > > M jdk/src/solaris/native/sun/awt/awt_Mlib.c > > M jdk/src/solaris/native/sun/awt/fontpath.c > > M jdk/src/solaris/native/sun/awt/gtk2_interface.c > > M jdk/src/solaris/native/sun/java2d/opengl/OGLFuncs_md.h > > M jdk/src/solaris/native/sun/xawt/awt_Desktop.c > > Hmmm, I'm surprised that FreeBSD uses different includes than Mac OS X. > > I guess adding an explicit include may be better than relying on it being > pulled in by another header file anyway, so maybe this is a good thing. > > Anyway, sorry about that. Thanks for testing things on Mac OS X. > What version of FreeBSD are you using? I am going to try and install 7. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081019/fc341048/attachment.html From glewis at eyesbeyond.com Mon Oct 20 12:58:32 2008 From: glewis at eyesbeyond.com (Greg Lewis) Date: Mon, 20 Oct 2008 12:58:32 -0700 Subject: hg: bsd-port/bsd-port/jdk: . Introduce macros to construct the name of shared libraries that take into In-Reply-To: References: <20081018035839.4E486D574@hg.openjdk.java.net> <20081019071140.GA50638@misty.eyesbeyond.com> Message-ID: <20081020195832.GA75283@misty.eyesbeyond.com> On Sun, Oct 19, 2008 at 12:25:35PM -0400, Michael Franz wrote: > On Sun, Oct 19, 2008 at 3:11 AM, Greg Lewis wrote: > > > On Sat, Oct 18, 2008 at 11:52:05PM -0400, Michael Franz wrote: > > > I had to add the include to jvm_md.h to the following files to get this > > to > > > compile > > > M jdk/src/share/demo/jvmti/hprof/hprof_init.c > > > M jdk/src/solaris/native/sun/awt/CUPSfuncs.c > > > M jdk/src/solaris/native/sun/awt/awt_Mlib.c > > > M jdk/src/solaris/native/sun/awt/fontpath.c > > > M jdk/src/solaris/native/sun/awt/gtk2_interface.c > > > M jdk/src/solaris/native/sun/java2d/opengl/OGLFuncs_md.h > > > M jdk/src/solaris/native/sun/xawt/awt_Desktop.c > > > > Hmmm, I'm surprised that FreeBSD uses different includes than Mac OS X. > > > > I guess adding an explicit include may be better than relying on it being > > pulled in by another header file anyway, so maybe this is a good thing. > > > > Anyway, sorry about that. Thanks for testing things on Mac OS X. > > > > What version of FreeBSD are you using? I am going to try and install 7. I'm currently running builds on FreeBSD 7/i386. -- Greg Lewis Email : glewis at eyesbeyond.com Eyes Beyond Web : http://www.eyesbeyond.com Information Technology FreeBSD : glewis at FreeBSD.org From nick.hilhorst at orange.nl Fri Oct 24 11:50:08 2008 From: nick.hilhorst at orange.nl (Nick Hilhorst) Date: Fri, 24 Oct 2008 20:50:08 +0200 Subject: Using javax.smartcardio from openjdk7-darwin-i386-20080820 In-Reply-To: <8F2BD69D-0E98-4F60-A60A-8B09ED890B6D@orange.nl> References: <8F2BD69D-0E98-4F60-A60A-8B09ED890B6D@orange.nl> Message-ID: Yesterday I finally got javax.smartcardio to work from both soylatte 1.6 as well as openjdk 7. The solution was setting the Java system property sun.security.smartcardio.library to /System/Library/ Frameworks/PCSC.framework/PCSC, which I did by adding the following as a Default VM Argument in Eclipse: -Dsun.security.smartcardio.library=/System/Library/Frameworks/ PCSC.framework/PCSC I vaguely remember that I came across some code, as I was going through the java sources, where several default locations for libpcsclite were probed. For a native darwin port it might be useful to change one of these to the library mentioned above. By the way, this still won't work from the Java 6 version provided by Apple, because Java is 64 bit and the library is 32 bit and PPC only. On Sep 6, 2008, at 15:59 , Nick Hilhorst wrote: > If you are running your own pcscd you need to set the Java system > property sun.security.smartcardio.library to the location of your PC/ > SC library (as described on http://java.sun.com/javase/6/docs/technotes/guides/security/SunProviders.html#SunPCSCProvider) > . I did this by adding the following as a Default VM Argument in > Eclipse: > > -Dsun.security.smartcardio.library=/usr/local/lib/libpcsclite.dylib > > This definitely changed something for the better, but I'm not > completely there yet. I now get the following exceptions: > > java.security.NoSuchAlgorithmException: Error constructing > implementation (algorithm: PC/SC, provider: SunPCSC, class: > sun.security.smartcardio.SunPCSC$Factory) > at java.security.Provider$Service.newInstance(Provider.java:1257) > at sun.security.jca.GetInstance.getInstance(GetInstance.java:243) > at sun.security.jca.GetInstance.getInstance(GetInstance.java:190) > at > javax.smartcardio.TerminalFactory.getInstance(TerminalFactory.java: > 243) > at com.ongelooflijk.chipknip.LoadTest.main(LoadTest.java:19) > Caused by: sun.security.smartcardio.PCSCException: SCARD_E_NO_SERVICE > at sun.security.smartcardio.PCSC.SCardEstablishContext(Native Method) > at > sun > .security.smartcardio.PCSCTerminals.initContext(PCSCTerminals.java:56) > at sun.security.smartcardio.SunPCSC$Factory.(SunPCSC.java:60) > at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native > Method) > at > sun > .reflect > .NativeConstructorAccessorImpl > .newInstance(NativeConstructorAccessorImpl.java:57) > at > sun > .reflect > .DelegatingConstructorAccessorImpl > .newInstance(DelegatingConstructorAccessorImpl.java:45) > at java.lang.reflect.Constructor.newInstance(Constructor.java:539) > at java.security.Provider$Service.newInstance(Provider.java:1252) > ... 4 more > > I'm testing with the following program: > > package com.ongelooflijk.chipknip; > > import java.security.NoSuchAlgorithmException; > import java.util.Iterator; > import java.util.List; > > import javax.smartcardio.CardException; > import javax.smartcardio.CardTerminal; > import javax.smartcardio.TerminalFactory; > > public class LoadTest { > > /** > * @param args > */ > public static void main(String[] args) { > List terminals = null; > try { > TerminalFactory factory = TerminalFactory.getInstance("PC/SC", > null); > System.out.println("TerminalFactory Type: " + factory.getType()); > // Get the list of readers configured in the environment > terminals = factory.terminals().list(); > for (Iterator iter = terminals.iterator(); > iter.hasNext();) > System.out.println("Terminal: " + iter.next()); > } catch (NoSuchAlgorithmException e) { > e.printStackTrace(); > } catch (CardException e) { > e.printStackTrace(); > } > > } > } > > > If anyone has ideas they're more than welcome. I don't really think > this has anything to do with openjdk anymore. I have the feeling > that /usr/local/lib/libpcsclite.dylib somehow doesn't work with the > pcscd that is installed, but I have no idea how to check this. I > know pcscd is running and working, because pcsctest still gives the > expected results. > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081024/facb7470/attachment.html From mvfranz at gmail.com Fri Oct 24 22:15:29 2008 From: mvfranz at gmail.com (Michael Franz) Date: Sat, 25 Oct 2008 01:15:29 -0400 Subject: Unable to start process using Runtime - Solved Message-ID: Hi, I have been trying to using OpenJDK BSD to run Eclipse and Netbeans. I have been successful in both, but it was not very useful as I there was no way to actually run my code from within the IDEs. There is an issue with OpenJDK for BSD being unable to start a process. After many compiles and narrowing the problem down to the closeDescriptors I was able to find this posting that explains why it doesn't work and some history to it. Most importantly, it also has the fix. http://www.mavetju.org/mail/view_message.php?list=freebsd-java&id=2564148 Applying the patch allows OpenJDK to spawn processes on OS X. Hopefully it will work for all of the BSDs. Michael -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081025/529040f0/attachment.html From martinrb at google.com Sat Oct 25 09:47:29 2008 From: martinrb at google.com (Martin Buchholz) Date: Sat, 25 Oct 2008 09:47:29 -0700 Subject: Unable to start process using Runtime - Solved In-Reply-To: References: Message-ID: <1ccfd1c10810250947x6f956e80vb901376a363a5667@mail.gmail.com> Hi Michael, I am the author of the changes to UNIXProcess_md.c. File descriptor 3 is used to communicate any cause of failure back to the parent process. One might think that the openjdk7 code would work on BSD because if the standard way of opening /proc/self/fd, it falls back to closing all descriptors up to sysconf(_SC_OPEN_MAX), which one would think the BSDs would have implemented. In any case, even if the current jdk7 code doesn't work on BSD, it should be easy to create a small patch to it that would be portable to more Unix systems, that could be accepted upstream. I would be willing to review. Martin On Fri, Oct 24, 2008 at 22:15, Michael Franz wrote: > Hi, > > I have been trying to using OpenJDK BSD to run Eclipse and Netbeans. I have > been successful in both, but it was not very useful as I there was no way to > actually run my code from within the IDEs. There is an issue with OpenJDK > for BSD being unable to start a process. After many compiles and narrowing > the problem down to the closeDescriptors I was able to find this posting > that explains why it doesn't work and some history to it. Most importantly, > it also has the fix. > > http://www.mavetju.org/mail/view_message.php?list=freebsd-java&id=2564148 > > Applying the patch allows OpenJDK to spawn processes on OS X. Hopefully it > will work for all of the BSDs. > > Michael > > > > From mvfranz at gmail.com Sat Oct 25 13:55:36 2008 From: mvfranz at gmail.com (Michael Franz) Date: Sat, 25 Oct 2008 16:55:36 -0400 Subject: Unable to start process using Runtime - Solved In-Reply-To: <1ccfd1c10810250947x6f956e80vb901376a363a5667@mail.gmail.com> References: <1ccfd1c10810250947x6f956e80vb901376a363a5667@mail.gmail.com> Message-ID: Martin, Here are the changes that work for OS X. Michael On Sat, Oct 25, 2008 at 12:47 PM, Martin Buchholz wrote: > Hi Michael, > > I am the author of the changes to UNIXProcess_md.c. > File descriptor 3 is used to communicate any cause of failure > back to the parent process. > > One might think that the openjdk7 code would work on > BSD because if the standard way of opening /proc/self/fd, > it falls back to closing all descriptors up to sysconf(_SC_OPEN_MAX), > which one would think the BSDs would have implemented. > > In any case, even if the current jdk7 code doesn't work on BSD, > it should be easy to create a small patch to it that would be > portable to more Unix systems, that could be accepted upstream. > I would be willing to review. > > Martin > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081025/6ebbc835/attachment.html -------------- next part -------------- A non-text attachment was scrubbed... Name: unixprocess_md.patch Type: application/octet-stream Size: 1321 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081025/6ebbc835/attachment.obj From martinrb at google.com Sat Oct 25 19:15:46 2008 From: martinrb at google.com (Martin Buchholz) Date: Sat, 25 Oct 2008 19:15:46 -0700 Subject: Unable to start process using Runtime - Solved In-Reply-To: References: <1ccfd1c10810250947x6f956e80vb901376a363a5667@mail.gmail.com> Message-ID: <1ccfd1c10810251915w7dea6222gbc14fd694754158@mail.gmail.com> Michael, That looks like a fine patch to the BSD version of UNIXProcess_md.c, but my idea was to avoid having to have a BSD version of this file at all. The hope is eventually to have BSD support integrated into the standard OpenJDK sources, hopefully without special case code specifically for BSDs. Martin On Sat, Oct 25, 2008 at 13:55, Michael Franz wrote: > Martin, > > Here are the changes that work for OS X. > > Michael > > > On Sat, Oct 25, 2008 at 12:47 PM, Martin Buchholz > wrote: >> >> Hi Michael, >> >> I am the author of the changes to UNIXProcess_md.c. >> File descriptor 3 is used to communicate any cause of failure >> back to the parent process. >> >> One might think that the openjdk7 code would work on >> BSD because if the standard way of opening /proc/self/fd, >> it falls back to closing all descriptors up to sysconf(_SC_OPEN_MAX), >> which one would think the BSDs would have implemented. >> >> In any case, even if the current jdk7 code doesn't work on BSD, >> it should be easy to create a small patch to it that would be >> portable to more Unix systems, that could be accepted upstream. >> I would be willing to review. >> >> Martin > > From mvfranz at gmail.com Sun Oct 26 05:58:40 2008 From: mvfranz at gmail.com (Michael Franz) Date: Sun, 26 Oct 2008 08:58:40 -0400 Subject: Unable to start process using Runtime - Solved In-Reply-To: <1ccfd1c10810251915w7dea6222gbc14fd694754158@mail.gmail.com> References: <1ccfd1c10810250947x6f956e80vb901376a363a5667@mail.gmail.com> <1ccfd1c10810251915w7dea6222gbc14fd694754158@mail.gmail.com> Message-ID: Martin, I can take a deeper look at the problem and let you know what I come up with. Michael On Sat, Oct 25, 2008 at 10:15 PM, Martin Buchholz wrote: > Michael, > > That looks like a fine patch to the BSD version of UNIXProcess_md.c, > but my idea was to avoid having to have a BSD version of this file > at all. The hope is eventually to have BSD support integrated into the > standard OpenJDK sources, hopefully without special case code > specifically for BSDs. > > Martin > > On Sat, Oct 25, 2008 at 13:55, Michael Franz wrote: > > Martin, > > > > Here are the changes that work for OS X. > > > > Michael > > > > > > On Sat, Oct 25, 2008 at 12:47 PM, Martin Buchholz > > wrote: > >> > >> Hi Michael, > >> > >> I am the author of the changes to UNIXProcess_md.c. > >> File descriptor 3 is used to communicate any cause of failure > >> back to the parent process. > >> > >> One might think that the openjdk7 code would work on > >> BSD because if the standard way of opening /proc/self/fd, > >> it falls back to closing all descriptors up to sysconf(_SC_OPEN_MAX), > >> which one would think the BSDs would have implemented. > >> > >> In any case, even if the current jdk7 code doesn't work on BSD, > >> it should be easy to create a small patch to it that would be > >> portable to more Unix systems, that could be accepted upstream. > >> I would be willing to review. > >> > >> Martin > > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081026/77e42a9a/attachment.html From mvfranz at gmail.com Sun Oct 26 16:52:15 2008 From: mvfranz at gmail.com (Michael Franz) Date: Sun, 26 Oct 2008 19:52:15 -0400 Subject: Unable to start process using Runtime - Solved In-Reply-To: References: <1ccfd1c10810250947x6f956e80vb901376a363a5667@mail.gmail.com> <1ccfd1c10810251915w7dea6222gbc14fd694754158@mail.gmail.com> Message-ID: Martin, I think I have found a way we can use the closeDescriptor version that is used by Solaris and Linux for OS X (and probably the other BSD versions). OS X uses /dev/fd instead of /proc/self/fd. I think the other BSD version also use /dev/fd. This patch removes a few functions and hopefully makes the code cleaner. Let me know what you think and if it still works on your platform. Michael On Sun, Oct 26, 2008 at 8:58 AM, Michael Franz wrote: > Martin, > > I can take a deeper look at the problem and let you know what I come up > with. > > Michael > > > On Sat, Oct 25, 2008 at 10:15 PM, Martin Buchholz wrote: > >> Michael, >> >> That looks like a fine patch to the BSD version of UNIXProcess_md.c, >> but my idea was to avoid having to have a BSD version of this file >> at all. The hope is eventually to have BSD support integrated into the >> standard OpenJDK sources, hopefully without special case code >> specifically for BSDs. >> >> Martin >> >> On Sat, Oct 25, 2008 at 13:55, Michael Franz wrote: >> > Martin, >> > >> > Here are the changes that work for OS X. >> > >> > Michael >> > >> > >> > On Sat, Oct 25, 2008 at 12:47 PM, Martin Buchholz >> > wrote: >> >> >> >> Hi Michael, >> >> >> >> I am the author of the changes to UNIXProcess_md.c. >> >> File descriptor 3 is used to communicate any cause of failure >> >> back to the parent process. >> >> >> >> One might think that the openjdk7 code would work on >> >> BSD because if the standard way of opening /proc/self/fd, >> >> it falls back to closing all descriptors up to sysconf(_SC_OPEN_MAX), >> >> which one would think the BSDs would have implemented. >> >> >> >> In any case, even if the current jdk7 code doesn't work on BSD, >> >> it should be easy to create a small patch to it that would be >> >> portable to more Unix systems, that could be accepted upstream. >> >> I would be willing to review. >> >> >> >> Martin >> > >> > >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081026/ca754560/attachment.html -------------- next part -------------- A non-text attachment was scrubbed... Name: UNIXProcess_md.patch2 Type: application/octet-stream Size: 3671 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081026/ca754560/attachment.obj From martinrb at google.com Sun Oct 26 17:29:24 2008 From: martinrb at google.com (Martin Buchholz) Date: Sun, 26 Oct 2008 17:29:24 -0700 Subject: Unable to start process using Runtime - Solved In-Reply-To: References: <1ccfd1c10810250947x6f956e80vb901376a363a5667@mail.gmail.com> <1ccfd1c10810251915w7dea6222gbc14fd694754158@mail.gmail.com> Message-ID: <1ccfd1c10810261729k529302d7q6d0ab27e812b856f@mail.gmail.com> Hmmmm.... I'm having second thoughts about whether it's worth the effort to try to push bsd support into OpenJDK. That sort of effort would be easier with a configure layer. The IcedTea team is moving in that direction. The most portable approach to finding /proc/self/fd or /dev/fd is to do the detection once at runtime. In pseudocode: final static String fdDir; static { if (new File("/proc/self/fd").isDirectory()) fdDir = "/proc/self/fd"; else if (new File("/dev/fd").isDirectory()) fdDir = "/dev/fd"; else fdDir = null; } And then use that value at runtime. I definitely think getting rid of the heuristic GUESS_FINISHED is worthwhile. Any failures with this heuristic will be rare, unpredictable, and almost undebuggable for mortals. And will only happen in production at 3am. I'm surprised the BSDs don't all have readdir64 and friends. Here's a case where configure would be useful. Or, since a Solaris bug is being worked around, one could make the use of readdir64 conditional on whether compiling for solaris. Martin On Sun, Oct 26, 2008 at 16:52, Michael Franz wrote: > Martin, > > I think I have found a way we can use the closeDescriptor version that is > used by Solaris and Linux for OS X (and probably the other BSD versions). > > OS X uses /dev/fd instead of /proc/self/fd. I think the other BSD version > also use /dev/fd. This patch removes a few functions and hopefully makes > the code cleaner. > > Let me know what you think and if it still works on your platform. > > Michael > > On Sun, Oct 26, 2008 at 8:58 AM, Michael Franz wrote: >> >> Martin, >> >> I can take a deeper look at the problem and let you know what I come up >> with. >> >> Michael >> >> On Sat, Oct 25, 2008 at 10:15 PM, Martin Buchholz >> wrote: >>> >>> Michael, >>> >>> That looks like a fine patch to the BSD version of UNIXProcess_md.c, >>> but my idea was to avoid having to have a BSD version of this file >>> at all. The hope is eventually to have BSD support integrated into the >>> standard OpenJDK sources, hopefully without special case code >>> specifically for BSDs. >>> >>> Martin >>> >>> On Sat, Oct 25, 2008 at 13:55, Michael Franz wrote: >>> > Martin, >>> > >>> > Here are the changes that work for OS X. >>> > >>> > Michael >>> > >>> > >>> > On Sat, Oct 25, 2008 at 12:47 PM, Martin Buchholz >>> > wrote: >>> >> >>> >> Hi Michael, >>> >> >>> >> I am the author of the changes to UNIXProcess_md.c. >>> >> File descriptor 3 is used to communicate any cause of failure >>> >> back to the parent process. >>> >> >>> >> One might think that the openjdk7 code would work on >>> >> BSD because if the standard way of opening /proc/self/fd, >>> >> it falls back to closing all descriptors up to sysconf(_SC_OPEN_MAX), >>> >> which one would think the BSDs would have implemented. >>> >> >>> >> In any case, even if the current jdk7 code doesn't work on BSD, >>> >> it should be easy to create a small patch to it that would be >>> >> portable to more Unix systems, that could be accepted upstream. >>> >> I would be willing to review. >>> >> >>> >> Martin >>> > >>> > >> > > From mvfranz at gmail.com Mon Oct 27 18:43:15 2008 From: mvfranz at gmail.com (Michael Franz) Date: Mon, 27 Oct 2008 21:43:15 -0400 Subject: Darwin OpenJDK 7 Binaries - Not Working With SWT In-Reply-To: References: <6CB8264F-247A-4B48-A5D6-904263F92144@apple.com> <3B0CBA27-1463-426B-8AA1-E7B00D557E25@plausiblelabs.com> Message-ID: Mike, If the runloop is running on Thread 0, can a thread that is not thread 0 pull events off the runloop by using NSApplication.sharedApplication(). nextEventMatchingMask() ? Where events are the keyboard and mouse events. How does one 'park' thread 0? Michael On Sun, Oct 12, 2008 at 11:21 AM, Mike Swingler wrote: > > You can create runloops on other threads, but their sources will be setup > by you. Only the runloop on Thread 0 receives keyboard and mouse events, > which is why -XstartOnFirstThread is necessary when user-space code wants to > pump the event loop. Otherwise, Thread 0 needs to be parked until it's time > for the AWT to startup, and start running the show. > > Cheers, > Mike Swingler > Java Runtime Engineer > Apple Inc. > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081027/378f3b2a/attachment.html From swingler at apple.com Tue Oct 28 09:34:57 2008 From: swingler at apple.com (Mike Swingler) Date: Tue, 28 Oct 2008 09:34:57 -0700 Subject: Darwin OpenJDK 7 Binaries - Not Working With SWT In-Reply-To: References: <6CB8264F-247A-4B48-A5D6-904263F92144@apple.com> <3B0CBA27-1463-426B-8AA1-E7B00D557E25@plausiblelabs.com> Message-ID: On Oct 27, 2008, at 6:43 PM, Michael Franz wrote: > Mike, > > If the runloop is running on Thread 0, can a thread that is not > thread 0 pull events off the runloop by using > NSApplication.sharedApplication(). nextEventMatchingMask() ? Where > events are the keyboard and mouse events. Sorry, nope. I'm pretty sure this method has been tried by the SWT folks. > How does one 'park' thread 0? pthread_mutex_lock()/pthread_cond_wait()/pthread_cond_signal(). When we load the AWT, we simply signal Thread 0, to continue and start pumping the event loop. If the AWT never comes up, the thread stays parked indefinitely. This is actually just a modification to how the JVM starts when you request a custom thread stack size for the main thread. > Michael > > On Sun, Oct 12, 2008 at 11:21 AM, Mike Swingler > wrote: > > You can create runloops on other threads, but their sources will be > setup by you. Only the runloop on Thread 0 receives keyboard and > mouse events, which is why -XstartOnFirstThread is necessary when > user-space code wants to pump the event loop. Otherwise, Thread 0 > needs to be parked until it's time for the AWT to startup, and start > running the show. > > Cheers, > Mike Swingler > Java Runtime Engineer > Apple Inc. > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081028/3daf20ab/attachment.html From mvfranz at gmail.com Wed Oct 29 15:48:05 2008 From: mvfranz at gmail.com (Michael Franz) Date: Wed, 29 Oct 2008 18:48:05 -0400 Subject: Darwin OpenJDK 7 Binaries - Not Working With SWT In-Reply-To: References: <6CB8264F-247A-4B48-A5D6-904263F92144@apple.com> <3B0CBA27-1463-426B-8AA1-E7B00D557E25@plausiblelabs.com> Message-ID: On Tue, Oct 28, 2008 at 12:34 PM, Mike Swingler wrote: > On Oct 27, 2008, at 6:43 PM, Michael Franz wrote: > > Mike, > > If the runloop is running on Thread 0, can a thread that is not thread 0 > pull events off the runloop by using NSApplication.sharedApplication(). > nextEventMatchingMask() ? Where events are the keyboard and mouse events. > > > Sorry, nope. I'm pretty sure this method has been tried by the SWT folks. > Just so I am clear, there is no easy way for a thread to get the mouse and keyboard events from Thread 0? A non-easy way might be to implement a producer/consumer pattern. Where thread 0 is the producer and some other thread is the consumer. > > How does one 'park' thread 0? > > > pthread_mutex_lock()/pthread_cond_wait()/pthread_cond_signal(). When we > load the AWT, we simply signal Thread 0, to continue and start pumping the > event loop. If the AWT never comes up, the thread stays parked indefinitely. > This is actually just a modification to how the JVM starts when you request > a custom thread stack size for the main thread. > OK, my PThreads book helped clarify this. Thanks for all your input. Michael -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/bsd-port-dev/attachments/20081029/34986e65/attachment.html