Author Topic: How to get demo programs running on Mac  (Read 8477 times)

Offline MrTAToad

  • byte
  • *
  • Posts: 6
    • View Profile
How to get demo programs running on Mac
« on: June 29, 2007, 04:05:58 pm »
Hello

How do you get the demo programs (that come with the SDK) running ? I've tried calling the files, but I just get an exception error.



Offline hytparadisee

  • int
  • **
  • Posts: 86
    • View Profile
    • http://peterhi.com
Re: How to get demo programs running on Mac
« Reply #1 on: June 29, 2007, 04:42:25 pm »
Do you mind giving the stack trace? (or at least what exceptions)
Today I finally found a problem to my soluuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuution

Offline MrTAToad

  • byte
  • *
  • Posts: 6
    • View Profile
Re: How to get demo programs running on Mac
« Reply #2 on: June 29, 2007, 04:44:24 pm »
The error I get is :

Exception in thread "main" java.lang.NoClassDefFoundError: fps/jar

Offline Melssj5

  • double
  • *****
  • Posts: 724
    • View Profile
Re: How to get demo programs running on Mac
« Reply #3 on: June 29, 2007, 04:49:24 pm »
The java.lang.NoClassDefFoundError you are getting is becausse you are not calling the app from the correct path!
Nada por ahora

Offline MrTAToad

  • byte
  • *
  • Posts: 6
    • View Profile
Re: How to get demo programs running on Mac
« Reply #4 on: June 29, 2007, 04:59:07 pm »
What is the correct path for a Mac - or rather, what is the full command line needed ?

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 12295
    • View Profile
    • http://www.jpct.net
Re: How to get demo programs running on Mac
« Reply #5 on: June 29, 2007, 07:50:25 pm »
I'm not sure myself. For Windows its like it's done in the bat-files. For Unix, it's similar, but with ":" as the path-seperator. Maybe it works that way on Mac too? I.e. something like java -cp fps.jar:lib/jpct.jar etc....!?

Offline MrTAToad

  • byte
  • *
  • Posts: 6
    • View Profile
Re: How to get demo programs running on Mac
« Reply #6 on: June 29, 2007, 08:10:54 pm »
I've tried :

java -Djava.library.path=..\..\lib\lwjgl-1.0 -cp ..\..\lib\lwjgl-1.0\lwjgl.jar:..\..\lib\jpct\jpct.jar:fps.jar -Xmx128m JPCTDemo width=512 height=384 mipmap zbuffer=16 refresh=60, and unfortunately, I get :

Exception in thread "main" java.lang.NoClassDefFoundError: com/threed/jpct/BufferedMatrix


Offline MrTAToad

  • byte
  • *
  • Posts: 6
    • View Profile
Re: How to get demo programs running on Mac
« Reply #7 on: June 29, 2007, 08:27:57 pm »
Good news - got it working in the end.

It was :

java -Djava.library.path=../../lib/lwjgl-1.0/ -cp ../../lib/lwjgl-1.0/lwjgl.jar:../../lib/jpct/jpct.jar:fps.jar -Xmx128m JPCTDemo width=512 height=384 mipmap zbuffer=16 refresh=60


Offline Melssj5

  • double
  • *****
  • Posts: 724
    • View Profile
Re: How to get demo programs running on Mac
« Reply #8 on: June 29, 2007, 10:07:21 pm »
Both llok exactly to me, which was the diference between this and the last one?
Nada por ahora

Offline MrTAToad

  • byte
  • *
  • Posts: 6
    • View Profile
Re: How to get demo programs running on Mac
« Reply #9 on: June 29, 2007, 11:59:08 pm »
It was probably the use of / instead of \ that did it.

Now to learn Java!

Offline hytparadisee

  • int
  • **
  • Posts: 86
    • View Profile
    • http://peterhi.com
Re: How to get demo programs running on Mac
« Reply #10 on: June 30, 2007, 05:11:56 am »
Ya ur right. Unix based never accepts "\"
Today I finally found a problem to my soluuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuution

Offline cyberkilla

  • float
  • ****
  • Posts: 413
    • View Profile
    • http://futurerp.net
Re: How to get demo programs running on Mac
« Reply #11 on: July 08, 2007, 04:30:02 am »
Which is understandable, because all characters are thought through.
Heck, I don't pretend to know everything about the thing, but...

The backslash \ character escapes the character to the right of it, so a path like that would be complicated.

C:\\something\\something\ else\\

"\ " escapes a space.

So, /home/user/file.ext is much better.
I run Ubuntu Feisty, and I'd be glad to help if somebody needs anything tested in Linux.


Also, the filesystem is better, in my opinion.

In windows, you have A-Z of drive letters.

A:\\ is normally floppy, C:\\ normally hdd partition 1, D:\\ & E:\\ normally cd drives.

In linux, every device seems to have a file pointer in /dev folder. These reference the device itself.
You can mount filesystems on a device, and link them to any folder you want.

And, ext3 filesystem is supposed to be so good at managing files that is almost never required a defragmentation - thats why its so rare to find a linux defrag tool.
http://futurerp.net - Text Based MMORPG
http://beta.rpwar.com - 3D Isometric MMORPG