Some initial impressions (was: emacs vs xemacs)
Greetings all, Well, it's been about 3 weeks since I've installed linux with a dual boot setup on my NT box in order to do java development. Thanks to all who offered advice and encouragement. I've tried all the popular java ide's on NT, Visual Age, Visual Cafe, JBuilder, etc., but I must say, my favorite development setup is the one on Linux. KDE with usually 4 screens. (1) for xemacs, a couple of xterm's and running my java code with jdk117_v1a; (2) for netscape/javadocs; (3) for togetherJ whiteboard edition; and (4) for browsing the web and getting mail. Still haven't gotten Makefile to work, but I get some ideas for that when I get back to work Monday. (Any sample Makefiles for java would be appreciated - TIA) Anyway, the thing with linux is that it seems to run java code faster than NT. NetBeans on the NT side (200MHz K6 w/128MB ram) is almost unusable, but on linux, it's not so bad. Also, with togetherJ, there are times that there are two jvm's going and switching screens causes a noticeably faster repaint for togetherJ on linux. I really like togetherJ. I'm trying to get up to speed on OO modeling and this is a great tool (and the whiteboard edition is free, too) Both togetherJ and NetBeans seem to me to be good examples of OO app's and I'm getting some good ideas for my own personal project. Which I'm glad to report is going much better since I trashed everything I had and started over with the linux setup. There have been a number of threads on what's the best ide/development system. My opinion is that it depends on where you're at. I'm a self-taught programmer and found some of the ide's helpful getting up to speed. I'm still interested in looking at the code they produce, but figure now I can do as well or better. At work, we have some developers using PowerJ for prototyping and I guess that's all right. But then we "real" developers hand code it for production using jdk and xemacs. JBuilder's code inspector brought me up to speed on swing pretty quick. I figured it was worth the money just for the learning. Hey, knowing swing got me my current job which is working on a big CORBA project. One further observation. IMHO, the learning curve for linux doesn't seem to be that steep but rather more gradual and it does takes time. Somehow learning linux makes me feel smarter, where windows at first made me feel dumber. At least until I got it that what was wrong was windows, not me. Theory: could windows have contributed to a loss of national IQ points? The dumbing down of a country? Slashdot had an interesting article by some professor that said that literacy for high school students should include basic linux. Great idea! I'd add some basic java literacy, also. OK, here's a research topic for some grad student: can linux/java training raise national IQ? Well, that's all for now. Best wishes to everyone for the new year Michael
Re: Some initial impressions (was: emacs vs xemacs)
Michael Doherty wrote: > > Greetings all, [...] > (Any sample Makefiles for java would be appreciated - TIA) > > Anyway, the thing with linux is that it seems to run java code faster > than NT. NetBeans on the NT side (200MHz K6 w/128MB ram) is almost [...] I'm surprised. NetBeans crawls with the Blackdown Linux JDK. Are you using TYA perhaps? What version? For a Makefile, I suggest: all: jikes *.java clean: rm -f *.class core *~ That's it. It works for me. Jikes is fast enough to completely recompile my entire Java project (60 source files) in just a few seconds. And if you use it as above, then it works out the dependencies and only recompiles what's necessary. Rich. -- - Richard Jones. Linux contractor London and SE areas.- -Very boring homepage at: http://www.annexia.demon.co.uk/ - - You are currently the 1,991,243,100th visitor to this signature. - -Original message content Copyright (C) 1998 Richard Jones.-
Re: Some initial impressions (was: emacs vs xemacs)
Richard Jones wrote: > > Michael Doherty wrote: > > Anyway, the thing with linux is that it seems to run java code faster > > than NT. NetBeans on the NT side (200MHz K6 w/128MB ram) is almost > [...] > > I'm surprised. NetBeans crawls with the Blackdown > Linux JDK. Are you using TYA perhaps? What version? I'm not running TYA. I was just saying that it was faster on linux than on the same box running jdk117 w/Symantec jit on nT4.0. I think I will check out jikes. Sounds great. Thanks, Michael
No events from KeyListener on a JWindow (unlike Win32)
I've written a slideshow presenter which displays full screen. I am using the Swing JWindow class which is a kind of java.awt.Window and therefore has not titlebar. I want the key to advance to the next slide, so I added a KeyListener to the JWindow. On Win32 this works fine - full screen slide, no titlebar, to advance. On Linux I get the full screen slide, but the KeyListener doesn't get any events. My first thought was focus differences, so I explicitly set focus (I tried both requestFocus and grabFocus) no difference. My only conclusion is the window manager (Window Maker) is not sending the events because of some window style used by Window/JWindow. To double check, I tried with Mouse Events. If I have another JFrame open, the frame can get mouse events, but not the JWindow. As soon as I close the JFrame the JWindow can get the mouse events, but still no KeyEvents. I've even tried using a JFrame shown at negative coords (-Insets.left, -Insets.top) to clip the titlebar - it refuses to accept negative coords. Sorry for the long account. Does anyone have any suggestions for how I can get a full screen, no titlebar Java canvas on Linux to accept Key events? Thanks, Jon Priddey. Elixir Technology Pte Ltd. /* Elixir IDE for Java: http://www.elixir.com.sg/ */
RE: serial port program
One problem we are encountering with rxtx is libc5 versions of the jdk native include files are not compiling clean with rxtx. If anyone able to dig around has the libc5 version installed we are interested in knowing if this is a problem with the libc5 jdk jni or rxtx. The only think on the rxtx side I can think of is maybe the flags -ansi -D_POSIX_SOURCE -D_BSD_SOURCE could be causing problems with the jdk jni. It works fine on the glibc version. This was not a problem with previous releases of the libc5 jdk/rxtx when I had libc5 systems around. There have been proposed changes to typedefs_md.h but I'm not convinced they are right. Trent Jarvi [EMAIL PROTECTED] http://jarvi.ezlink.com/rxtx [Typical problems] > gcc -I /usr/local/lib/rxtx-1.2-beta-1 -I /usr/local/lib/rxtx-1.2-beta-1/i586-pc-linux-gnulibc1 -I . -I /usr/local/lib/java/jdk1.1//include -I /usr/local/lib/java/jdk1.1//include/genunix/ -g -O2 -Wall -ansi -DTIMEOUT -DASYNC -D_POSIX_SOURCE -D_BSD_SOURCE -c -fPIC -DPIC ../src/SerialImp.c > In file included from /usr/local/lib/java/jdk1.1//include/typedefs.h:18, > from /usr/local/lib/java/jdk1.1//include/oobj.h:25, > from /usr/local/lib/java/jdk1.1//include/StubPreamble.h:26, > from ../src/SerialImp.c:24: > /usr/local/lib/java/jdk1.1//include/genunix/typedefs_md.h:149: parse error before `a' > In file included from /usr/local/lib/java/jdk1.1//include/oobj.h:25, > from /usr/local/lib/java/jdk1.1//include/StubPreamble.h:26, > from ../src/SerialImp.c:24: > /usr/local/lib/java/jdk1.1//include/typedefs.h:31: parse error before `int64_t' > /usr/local/lib/java/jdk1.1//include/typedefs.h:31: warning: no semicolon at end of struct or union > /usr/local/lib/java/jdk1.1//include/typedefs.h:33: parse error before `}' > /usr/local/lib/java/jdk1.1//include/typedefs.h:33: warning: data definition has no type or storage class > In file included from /usr/local/lib/java/jdk1.1//include/StubPreamble.h:26, > from ../src/SerialImp.c:24: > /usr/local/lib/java/jdk1.1//include/oobj.h:55: parse error before `number' > /usr/local/lib/java/jdk1.1//include/oobj.h:160: parse error before `int64_t' > /usr/local/lib/java/jdk1.1//include/oobj.h:160: warning: no semicolon at end of struct or union > /usr/local/lib/java/jdk1.1//include/oobj.h:161: warning: data definition has no type or storage class > /usr/local/lib/java/jdk1.1//include/oobj.h:162: parse error before `ClassArrayOfLong' > /usr/local/lib/java/jdk1.1//include/oobj.h:162: warning: data definition has no type or storage class > [One solution provided by Robert Perry This isnt the cleanest patch...] --- typedefs_md.h Fri Jan 1 15:30:40 1999 +++ typedefs_md.h.new Fri Jan 1 15:29:27 1999 @@ -1,5 +1,5 @@ /* - * @(#)typedefs_md.h1.32 97/06/25 + * @(#)typedefs_md.h1.31 97/01/23 * * Copyright (c) 1995, 1996 Sun Microsystems, Inc. All Rights Reserved. * @@ -17,7 +17,6 @@ * THIS SOFTWARE OR ITS DERIVATIVES. * * CopyrightVersion 1.1_beta - * */ @@ -25,11 +24,6 @@ * Solaris-dependent types for Green threads */ -/* sbb: Johan Vos, why isn't this #ifndef inside the solaris header guard? */ -#ifndef BITSPERCHAR -#define BITSPERCHAR 8 -#endif - #ifndef _SOLARIS_TYPES_MD_H_ #define _SOLARIS_TYPES_MD_H_ @@ -37,57 +31,33 @@ #include #include "bool.h" -#if defined(__alpha__) -typedef unsigned long ptr_int; -#define PTR_IS_64 1 -#define LONG_IS_64 1 -#else + typedef unsigned int ptr_int; #define PTR_IS_32 1 -#endif /* don't redefine typedef's on Solaris 2.6 or Later */ -#if !defined(_ILP32) && !defined(_LP64) -#ifndef _UINT64_T -#define _UINT64_T -#ifdef LONG_IS_64 -typedef unsigned long uint64_t; -#else -typedef unsigned long long uint64_t; -#endif -#define _UINT32_T +typedef unsigned long long uint64_t; typedef unsigned int uint32_t; -#if defined(__linux__) typedef unsigned int uint_t; -#endif -#endif -#ifndef __BIT_TYPES_DEFINED__ -#ifdef (__i386__) -/* that should get Linux, at least */ #ifndef _INT64_T #define _INT64_T -#ifdef LONG_IS_64 -typedef long int64_t; -#else typedef long long int64_t; -#endif -#define _INT32_T -typedef int int32_t; -#if defined(__linux__) -typdef int int_t; -#endif -#endif -#endif /* i386 */ + +/* typedef int int32_t; */ + +typedef int int_t; #endif /* __BIT_TYPES_DEFINED__ */ #endif /* !defined(_ILP32) && !defined(_LP64) */ #ifndef BITSPERCHAR #define BITSPERCHAR 8 + + #endif /* use these macros when the compiler supports the long long type */ @@ -119,28 +89,12 @@ #define IS_NAN(x) isnan(x) #endif - -/* On Intel these conversions have to be method calls and not typecasts. - See the win32 typedefs_md.h file */ -#if ((defined(i386) || defined (__i386)) && defined(__solaris__)) || defined(__powerpc__) - -extern int32_t float2l(float f); -extern int32_t double2l(double d); -extern int64_t float2ll(float f); -extern int64_t double2ll(double d); - -#else /* n
Re: No events from KeyListener on a JWindow (unlike Win32)
> I am using the Swing JWindow class which is a kind of java.awt.Window > and therefore has not titlebar. Under Linux the Windows and JWindows does not allow children to get focus. This is also a Solaris problem... If you use TextComponents or JTextComponents the input appears on the console and not in the TextField, this is the same problem! See my bug-request at Blackdown's bug-parade #91 But this is a SUN-bug: Look at Sun-Developer-Connection -> Bug-Parade #4121501 and #4094957! I hope this bug will be fixed soon (Java 2), i found this bug 6 month ago( :((( ) and nothing happended I tried it with JFrames a Window would be better in this case... Hope I could help you Kalimero
JDK1.1.7 and 8bpp StaticColor display
Hi, I've upgraded from JDK-1.1.3-v1 to JDK-1.1.7-v1a and my AWT/Motif widgets appear in black & white dotted, exactly like this : . : Menu Bar File Edit : Button 1 : Button 2 ... : Choice :¨¨¨ Only the upper and left edges of the widgets are drawn with dot lines (no colors and 3d effects), it do not affect the JAVA drawing functions (drawLine, fillOval, etc). I'm using XFree86 3.3.1 SVGA server configured in 8bpp and StaticColor (8bpp for speedup and 8bpp to disable colormap switching). This happen with both dynamic OSF/Motif 2.0.0 and static Metro/Motif (DYN_JAVA). In the other 8bpp color mode (PseudoColor, GrayScale, StaticGray) there is no problem, and JDK-1.1.3-v1 was behaving correctly in StaticColor. My other Motif 2.0 applications work very well with 8bpp StaticColor, so I think it's the way JDK 1.1.7 manage the Motif widgets... Is there a way to get correct widgets in 8bpp StaticColor ? Thanks. ( I use a Slackware 3.4 libc5 )
Re: Some initial impressions (was: emacs vs xemacs)
Works great! Thanks Rich. I'm frankly kinda amazed. Jikes seems about an order of magnitude faster than the jdk117_v1a compiler. Not sure how that's possible but goota hand it to the guy(s) at IBM who wrote it. Regards, Michael Richard Jones wrote: > > Michael Doherty wrote: > > > > Greetings all, > [...] > > (Any sample Makefiles for java would be appreciated - TIA) > > > > Anyway, the thing with linux is that it seems to run java code faster > > than NT. NetBeans on the NT side (200MHz K6 w/128MB ram) is almost > [...] > > I'm surprised. NetBeans crawls with the Blackdown > Linux JDK. Are you using TYA perhaps? What version? > > For a Makefile, I suggest: > > all: > jikes *.java > > clean: > rm -f *.class core *~ > > That's it. It works for me. Jikes is fast enough to > completely recompile my entire Java project (60 > source files) in just a few seconds. And if you > use it as above, then it works out the dependencies > and only recompiles what's necessary. > > Rich. > > -- > - Richard Jones. Linux contractor London and SE areas.- > -Very boring homepage at: http://www.annexia.demon.co.uk/ - > - You are currently the 1,991,243,100th visitor to this signature. - > -Original message content Copyright (C) 1998 Richard Jones.-
Re: Some initial impressions (was: emacs vs xemacs)
Michael Doherty wrote: > > Works great! Thanks Rich. I'm frankly kinda amazed. Jikes seems about > an order of magnitude faster than the jdk117_v1a compiler. Not sure how > that's possible but goota hand it to the guy(s) at IBM who wrote it. Native code (Jikes) vs Java (Sun compiler) implementation. Plus some built-in Jikes cleverness to check dependencies and avoid unneeded compiles. Java still has a ways to go in delivering the promised native-like performance... and not just on Linux. Nathan Meyers [EMAIL PROTECTED]
Re: Some initial impressions (was: emacs vs xemacs)
Michael Doherty wrote: > > browsing the web and getting mail. Still haven't gotten Makefile to > work, but I get some ideas for that when I get back to work Monday. > (Any sample Makefiles for java would be appreciated - TIA) Hi Michael I've included four sample files that I tend to use over and over again for my projects. Hope this is usefull: .makefile.projectX - this lives in my home directory and contains various variables. A good way to get around operating system specifics, for example developing in Linux and deploying on Solaris. Makefile.common - located at the root of the source tree. this makefile template is included by every other makefile in the source tree. Makefile - this is located at the root of the source tree. I use it to generate a jar file for deployment, to generate the project javadoc and to build the whole project. you can modify it to be used at every branch node in your source tree. Makefile.leaf - (rename this to Makefile) sits in a leaf node directory of your source tree and lists the source files. use to to build other stuff specific to the directory. Chris Dynamic Solutions Pty Ltd http://www.dynamic.net.au/christos 414 Gilbert Road [EMAIL PROTECTED] Preston, Victoria 3072 61 3 94718224 - voice Australia 61 3 94711622 - fax CP_JDK=/usr/local/jdk/lib/classes.zip CP_SOURCE=/home/christos/work CP_JSDK=/usr/local/jsdk/lib/servclasses.zip CP_JDBC=/usr/share/postgresql/postgresql.jar CP_EJB=/usr/local/classes/ejbhome.jar JAVA=/usr/local/jdk/bin/java JAVAC=/usr/local/bin/jikes RMIC=/usr/local/jdk/bin/rmic RMIREGISTRY=/usr/local/jdk/bin/rmiregistry ECHO=/bin/echo HAVE_SUBDIRS = true SUBDIRS = au com docs SOURCES = CLASSES = $(SOURCES:.java=.class) DOCDIR = docs DEPLOYDIR= deploy all:subdirs $(SOURCES) include Makefile.common javadoc: rm -f $(DOCDIR)/*.html javadoc -d $(DOCDIR) -author -private -version \ au.net.dynamic.projectX \ com.beeble.misc chmod g+w $(DOCDIR)/*.html deploy: @$(ECHO) -n "Creating jar file ..." @jar cf $(DEPLOYDIR)/projectX.jar `find au com -name "*.class" -print` @$(ECHO) "done." .SUFFIXES: .java .class $(SUFFIXES) .java.class: @echo "compiling $<" @$(JAVAC) -classpath $(CLASSPATH) $< CLASSPATH=.:$(CP_JDK):$(CP_SOURCE):$(CP_JSDK):$(CP_JDBC):$(CP_EJB) # Set some global variables that are used to construct the CLASSPATH # and that are also used in the leaf-node Makefiles. include $(HOME)/.makefile.projectX subdirs: @if $(HAVE_SUBDIRS); then \ for i in ""$(SUBDIRS); \ do ( cd $$i; make );\ done; \ fi clean: @rm -f *.class $(JUNK) cleanall: clean @if $(HAVE_SUBDIRS); then \ for i in ""$(SUBDIRS); \ do ( cd $$i; make cleanall ); \ done; \ fi HAVE_SUBDIRS = false SUBDIRS = SOURCES = Main.java ProjectX.java CLASSES = $(SOURCES:.java=.class) JUNK = test all:subdirs $(CLASSES) scripts # This target generates a script for testing our project scripts: @$(ECHO) -n "Building scripts " @rm -f $(JUNK) @$(ECHO) "CLASSPATH=$(CLASSPATH)" > test @$(ECHO) "export CLASSPATH" >> test @$(ECHO) "$(JAVA) au.net.dynamic.projectX" >> test @chmod 750 test @$(ECHO) "done." include ../../../../Makefile.common
ISO libstdc++-2.8 (to make jikes happy)
Hello all, Happy new year! I would like to run jikes on my RH 5.0 linux box, but jikes wants libstdc++-2.8, while the current rpm contains libstdc++-2.7 and ...-2.9, but not 2.8. :( I've tried downloading the source to build libstdc++-2.8 but the build failed; some obscure (to me) message about "no source file dummy.c; required for dummy.o" or some such. I've searched for libstdc++-2.8 without luck. Does someone have a copy of the 2.8 rpm that I can copy? On a related note, perhaps jikes should be bundled with the libstdc++ which it wants; I symlinked 2.8 to 2.9 and jikes dies with a "symbol not found." Is it usual for apps to be bundled with specific library versions, or more usual that they aren't? Many thanks for any advice, Robert Dodier
Re: ISO libstdc++-2.8 (to make jikes happy)
On Fri, 1 Jan 1999 19:13:12 -0700 (MST), Robert Dodier wrote: >Hello all, > >Happy new year! > >I would like to run jikes on my RH 5.0 linux box, but jikes wants >libstdc++-2.8, while the current rpm contains libstdc++-2.7 and ...-2.9, >but not 2.8. :( You should be able to get the Jikes libc5 version or download the source to Jikes and compile it locally. The glibc version is RedHat 5.2 with egcs compiler and not statically linked with the libstdc++ >On a related note, perhaps jikes should be bundled with the libstdc++ >which it wants; I symlinked 2.8 to 2.9 and jikes dies with a "symbol >not found." Is it usual for apps to be bundled with specific library >versions, or more usual that they aren't? Well, it is usually not nice to bundle an application with all of the libraries it needs since it just takes up disk space. Much of the point of shared libraries is to reduce download time and disk space and in-memory space and ease of fixing problems in the library. However, it also means that you have problems with library versions and incompatibilities. Yuck. Michael Sinz -- Director of Research & Development, NextBus Inc. mailto:[EMAIL PROTECTED] - http://www.nextbus.com My place on the web ---> http://www.users.fast.net/~michael_sinz
Re: ISO libstdc++-2.8 (to make jikes happy)
This may not be related, but when you recompile the kernel, it asks if you want to inlude dummy support. I'm not really clear on what it does, but it may be related to your problem. I know that it is only required occasionally, so it may not be compiled into your kernel. -dave On Fri, 1 Jan 1999, Robert Dodier wrote: > Hello all, > > Happy new year! > > I would like to run jikes on my RH 5.0 linux box, but jikes wants > libstdc++-2.8, while the current rpm contains libstdc++-2.7 and ...-2.9, > but not 2.8. :( > > I've tried downloading the source to build libstdc++-2.8 but > the build failed; some obscure (to me) message about "no source > file dummy.c; required for dummy.o" or some such. > > I've searched for libstdc++-2.8 without luck. Does someone have a > copy of the 2.8 rpm that I can copy? > > On a related note, perhaps jikes should be bundled with the libstdc++ > which it wants; I symlinked 2.8 to 2.9 and jikes dies with a "symbol > not found." Is it usual for apps to be bundled with specific library > versions, or more usual that they aren't? > > Many thanks for any advice, > Robert Dodier > >
Re: ISO libstdc++-2.8 (to make jikes happy)
On Fri, 1 Jan 1999, Robert Dodier wrote: > I would like to run jikes on my RH 5.0 linux box, but jikes wants > libstdc++-2.8, while the current rpm contains libstdc++-2.7 and ...-2.9, > but not 2.8. :( Grab it at ftp://ftp.tux.org/pub/distributions/redhat/redhat-5.2/i386/RedHat/RPMS/libstdc++-2.8.0-14.i386.rpm It comes with RH 5.2. I have both 2.7.x and 2.8.x on my system, as a matter of fact. I think egcs might use the 2.8 libraries, since the 2.7 libraries had broken exception handling, which is probably why jikes wants the later one -- but don't quote me on that. Brett W. McCoy http://www.lan2wan.com/~bmccoy/ --- "The number of UNIX installations has grown to 10, with more expected." -- The UNIX Programmer's Manual, 2nd Edition, June, 1972 -BEGIN GEEK CODE BLOCK- Version: 3.12 GAT dpu s:-- a C UL$ P+ L+++ E W++ N+ o K- w--- O@ M@ !V PS+++ PE Y+ PGP- t++ 5- X+ R+@ tv b+++ DI+++ D+ G++ e>++ h+(---) r++ y --END GEEK CODE BLOCK--
Re: ISO libstdc++-2.8 (to make jikes happy)
On Fri, 1 Jan 1999, David Harvill wrote: > This may not be related, but when you recompile the kernel, it asks if > you want to inlude dummy support. I'm not really clear on what it does, > but it may be related to your problem. I know that it is only required > occasionally, so it may not be compiled into your kernel. I think the dummy support in the kernel configuration is for networking (i.e., for making a faked network connection when your SLIP or PPP connection isn't up). Brett W. McCoy http://www.lan2wan.com/~bmccoy/ --- "The number of UNIX installations has grown to 10, with more expected." -- The UNIX Programmer's Manual, 2nd Edition, June, 1972 -BEGIN GEEK CODE BLOCK- Version: 3.12 GAT dpu s:-- a C UL$ P+ L+++ E W++ N+ o K- w--- O@ M@ !V PS+++ PE Y+ PGP- t++ 5- X+ R+@ tv b+++ DI+++ D+ G++ e>++ h+(---) r++ y --END GEEK CODE BLOCK--
Re: ISO libstdc++-2.8 (to make jikes happy)
Brett W. McCoy writes: > > I would like to run jikes on my RH 5.0 linux box, but jikes wants > > libstdc++-2.8, while the current rpm contains libstdc++-2.7 and ...-2.9, > > but not 2.8. :( > > Grab it at > > >ftp://ftp.tux.org/pub/distributions/redhat/redhat-5.2/i386/RedHat/RPMS/libstdc++-2.8.0-14.i386.rpm > > It comes with RH 5.2. I have both 2.7.x and 2.8.x on my system, as a > matter of fact. I think egcs might use the 2.8 libraries, since the 2.7 > libraries had broken exception handling, which is probably why jikes wants > the later one -- but don't quote me on that. you can also grap the jikes.src.rpm and rebuild it against 2.9 that comes with egcs1.1 or pgcc. works very well. -- Real programmers don't comment their code. It was hard to write, it should be hard to understand.