Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: simple compilation error?



sam aspin wrote:

Hi Guys, im struggling to compile a couple of classes in a JNI example I'm following ( http://www.pacifier.com/~mmead/jni/cs510ajp/index.html#Example )

The first class HelloWorld.java compiles without any problems, however, when i try and compile TheMane.java i get the following errors

********************************************************************
sam-aspins-mac-mini:~/Jan06/com/manual samaspin$ javac HelloWorld.java
sam-aspins-mac-mini:~/Jan06/com/manual samaspin$ javac TheMane.java

If the classes are in a package called "com.manual", then you should:
- be in the directory "~/Jan06"
- compile using "javac -d . TheMane.java HelloWorld.java" to place your output files in the current directory, in package structure.
- run your code from same directory, using "java com.manual.TheMane"


Your problem is that the class path when you attempt to compile/run the application does not have in it a folder that contains "com/manual", your package structure...

Moises

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Java-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/java-dev/email@hidden

This email sent to email@hidden
References: 
 >simple compilation error? (From: "sam aspin" <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.