X-Spam-Check-By: sourceware.org X-YMail-OSG: jU1KU.wVM1l94EyIhpUzQgxW5deN5PJ3yXJtB.zNoLRDo3VoasTxwmLzgjsmCtFA43RgPqD4.JAf2vrfgG_TEmCYOLI15UgDL0TG3Eyf_fYIAZjGuibxflcoPxdfeg-- Date: Thu, 5 Jul 2007 05:17:23 -0700 (PDT) From: Dan N Subject: Problem: Java interpreter does not work To: cygwin AT cygwin DOT com MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Message-ID: <476590.78864.qm@web42104.mail.mud.yahoo.com> Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com I tried to run Java interpreter, but it doesn't work. Here is how it looks like: [~/Java] cat HelloWorld.java public class HelloWorld { public static void main(String[] args) { System.out.println("Hello world!"); } // main } [~/Java] jikes -bootclasspath /usr/share/java/libgcj-3.4.4.jar HelloWorld.java [~/Java] gij HelloWorld.class Exception in thread "main" java.lang.NoClassDefFoundError: HelloWorld.class <> [~/Java] jcf-dump HelloWorld.class Reading .class from HelloWorld.class. Magic number: 0xcafebabe, minor_version: 0, major_version: 48. Constant pool (count: 29): #1: Utf8: "HelloWorld" #2: Class name: 1="HelloWorld" #3: Utf8: "java/lang/Object" #4: Class name: 3="java/lang/Object" #5: Utf8: "main" #6: Utf8: "([Ljava/lang/String;)V" #7: Utf8: "Code" #8: Utf8: "LineNumberTable" #9: Utf8: "out" #10: Utf8: "Ljava/io/PrintStream;" #11: NameAndType name: 9=out, signature: 10=java.io.PrintStream #12: Utf8: "java/lang/System" #13: Class name: 12="java/lang/System" #14: Fieldref class: 13=java.lang.System name_and_type: 11= #15: Utf8: "Hello world!" #16: String 15="Hello world!" #17: Utf8: "println" #18: Utf8: "(Ljava/lang/String;)V" #19: NameAndType name: 17=println, signature: 18=(java.lang.String)void #20: Utf8: "java/io/PrintStream" #21: Class name: 20="java/io/PrintStream" #22: Methodref class: 21=java.io.PrintStream name_and_type: 19= #23: Utf8: "" #24: Utf8: "()V" #25: NameAndType name: 23=, signature: 24=()void #26: Methodref class: 4=java.lang.Object name_and_type: 25=< ()void> #27: Utf8: "SourceFile" #28: Utf8: "HelloWorld.java" Access flags: 0x21 public super This class: 2=HelloWorld, super: 4=java.lang.Object Interfaces (count: 0): Fields (count: 0): Methods (count: 2): Method name:"main" public static Signature: 6=(java.lang.String[])void Attribute "Code", length:37, max_stack:2, max_locals:1, code_length:9 Attribute "LineNumberTable", length:10, count: 2 Method name:"" public Signature: 24=()void Attribute "Code", length:33, max_stack:1, max_locals:1, code_length:5 Attribute "LineNumberTable", length:10, count: 2 Attributes (count: 1): Attribute "SourceFile", length:2, #28="HelloWorld.java" [~/Java] ____________________________________________________________________________________ Never miss an email again! Yahoo! Toolbar alerts you the instant new Mail arrives. http://tools.search.yahoo.com/toolbar/features/mail/ -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/