Re: Java and 3D.
Magician http://www.arcana.co.uk is the best way to do Opengl with java. Joel Shellman wrote: > Related question. Does anyone know how or if there is a way to use the > Java 3D kit on Linux? I tried to download it but realized it was an > executable and therefore not runnable on linux. > > Thank you, > > Joel Shellman > http://corp.knocean.com/
Re: javac problem
I also have the exact same problem. Just install JDK-1.1.6-v4a libc version on Red Hat 4.2. If I run javac_g, I get: SIGSEGV 11* segmentation violation Full thread dump: "../../../../src/genunix/java/green_threads/src/monitor_md.c", line 443: assertion failure *** panic: Internal error dumping threads! I also believe it may be because it can't find shared lib's libjava.so & libawt.so, still investigating!! Gao Lei wrote: > > Same thing to me, one of my slackware machine have this problem, but > the wired thing is that javac on other red hat machines have a nearly > same glibc libraries runs well. > > Hope somebody helps. > Thanks. > > Calixto Melean (Personal) wrote: > > > I installed the corresponding jdk in my glibc linux system. the java > > command runs fine. however, the compiler (javac) gives me the > following > > errors: > > > > SIGSEGV 11* segmentation violation > > > > Full thread dump: > > Monitor Cache Dump: > > Registered Monitor Dump: > > Monitor IO lock: > > Child death monitor: > > Event monitor: > > I/O monitor: > > Alarm monitor: > > Monitor registry: > > Thread Alarm Q: begin:vcard n:Sider;Jeff x-mozilla-html:FALSE org:SIDC Software Development Inc. adr:;;;Hamilton;Ontario;;Canada version:2.1 email;internet:[EMAIL PROTECTED] title:Senior Consultant x-mozilla-cpt:;0 fn:Jeff Sider end:vcard
Re: NETBEANS INSTALL
> interface com.sun.java.swing.*; I think you mean "import" ??? Syed Mubin wrote: > > __ > Syed Mubeen National Centre For Biological Sciences, > [EMAIL PROTECTED]TIFR Centre, P.B #1234, > 80-334-5615 or 4062 or 3035 IISc Campus, > Resi :3452848Bangalore - 560 012. INDIA. > ___ > > Hi, > > I'm trying to install Netbeans nbdv20b3.sh on JDK1.1.6 but > not sucessful.I also have installed SWING1.0.3 the SwingSet example is > working fine but when i wrote a simple program it shows the following > errors. > > - > CLASSPATH SET > > # .bashrc > #CONTENTS > > # User specific aliases and functions > > # Source global definitions > if [ -f /etc/bashrc ]; then > . /etc/bashrc > fi > > /usr/games/fortune > > JAVA_HOME="/home/syed/JDK1.6/jdk1.1.6" > export JAVA_HOME > export DISPLAY=:0 > PATH="/home/syed/JDK1.6/jdk1.1.6/bin:$PATH" > SWING_HOME="/home/syed/SWING13/swing-1.0.3" > export SWING_HOME > > - > > import java.awt.*; > import java.awt.event.*; > interface com.sun.java.swing.*; > import java.applet.*; > > public class SimpleSwing extends JApplet > { > JRadioButton metalButton; > JButton button; > > public void init() > { > JButton button = new JButton("Hello, world"); > JRadioButton metalButton = new JRadioButton(metal); > add(button); > add(metalButton); > validate(); > button.show(); > metalButton.show(); > } > } > > - > ERRORS SHOWN > > SimpleSwing.java:3: '{' expected. > interface com.sun.java.swing.*; > ^ > SimpleSwing.java:7: Superclass JApplet of nested class com. SimpleSwing > not found. > public class SimpleSwing extends JApplet > ^ > 2 errors > > > Is it compulsory to have swing installed for working netbeans? > > Please help > > Syed Mubeen > > begin:vcard n:Sider;Jeff x-mozilla-html:FALSE org:SIDC Software Development Inc. adr:;;;Hamilton;Ontario;;Canada version:2.1 email;internet:[EMAIL PROTECTED] title:Senior Consultant x-mozilla-cpt:;0 fn:Jeff Sider end:vcard
Re: JIT compiler TYA
Does anyone have the URL for this or any JIT that will work with JDK1.1.6v4a. Thanks. Leung Yau Wai wrote: > > Dear all, > > I would like to ask do TYA support a JAVA application with native > C function call? It seem that I got core dump in this suitation. I would > like to confirm it! > > Thanks! > > === > ¤µ¤Ñ¨ì¦Ñ§Ú¹³¨º¶^¤£¨ì §Ú·Q°µLeung Yau Wai > °µ§Ú©R¹B²Å¸¹ ¥Î§Ú¤OçE§Ú¸ô³~§Ú«Y¬ì¤j¹q¤lpºâ¾÷¬ì¾Ç¨t¤G¦~¯Å > ¥u¬ß§Ú¤@¤é·|¦b¬P©]¸Ì[EMAIL PROTECTED] > ¨º¤Ñ§Ú·| §t²\»¡Án §Ú°µ¨ì [EMAIL PROTECTED] begin:vcard n:Sider;Jeff x-mozilla-html:FALSE org:SIDC Software Development Inc. adr:;;;Hamilton;Ontario;;Canada version:2.1 email;internet:[EMAIL PROTECTED] title:Senior Consultant x-mozilla-cpt:;0 fn:Jeff Sider end:vcard
Re: Java access to syslog?
Greg Cook wrote: > > Is there a class (or other simple way) to have a running program open and use the >Unix/Linux syslog utility? > > Greg Cook check this out http://www.ice.com/java/syslog/index.shtml -- __ Jeff Sider Senior Consultant SIDC Software Development Inc. Hamilton, Ont. Canada www.sidc-software.com [EMAIL PROTECTED]
Feedback requested: java-linux mail archives
Hi all, I am the person who is running the java-linux mail archives, at http://www.mail-archive.com/java-linux@java.blackdown.org They've been chugging along for a while and will continue to do so. I'd like to get some feedback. How well have the archives been working for the java-linux community, and what improvements you would like to see? The mail archives are a small portion of the general java-linux infrastructure, but I'm trying to polish them as much as humanly possible. If you'd prefer not to post to the java-linux list about this topic, sending direct feedback to [EMAIL PROTECTED] is highly appreciated. Thank you, Jeff PS Some of the things I'm curious about: * Are the archives fast enough? * If not, where are you, and how slow is it for you? * Are they organized well? * Can the layout be improved? * What is the best/worst aspect of the archives? * Does everything work correctly for you/your browser? * What else?
Sun ports JDK 1.2 to Linux in push for ubiquitous Java (InfoWorld)
http://www.infoworld.com/cgi-bin/displayStory.pl?98112.ecsunjava2.htm have you all seen this??
RE: Apache and JServ Module
http://www.servletcentral.com/1999-01/jserv.dchtml this may help you out. -Original Message- From: Marc Dumontier [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 13, 1999 4:52 PM To: [EMAIL PROTECTED] Subject: Apache and JServ Module Has anyone gotten the apache jserv module to work with jdk1.1.7??? My log file keeps saying that the JVM exits right away (at initialization of module) If anyone has any info , please email me ASAP. thanks
Re: About Communication Ports API...
Julian Bolivar wrote: > > Dear Srs. > > Can I use the Sun's Communication API in the Linux JDK 1.1.7v1a, > because I need access the PC's Serial and Parallel Ports. > > Regards. > > Julian Bolivar Unless there is Win32-dependent native code in the Communications API (I haven't played with it myself), you should be able to use it with no trouble at all. If there is any native code, and if it doesn't include the sources, someone should arrange with Sun to port the native portions of the package. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization.
Re: Help me compile for Native Methods?
Make sure that: #1: you're calling System.loadLibrary(someLib) [ I'm assuming you are ] #2: when you compile your native library, you are exporting the symbols you need to call from your Java program [ this was a real pain in the butt on a Mac ] Peter Gutowski wrote: > > I've used Cay Horstmann's and Gary Cornell "Core Java" books and have been > pretty happy with them. The second volume claims to help you create native > methods that can be called from java code. Their examples use Solaris and > WindozNT only though.. > > The instructions for using javah -jni to create a .h file are clear. > Everything seems quite smooth until I try to run the java program that > calls the C code. Here's what I get: > > $ java HelloNative > @@Native.so: ELF file's phentsize not the expected size > (libHelloNative.so) > java.lang.UnsatisfiedLinkError: greeting > at HelloNative.main(HelloNative.java:10) > $ > > I'm guess I'm not sure what compile options I need to be using to make > java happy. My Make file (currently) looks something like this: > > libHelloNative.so: HelloNative.c HelloNative.h > gcc -c -o libHelloNative.so \ > -static \ > -I/usr/java/include \ > -I/usr/java/include/genunix \ > HelloNative.c > > The java program calling the C function is quite simple: > > public class HelloNative { > public native static void greeting(); > > static { > System.loadLibrary ( "HelloNative" ); > } > > public static void main ( String args[] ) { > HelloNative hn = new HelloNative(); > hn.greeting(); > } > > } > > The C program is equally simple: > #include "HelloNative.h" > #include > > JNIEXPORT void JNICALL Java_HelloNative_greeting > ( JNIEnv *env, jclass cl) { > printf ( "Hello Native World" ); > } > > All of this is *similar* to the example in the book but I am not sure what > I need to do to make it work. Any ideas? > > Peter Gutowski > email: [EMAIL PROTECTED] > http://www.powervue.com/~peterg -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization.
Re: JavaLinux for servlets
Okay, time for me to step into the fray. Here's how this works: When a webserver (let's say Apache) gets a request from a client to run a traditional CGI, the server spawns a new process *independent* of itself. If the process is a Perl process, then it has the overhead of initialization, reading in the file, parsing, etc. *before* it can do anything useful to the end user. If you have a servlet engine installed (say, Apache JServ), then when the webserver gets a request for a servlet to be run, the server just passes the request to the servlet engine *which is already running*, which then passes the servlet info to the JVM *which is already running* and the JVM spawns a Java thread on top of itself to handle the servlet request. This all happens in very short order. If I recall correctly, an ISP in San Francisco did some tests of Perl CGIs and Java servlets side-by-side, both doing *exactly* the same things, and found that the servlets ran on the order of 10 times faster than Perl, and produced a significantly lower overhead on the server (I think the exact data are on java.sun.com somewhere -that's where I first saw it about a year ago). The reason for the difference? The servlets don't have to start a new JVM process for each request, whereas Perl CGIs have to start a new Perl process for each request. This is not to say that Perl isn't better suited for some tasks when you restrict yourself *only* to the "core" Perl distribution. Pattern-matching and other such niceties are truly wonderful builtins. But if someone wants to use Java on their server, unless there is a very compelling reason not to, I don't see any reason to try to convince them otherwise. By the way, java.sun.com is served from Java WebServer, and uses servlets for almost everything, as does sun.com. So, before you dismiss Java as a "toy", take a look at those two sites. You might be surprised to see how much functionality is there, and how fast they serve. John Goerzen wrote: > > On Wed, Feb 17, 1999 at 01:17:43AM -0800, Steve Byrne wrote: > > > > But what techincal advantage do they really give? Java is slower, uses more > > > system resources, etc. > > > > John, if you don't like Java, can you please tell us why you feel it's > > necessary to clog this mailing list with your anti-Java sentiments? I don't > > think it's being constructive. > > I am really getting annoyed with people picking out bits and pieces of what > I wrote. You, and others, are taking it out of context. > > I have explained the areas in which I feel Java has an advantage over other > languages -- for example, development of large-scale client GUIs. I have > also explained the areas in which I feel Java has some catching up to do, > for example, tasks involving parsing. > > If you feel that any particular language, including Java, is the best choice > for every possible task, then you need to take a larger view of reality. > The fact is that Java is not the best in all areas. Likewise, Perl is not > the best in all areas. Neither is C. For that matter, neither is Linux or > Windows. > > You use the tool that's right for the job. I use Java for some things, Perl > for some things, C for some, C++, shell scripting, etc. All of them have > their unique advantages and disadvantages. > > You would probably think me crazy to use shell scripting for a GUI. While > technically possible, it would be horrendous code. Likewise, I would > probably think that using Java for an application that does a lot of > complicated parsing of input, computation, and then generation of output > would not be wise; Perl is better suited to that task. Similarly, if I were > writing a webserver or other server that could see high levels of load, C is > really the only good choice. Perl and Java may require less code, but the > performance would not be the same simply because of the abstraction in order > to make it system-independant -- although Perl is closer to Unix than Java. > The interpretation cost and memory overhead hurts, too. > > Constructive criticism is a well-known useful device. If I point out to the > Perl people that the lack of strong typing can make large projects > difficult, and thus make Java a better tool for the job, perhaps the Perl > people will consider adding typing to the language (and indeed, they are > doing so). Likewise, if I point out to Java people that Java's parsing > capabilities are weak compared to Perl, perhaps they will add something to > help with that. In the end, everone wins, because all the languages > improve. > > I fail to see what's wrong with talking about Java's unique benefits and > problems in a Java list. > > John -- Jeff Galyan http:/
Re: JavaLinux for servlets
Pardon me, but you appear to be the ONLY person actually using mod_perl or FastCGI in a production environment. As for my assumptions being "flawed", that would mean that the developers at Java Software (formerly JavaSoft) don't know what they're talking about either, nor do the course developers at Sun Educational Services, nor do anyone else I work with at Sun. Perhaps the reason people are ignoring your argument against using Java is because your argument is, plain and simple, wrong. Now I hope this puts an end to this stupid thread. John Goerzen wrote: > > OK, this is about the 6th or 7th time I've said this and STILL people are > ignoring it. > > Your whole argument is based on a flawed premise: that with CGI, a new > process must be started for each request. This is plain and simply NOT > correct. I have pointed this out time and time again. > > Any benchmarks comparing Java to this sort of thing are misleading at best, > and more likely downright incorrect. > > If people want to discuss the performance of mod_perl or FastCGI vs. > servelts, please do so. But please cease this misleading practice of > comparing current Java to outdated Perl. > > In <[EMAIL PROTECTED]>, I wrote: > > I keep saying this and apparently nobody is listening. > > Let me give you URLs then: > > http://www.apache.org/related_projects.html#modperl > > "With mod_perl it is possible to write Apache modules entirely in Perl. >In addition, the PERSISTENT interpreter embedded in the server avoids >the overhead of starting an external interpreter and the penalty of >Perl start-up time." (emphasis mine) > > http://fastcgi.idle.com/fcgi-devkit-2.1/doc/fastcgi-whitepaper/fastcgi.htm > > "FastCGI processes are persistent: after finishing a request, they wait >for a new request instead of exiting." > > "FastCGI . . . multiplexes the environment information . . . [allowing] >FastCGI programs to run on remote machines" > > On Wed, Feb 17, 1999 at 11:10:12AM -0700, Jeff Galyan wrote: > > > When a webserver (let's say Apache) gets a request from a client to run > > a traditional CGI, the server spawns a new process *independent* of > > itself. If the process is a Perl process, then it has the overhead of > > initialization, reading in the file, parsing, etc. *before* it can do > > anything useful to the end user. > > Not if using mod_perl or FastCGI, as I have kept saying. As the rest of > your post relies on this flawed assumption, there isn't much else to say. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization.
egcs-1.1a libstdc++ and jdk1.2
Hi. Sorry if this is a repeat - I don't watch the list. The JDK1.2 prerelease seem to run fine on a Redhat 5.2 with all updates installed if you do ln -s /usr/lib/libstdc++.so.2.8.0 /usr/lib/libstdc++-libc6.0-1.so.2 Redhat doesn't have the latter. Since I had installed egcs1.1a, I noticed that linking to the 2.9.0 version that comes with that package does not work: ... undefined symbol: __frame_state_for The 2.9.0 library also seems to be stripped. I had pulled the egcs1.1a (I think) off of the Redhat contrib site, but I can't be sure of it. In any case, the above link should work. Hope this helps someone. Thanks to the porting team. JwL. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: JDK1.2 fails to start
I had the same problem - use 'java -green -Djava.compiler= ' (green threads VM, no JIT) until this is resolved. It works quite well on my system (linux 2.2.1, glibc 2.1). The reason is that there is a problem with native threads together with glibc 2.1. "David A. Guthrie" wrote: > > You don't need to put the jdk source jars in your classpath in 1.2. > inkle c wrote: > > > I am having linux2.2.3, egcs1.1.1 on my x86 together with JDK1.2-pre1, > > any java command I execute, there is always same error: > > > > === > > > > *** panic: GC: getStickySystemClass failed: java/lang/ref/Reference > > CLASSPATH may be incorrect > > SIGABRT 6* abort (generated by abort(3) routine) > > stackpointer=0xbfffebf0 > > > > Full thread dump Classic VM (Linux_JDK_1.2_pre-release-v1, native > > threads): > > "main" (TID:0x410e21e0, sys_thread_t:0x81436d8, state:R, native > > ID:0x400) prio=5: pending=java.lang.OutOfMemoryError > > Monitor Cache Dump: > > Registered Monitor Dump: > > utf8 hash table: > > JNI pinning lock: > > JNI global reference lock: > > BinClass lock: > > Class linking lock: > > System class loader lock: > > Code rewrite lock: > > Heap lock: > > Monitor cache lock: owner "main" (0x81436d8) 1 entry > > Thread queue lock: owner "main" (0x81436d8) 1 entry > > Dynamic loading lock: > > Monitor registry: owner "main" (0x81436d8) 1 entry > > > > == > > > > I believe I have set up my CLASSPATH well, well, it looks like this: > > > > >/usr/local/jdk/lib/dt.jar:/usr/local/jdk/src.jar:/usr/local/jdk/lib/tools.jar:/usr/local/jdk/jre/lib/rt.jar:/usr/local/jdk/jre/lib/i18n.jar > > > > I only download JDK1.2, no JRE as I think it is not necessary. > > > > Anyone knows what is the problem? > > _ > > DO YOU YAHOO!? > > Get your free @yahoo.com address at http://mail.yahoo.com > > > > -- > > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] > > -- > > Grace and peace to you from God our Father > and the Lord Jesus Christ, > > David Guthrie > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: JDK1.2 release
"James D. Carr" wrote: > I already have all > the class and source files (like I assume a lot of people do). My Do you mean you have the Java 2 class and source files? Classes from earlier versions probably won't work quite the same, since some packages were renamed (com.sun.java.swing to javax.swing, for example)... -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Understanding 1.2 classpath
> > Steve> With jdk 1.2 installed in /usr/local/java/jdk1.2 what would > Steve> be the equivalent classpath to use in 1.2 for compilation? > Steve> For execution? > > You need no classpath. Don't even set it to "". > I've found in my use of Java 2 (both at Sun and on my machine at home), that if you have declared packages, and you have a directory structure set up in your source directories, you still have to use the -classpath command-line flag to javac. *However* you ONLY need to have the path to the directory one level up from the beginning of *your* package name. For example, if you have named your package "com.anamorphic.MySpiffyClasses" and your build directory sits in /usr/src/mysources/com/anamorphic/MySpiffyClasses, then your command line would look like: javac -classpath /usr/src/mysources SpiffyClass.java For running, you just jar up all your classes and put that jar file in /jre/lib/ext and everything works. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Java Machine Code
You should look at writing it as a servlet and using Apache JServ (details at www.apache.org), instead of trying to find a Java bytecode-to-native-code compiler. So far as I know, there isn't one that's complete enough yet to be useable. --Jeff Chengyan Che wrote: > > Hi Friends, > > I am kind of newbie to both java and linux. Using JDK1.1.1, I've made a > small java application which is intended to be used as a CGI script running > on Linux(RedHat), Apache as http server. But how can I compile it into a > native Linux machine code executable, instead of a .class file? I don't find > any options for "javac" to achieve this. Where can I find such a compiler? > > Thanks in advance for any input. > > Chengyan > -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Swing?
You can get Swing from java.sun.com. It is 100% Java (no native code), so there is no need for the Java-Linux team (or anyone else) to port it. Peter vdW wrote: > > There is a link to your page from FreeBuilder suggesting that we can > download the following from your site (or at least find a link to it > there): > > Swing 1.0.x (preferably 1.0.3) > > But I was unable to find a mention of it at all... > Maybe you could add the topic to FAQ? > Indeed I do not have it installed and I need it. > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: OT. java list
Anil kumar wrote: > this is off topic. could you pl. suggest a java mail list where i can > discuss language-specific issues. Have you checked out the Java Developer Connection at developer.javasoft.com? Registration and membership are free, and you will get an email newsletter every month with tech tips and so forth. There is also a threaded discussion area on the site where you can post (and answer) language-specific questions. Also, there are a number of Java-related Usenet newsgroups you may want to have a look at. My experiences with the newsgroups and the Jave Developer Connection have been good. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: IDE for Java
Have you looked at NetBeans Developer? It's 100% Java, runs fairly well (in terms of speed) in my experience, and you can download it free for non-commercial development. It's at www.netbeans.com -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: KDE PLAF
[EMAIL PROTECTED] wrote: > > On Wed, 24 Mar 1999 09:56:59 +0100 > Peter Kovacs <[EMAIL PROTECTED]> wrote > > > What is PLAF? > > PLAF stands for Pluggable Look-and-Feel. It is a feature of Swing > that allows the look and feel of Java GUI interface to be set > independent of the other GUI code and on the fly if set up correctly. > The native Swing PLAF is Metal, but one can also set it to Windows or > Motif. I have heard this is even a Mac PLAF available somewhere. > The Mac look & feel is only available in the Mac download of Swing, and will only run on MacOS (just as the Windows look & feel only runs on a Win32 machine), as the legal issues involved in making those look & feel sets available on other platforms are unclear. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: jni problem
Wes Biggs wrote: > > optima wrote: > > > cc -G NativeHello.c NativeHelloImp.c -o libHello.so > > ,I encount a problum > > "cc: unrecognized option `-G' > > /usr/lib/crt1.o(.text+0x36): undefined reference to `main'" The problem is that there is no "-G" option to gcc. If you want to build with debugging symbols, use the "-g" flag. Also add -shared and -rdynamic to the command line to build a proper shared library. /usr/lib/crt1.o is part of gcc. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: go back to gzip!
Umm... bzip2 is open source and freely available to anyone (I compiled the binaries I use myself). David Wall wrote: > > It was a bit rude as written, and that's part of the problem with email in > general. Sometimes terse statements sound worse than the intended message > was to be delivered. > > While I am really happy with the work that this free software team has been > doing, and I appreciate and make good use of their labor, the original post > did have a good point: why introduce a new zip scheme that would not be > available to most people? gzip is open source and widely deployed. Was > there a particularly strong reason for using bzip2 over gzip? > > David > > > It always amazes me when people using free software are rude to the > > folks who are doing the work. Your message was impolite, and you were > > too lazy to go find bzip2, thereby wasting everyone else's time. > > > > You can get bzip2 at > > http://ma.us.mirrors.freshmeat.net/appindex/1998/04/15/892661723.html > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: go back to gzip!
My RedHat 5.2 CD included bzip2... Tucker Balch wrote: > > Don't get me wrong, I'm glad to have java-linux even if I have to > download and install bzip2 to use it. Still I think it's better > to stick with more commonly available installation tools (and libraries > and kernels for that matter). > > Is java-linux for kernel developers (100s of people) or the linux masses (millions)? > I suppose Debian includes it, but RedHat 5.2 does not include bzip2, nor bzip2 > capable tar. > > --Tucker > > Levente Farkas wrote: > > > > Tucker Balch wrote: > > > > > > Nobody has bzip2, whatever that is. You're making your product less portable. > > > If you do insist on keeping bzip2, you'll need to change your installation > > > instructions because they reference gzip'd files. > > > > Nobody has gzip, whatever that is. You're making your product less portable. > > If you do insist on keeping gzip, you'll need to change your installation > > instructions because they reference compress'd files. > > :-) > > > > it's high time to switch, and as size are growing the size difference > > growing. anyway "nobody" do not include some irrelevant people like > > kernel developers:-) > > > > -- Levente > > > > -- > > E-Mail: Levente Farkas <[EMAIL PROTECTED]> > > Homepage: http://www.inf.u-szeged.hu/~lfarkas/ > > PGP public key & Geek Code: [EMAIL PROTECTED] > > -- > > -- > Tucker Balch > Computer Science Department > Carnegie Mellon University > http://www.cs.cmu.edu/~trb > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: This works on Linux/ W95 not on NT. Why?
Maybe because NT is notorious for being very unfriendly to Java? Seriously, though... I suspect there may be issues with Runtime.exec() on NT due to permissions problems when you're logged in as a normal user - try it as Administrator and see if it works then. -Jeff [EMAIL PROTECTED] wrote: > > I have some attached files. Basically Java program that > launches another Java AWT program. > > % java Launcher > > It works on Linux / Windows95 not on NT 4.0. Why? > > Peter > > >Name: launch~1.jav >launch~1.javType: unspecified type (application/octet-stream) >Encoding: base64 > > Name: hello~1.jav >hello~1.javType: unspecified type (application/octet-stream) > Encoding: base64 -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Non mofit AWT.
That's a question you should pose to Sun. Matthew Panetta wrote: > > Given that there are a few good windowing toolkit out now for linux (GTK, > QT, JX) could the JDK be proted to these instead of useing mofit? > > Regards Matt > -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: go back to gzip!
If you "only have access to a Win95 machine", why aren't you just getting the Win32 version of Java from Sun? Win95 and Linux are so completely *not* similar in any way... Volker Augustin wrote: > > Ok, there has been a long discussion about using bzip2 or not. Apart from personal >problems using > bzip2 (I have only access to a Win95 machine and bzip2 --help does display help, but >since it's > going to stderr you cannot read all of it and since I could not find documentation I >have no clue > how to use bzip2) I would recommend that you provide both a bzip2 and a gzip-version >of the > distribution. Isn't that a fabulous idea? Why didn't anyone else come up with it? >It's the obvious > thing to do, isn't it? It solves all problems - well maybe not all, since e.g. I've >been trying to > work effektively on Win95 for a long time now without result... :-) > Volker > -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: javac can not find com.sun.java.swing.JApplet class
com.sun.java.swing.* have been renamed to javax.swing.*. Update your import declarations and you should be fine. > Richard James wrote: > > I am new to java and the 1.2 JDK. I am running RedHat 5.2 and the > Blackdown JDK1.2-v1pre-release. The install went fine. I have finally > figured out the libstdc++ link and I can successfully compile command > line applications. > > However, I am getting the following error on this simple applet. Any > ideas on how to resolve this. > > [root@localhost java]# cat RootApplet.java > import java.awt.*; > > public class RootApplet extends com.sun.java.swing.JApplet { > int number; > > public void init() { > number = 225; > } > > public void paint(Graphics screen) { > super.paint (screen); > Graphics2D screen2D = (Graphics2D) screen; > screen2D.drawString("The square root of " + > number + > " is " + > Math.sqrt(number), 5, 50); > } > } > [root@localhost java]# javac RootApplet.java > RootApplet.java:3: Superclass com.sun.java.swing.JApplet of class > RootApplet not found. > public class RootApplet extends com.sun.java.swing.JApplet { > ^ > 1 error > [root@localhost java]# > > Thanks > Richard James > > -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Windows PLAF hack?
The reason the Windows L&F doesn't run on other platforms is because it is not known whether Sun can legally distribute that L&F on non-Windows platforms. The MacOS L&F doesn't work on non-Macintosh platforms for the same reason. Matthew McKeon wrote: > > I don't suppose anyone knows of / can recommend a hack > to get around the windows PLAF block in v1.2 of the Linux JDK? > Is such a thing possible? Is the block integral to the VM > or is it located somewhere in the runtime libs? > I'm just looking to hack it to the point where > I can get it up and running on my dev box, > since my target client platform is Windows anyway. > > Or is doing so illegal? :) > -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: javac-BUG ???
"Dipl.-Ing. Dr. Mustafa Radi" wrote: > since Sun does not see, that Linux is becoming a competitive > alternative to Microsoft's Windows > You clearly have not been paying attention to the news, have you? -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Non mofit AWT.
AWT on top of Swing sounds pretty interesting... Netscape's IFC basically do everything on top of a Panel (faster than Swing for many uses), so that's another alternative. --Jeff Michael Emmel wrote: > > Ulli Kortenkamp wrote: > > > >>>>> "Jeff" == Jeff Galyan <[EMAIL PROTECTED]> writes: > > > > Jeff> That's a question you should pose to Sun. Matthew Panetta > > Jeff> wrote: > > >> Given that there are a few good windowing toolkit out now for > > >> linux (GTK, QT, JX) could the JDK be proted to these instead of > > >> useing mofit? > > > > I did this, since I asked for a non-motif-based AWT some month > > ago. The answer by Sun was: It exists. It is called Swing. > > And I have rewritten the AWT to run on top of Swing so I don't use Motif. > -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Non mofit AWT.
It's interesting to me that so many people have found Swing slow, while my experience has been opposite (I wonder if I have something set up differently on my system or something...). I do see how it can be slower than AWT, since it doesn't use any native peers. Swing's slow performance can be attributed to the fact that Swing does its own drawing, unlike AWT which calls Motif routines to create the widgets. I do agree, though, that there should be a choice of AWT peering implementations for Unix and Unix-like systems, since there are so many widget sets available. --Jeff Jonathan Mark Brooks wrote: > > I suspect that they didn't get the point. What people are asking for is > that the graphical elements of java be implemented with GTK+ rather than > Motif or some other platform specific GUI kit (GTK exists for win32 now as > well...). Even Swing must at some level call on GUI elements that are > coded not with Java but with a lower-level graphics library. > > Besides, Swing is still, well, SLOW. Especially on Linux. I have a > Cel400 w/128meg, so it shouldn't be, but it is. > -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: This works on Linux/ W95 not on NT. Why?
Jim Frost wrote: > > > Maybe because NT is notorious for being very unfriendly to Java? > > Huh? NT is one of the best Java platforms around. It's relatively stable, has > great JVM availability, has very stable JVMs, has a slew of IDEs and other > tools, has several very fast compilers > > We do almost all development on NT for these reasons even though we typically > deploy on Solaris (for scalability and core OS reliability). > Pardon me, but... WRONG! It's been proven in court that Microsoft's JVM is utterly *non-compliant*, NT crashes way too frequently to be considered *alpha* quality software, Microsoft's IDE produces binaries that simply will not run on any platform except Win32 (again, proven in court)... "NT is one of the best Java platforms around" ? What have you been smoking? -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Java Certification
Ozer - Full details on Sun Certification programs can be found at http;//suned.sun.com. Also, I recommend reading the Java Certification Study Guide by Simon Roberts (he wrote the certification exam for Sun). That book has a complete sample exam which will give you a feel for what to expect from the real thing. Most importantly: study, study, study. The pass rate for the exam is very low, with most people having to take the exam two or more times before passing. I passed on my second go at it (and I had seen all the real questions and answers beforehand in technical reviews of the exam), so I can attest to the difficulty of the exam. Good luck! --Jeff Ozer Irfan wrote: > > Hello, > I'm from Belgium. > > I'll be passed the java certification. > > Have any questions examples ? > Know you what I must do ? > > Thanks. > > Irfan > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Too manyopen files in system
Jaco de Groot wrote: > > Hi, > > I'm using jdk1.2 pre-v1 on RedHat 5.2 for my servlets using > Apache JServ. Every once in a while I get the following error: > > Too many open files in system Make sure you're closing the files when you're done with them. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Too manyopen files in system
Jaco de Groot wrote: > > > > > > Too many open files in system > > > > Make sure you're closing the files when you're done with them. > > I've checked my code for this. But even without closing them > myself, shouldn't they be closed at garbage collecting time? > > What tool under Linux do I use to check how many files are > currently open in my system? As long as the File objects (or whatever Stream you're using on them) is open, it is *absolutely guaranteed* not to be garbage collected. As far as the VM knows, you're still using the reference, so it won't free the memory being used by it. If you're opening a file to read from, then be sure to close it when the read is completed (and if you want it to be GCed, assign the reference to "null"). If you're opening a file to write to it, close it when you're done writing. On a read, you can use a while loop to check for end of file: //open a file - we'll call it "f" // get a stream on it - let's call it "s" while (s.read != -1) { // -1 signals EOF // do something useful } f.close(); Of course, you have to catch the possible IOException, so wrap that in a try-catch block. On a write, you can call flush() on the stream, then close the stream. I don't know what tools there may be for finding out how many files are open at a given time on Linux. I hope this helps. :) -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Getting a frames X window handle
Michael Hope wrote: > > I meant getting the window handle directly from the innards of Java. The > current program has some code ripped directly from xprop which searches by > name, but it takes a good 3-4 sec on a remote X server. Could part of the time issue be due to network latency? -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: read from syslog file ...
Daniel Ignat wrote: > > i'm new in java .. and i need some topic for create a little programm > i need to formating a file for insert in a database: (/var/log/message) > You could just open the file using java.io.File, read it in, then write the new file in some directory this program would have write permission to (dependent on the user it runs as). If you need to enclose the messages in quotes (as in your example), you probably want to use a StreamTokenizer to get each line as a String (there's probably a much better way to do this, but I'm very busy and frazzled with Sun's Developer certification exam right now). Once you've got each message as a String, you can writeUTF() into the new file and add the quotes at each end. I'm not sure how much processing you need to do on it, though. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Problem
Jon Bohm wrote: > > I experience the same problem, but linking the library doesn't prevent the > last serious error. I have tried with libstdc++.so.1.8.0 and 1.9.. > > Debian 2.1, Linux 2.1 > > /Jon > > P.S> > > grimm@aida:~/Java/src/apps> java ArrayTest > SIGSEGV 11* segmentation violation > stackpointer=0xbfffe328 > > Full thread dump Classic VM (Linux_JDK_1.2_pre-release-v1, native > threads): > "Finalizer" (TID:0x41081320, sys_thread_t:0x81c3368, state:CW, Have you tried 'java -green ArrayTest' ? If not, try it and see if it gives the same errors. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: jdk1.2
Hasan Mahmood wrote: > > Hi. > > I am facing a problem with jdk1.2. It seems that jdk runs just fine > remotely in X, but on the console it crashes with the following messages: > > Exception in thread "main" java.lang.Error: can't load > javax.swing.plaf.metal.MetalLookAndFeel > Sounds like you're trying to run a Swing GUI app without an X server running. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: javax.swing.preview not found
Bernardo Paz Betancourt wrote: > > > Ok, thankyou, I understand, my problem is that I dont have the javax package > How could I find it, I´m using Linux 5.2 whith JDK 1.1.7 and there is > not any "javax" in the crs.zip (?) directory. > Ah - under 1.1.x, Swing is a separate download. Get Swing 1.1.1 from java.sun.com/products/swing (I think that's the right URL). Put the swingall.jar in your $CLASSPATH and you're all set. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: ... java.io.*
Use a StreamTokenizer to break the input stream into tokens, using whitespace as the quote character. Daniel Ignat wrote: > > > now .. how can I read from file > first line is: > > May 4 15:51:04 dexter pppd[304]: local IP address *.*.*.* > > - in my scenario I need to read first line and: > read from second May 4 and format text 'May 4' > read from next 15:51:04 and rezult '15:51:04' > read from next dexter . > read from next pppd[304]: ... > read from end off line and '. rest of line' > > go to next line ... > ... > > Q: for this class I need to use FileReader - for read-in >and FileWriter - for write-in ? > -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Swing never waits?
Michael Durket wrote: > > I started up the SwingSet demo and noticed how slow it was. I ran > top and noticed that even when I was doing nothing (i.e. no mouse > moves, no selections, just sitting there) the demo was eating up > 16 MB of memory and 50-60% of my cpu. It seems as if the virtual > machine never waits (at least when running this demo). > One of the issues with Swing performance has to do with the Swing components not having native peers (unlike AWT). With AWT, the peering mechanism creates a native widget which handles all the drawing of the widget; Swing has to do all of its own drawing and so forth, which is why many people find Swing slow, and also may be related to the memory usage you're seeing in the SwingSet demo. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: javax.swing not found
javier ganzarain wrote: > > * > Well, in my case I am also having a similar problem. I get the message > java.lan.NoClassDefFoundError javax/swing/JApplet > > I am using Linux 6.0 with JDK1.2.1 (I am trying it as well at home with > W95 and WNT). But in any case Swing does not work (Only the > appletviewer). Make sure you do not have any CLASSPATH environment variable set - Java 2 has default search paths for the core classes, and gets confused if you have a CLASSPATH env var set. If you have given a package name to your own code, you only need to add that path with the -classpath flag -everything else happens automatically. You might also want to look in your Java directories to see if you have all the jar files that should have come with your download (dt.jar, tools.jar in jdk1.2/lib are the most important ones; jdk1.2/jre/lib/ext should have iiimp.jar and any third-party jar files you add to it). The dt.jar file should have the javax.swing.* classes in it. > > It seems to be that my Browser is also not yet prepared for Swing. When > i look to the infos under Sun pages, they talk about installing the java > plug-in. Sorry, but I thought that Swing, 2D and the plug-in was > already integrated within JDK1.2.1 > > Can any one please help me? Netscape doesn't use the version of Java you have installed on your local system to run applets - it uses its own internal version. You can get Swing applets working in Netscape by copying swingall.jar from the standalone Swing 1.1.X release to Netscape's "java/classes" directory (or whatever they're calling it these days). -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Servlets and Such
"Robert H. Thompson" wrote: > > Anybody out there can suggest a good servlet tutorial. I've just > downloaded Sun's Java Web Server and I am writting some servlets > using Blackdown's java1.2 port. I know this is a little off topic > but I'd appreciate any references I can get. > The book "Core Java WebServer" has just over half of its pages dedicated to the Servlet API. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Delivering Java Apps
Stephen Martin wrote: > > Ok, so i've got my application written and packaged into a jar file > and it's ready to ship. What is the best way to use it in the target > system? Just running java my.class sparks up a 77 Meg 1.2 jvm on > my system which seems pretty heavy weight for a simple application. > I'm aware of the -Xms and -Xmx options but have no idea what are good > values for these. I'm also aware of other jvm's such as kaffe but > have no idea what the difference is between regular java and personal > java. > > So my question is this, given a fairly simple java app (ie no native > methods, no rmi, no jdbc...). What is the best way for an end user > to run it without having it hog all the resources on their system. > On UNIX systems, you can use a shell script to set environment variables, call the JVM, and pass command-line flags to it. You can also use JNI to create a small native executable that instantiates the JVM with arguments. See http://java.sun.com/docs/books/tutorial/native1.1/index.html and follow that trail for instructions on how to do it. In regards to setting minimum and maximum stack sizes, a "good value" is really dependent on your application. If you're doing alot of file IO or very intense computations, you might want to set those numbers fairly high. The only way to really determine how much memory to explicitly allocate to your application's VM is to experiment with different settings. It seems to me that most folks usually use around 64 MB as the max size. Your mileage may vary. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Delivering Java Apps
Godmar Back wrote: > > I just like to address your reference to Kaffe being a personal java > environment. > After lurking a while on this list, I'm starting to realize that Kaffe's > labeling as "PersonalJava" is an unfortunate one. > > PersonalJava (http://www.javasoft.com/products/personaljava/) > http://www.javasoft.com/products/personaljava/spec-1-1-1/pjae-spec.html > is a Sun product and specification for a subset of Java. This subset > is roughly equivalent to Java 1.1.x, although some packages' API has PersonalJava is Java for personal devices (palmtops, internet phones, etc.), and is a superset (if I remember correctly) of EmbeddedJava (Java for embedded systems). -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Problems appending to a file
"Frank B. Brokken" wrote: > > Dear listmembers, > > I have a problem using FileOutputStreams. I want to be able to append to > an existing file, and I would like to be able to read the information back > later. > If you want to write the Strings as text appended to the file, you're better off using a RandomAccessFile and calling writeUTF(String). try { RandomAccessFile raf = new RandomAccessFile("myfile", "rw"); raf.seek(raf.length()); raf.writeUTF("hello\n"); raf.writeUTF("world\n"); // omit '\n' if you want the words // on one line raf.close(); } catch (IOException ioe) { // do something with it } Reading in a String is done with readUTF(). If you need this to go into a binary format file, writeUTF() and readUTF() are useful as well. The writeObject() methods don't work well for appending files, as they are object serialization methods and expect a single object to be read/written per file. Appending objects onto one another is likely causing the class verifier to think the objects are corrupted. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: javax.swing.preview not found
Robert Williams wrote: > > > import javax.swing.preview.*; > > returns a "not found in import" message. > Is this something new that hasn't found it's way > into the blackdown release? > The package com.sun.java.swing.preview no longer exists. The archive on java.sun.com still has old code in it, as evidenced by the "com.sun" package names for the Swing packages. Just remove both imports of the preview package and you should have no problems with imports. Comb that source file for methods that don't exist anymore, too - it's a pretty old example. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: 1.2 Certification info
For information on the Sun Java Certification courses and exams, see suned.sun.com. --Jeff Ozer Irfan wrote: > > Hello, > I search information about Java 1.2 certification exam. > > Have you exam simulation applet ? > Or documentation ? > > Please send me. > > Thanks. > > Irfan > -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Problem running Java3D
Maybe the porting team can experiment with linking against libGL.so (when you follow the Mesa installation instructions, or if you install from an RPM, you'll have libGL.so symlinked to libMesaGL.so.x). Hopefully there won't be any problems with the loader barfing on the symlink. PS: Most Linux users will have Mesa rather than a "real" OpenGL implementation, since Mesa is free, and most OpenGL implementations cost around $1,000 (even on Linux). Mesa also supports Voodoo graphics-based hardware acceleration, which OpenGL does not, it plays well with XFree86, etc. BUT... it's supposed to be source-compatible with OpenGL. --Jeff Francisco Figueirido wrote: > > I downloaded the Java3D port but was unable to get it running. One of the > shared libraries needs libMesaGL.so.3.? (forgot the number), but I have > the Xi Graphics OpenGL port instead. After making the appropriate symbolic > links (libMesaGL.so.3.? -> libGL.so) I get an `undefined symbol' error for > glTexImage3DEXT. Am I right in thinking that this is an OpenGL 1.2 function? > The Xi OpenGL is a port of version 1.1, and doesn't contain this function > (it contains glTexImage1D and glTexImage2D). If this is so, is OpenGL 1.2 > really needed for Java3D? If not needed, would it be possible to provide a > version linked against an OpenGL 1.1 port? > > Another question: has anybody had success running jdk1.2-pre.v2 with the TYA > JIT? Just curious ... > > -- > Francisco Figueirido, Ph.D. Phone: (212)317-7680 > Quantitative AnalystFax: (212)317-7601 > Imagine Software, Inc. e-mail: [EMAIL PROTECTED] > 400 Madison Avenue, 21st Floor > New York, NY 10017 > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: FW: Warning: could not send message for past 4 hours
use 'java -classpath $CLASSPATH:. someClass' In Java 2 you don't need to have CLASSPATH set, and the '-classpath' switch appends the parameter to the system classpath (default /lib:/jre/lib/ext). If you jar your application classes, you can add them to the system classpath by dropping the jar into /jre/lib/ext. --Jeff Paul Mclachlan wrote: > > --- "Herbel, Rick" <[EMAIL PROTECTED]> wrote: > > + exec /usr/local/java/bin/i686/green_threads/java -verbose > > -verbosegc > > -cs -verify -classpath ./ HelloWorld.class > > Unable to initialize threads: cannot find class > > java/lang/Thread > > It's this last line that's having the problem. -classpath > overrides your CLASSPATH environment variable [I'm pretty sure, > anyway. I read something about this changing in 1.2, or > something like that? anyone know?], so all the work it did > setting that up is wasted. Personally, I always include > /usr/local/java/lib/classes.zip in my CLASSPATH so it never does > any of this translation for me > > I suspect if you do this you'll be better off. The cannot find > java/lang/Thread just means that the classes.zip isn't in the > path or isn't valid (or you don't have permission to it, or > wierd stuff like that) > -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Problems installing Swing.
In Java releases prior to 1.2 (Java 2), you must list each .zip or .jar file individually in the classpath. So, your CLASSPATH variable should be '/usr/java/lib/classes.zip:/usr/java/lib/swingall.jar:.' . --Jeff Bob Cadenza wrote: > > Not really a blackdown problem, but I just downloaded the Swing for > jdk117v3, and I just can't figure out how to install it correct. I > moved all of the *.jar files to /usr/java/lib next to my class.zip. > And I set the CLASSPATH="/usr/java/lib:./" What am I doing wrong? > Well thanks in advance. > Bri > -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: What's so platform dependent with Java2 source?
Gerald wrote: > > Why has it been so difficult to port Sun's Java2 source to Linux? I > was under the impression that > > a) Sun isolated their platform-dependent parts, > b) all the rest of the code is in portable, standard C, and > c) the source code is fairly well-organized. > > I would also tend to believe that Sun would probably use POSIX and/or > de-facto system calls for system-related tasks such as threads and > I/O. > (Keep in mind that I'm not part of the Blackdown team; I'm just another licensee, so I'm not speaking on their behalf) Part of what makes porting so difficult is that even though the porting team get a (very) little bit of a break in that they can start with the Solaris sources, there are still a lot of files they have to touch to do a port. One of the problems they have to face is adapting code written for 64-bit Solaris/SPARC to run on 32-bit Intel x86-based systems. Solaris and Linux have many differences in their low-level system calls. As much as we all like to believe in "de facto" system calls, there isn't an OS around that I've ever seen that implements *all* of the POSIX specifications (unfortunately). Now, none of the porting tasks are particularly difficult *if* you have a team of engineers dedicated to nothing but porting Java over. The Blackdown team are working on this in their spare time, for no pay, just because they believe in Java and Linux. Half the time, they don't even get any kind of thanks or support from their users. Frankly, I'm extremely impressed that they've come as far as they have already, and with the quality that they've achieved (even for a pre-release). -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: JNI
(answers below each question) > > --Simple question first: "Is it possible to use the JNI with AIX JDK 1.1.6 > and egcs/gcc C/C++ compiler under the AIX OS 4.x ??? " > Assuming IBM didn't mistakenly leave JNI out of their port, then yes. > --Harder question: "If the answer to the first question is 'yes' then HOW > could it be done ? " > Same as for any other platform: write a Java class that uses native methods, compile the class, run 'javah -jni classname' to generate the header, write the native implementation, 'gcc -shared foo.c -o libfoo.so' See The Java Tutorial for more detail: http://java.sun.com/docs/books/tutorial/native1.1/index.html > IBM only describes the use of the JNI with its own IBM C-Set C/C++ > compiler and that isn't very useful for egcs. (They changed the way to use > JNI compared to the way you can use it under Linux/JDK and Sun/JDK in a > lot of points). > ... just as Sun only describes using the SPARC native compilers. In the Java Tutorial JNI lessons, whenever you see '-G', replace it with '-shared' for gcc/egcs. All other compiler options are as you would normally use them ('-g' for debug, '-O' for optimization, etc.). I also recommend reading the 'jdk1.2/include/jni.h' and 'jdk1.2/include//jni_md.h' files (where is your OS). The Java Developers' Almanac has a nice section with an overview of the JNI types and methods, as well - great for reference. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Linux Desktop based on JDK 1.2
Theoretically, if you're doing most of the time-critical stuff in native code and using JNI and the invocation api, then you could have a workable desktop. One idea that springs to mind would be to use the invocation api to create a VM instance when the desktop is initialized, so you don't have the overhead of startup in the middle of running applications. --Jeff Nathan Meyers wrote: > > Michael Holst wrote: > > > > I've given the project some thought and it seems not so far fetched, if > > you look at Novell 5 they sport a Java desktop for administration. > > > > If speed is a factor we may need to get source to the JDK, but that's > > not hard. > > Not to sound too heretical, but if you want to mess with source there's > always Kaffe. Not to mention if speed is a factor :-). > > Nathan > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: An idea for Java / KDE or GNOME integration
There is a group of engineers (including me) working on binding Java to mozilla's XPCOM, which uses ORBit. If you made it to JavaOne, you may have seen an early demo at one of Sun's booths. --Jeff Cees de Groot wrote: > > [EMAIL PROTECTED] wrote: > >Now, once this basic idea is implemented, the CORBA/IDL solution offers > >extreme flexibility. For example, there's no reason that a GNOME server > >couldn't be written that creates the GNOME equiv of KApplication > >(whatever that may be...). It would serve the same IDL, and all the > >Java apps would work with it too. The same could even be done for MS > >Windows. > > > Has anyone actually tried to talk from Java to ORBit/GNOME with the > supplied .idl files in .../gnome/share/idl? Never looked at the > bloody stuff, but I figure that a org.gnome package could be provided > relatively easy on top of this. Maybe even transparent drag-and-drop > integration? > > -- > Cees de Groot http://www.cdegroot.com <[EMAIL PROTECTED]> > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: javamail
JavaMail is 100% Java, so the Solaris version will work fine on Linux. I've been using it in the Grendel project at mozilla.org for quite some time now with no problems. --Jeff R MUTHUSWAMY wrote: > > hi all, > > i have downloaded javamail1.1.2 zipfile and in the README it has > given only the installation of the programs for only solaris and windows > platform and where can i get the same for linux. > > bye, > MUTHU. > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Swing API
Who told you you can't use the Solaris Swing download on Linux? It's 100% Java, and works just fine on Linux. --Jeff Kontorotsui wrote: > > On 14-Jul-99 R MUTHUSWAMY wrote: > > i am using java1.1.7 and i want swing api's for linux. i have > > heard that i can't use the solaris files for swing. And also there is no > > swing available for linux for earlier versions. > > I used Swing for JDK1.1.7 before switching to 1.2, you can find Swing for Linux > from the blackdown page. > -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: JWS - Problems with native compile. HELP?
Make sure the lines below each Makefile target use tabs as the spacing instead of spaces. If you're using an editor which is set up to convert tabs to spaces, change that preference. --Jeff "John N. Alegre" wrote: > > I am trying to compile the native library in JavaWebServer1.1.3 using the > instructions from the blackdown site. I applied the diffs by hand. When I try > to compile make complains about errors in Makefile.lnx. > > [root@zaragoza native]# (cd native; make -f Makefile.lnx install) > bash: native: No such file or directory > Makefile.lnx:45: *** missing separator. Stop. > > Here is Makefile.lnx with line numbers: > > ### > 1 # @(#)Makefile.sol 1.11 97/11/06 > 2 # > 3 # Solaris-specific makefile for building optional native library > support. > 4 # Use this as a starting point for porting to other UNIX platforms. > 5 # > 6 > 7 # Path to top of Java Web Server distribution tree > 8 TOP = .. > 9 > 10 # Name of the library we're making (given to System.loadLibrary) > 11 LIBNAME = server > 12 > 13 # Location of Java Developer's Kit (and runtime) > 14 JAVA_HOME =/usr/local/jdk117 > 15 > 16 # Java runtime flags > 17 JAVAH =$(JAVA_HOME)/bin/javah > 18 CLASSPATH = > $(TOP)/classes:$(TOP)/lib/classes.zip:$(JAVA_HOME)/classes:$(JAVA_HOME)/lib/clas > ses.zip > 19 > 20 # OS and machine type > 21 OS = genunix > 22 ARCH = unknown > 23 OBJ = $(OS)/$(ARCH) > 24 > 25 # Preprocessor, compiler, linker, and related flags > 26 CC = cc > 27 CFLAGS = -shared -fPIC > 28 CPPFLAGS = -I$(OS) -I$(JAVA_HOME)/include > -I$(JAVA_HOME)/include/$(OS) > 29 LDFLAGS = #-G -h $(LIBNAME) > 30 INSTALL = /usr/bin/install > 31 > 32 LIBDIR = $(TOP)/lib/$(OBJ) > 33 > 34 LIBRARY = $(OBJ)/lib$(LIBNAME).so > 35 OBJS = $(OBJ)/server.o \ > 36$(OBJ)/UNIXUser.o \ > 37$(OBJ)/UNIXUserEnumeration.o \ > 38$(OBJ)/com_sun_server_ServerProcess.o \ > 39$(OBJ)/com_sun_server_realm_unix_UNIXUser.o \ > 40$(OBJ)/com_sun_server_realm_unix_UNIXUserEnumeration.o > 41 > 42 default all: $(LIBRARY) > 43 > 44 $(LIBRARY): $(OBJS) > 45$(LINK.c) -o $@ $(OBJS) > 46 > 47 $(OBJ)/server.o: server.c $(OS)/com_sun_server_ServerProcess.h > 48$(COMPILE.c) -o $@ server.c > 49 > 50 $(OBJ)/UNIXUser.o: UNIXUser.c $(OS)/com_sun_server_realm_unix_UNIXUser.h > 51$(COMPILE.c) -o $@ UNIXUser.c > 52 > 53 $(OBJ)/UNIXUserEnumeration.o: UNIXUserEnumeration.c \ > 54$(OS)/com_sun_server_realm_unix_UNIXUserEnumeration.h > 55$(COMPILE.c) -o $@ UNIXUserEnumeration.c > 56 > 57 > 58 $(OBJ)/com_sun_server_ServerProcess.o: > $(OS)/com_sun_server_ServerProcess.c > 59$(COMPILE.c) -o $@ $(OS)/com_sun_server_ServerProcess.c > 60 > 61 $(OS)/com_sun_server_ServerProcess.c: > 62$(JAVAH) -d $(OS) -classpath $(CLASSPATH) -stubs > com.sun.server.ServerP rocess > 63 > 64 $(OS)/com_sun_server_ServerProcess.h: > 65$(JAVAH) -d $(OS) -classpath $(CLASSPATH) > com.sun.server.ServerProcess > 66 > 67 $(OBJ)/com_sun_server_realm_unix_UNIXUser.o: > $(OS)/com_sun_server_realm_unix_U NIXUser.c > 68$(COMPILE.c) -o $@ $(OS)/com_sun_server_realm_unix_UNIXUser.c > 69 $(OS)/com_sun_server_realm_unix_UNIXUser.c: > 70$(JAVAH) -d $(OS) -classpath $(CLASSPATH) \ > 71-stubs com.sun.server.realm.unix.UNIXUser > 72 $(OS)/com_sun_server_realm_unix_UNIXUser.h: > 73$(JAVAH) -d $(OS) -classpath $(CLASSPATH) > com.sun.server.realm.unix.UNI XUser > 74 > 75 $(OBJ)/com_sun_server_realm_unix_UNIXUserEnumeration.o: \ > 76$(OS)/com_sun_server_realm_unix_UNIXUserEnumeration.c > 77$(COMPILE.c) -o $@ > $(OS)/com_sun_server_realm_unix_UNIXUserEnumeration. c > 78 $(OS)/com_sun_server_realm_unix_UNIXUserEnumeration.c: > 79$(JAVAH) -d $(OS) -classpath $(CLASSPATH) \ > 80-stubs com.sun.server.realm.unix.UNIXUserEnumeration > 81 $(OS)/com_sun_server_realm_unix_UNIXUserEnumeration.h: > 82$(JAVAH) -d $(OS) -classpath $(CLASSPATH) \ > 83com.sun.server.re
Re: please help a java-linux newbie with swing
Looks like you don't have X installed. --Jeff Ken Huisman wrote: > > I downloaded swing from sun and I unpacked it in a directory, followed > the instructions and so on. The problem I have is when I go to run > the SwingSet example, I get the following error: > > /usr/local/jdk/lib/i686/native_threads/libawt.so: undefined symbol: XtShellStrings >(libawt.so) -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Newbie question
Try calling update(). --Jeff > "Bern Rewel L. Mutia" wrote: > > Hi, > > I'm new to Java so please bear with me. > > I am resizing the length of the array of String elements in a JList > inside a JScrollPane, but repaint() does not update my UI. > > Help please... > > Burn > > -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Food for thought...
Riyad Kalla wrote: > These are good points.. and I think the reason Sun doesn't support Linux so readily > is simply because it would be shooting its self right in the Solaris-Foot. If it > provides a high performance, solaris quality Java implementation... they may loose > a bit of business. I don't know details of course about this, but that seemed the > most readily availble answer. > > Anyone else have input on this? > > -Riyad > > Mike Christiansen wrote: > I absolutely agree. I am working on a pure Java/CORBA distributed system that could require as many as 10-20 servers. I would like to tell my client they should use Linux but the Java 1.2 speed/quality seems very weak compared to the JIT and Hotspot VMs on Solaris. I have no choice but to recommend they run Solaris, a very expensive alternative to say the least. I think that Linux on an Intel platform provides the most computing "bang for the buck", but I cannot utilize this if my software runs so much slower (easily 10x I would guess) on Linux than on Solaris. I understand my client's company spent $50k on two Ultra-60s, so I am guessing Sun would loose somewhere between $250k and $500k in business if I could find a fast, reliable Java 1.2 VM that ran on Linux. I am very pleased with Blackdown's efforts but would like to hear more status type information from them concerning the progress of their port. Jeff Calog -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Problem with installing JDK on Red Hat 6.0
i have gotten this message and it was the result of having JDK1.1 on my path and it was hitting there first. also, remove any references to 1.1 in CLASSPATH. -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Jeff Sider[EMAIL PROTECTED] Senior Consultant/Developer SIDC Software Development Inc. Hamilton, Ontario, Canada -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= On Wed, 8 Sep 1999, Liguo Song wrote: > Dear Friends, > > I am having problem with installing JDK1.2 for Linux on my Red Hat 6.0. > > I put it in /usr/local/java, here local is a link to /home/usr-local/. I put the >java/bin diretory > before the /usr/bin to avoid messing up with Kaffe. > > The following is the problem: > > Anytime, I want to run java or javac or appletviewer, a error message pops out. I >will attach the > error message at the end of this message. > > What's wrong? What I can do to fix it? I even tried to setupp >CLASSPATH==/usr/local/java, but it > want help! > > Any help comment will be highly apprecicated. Thanks for your time! > > > *** panic: GC: getStickySystemClass failed: java/lang/ref/Reference > CLASSPATH may be incorrect > SIGABRT 6* abort (generated by abort(3) routine) > stackpointer=0xb4b0 > > Full thread dump Classic VM (Linux_JDK_1.2_pre-release-v2, native threads): > "main" (TID:0x404c81e0, sys_thread_t:0x804bf38, state:R, native ID:0x400) prio=5: > pending=java.lang.OutOfMemoryError > Monitor Cache Dump: > Registered Monitor Dump: > utf8 hash table: > JNI pinning lock: > JNI global reference lock: > BinClass lock: > Class linking lock: > System class loader lock: > Code rewrite lock: > Heap lock: > Monitor cache lock: owner "main" (0x804bf38) 1 entry > Thread queue lock: owner "main" (0x804bf38) 1 entry > Dynamic loading lock: > Monitor registry: owner "main" (0x804bf38) 1 entry > > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] > > > -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Niiiccee...
Worked fine for me - I suspect Jacob doesn't have tr in his path. --Jeff Daniel Barclay wrote: > > > From: Jacob Nikom <[EMAIL PROTECTED]> > > > ... > > I am sure it is something great, but I the response I got was: > > tr: no match > > > > Riyad Kalla wrote: > ... > > > echo njdsptpgu tvdlt | tr [b-z] [a-y] > > It should have quotes around the [b-z] and [a-y] parts. > > Daniel > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Swing Problems
Make sure you're using correct package naming in your Swing apps; i.e., javax.swing NOT com.sun.java.swing. --Jeff Robert Mullen wrote: > > Are the swing classes supported in the blackdown port of the 1.2 JDK? I can > write, compile and execute code properly if I don't use swing but anything > that uses swing bombs with and a class not found error. This includes the > demo's that came with the installation. Do I need to set a classpath > specific for swing or do I need to download another package? TIA > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Java implementation question
Whether the Java3D VecMath package uses Pentium III-specific instructions is dependent on the platform's OpenGL or DirectX implementation. Java3D is implemented on top of either of those, depending on your OS platform (UNIX implementations use OpenGL or Mesa, Windows implementations use OpenGL or DirectX). Check the documentation for the low-level graphics library you're using to find the answer to your question. --Jeff "Thomas M. Sasala" wrote: > > Frank Deutschmann wrote: > > > > Hello all, > > > > Presuming that I can't get a hold of the source code, could someone > > perhaps tell me how the Java3D VecMath package is implemented? > > Specifically, I'm wondering if it makes use of the SIMD floating point > > instructions on P-3 processors, and, more generally, how efficient it > > is/what sort of performance to expect. > > > > Java is crossplatform, so, it is highly unlikely that a class package > uses something so intel-specific (if it doesn't use JNI). However, the > JVM *might* be smart enough to do such a thing. > -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: [Q] CLASSPATH, JAR searching, etc
dave madden wrote: > ... > find classes there, but is there any more to it? Why are there so > many .jar files? Why are some in ...java/lib, and others in (and > under) ...java/jre/lib? Is it a Bad Idea to unpack them all into a > master tree, then make a giant .jar containing all the .class files? > Well, if you're using JDK 1.2, you don't need to set a CLASSPATH environment variable. The VM will find the classes automatically in the default locations in that release. If you want to use add-on packages (like JMF for example), you can take advantage of the extension mechanism by putting the jar files in /jre/lib/ext and then it "just works" - as long as the jar files are world-readable (or at least readable by your user account). If you're using an earlier release of Java, you'll need to have all the jar and zip files containing classes in your CLASSPATH. Generally, you should not need to unpack the jar files, nor is it generally a good idea to do so, as they frequently contain fairly complex directory structures that, if altered, will cause the VM to not be able to find the classes it needs. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: required Libraries
Actually, libXm.so is Motif, which is required by AWT, and therefore Java. You'll need to get a Motif distribution (I use RedHat Motif 2.1.10 with no problems). --Jeff Carsten Hoeger wrote: > > On Tue, Sep 28, Rolf wrote: > > > I am running a SuSe Linux 6.1 on my box and have libc 2 installed on my > > system. > > When I try to install JDK 1.1.1 using rpm, I get the message libXm.so.2 > > is needed by jdk1.1-1.1.7v1a-3. Where do I get this library ? > > Try 'rpm --nodeps --force yourrpmname.rpm'... > > -- > mit freundlichen Gruessen, > > Carsten Hoeger - SuSE Professional Services - > > SuSE GmbH, Schanzaeckerstr. 10, 90443 Nuernberg, Germany > Tel: +49-911-7405356 Mo-Fr 09-17.00, Fax: +49-911-3206727 > http://www.suse.de/bsupport/index.html Email: [EMAIL PROTECTED] > > Braune Blaetter schmeissen sich vom Baum und sind tot. > Es ist Herbst. (O. Kalkofe) > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: required Libraries
Java *always* requires Motif and X libraries. Even on Solaris. End of story. --Jeff Carsten Hoeger wrote: > > On Sat, Oct 02, Jeff Galyan wrote: > > > Actually, libXm.so is Motif, which is required by AWT, and therefore > > Java. You'll need to get a Motif distribution (I use RedHat Motif 2.1.10 > > with no problems). > > That's not true! > > There are both, static and dynamic linked versions of the java > vm. The dependency to libXm results from the dynamical linked > version. > > The static linked version of java _does_ _not_ _need_ Motif > Runtime Libraries!!! > > -- > mit freundlichen Gruessen, > > Carsten Hoeger - SuSE Professional Services - > > SuSE GmbH, Schanzaeckerstr. 10, 90443 Nuernberg, Germany > Tel: +49-911-7405356 Mo-Fr 09-17.00, Fax: +49-911-3206727 > http://www.suse.de/bsupport/index.html Email: [EMAIL PROTECTED] > > Braune Blaetter schmeissen sich vom Baum und sind tot. > Es ist Herbst. (O. Kalkofe) -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: required Libraries
Okay, here's how I understand the Blackdown builds of the VM: there is a fully dynamic version and a static version. To switch between them, you set an environment variable (I think). If you want to use the dynamically-linked VM, you have to have both X and Motif shared libraries on your system. As for Swing, if you go far enough up the class hierarchy, you'll find that all Swing components descend from AWT's Component class, which means (unfortunately or fortunately) that Swing really does use native X and Motif at its most base level. The widgets themselves don't have native peers, true, but in order to draw, Swing uses facilities of X and Motif. I don't know the full down'n'dirty details, just that Swing does need X and Motif libraries. Unfortunately, I don't know if there's any way to get around it (besides the statically-linked version of Blackdown's port of the VM). --Jeff Jacob Nikom wrote: > > Hi, > > I am interested in this discussion, but I am trying to convert it into > more > plain English. I always thought that the lightweight components are > peerless. > They don't need X libraries and work "directly" with OS and hardware. > > Swing was claimed as lightweight component based package, so it should > not > need X or Windows. On contrary, AWT was claimed to be heavyweight based > component package, that is why it needs X - is it true? Is it different > on > Solaris, Windows or Linux? > > Also, "libXm appears to be statically linked into libawt.so" - does it > mean > that X modules were compiled and placed into libawt.so library, so in > reality > you call X, but you don't need to link with it? > > Thank you, > > Jacob Nikom > > Nathan Meyers wrote: > > > > Jeff Galyan wrote: > > > > > > Java *always* requires Motif and X libraries. Even on Solaris. End of > > > story. > > > > "Requires" meaning that Blackdown requires an *external* libXm? Not > > necessarily. JDK1.2pre2 certainly doesn't (libXm appears to be > > statically linked into libawt.so), and I believe something similar was > > done for some of the JDK1.1 executables and/or libraries. > > > > Nathan > > > > > > > > Carsten Hoeger wrote: > > > > > > > > On Sat, Oct 02, Jeff Galyan wrote: > > > > > > > > > Actually, libXm.so is Motif, which is required by AWT, and therefore > > > > > Java. You'll need to get a Motif distribution (I use RedHat Motif 2.1.10 > > > > > with no problems). > > > > > > > > That's not true! > > > > > > > > There are both, static and dynamic linked versions of the java > > > > vm. The dependency to libXm results from the dynamical linked > > > > version. > > > > > > > > The static linked version of java _does_ _not_ _need_ Motif > > > > Runtime Libraries!!! > > > > > > > > -- > > > > mit freundlichen Gruessen, > > > > > > > > Carsten Hoeger - SuSE Professional Services - > > > > > > > > SuSE GmbH, Schanzaeckerstr. 10, 90443 Nuernberg, Germany > > > > Tel: +49-911-7405356 Mo-Fr 09-17.00, Fax: +49-911-3206727 > > > > http://www.suse.de/bsupport/index.html Email: [EMAIL PROTECTED] > > > > > > > > Braune Blaetter schmeissen sich vom Baum und sind tot. > > > > Es ist Herbst. (O. Kalkofe) > > > > > > -- > > > Jeff Galyan > > > http://www.anamorphic.com > > > http://www.sun.com > > > jeffrey dot galyan at sun dot com > > > talisman at anamorphic dot com > > > Sun Certified Java(TM) Programmer > > > == > > > Linus Torvalds on Microsoft and software development: > > > "... if it's a hobby for me and a job for you, why are you doing such a > > > shoddy job of it?" > > > > > > The views expressed herein do not necessarily reflect those of my > > > employer. > > > > > > Sun Microsystems, Inc., has no connection to my involvement with the > > > Mozilla Organization. > > > > > > -- > > > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > > > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] > > > > -- > > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Applet transparency?
Hmmm... you may have some difficulty with this. In Eterm, for example, (not Java, I know, but it's a good example of this) the application basically just queries the root window of the display for its background, gets a clip region of the background based on the application's geometry and such, and sets its own background to be that clip region, creating the illusion of transparency. Probably the easiest way to do it from Java would be via JNI, but you can't do that with applets usually. You might be able to get it to work with a signed applet, but I'm not sure how you'd deal with delivering the native library (and then you have the headache of porting the native code to whatever platforms you want to support). Before giving up on it, though, you might want to look at the Toolkit class and see if it has any methods that can get the root window background (I've never checked). --Jeff "Roll, Greg" wrote: > > Hi All, > > Anyone know if there a way to set an applets background color to be > transparent? > > Greg E. Roll > > BT Office Products Intl. > Interface/Conversions Team > phone - (817) 323-1300 ext. 2921 > e-mail - [EMAIL PROTECTED] > > > Name: Tech Tools.gif > Tech Tools.gifType: GIF Image (image/gif) > Encoding: base64 -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Assistance please...
Yes, the Unix/Linux versions of Java are a bit different from the Win32 versions with regard to the directory structure. With regard to the scripts in /bin, they work a bit of magic to figure out some things and set up the execution environment properly (a very nice convenience, really, as it would be quite a pain to have to do it yourself - and you never know what might be affected if you set it all up in your login environment). Another difference between Unix and Win32, but not a bad one, in my opinion. --Jeff James Butler wrote: > > Ahhh! I understand. I think. > > So, although java, javac etc. are not physically in jdk1.2/bin the wrapper > redirects to the appropriate version in the green & native directories. > > I don't see how it does that but so long as it does I don't mind. > > I was basing my knowledge of the jdk on the directory structure of the Win32 > version of Java and expected to see the runtimes in jdk1.2/bin and as I > didn't I hunted round until I did. > > Many thanks, > > James. > -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Assistance please...
James, If you're using 'bash' as your login shell (the thingie that gives you a prompt - in DOS it's 'command.com'), you can set your path like so: export PATH=$PATH:/usr/share/jdk1.2/bin then try running 'java' again. To test that it's working on some level, try running 'java -version' and see if you get output. I've heard reports from a number of folks that permissions aren't getting set properly on the Blackdown JDK at install time. An explanation follows. If you still get messages about 'java not found', then check the permissions on the directories and files in the JDK. Unix/Linux have a nifty little annoyance for new users called 'permissions'. Basically, this allows you to change the access different users have to different stuff. Permissions which can be changed include read, write, and execute (that's right - just because a file is a compiled binary "executable" doesn't mean it can actually be executed unless the permission flags on it say it can). In my install of Java 2, the permissions look like this: [jgalyan@talisman Jeff]$ ls -l /usr/local/jdk1.2 total 4706 -r--r--r-- 1 jgalyan jgalyan 915 Dec 1 1998 COPYRIGHT -r--r--r-- 1 jgalyan jgalyan 8605 Dec 1 1998 LICENSE -rw-r--r-- 1 jgalyan jgalyan 6650 May 12 1999 LICENSE.Java3D -r--r--r-- 1 jgalyan jgalyan 5864 Dec 1 1998 README -rw-r--r-- 1 jgalyan jgalyan 9949 May 12 1999 README.Java3D-jdk -rw-r--r-- 1 jgalyan jgalyan 585 May 12 1999 README.Java3D.linux -rw-r--r-- 1 jgalyan jgalyan 608 Aug 13 02:14 README.PRE-RELEASE -r--r--r-- 1 jgalyan jgalyan 19431 Dec 1 1998 README.html -rw-r--r-- 1 jgalyan jgalyan 11688 Aug 13 02:14 README.linux -rw-r--r-- 1 jgalyan jgalyan 6422 Aug 13 02:14 README.linux.src drwxr-xr-x 3 jgalyan jgalyan 1024 Aug 13 02:12 bin drwxr-xr-x 3 jgalyan jgalyan 1024 May 12 1999 demo drwxr-xr-x 3 jgalyan jgalyan 1024 Aug 13 02:13 include drwxr-xr-x 3 jgalyan jgalyan 1024 Aug 13 02:13 include-old -rw-r--r-- 1 jgalyan jgalyan287226 May 12 1999 java3d-utils-src.jar drwxr-xr-x 4 jgalyan jgalyan 1024 May 12 1999 jre drwxr-xr-x 2 jgalyan jgalyan 1024 Aug 13 02:15 lib -rw-r--r-- 1 jgalyan jgalyan 4427336 Aug 13 02:14 src.jar (ignore the java3d stuff - that's a separate add-on package, not part of what you should have already). I realize this all looks a bit confusing to a new user. Here's an explanation. The first column shows what flags are set: d = directory, r = readable, w = writable, x = executable. The order of the flags is owner (the user whose name appears in the third column), group (the name in the fourth column), others. The important thing to have set up on everything in your Java installation is that all of the files are readable by everyone. Directories are a special case - directories must be readable and executable if you want to even see what's inside them. So, directories permissions should look like drwxr-xr-x (dir, read/write/execute by owner, read/execute by group, read/execute by others). Confused yet? Here's what you want to do: 1. log in as root 2. use the chmod command to change the "mode" (permissions) on the files and directories: 'chmod 755 /usr/share/jdk1.2' OR 'chmod a+rx /usr/share/jdk1.2'. Either way works fine. To speed things up a little, run 'chmod -R a+r /usr/share/jdk1.2' then cd into /usr/share/jdk1.2. Inside that directory, you need to chmod a+rx everything that is a directory - don't worry about regular files, you've already made everything in the whole hierarchy readable by all. If you see anything that has permissions of 'rws' in there when you run 'ls -l', do 'chmod a-s '. Java doesn't need to run as a specific user (this is actually a problem with the current build process that we at Sun are using - it works fine on Solaris, but sets permissions incorrectly on Linux). Keep going through all the directories until all the directories are read/execute by all, and all regular files (i.e., READMEs and such like that) are readable by all. All the jar files should be readable by all. 3. Once that's finished, you should be able to run java fine. I know this sounds like alot of work to go through to get Java working on your Linux system, but at least you only have to do this once. If this is the problem you're experiencing, then hopefully we'll figure out soon where the permissions are getting set incorrectly at and fix it. I've had to go through this process of chmodding everything in sight myself (and I do my own builds of Java, so I'm pretty sure it's somewhere in the actual build process that the problem is occurring). Anyway, I'm betting this will solve your problem. Let me kno
Re: Assistance please...
disregard all this, since the problem seems to have been discovered in the unarchiving of the distribution --Jeff Jeff Galyan wrote: > > James, > > If you're using 'bash' as your login shell (the thingie that gives you a > prompt - in DOS it's 'command.com'), you can set your path like so: > > export PATH=$PATH:/usr/share/jdk1.2/bin > > then try running 'java' again. To test that it's working on some level, > try running 'java -version' and see if you get output. > > I've heard reports from a number of folks that permissions aren't > getting set properly on the Blackdown JDK at install time. An > explanation follows. > > If you still get messages about 'java not found', then check the > permissions on the directories and files in the JDK. Unix/Linux have a > nifty little annoyance for new users called 'permissions'. Basically, > this allows you to change the access different users have to different > stuff. Permissions which can be changed include read, write, and execute > (that's right - just because a file is a compiled binary "executable" > doesn't mean it can actually be executed unless the permission flags on > it say it can). In my install of Java 2, the permissions look like this: > > [jgalyan@talisman Jeff]$ ls -l /usr/local/jdk1.2 > total 4706 > -r--r--r-- 1 jgalyan jgalyan 915 Dec 1 1998 COPYRIGHT > -r--r--r-- 1 jgalyan jgalyan 8605 Dec 1 1998 LICENSE > -rw-r--r-- 1 jgalyan jgalyan 6650 May 12 1999 LICENSE.Java3D > -r--r--r-- 1 jgalyan jgalyan 5864 Dec 1 1998 README > -rw-r--r-- 1 jgalyan jgalyan 9949 May 12 1999 README.Java3D-jdk > -rw-r--r-- 1 jgalyan jgalyan 585 May 12 1999 > README.Java3D.linux > -rw-r--r-- 1 jgalyan jgalyan 608 Aug 13 02:14 > README.PRE-RELEASE > -r--r--r-- 1 jgalyan jgalyan 19431 Dec 1 1998 README.html > -rw-r--r-- 1 jgalyan jgalyan 11688 Aug 13 02:14 README.linux > -rw-r--r-- 1 jgalyan jgalyan 6422 Aug 13 02:14 README.linux.src > drwxr-xr-x 3 jgalyan jgalyan 1024 Aug 13 02:12 bin > drwxr-xr-x 3 jgalyan jgalyan 1024 May 12 1999 demo > drwxr-xr-x 3 jgalyan jgalyan 1024 Aug 13 02:13 include > drwxr-xr-x 3 jgalyan jgalyan 1024 Aug 13 02:13 include-old > -rw-r--r-- 1 jgalyan jgalyan287226 May 12 1999 > java3d-utils-src.jar > drwxr-xr-x 4 jgalyan jgalyan 1024 May 12 1999 jre > drwxr-xr-x 2 jgalyan jgalyan 1024 Aug 13 02:15 lib > -rw-r--r-- 1 jgalyan jgalyan 4427336 Aug 13 02:14 src.jar > > (ignore the java3d stuff - that's a separate add-on package, not part of > what you should have already). > > I realize this all looks a bit confusing to a new user. Here's an > explanation. The first column shows what flags are set: d = directory, r > = readable, w = writable, x = executable. The order of the flags is > owner (the user whose name appears in the third column), group (the name > in the fourth column), others. The important thing to have set up on > everything in your Java installation is that all of the files are > readable by everyone. Directories are a special case - directories must > be readable and executable if you want to even see what's inside them. > So, directories permissions should look like drwxr-xr-x (dir, > read/write/execute by owner, read/execute by group, read/execute by > others). Confused yet? > > Here's what you want to do: > > 1. log in as root > > 2. use the chmod command to change the "mode" (permissions) on the files > and directories: 'chmod 755 /usr/share/jdk1.2' OR 'chmod a+rx > /usr/share/jdk1.2'. Either way works fine. To speed things up a little, > run 'chmod -R a+r /usr/share/jdk1.2' then cd into /usr/share/jdk1.2. > Inside that directory, you need to chmod a+rx everything that is a > directory - don't worry about regular files, you've already made > everything in the whole hierarchy readable by all. If you see anything > that has permissions of 'rws' in there when you run 'ls -l', do 'chmod > a-s '. Java doesn't need to run as a specific user (this is > actually a problem with the current build process that we at Sun are > using - it works fine on Solaris, but sets permissions incorrectly on > Linux). Keep going through all the directories until all the directories > are read/execute by all, and all regular files (i.e., READMEs and such > like that) are readable by all. All the jar files should be readable by > all. > > 3. Once that's finished, you should be able to run java fine. > > I know this
Re: RPMs
RedHat have made available excellent documentation for developers who wish to use the RPM packaging system in the book "Maximum RPM". You should be able to find it at fatbrain.com or your local bookstore. --Jeff > James Butler wrote: > > You may remember my plea for assistance for help with installing the > JDK and all the archiving problems I had. I was wondering if there was > a concerted effort, anywhere, to create RPMs of the latest releases. > > Because my office network and CD writer, in a concerted attempt, do > not wish me to copy any file that ends with .tar or .bz2 I settled for > a jdk1.7 RPM and had no problems with it at all. > > I know it is a bit selfish of me to ask for RPMs, and not more generic > distributions, but if it helps anyone to put java on their machine > then it can only be a good thing. > > If someone knows of any method for generating RPMs I might have a go > myself. > > Thanks. > > James. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
font.properties
I'm looking for a font.properties file that utilizes only basic X fonts that are compatible with xfs or are common to most Unix/Linux systems. I want to be able to run java applications cross platform, via remote X server, and am constantly hitting either font-not-found problems, or runtime java errors that read like: Exception occurred during event dispatching: java.lang.InternalError: Unsupported 16-bit depth I have no problems running java via remote X servers of the same flavor (both Linux, both Solaris, etc), but this doesn't really get me anywhere. If anyone has such a file (or can point me to one in a blackdown distribution) I would be much obliged! --Jeff B. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: font.properties
Hi John, folks, I finally solved the Java-fonts-not-found-via-remote-XServer problem using a combination of xlsfonts and sed to get a tailor-made font.properties for my Xserver setup. I figure the jdk will change again and the font.properties will change again as well, so this will either pretty much always be a problem, or sun will change their font implementation again and introduce different annoyances. I'm thinking of cobbling together an automatic configuration script that will replace the fonts in font.properties with the most similar fonts listed in the output of xlsfonts. Do you think this is worth doing, if anyone else has already done something like this? It might even be worth hacking up java to do this on the fly when it detects that it's being run with a remote display. --Jeff -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: font.properties
"John N. Alegre" wrote: > > Jeff, > > My suggestion is a real short HOWTO posted to the list. I, for one would just > love to see what you did and I feel that once it was all in front of me once I > could digest it and handle the issue in the future. I feel that most people on > the list are of the same mind. > > Please post how you did it and I will tuck it away for the next round of > tweaking. This is what I did. I've been busy and haven't been able to automate it yet, and there are some issues with automation -- like how to pick replacement the font out of the output of xlsfonts (largest common substring? font database? just random?) But here's what I did by hand on my system: Run my java app, noting which fonts it complained about... Run xlsfonts. This tells you which fonts the server *can* display. For each font A not found from java app, pick a font B in the output of xlsfonts. Massage font B so that it looks like the fonts to generalize the metrics, as in font.properties. For instance, I would change -adobe-courier-bold-r-normal--0-0-0-0-m-0-iso8859-1 to -adobe-courier-bold-r-normal--*-%d-*-*-m-*-iso8859-1 You're going to be running sed, so you want to escape the special characters, so now font B becomes: -adobe-courier-bold-r-normal--\*-\%d-\*-\*-m-\*-iso8859-1 Now just enter the following: cat font.properties | sed -e 's///' -e > font.properties.NEW Where another s/// replacement scheme is specified after the second -e, and another, and another... Then just backup the original font.properties file and replace it with the NEW one. --Jeff -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: another possibility wrt the press-release.
I have to agree with Nathan. Until recently ("recently" being defined as within the last two or three months), I never got any response from the Blackdown team to my offers of assistance with porting -- and I'm from Sun. Now, don't get me wrong here -- the Blackdown team are volunteers and don't necessarily have the time to jump everytime someone knocks. They have personal lives, day jobs, families. They have to take time for themselves, just like the rest of us do. I wasn't involved in the Inprise deal, and I don't buy the argument that Inprise wanted "brand recognition" on the JVM for Linux. Why don't I buy that argument? Because Sun owns the trademark and copyright on the Java "brand". No one else can "brand" Java. Does Inprise have their own "brand" of C? No, they have a compiler set that perform exceptionally well on Windows/DOS. Does Inprise have their own "brand" of Java? Absolutely not. Java is Java is Java. That's the point of the JCK, the specification, the required core libraries. I tend to believe what Paolo Ciccone has posted regarding the why and how of the Sun JDK for Linux release: Inprise had a business need and a hard deadline (businesses tend to set unchangeable deadlines). I've been seeing alot of anti-Sun sentiment since the release. Some of it may be deserved (I was horrified that whoever wrote the release left out acknowledgement of Blackdown -- and I was very vocal about that internally), but most of what I've been seeing has amounted to "Sun has no right to put out a JVM/JDK for Linux, because that belongs to Blackdown." I want to make something very clear here: just because Sun has released a JDK for Linux, that does not mean that Blackdown can't. They licensed the code, they can do their port. When all the JCK tests are being passed (currently held up by the sunwjit on Linux, which I'm working on fixing), then they can call their port an FCS. Even if we continue to release more ports of Java for Linux, it doesn't change anything. Blackdown can continue to do ports of Java to Linux as long as they are licensees and willing to give up most of their spare time and not get any gratitude for it. Someone suggested that Sun is trying to "fracture" the Linux Java community. How does that make any sense? Do you really think Sun cares in the least whose VM you're using? All Sun cares about is that *all* implementations of Java conform to the spec - otherwise compatibility is compromised and you lose the cross-platform nature of Java. That's one of the best things about Java - it doesn't matter which vendor's VM you run on as long as that VM implementation has been shown to be fully compatible. Just my two cents. --Jeff Nathan Meyers wrote: > > Mike Ajemian wrote: > > > Let me suggest a motive that makes sense. Inprise makes IDEs. IDEs > > > include debuggers...Connect the dots. > > > > This was the point, Einstein. Inprise relies on its brand. I didn't > > think I had to spell this out to the nth degree (I mean, who in this > > discussion doesn't know about ownership of Java and the JDK?). > > Yes, Inprise relies on branding an IDE. Just like Red Hat (to use your > earlier example) relies on branding a distribution, some tools, and user > support. But Red Hat doesn't brand the kernel or anything else about > Linux. Inprise's JBuilder is a cross-platform product that runs on any > Java platform; why would they want to dilute their brand by going into > the Linux JDK business? Where's the motive? What's the payoff? If JDKs > are a business they want to own, why don't they have one for a big > market like Windows? > > Looking back on the notes that have comprised this conversation, you've > described some motives that have me scratching my head: that Inprise > wants to be in the Linux JDK business, that a "decision was made pretty > high up" (your words) to deliberately piss off the Blackdown community, > that the "poor communications" argument is spin-doctoring. All pretty > serious stuff, but I still haven't seen any evidence. Why would > companies that depend on a) spending money wisely, b) maintaining user > good will, and c) supporting their core brands make such decisions? Are > they run by lunatics? > > I'm sorry to keep hammering on the communications thing, but there is a > lot of experience in this group to support it. When I tried to contact > Blackdown about including the Blackdown JDK with my book (a simple > enough question), it took me many attempts to get an answer. My other > book-related queries were ignored completely. A look through past mail > turns up many similar experiences: developers willin
Re: invalid method hash with rmi calls
[EMAIL PROTECTED] wrote: > > They were in sync. I discovered I got the same message after I killed the > server! I had been playing with my policy file before, and I had removed > the allpermission that had been granted to jdkhome/lib/ext. When I put > that back all my problems went away. The permission thing seems real > screwy to me. > Actually, that makes sense. Java 2 has a different security structure than previous releases. If you took away permissions from the jre libs, then you'd get that error. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: invalid method hash with rmi calls
I have no idea why the security mechanism was changed. All I can tell you is that I had the same problem with RMI stuff (on Solaris, even) until I both gave all permissions to jre/lib/ext codebase AND created a .java.policy file in my home directory which was identical to the default java.policy file. This could be a bug in the VM; on the other hand, this could also be the intended functionality. I don't know for sure since I'm not involved in the Java security development. --Jeff Chris Abbey wrote: > > At 21:59 12/18/99 -0700, Jeff Galyan wrote: > >Actually, that makes sense. Java 2 has a different security structure > >than previous releases. If you took away permissions from the jre libs, > >then you'd get that error. > > That error makes sense to you because of security being restriced? > HUH? in 1.1 that error had a single, clear, meaning. Why on earth > would it make sense to overlap a completely different type of problem > onto the same error? Why not a *security* error... or is this an > attempt at security through obfuscation? -=Chris > > cabbey at home dot net <*> http://members.home.net/cabbey >I want a binary interface to the brain! > Today's opto-mechanical digital interfaces are just too slow! > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: jni + rmi = NoClassDefFoundError + consternation
Jean-Pierre Fournier wrote: > > Does anyone know how one could get the same > functionality as the -verbose option when > starting a JVM from the commandline from > within java or C? > Do something like this in your C code: #define USER_OPTIONS = "-verbose"; #define OPTS_SEPARATOR = "\s"; #ifdef JNI_VERSION_1_2 JavaVMInitArgs vm_args; JavaVMOption options[1]; options[0].optionString = USER_OPTIONS; vm_args.version = 0x00010002; vm_args.options = options; vm_args.nOptions = 1; vm_args.ignoreUnrecognized = JNI_TRUE; res = JNI_CreateJavaVM(&jvm, (void**)&env, &vm_args); #endif /* JNI_VERSION_1_2 */ Unfortunately, JNI in 1.1.x doesn't give you a way to specify JVM init arguments when you create a Java VM from native code. If you can be absolutely sure that all your deployment will be on Java 2, then the above will do the trick for you. Incidentally, we recently published a book on JNI, called "The Java Native Interface", by Sheng Liang. It's part of The Java Series from Addison/Wesley, and I've found it to be an excellent reference (and I'm pleased that we *finally* published a reference on JNI - it's about time!). -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Simpliest way to check the file presence.
java.io.File.exists() returns a boolean indicating whether the named file exists. --Jeff Jacob Nikom wrote: > > Hi, > > What is the simplest way to check, whether the file > exist or not on the Linux hard drive? Is there any operation > which delivers binary output whether file exist or not? > > Thank you, > > Jacob Nikom > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: glibc requirements
Juergen Kreileder wrote: > > No big surprise, they've commented out the relevant entries in the > font.properties file. I'll do the same for the next Blackdown release > as people think that it is a bug, but it isn't. > Exactly, it just means that a font package isn't installed on the host system. I seem to remember seeing something some time back about the specific font package to install, but I don't remember what it was... > Try to display dingbats characters (0x2701 - 0x27be) on an AWT > component with the Inprise JDK, you'll get no warnings but the > component only will show question marks: ''. The warnings from > the Blackdown JDK just tell you immediately that something might not > work correctly. > This is, in my opinion, the correct way to handle it - let the user know right away that something may not work right instead of making them guess. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Raster ShortInterleavedRaster error
Try copying the 16-bit subsection of the Screen section in XF86Config and change the depth line to 15, then start X like this: startx -- -bpp 15 and see if it works. --Jeff Ryan Marsh wrote: > > Thanks for the help but I don't think that I can set it to 15bpp. When I > was running Xconfigurator for my card I believe the only color depths > available to me where 8bpp, 16bpp, 32bpp. > > -ryan > > -Original Message- > From: Martin Schröder [mailto:[EMAIL PROTECTED]] > Sent: Thursday, December 23, 1999 3:26 AM > To: '[EMAIL PROTECTED]' > Subject: Re: Raster ShortInterleavedRaster error > > On 1999-12-23 02:54:23 +0100, Juergen Kreileder wrote: > > >>>>> Ryan Marsh writes: > > Ryan> I am on Red Hat 6.1, using KDE, at 1280 x 1024 resolution > > Ryan> and 16bpp. > > > > ... but the masks say you only have 15bpp. I'm working on a fix for > > our next release. > > Till then set your display to 15bpp. > > Been there, done that. :-) > > Best regards >Martin > -- > Martin Schröder, [EMAIL PROTECTED] > ArtCom GmbH, Grazer Straße 8, D-28359 Bremen >Voice +49 421 20419-44 / Fax +49 421 20419-10 > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Speed of 1.1 vs 1.2
The Solaris JDK uses DGA under the covers to speed up Java 2D. Right now, the XFree86 DGA extension is undocumented (for the most part) and it's not clear how many of the supported cards are also supported for DGA in XFree. I'm trying to get a dialogue going with the XFree folks to find this out. For now, I don't think the Linux JDK uses DGA in Java2D. If enough cards (ideally, all of them) are supported to make using the DGA stuff feasible, that will accelerate Java 2D quite alot. So, in a sense, you're right: it just hasn't been optimized for speed yet. :) --Jeff Ekkehard Kraemer wrote: > > Hi, > > I have an application that draws a lot of java.awt.Images onto another image, > and then draws the latter one onto the screen (the application does no other > relevant things). It is written for JDK 1.1.x, and runs very smooth under > Blackdown 1.1.7v3 or IBM 1.1.8. Is it normal that the same application runs > *much* slower (5-15 times) on Blackdown JDK 1.2.2rc3 or Inprise JDK 1.2.2rc1? > Is this a known problem with all 1.2 JDKs, or are the Linux ports of the > native Java2D parts not yet optimised for speed (which would be excusable, > since speed should be the last thing to optimize...)? > > I'm sure that I'm using a JIT since if I add -Djava.compiler=NONE, it runs > several factors slower. I've also tried to vary -green or -native, with no > large effect. > > MbG, Ekkehard > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: compiling the JDK
Michael, The easiest way to compile the Blackdown port is if you use the 'patchomatic.sh' script to apply their patches. It extracts the archives and sets up the directories for you (and is *way* faster and better than doing it by hand). Just be sure to edit the patchomatic.sh script to set up the variables at the beginning to match your environment before you run it. --Jeff "Michael E. Moores" wrote: > > it looks like i will have to compile the JDK > to figure out my glibc2.1.2 troubles. > > i read the page > http://www.place.org/~stevemw/java/FAQ/README.linux.src.txt > > is this the latest data on compiling? can i > use this to compile the latest versions? > > thanks for the input! i don't see others getting > much response on this topic. > > --michael moores > tech leader, e-commerce > Real Networks > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Java 3d installation problem
Jacob, Just make a symlink to libGL.so as libMesaGL.so.3 - in Mesa3D 3.x, the default for the build is to name the libraries libGL.so etc., for easier swappability with "real" OpenGL implementations. Earlier versions of Mesa3D used the name libMesaGL.so for the libGL.so library. The sumlink can be created in whichever directory your libGL.so lives in. --Jeff Jacob Nikom wrote: > > Hi, > > I run RedHat 6.0, libc-2.1.1 and Blackdown jdk1.2pre-v2-debug.tar.bz2. > I installed Java3D package from > ftp://metalab.unc.edu/pub/linux/devel/lang/java/blackdown.org/java3d/1.1.1/i386/ > > Everything went smoothly, even the installation of the MesaGL library. > I was able to run a lot of MesaGL demos. > > However, when I started to run Java3d examples, every example > complained about the lack of libMesaGl.so.3 library: > appletviewer -J-mx64m HelloUniverse.html > java.lang.UnsatisfiedLinkError: > /homes/nikom/Java/jdk1.2/jre/lib/i386/libJ3D.so: > libMesaGL.so.3: cannot open shared object file: No such file or > directory > at java.lang.ClassLoader$NativeLibrary.load(Native Method) > at java.lang.ClassLoader.loadLibrary0(Compiled Code) > at java.lang.ClassLoader.loadLibrary(Compiled Code) > at java.lang.Runtime.loadLibrary0(Compiled Code) > at java.lang.System.loadLibrary(Compiled Code) > at javax.media.j3d.UniverseManager$1.run(Compiled Code) > at java.security.AccessController.doPrivileged(Native Method) > at javax.media.j3d.UniverseManager.(Compiled Code) > at javax.media.j3d.VirtualUniverse$2.run(Compiled Code) > at java.security.AccessController.doPrivileged(Native Method) > at javax.media.j3d.VirtualUniverse.(VirtualUniverse.java:464) > at HelloUniverse.(Compiled Code) > at java.lang.Class.newInstance0(Native Method) > at java.lang.Class.newInstance(Compiled Code) > at sun.applet.AppletPanel.createApplet(Compiled Code) > at sun.applet.AppletPanel.runLoader(Compiled Code) > at sun.applet.AppletPanel.run(Compiled Code) > > However, Mesa's installation script did not create MesaGL library - it > only > produced libGL.so, libGLU.so, libglut.so, etc. How I can get > libMesaGL.so > and where I have to put it? > > Thank you, > > Jacob Nikom > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: problems with rmi (linux 1.2 client, solaris 1.3 server)
If I'm not mistaken, the stubs have to be on both the server and the client side. RMI is a bit tricky that way... --Jeff Aaron Stromas wrote: > > > Aaron Stromas wrote: > > > > > [EMAIL PROTECTED] wrote: > > > > > > > On Tue, Jan 11, 2000 at 02:00:00PM +, Aaron M. Stromas wrote: > > > > > greetings, > > > > > > > > > > may someone have a hint as to what my problem may be and how to fix it. > > > > > here is what is happening. i have a an rmi application with linux > > > > > client (jdk 1.2) and solaris server (jdk 1.3). the client throws an > > > > > UnmarshalException. i could not figure out why it wa happening, so i > > > > > tried the rmi example from the "professional java server programming" > > > > > which also throws the unmarshal exception. the client ran fine on the > > > > > same solaris box where the server ran, so i tried the client from > > > > > another solaris host, also running jdk 1.3 - runs fine. > > > > > > > > Don't the two vm's have to be the same, as the serial numbers will be > > > > different between 1.2 and 1.3, which will cause Serialization errors? > > > > > > > > > > i did not know that. is that a fact? if so, i have a serious problem :-( > > > > that does not appear to be so, at least, not on solaris - i installed > > jdk1.2.1_04 and the client ran ok. > > > > it also worked on linux when i copied the _Stub class to the client. > so, why doesn't the server find the stub to return to the client? > -- > Aaron Stromas > Oracle Corp. > > "Tick-tick-tick!!!... ja, Pantani is weg" > (BRTN commentator, L'Alpe d'Huez, 1995 Tour de > France) > -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: about Mozilla & blackdown's JVMPlugin
Mozilla doesn't yet have an OJI implementation for Unix/Linux. See www.mozilla.org/oji for more details. --Jeff Heeyeon Hwang wrote: > > Hi all, > > Mozilla still can't view any applet, on my machine. > My machine is i686, Linux kernel ver. 2.2.15 and JVMPlugin based JDK1.1.8. > And Mozilla is M12 release. > Which part cause this problem Mozilla or JVMPlugin ? > > Thanks for reading. > > From: [EMAIL PROTECTED] > Heeyeon Hwang > ôèPÔ? ? >ÿzf¢-Ú#jöÿ-)îÇúު笷øÚ½¯Û*§$v?'þSàÂ+ajË>?ç-¡ÿî?Ë>±ÊâmïÿNº.nWÿ > ?íiËdj¹ÿnV??Ú0Yú+ -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Java Decompiler
Jad is written in C++ and therefore probably won't be able to decompile itself. --Jeff Nicholas Wright wrote: > > ;) Ever tried running a binary through a Java decompiler? > > Best Regards > > Nicholas > > > Resent-Date: Mon, 17 Jan 2000 04:02:48 -0700 (MST) > > From: "Oliver Fels" <[EMAIL PROTECTED]> > > To: [EMAIL PROTECTED] > > Date: Mon, 17 Jan 2000 11:54:20 CET > > Mime-Version: 1.0 > > Content-Transfer-Encoding: 7BIT > > Subject: Re: Java Decompiler > > Resent-Message-Id: <[EMAIL PROTECTED]> > > Resent-From: [EMAIL PROTECTED] > > X-Mailing-List: <[EMAIL PROTECTED]> archive/latest/2446 > > X-Loop: [EMAIL PROTECTED] > > Resent-Sender: [EMAIL PROTECTED] > > > > On 17 Jan 00, at 17:48, MARUYAMA Fuyuhiko wrote: > > > > > > > > I just accidentally deleted a bunch of my Java source files. Anyone > know > > > > a good decompiler that works under Linux? > > > I think "Jad" is fast and stable. The only regrettable thing is no > > > sources are available :-< > > > > So where is the problem then if that is the purpose of this tool ? :-) > > Ever tried running it through itself ? > > > > Oliver > > > > > > -- > > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] > > > > === > Nicholas WrightImperial Software Technology Technical Support > --- > Email : [EMAIL PROTECTED] or [EMAIL PROTECTED] > Berkshire House120 Hawthorne Ave, #101 > 252 Kings Road Palo Alto > Reading RG1 4HP United Kingdom California 94301 USA > Tel: +44 118 958 7055 Tel: 650 688 0200 > FAX: +44 118 958 9005 FAX: 650 688 1054 > === > ** VISAJ AT http://www.ist.co.uk/visaj ** > === > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: AttachCurrentThread()
Hi, Mark, First, you might want to check out Sheng Liang's excellent book on JNI, titled "The Java Native Interface". Also, Nathan Meyers' book, "Java Programming on Linux" is an excellent resource for Linux-specific Java programming questions, and (I think) includes a chapter or two covering JNI and Linux-specific gotchas. Between the two of those, you should have just about all your JNI questions covered! :) --Jeff Mark Delafranier wrote: > > Java Linux Buffs: > > I have a mutli-threaded application using pthreads, RedHat 6.1, gcc 2.91.66, > libc 2.1.2. This is a standard RedHat 6.1 install with no patches or upgrades. > > I have searched through the www.blackdown.org faqs on using JNI and I did not > find anything helpfull for this problem. > > I application spawns various threads to deal with client requests, like a web > server would spawn threads to deal with http requests. The main process > performs the JNI_CreateJavaVM() which succeeds. > > When a thread is started it issues an AttachCurrentThread and then proceeds with > its work. I am finding that this method succeeds for 4 threads and then blocks > for other threads. > > Its like AttachCurrentThread is hanging or blocked on mutex of some sort. The > same code works under Solaris and NT. > > Is there a limit to the number of threads that can be attached to the VM? > > BTW: I believe I have everything setup so that the vm properly uses > native_threads. > > Any suggestions? > > Thanks > Mark DeLaFranier. > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Terrible native thread performance
Dan, A big part of the threads problem on Linux stems from the pthreads implementation that's available in glibc. There has been much discussion on this topic of late - check the archives for more detail. I believe the word is that glibc 2.1.3 is supposed to have improvements in the pthreads implementation that may help the Linux JVM perform better. --Jeff Daniel Stux wrote: > > Hi folks, > > I've just installed two versions of the JDK1.2.2 for linux: Sun's RC2, and > Blackdown's RC3. I am experiencing the wierdest behavior I have ever seen > for a JDK. > > Here is what I am *used* to seeing. We run Java all day long on Solaris > Sparc and x86 and Windows NT. With green threads, things are slow as hell, > and the processors are kept very busy, even when the program is idle. With > native threads, everything zips along nicely. > > Here is what I see with Linux. I am running on a freshly installed RedHat > 6.1 machine. With either JDK, running in native threads is absolutely > crippling. There seems to be a serparate JDK process ID for each running > thread, or otherwise something is casuing it to fork 15 times. Of these > threads four or five of them just hammer the CPU, leaving the whole > machine at a crawl. Actual performance of our Java GUI isn't too bad, but > it's no where near where it should be. > > Switch to green threads. With Sun's JDK it's like lightning. Processor > utilization is practically nill, and the GUI is extremely responsive. With > Blackdown's JDK, processor utilization is also very low, but GUI > responsiveness is very low as well. > > I have looked through all the FAQs I could find, tried the various > combinations of env variables. > > Anyone else experienced this behavior? Really odd. Any fixes, work > arounds, or do I just hope something miraculous happens between the > release candidates and the release? > > Thanks! > > -Dan Stux > > ------ > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: No swing classes
paul campbell wrote: > > Works OK - well sort of... > > (except "Font specified in font.properties not found[--symbol blbah blah This one's a known issue. I think there may be a fix for it - check the Blackdown.org site. > and > Could not load Look and Feel: > com.sun.java.swing.plaf.windows.WIndowsLookAndFeel > when I clicked the "Windows" radio button. > ) > This is expected behaviour on non-MS systems. The decision was made to simply not allow the Windows look & feel to be loaded except on Windows (although the classes *are* there), since Microsoft hasn't given permission to Sun to use the Windows look & feel anywhere except Windows. -- Jeff Galyan http://www.anamorphic.com http://www.sun.com jeffrey dot galyan at sun dot com talisman at anamorphic dot com Sun Certified Java(TM) Programmer == Linus Torvalds on Microsoft and software development: "... if it's a hobby for me and a job for you, why are you doing such a shoddy job of it?" The views expressed herein do not necessarily reflect those of my employer. Sun Microsystems, Inc., has no connection to my involvement with the Mozilla Organization. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: JNI & .so Files
Change RTLD_LAZY to RTLD_NOW and I think it will work. There was a bug filed at Sun about something similar to this, and if I recall correctly, the fix was to use RTLD_NOW. --Jeff [EMAIL PROTECTED] wrote: > > Hi Nathan, > > Thank you for your response. Please let me re-address my question by using > the following pseudo code. I embedded my question in so2.c pseudo code. > > The following lines are app.java, so1.c and so2.c. They are only pseudo > code. > > == > //app.java > public class app > { > static > { > System.loadLibrary("so1"); > } > native void so1Func(); > > public static void main(String args[]) > { > app myApp = new app(); > myApp.so1Func(); > } > > javaFunc() > { > System.out.printfln("In Java, called back from so1.so"); > } > > } > == > //so1.c for libso1.so > JNIEnv gEnv; > jobject gObj; > > void Java_app_so1Func(JNIEnv * jEnv, jobject _this) > { > gEnv = jEnv; > gObj = _this; > ... > library = dlopen("./libso2.so", RTLD_LAZY); > funcRef = dlsym(library, "so2Func"); > (*funcRef)(); //call function so2Func() in libso2.so > ... > } > > void callBack() > { > jclass cls = (*gEnv)->GetObjectClass(gEnv, gObj); > jmethodID mid = (*gEnv)->GetMethodID(gEnv, cls, "javaFunc", "(V)V"); > (*gEnv)->CallVoidMethod(gEnv, gObj, mid); //call back to java app. > } > == > //so2.c for libso2.so > so2Func() > { > while(1) > { > ... > // > //how to call back to the function > //callBack() in libso1.so from here? > // > ... > } > } > > app.java loads libso1.so into its address space, and libso1.so loads > libso2.so into the same address space. So, libso2.so should be able to call > a function in libso1.so (in the same address space) if libso2.so can resolve > that function's symbol, but how? > > Thanks. > > Lee > > -Original Message- > From: Nathan Meyers [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, February 02, 2000 10:44 PM > To: [EMAIL PROTECTED] > Cc: [EMAIL PROTECTED] > Subject: Re: JNI & .so Files > > [EMAIL PROTECTED] wrote: > > > > Hi, > > > > I got a question on JNI. It would be appreciated if someone could help. > > Lee, > > I'm having trouble understanding the problem you're posing. What is the > difficulty you're trying to solve... how to call functions in one .so > from another .so? You're already doing that. > > Is it the problem of figuring out how to call a function whose name you > do not know until runtime? If so, I think you'll find the > dlopen()/dlsym()/dlclose() functions useful. Other than that > possibility, I'm not quite sure what problem you're trying to solve. > > Nathan > > > > > Q: > > In order to hide java and jni related issues (e.g. jni function name > > convention, etc.) from .so programmers, a wrapper .so file so1.so is used > in > > between java app and another .so file so2.so (the one with native > functions > > we need). This way, the java app interacts with the wrapper so1.so > > directly. Every time when java app needs a native function service in > > so2.so, it first calls a native function in so1.so through jni. so1.so, > in > > turn, calls the required function in so2.so. Everything works fine in > this > > direction (i.e. java app->so1.so->so2.so. java app loads so1.so, and > so1.so > > loads so2.so, then java app invokes a function in so2.so through a > function > > in so1.so). The question is how a function in so2.so calls back to java > app > > through a function in so1.so? In fact, we only need to know how functions > > in so2.so can call functions in so1.so because jni will let us call back > to > > java app from so1.so. > > > > More information: > > - the java app is multithreaded application using Thread.start(). > > - each java thread may call the same function in so1.so, then > > this function, in turn, calls a function in so2.so > > - native code doesn't create any thread. > > > > Use IPC? which one is easier on
Re: Servlet
Another good servlet framework is Enhydra, from www.enhydra.org. --Jeff [EMAIL PROTECTED] wrote: > On Fri, 7 Apr 2000, Jacek Laskowski wrote: > > > I should also mention about Jakarta which is a project of people who have worked > > on JSWDK. This product will someday be a RI for JSP/Servlet, but currently there > > is one major problem - there is no servlet auto-reloading. That's the reason why > > I mentioned about it at the end. You may find it at http://jakarta.apache.org. > > The version in CVS (and available as a pre-build download) does now have > servlet reloading. The next release should be out very soon. I use it > actively for development now and it is very easy to setup and run. If you > want to learn about servlets you might as well learn the Servlet 2.2 API > (with JSP 1.1). > > -jh > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: JDK1.3 on Linux with SMP
Joseph Shraibman <[EMAIL PROTECTED]> writes: > Uh, yeah, that's right. Sun's jdk says that it doesn't work on smp > kernels. The beta refresh up on java.sun.com removed the restriction on SMP machines. I've been using it with good results. -- Jeff Hutchison <[EMAIL PROTECTED]> Stryker Instruments, Kalamazoo, MI -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Linux - Java Open Files
Hi I need some clarification on a problem I'm having running java under Linux. I start a number of java applications (JDK 1.3.1_01) on our Red hat 6.2 box. Now as I understand what happens is, when a thread is spawned, each thread is cloned and becomes its own process. This is since JDK 1.3.x, while JDK 1.2.x used green threads. What I need to understand is, do they share the same memory? And the same files? The problem I am having is the number of files that are opened by my applications. Listed using lsof. It seems that each thread (each process) has a handle to each jar file that it references. For example, after I have started all my applications I have about 600 java processes running on the Linux box. Doing the following lsof | grep log4j.jar --count" will return about 580 instances. Doing a complete count on all the files open by the user who starts the application, I get about 55000 open files Any help would be great Thanks in advance Jeff Singer -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
RE: Linux - Java Open Files
Hi Thanks for the reply. Im still not sure exactly what you meant with the open file issue. If the open file is counted one per thread, is the file open for each thread or only reported as open. If so lsof might not be accurate with threads ?? The reason we started looking at the open files is, we where having IO problems. After running for about 1 day, Linix started reporting IO errors and stating that it couldnt open any more files. The other concern or question is, should the handle to a referenced jar file not be closed at some point? Thanks Jeff > -Original Message- > From: Anders Lindback [mailto:[EMAIL PROTECTED]] > Sent: 03 October 2001 12:21 > To: Jeff Singer > Cc: [EMAIL PROTECTED] > Subject: Re: Linux - Java Open Files > > > Jeff Singer skrev: > > I start a number of java applications (JDK 1.3.1_01) on our Red > hat 6.2 box. > > Now as I understand what happens is, when a thread is spawned, > each thread > > is cloned and becomes its own process. This is since JDK 1.3.x, > while JDK > > 1.2.x used green threads. > > Actualyy no they do not become their own process. In the Linux a thread > gets a process entry so that it looks and behaves like a process for > scheduling etc. But a thread is not a process. > > > What I need to understand is, do they share the same memory? > And the same > > files? > > All threads share their memory open files etc thisi whats > separate them from > normal processes. > > > The problem I am having is the number of files that are opened by my > > applications. Listed using lsof. It seems that each thread > (each process) > > has a handle to each jar file that it references. For example, > after I have > > started all my applications I have about 600 java processes > running on the > > Linux box. Doing the following lsof | grep log4j.jar --count" > will return > > about 580 instances. > > > > Doing a complete count on all the files open by the user who starts the > > application, I get about 55000 open files > > Each open files are counted 580 times - one for each thread - thus > the program containging all threads has about 100 open files. > > Anders -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]