116v4a glibc bug
below is a program that has a bug - it doesn't create an array
before assigning into it (happens in a constructor).
Under 116v4a/glibc, the program says "Can't find class" rather
than printing a nice stacktrace. Under 115v5,7 it sometimes
prints the stacktrace; sometimes the constructor returns
null and no (correct) error is printed.
-
// 1.1.6v4a calles the parent constructor(shape), then
// says "Can't find class bblobBUG"
// 1.1.5v5 runs, but theShape is printed as null
// search for BUG.
import java.awt.*;
import java.applet.*;
class avector {
avector() { arr = new float[3]; }
float[] arr;
}
abstract class shape
{
static avector p[][];
shape()
{
System.out.println("shape constructor, initializing");
// BUG is here: need p = new avector[2][2]
for( int ir=0; ir < 2; ir++ ) {
for( int it=0; it < 2; it++ ) {
p[ir][it] = new avector();
}
}
}
} //shape
//
public class bblobBUG extends java.applet.Applet
{
static class sphere extends shape
{
sphere() {
super();
System.out.println("sphere constructor");
}
} //sphere
//
final static int XRES= 300;
final static int YRES= 300;
static shape theShape = new sphere();
//
public static void main(String[] args)
{
bblobBUG bb = new bblobBUG();
System.out.println(theShape); // BUG: says "null"
Frame mainFrame = new Frame("bblob");
mainFrame.setSize(XRES, YRES);
mainFrame.add(bb);
mainFrame.show();
} //main
} //bblob
---
j.p.lewis [EMAIL PROTECTED]
012 345 6789 //www.idiom.com/~zilla
sun jdk under wine?
Has anyone tried to run the W95 sun jdk binary (or the IBM w95 java->native compiler) under Wine? --- j.p.lewis [EMAIL PROTECTED] 012 345 6789 //www.idiom.com/~zilla
1.1.6,1.1.7: cannot find ldd
The lastest versions of the x86 blackdown jdk report the following error when starting java (though things work fine otherwise): /usr/local/java/bin/checkVersions: ldd: command not found This is on a system that was originally RH5.0, since upgraded to RH5.1, pretty vanilla (compiled apm support into the kernel but no other changes). I don't see 'ldd' on the system - what is this? --- j.p.lewis [EMAIL PROTECTED] 012 345 6789 //www.idiom.com/~zilla
Q: how to layout jar/directories?
Hello, (a bit off topic, but this is a unix/linux-specific java question) I have several packages that are logically (to me) arranged in the file tree; the CLASSPATH points to their .jars and everything works fine. I would like to combine the class files into a *single jar* to be distributed to people. Is this possible/is it only possible if all the jars reside under a single tree and the packages are renamed accordingly? Example off the top of my head: /usr/xx/dev/applications/util/foo/foo.java package util.foo imports /usr/xx/dev/lib/zlib/zlibmisc.java package zlib Can util.foo.* and zlib.* live in the same jar? --- j.p.lewis, r&d lead centropolis fx 310 449 4545 [EMAIL PROTECTED] //www.idiom.com/~zilla
ANNOUNCE: network file synchronization utility
(swing+rmi; developed with Blackdown jdk1.1.7a) Xfiles synchronizes and cross-validates two file directory trees across a network. A client/server program (GUI on the client) traverses an indicated file tree and reports any files that are missing on the server machine, missing on the client machine, or different. For each such file, the file size/sizes and modification date(s) are shown, and a comparison (using Unix diff) can be obtained. For files that are missing from one tree, similarly named files in that tree are reported. Inconsistent files can then be copied in either direction or deleted on either machine. The file trees do not need to be accessible via nfs. Files checksums are compared, so largely similar trees can be compared over a slow network link. The client and server processes can also be run on the same machine. (The program is also usable as an alternative backup strategy: Portions of a disk may go bad at any time, with no simple indication of which files were affected. You may not examine all of the thousands of files on a disk in the time interval before a backup tape goes bad. Don't stop making backups, but cross-validate against a second disk to make sure you aren't backing up bad data.) GPL'd source & binary at: www.idiom.com/~zilla/xfiles.html
1.1.6-libc under redhat 5?
Hello, can I run the libc version of 1.1.6 under plain redhat 5 (rather than downloading the glibc and its antecedants, which would be a big project with my unreliable net connection) --- j.p.lewis [EMAIL PROTECTED] 012 345 6789 //www.idiom.com/~zilla
1.1.6-libc under redhat 5? (fwd)
Alternate question: with 1.1.6-v2 do I need to upgrade a plain Redhat5 to the new glibc/ld/etc? The FAQ talks about this, but I don't understand what it is saying: "The latest versions of the Blackdown JDK have their own built-in loader and libc, which will hopefully make them more robust. Older versions of the JDK 1.1.5 (especially) are much more sensitive. Karl Asha maintains a list JDK-related library issues at: http://www.blackdown.org/java-linux/docs/libraries.html. In short, you need glibc-2.0.7 and glibc-devel-2.0.7 or higher on a glibc-based system such as RedHat 5.0 or Debian 2.0." -- Forwarded message -- Hello, can I run the libc version of 1.1.6 under plain redhat 5 (rather than downloading the glibc and its antecedants, which would be a big project with my unreliable net connection) --- j.p.lewis [EMAIL PROTECTED] 012 345 6789 //www.idiom.com/~zilla
1.1.6-v2 problem with swing textinput
On an i386 redhat5.0 system, I'm developing a swing1.02 program. It works ok under jdk1.1.5v5-980311. Under 1.1.6-v2-glibc, various problems with text input in a jtable cell: - double characters - does not end editing, rather it enters as an unprintable character - likewise del and backspace do not function - after editing the cell once, double characters do nnot appear during subsequent edits; likewise del and backspace work (glibc2.0.7-13 ld.so1.9.5-5) Thanks for any thoughts --- j.p.lewis [EMAIL PROTECTED] 012 345 6789 //www.idiom.com/~zilla
Links/Aliases/Shortcuts in Java (how-to doc)
A description of this issue + a pure java routine that seems to work correctly under linux: http://www.idiom.com/~zilla/Xfiles/javasymlinks.html
ANNOUNCE: network file synchronization utility v1.1
(swing+rmi; developed with Blackdown jdk1.1.7a) Version 1.1 is rewritten to no longer require native (non-java) link detection; installation is simplified; other improvements. - Xfiles is a X/JFC utility that interactively cross-validates one disk against another over a network. It's useful for people who work on several machines and also as alternative backup strategy (portions of a disk may go bad at any time, with no simple indication of which files were affected. Cross-validate against a second disk before backup to make sure you aren't backing up bad data). A client/server program (GUI on the client) traverses a file tree and reports any files that are missing on the server machine, missing on the client machine, or different. For each such file, the file size/sizes and modification date(s) are shown, and a comparison (using Unix diff) can be obtained. For files that are missing from one tree, similarly named files in that tree are reported. Inconsistent files can then be copied in either direction or deleted on either machine. The file trees do not need to be accessible via nfs; files checksums are computed in parallel, so largely similar trees can be compared over a slow network link; the client and server processes can also be run on the same machine. GPL'd source & binary at: www.idiom.com/~zilla/xfiles.html
Re: A file system for organising java stuff ?
I agree that there should be at least a vague convention on how/where Java programs are installed under Unix/Linux. At present, suppose you want to release a rpm'd or similar public version of a program - where should it go? Probably the java community should propose the solution - otherwise some poorly chosen convention might take hold. I think a couple more people should join the original poster and publish a more formal looking recommendation. R.e. the specific proposal, no problems with what's there, but I think Java programs may need to exist in places other than just /usr/local. If someone wrote a system control panel using swing (e.g. replacement for the redhat scripts such as adduser that use tk), where should this go? --- j.p.lewis [EMAIL PROTECTED] 012 345 6789 //www.idiom.com/~zilla
Re: A file system for organising java stuff ?
An additional thought: Suppose one writes a control panel or system utility using java. Conventionally this should be installed in /usr/bin or /usr/sbin. - Linux has the kernel facility that launches a .class path when it's name is typed. So one could install the .class in /usr/bin. One could install all the needed files for the program (including icons) into the .jar. The kernel java launching should be able to launch a .jar file rather than just a .class file, setting the CLASSPATH to the jar. - we should be able to install things like standard jpeg parsing librarys as .jars in /usr/lib, and some 1.1 programs will need to set the CLASSPATH to include swing. Java programs that uses these will require a separate script to set the classpath. Propose instead that the kernel java facility should look inside the .jar for a file _CLASSPATH_ or something and set the classpath to this before running. - Is there some way to distinguish between a .jar file and a plain .zip file? I don't know. One way would be to look for the _CLASSPATH_ file in the zip and only try to launch the file as a java .jar if this file exists (and maybe only if it contains a magic number before the classpath) With this approach, for linux at least, the problem seems pretty easy - just install everything in the same places it would go if it were a C program. /usr/bin/diff c program /usr/bin/jdiff java .jar diff with a nice gui, jar file contains mos /usr/lib/libjpeg.*soc library /usr/lib/libjpeg.jarjava library --- j.p.lewis [EMAIL PROTECTED] 012 345 6789 //www.idiom.com/~zilla
ANNOUNCE: network file synchronization utility v1.3
(swing+rmi; developed with Blackdown jdk1.1.7a) Xfiles is an interactive utility for cross-validating one file tree against another over a network. It's useful for people who work on several machines and also as alternative backup strategy. Version 1.3 adds JPython scripting to control what files are visited and to script interaction with a revision control system such as RCS. GPL'd source & binary at: www.idiom.com/~zilla/xfiles.html -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Java/C benchmark
There is a very good article that benchmarks a number of jvms including the blackdown jdk1.1.7+tya at http://www.javalobby.org/features/jpr One interesting point is that TYA is on various benchmarks 2-8 times slower than the Symantec jit included with Sun's java under Windows (which in turn is slower than the forthcoming hotspot). Since TYA is roughly the same speed as the 'sunwjit' jit supplied by sun for the linux java1.2, this means that Sun supplied linux a much slower jit than the one it supplies with Windows. Is this because they cannot legally supply the Windows jit? Where did this jit come from? - Somewhat related, some timings of two programs that I had available in both C and Java versions: The SPLINEFILL program rasterizes a closed spline contour and then uses a seed fill algorithm to color its interior. The java version is 1500 lines, not including some libraries. The seed fill is likely to be the inner loop but I did not verify this. The RANDOM program calls a custom random number generator a number of times and prints the last-generated number. This is a rather too simple (8-line) integer-heavy algorithm. In both cases I verified that the output was identical between the C and Java versions. The C timings on the SPLINEFILL were so short that they are probably not reliable, but maybe they give a rough guess about where we are. The RANDOM timings are encouraging, but it seems that this performance is only obtained for small routines with no floating point or objects. The machines involved are an Intel 166mmx running Linux 2.0.36 and an SGI (not running linux) using a 195mhz R10K. Both C,Java programs were compiled without optimization. The program times are "user" times in seconds as shown by the 'time' command. SPLINEFILL/intel gcc .23 jdk1.2prev1 .638 jdk117v1a/tya13 .621 jdk117v1a/tya11v4 .676 jdk117v1a/shujit0.2.10 .998 jdk117v1a(interp) 1.139 SPLINEFILL/sgi cc 0.086u+0.047s (not reliable) jdk115+jit .525 RANDOM/intel gcc 12.2 jdk1.2prev1 14.37 tya13 15.1 jdk117v1a interpreted 29.8 RANDOM/sgi cc 3.83 jdk115+jit 7.2 --- j.p.lewis [EMAIL PROTECTED] 012 345 6789 //www.idiom.com/~zilla -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Java/C benchmark
> but I'm afraid I have to say your followup comparisons are unfair... hold on - this post was intended to be just a statement of fact, not a complaint. I use blackdown and am very grateful for its existence. I've timed tya across releases, and it's gotten steadily faster over the last 6 months. The fact that it already keeps up with the sun-supplied jdk12/linux jit is impressive. I primarily wanted to point out the curious fact that the jit supplied by sun for Windows is much faster than the jit supplied by sun for Linux, and to ask what this meant. > p.s. (_way_ off-topic) /pix/sunset640sig.jpg is gorgeous, as is the thanks -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: JIT in pre2???
The JIT is one developed by Sun, but it's a lot slower than the one Sun obtained from Symantec that is included in the windows version of java. Which in turn is said to be slower than hotspot for long-running programs. There was a good set of benchmarks on www.javalobby.org a month or so ago. Also see my informal java/C benchmarks at www.idiom.com/~zilla/Computer/javaCbenchmark.html The good news is that Hotspot is supposed to be available for linux later this year, and IBM's very fast jvm/jit is also rumored to be on the way. -- jp lewis director software r&d dreamquest digital images 805 578 3136 [EMAIL PROTECTED] www.idiom.com/~zilla -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
linux distribution preinstall java
I think we should lobby a couple of the major linux distributions to include blackdown on their CDs. Most developers have a fast net connection, but downloading and correctly installing java is quite an effort if all you have is a modem connection. I heard that Redhat says that they can't for licensing reasons. On the other hand, I believe that Mandrake includes blackdown on the applications cd. Does anyone know what the issue is? Is the licensing problem true even of the jre? -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: linux distribution preinstall java
> SuSE has the JDK. SuSE 6.0 has the 1.1.7 JDK I think, and the JRE, no > version of 1.2 though. I don't know about 6.2. RedHat does not yet include any version of blackdown. --- j.p.lewis [EMAIL PROTECTED] 012 345 6789 //www.idiom.com/~zilla -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
java vs. C benchmark
A few simple benchmarks comparing blackdown, the ibm jdk116, and gcc are at: www.idiom.com/~zilla/Computer/javaCbenchmark.html -- jp lewis director software r&d dreamquest digital images 805 578 3136 [EMAIL PROTECTED] www.idiom.com/~zilla -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
