Welcome, Guest. Please login or register.

Login with username, password and session length

 
Advanced search

11991 Posts in 1587 Topics- by 3508 Members - Latest Member: NevilleKemp

26. May 2012, 02:35:30 pm
Xith3D CommunityGeneral CategorySupport (Moderator: Marvin Fröhlich)Problem compiling
Pages: 1 [2]
Print
Author Topic: Problem compiling  (Read 3285 times)
oliver1974
Just dropped in

Offline Offline

Posts: 21


View Profile
« Reply #15 on: 19. February 2007, 08:07:27 pm »

I'm working on the build.xml's of xith3d and xithtk... I've been successful
building both with ant already, so i'll post the (very few) changes soon.
Logged
Marvin Fröhlich
Xith Lord
Administrator
Guru
*****
Online Online

Posts: 4381


May the 4th, be with you...


View Profile
« Reply #16 on: 19. February 2007, 08:13:46 pm »

I'm working on the build.xml's of xith3d and xithtk... I've been successful
building both with ant already, so i'll post the (very few) changes soon.

Cool. Thanks Smiley. I will commit them to the SVN trunk, then.

Marvin
Logged
oliver1974
Just dropped in

Offline Offline

Posts: 21


View Profile
« Reply #17 on: 19. February 2007, 10:29:35 pm »

So, it's even worse than i thought....

The invalid build.xml files even prevent netbeans from building the project directly
after checking it out via the svn plugin (netbeans 5.5 has no svn support by default, you add it later via the update function and after installing
the svn tools..)

Netbeans does a normal ant run on the project if you click "Build Main Project"...
, and this run fails with the same errors as the "normal" ant run
on the command line..

Eclipse works out of the box? Really? I still didn't check that, but this can't be
a "normal" ant build..

It seems that we are really locked in eclipse at the moment...


The changes:

build.xml of xith3d:
-------------------------
Change line 28
<pathelement location="third-party/vecmath/vecmath-kh.jar"/>
to
<pathelement location="third-party/math/openmali.jar"/>

build.xml of xith-tk:
--------------------------
Change line 25
<pathelement location="${xith3d.location}/third-party/vecmath/vecmath-kh.jar"/>
to
<pathelement location="${xith3d.location}/third-party/math/openmali.jar"/>


Well, this line (line 10) is a problem:
<property name="xith3d.location" value="../xith3d"/>

Where should the root of the xith-tk folder be? Because the value of xith3d.location
is (of course) dependant of this folder...

If the xith3d and the xith-tk folder are intended to be installed side by side,
the path should be somewhat like this (in case you named the xith3d folder
really "xith3d", which is recommended to avoid confusion):

<property name="xith3d.location" value="../../xith3d/0.9.0"/>

We need "0.9.0" because of the branch of the actual svn trunk.

Both xith-tk and xith3d should build now with no errors.. you will
get deprecation warnings for xith-tk using JDK1.5, and a whole bunch
of deprecation warnings with JDK1.6 for xith3d AND xith-tk, but it should
compile nonetheless.

Logged
Marvin Fröhlich
Xith Lord
Administrator
Guru
*****
Online Online

Posts: 4381


May the 4th, be with you...


View Profile
« Reply #18 on: 19. February 2007, 11:02:46 pm »

Are you working with the 0.9.0 branch? Please don't. Use the trunk.

Marvin
Logged
oliver1974
Just dropped in

Offline Offline

Posts: 21


View Profile
« Reply #19 on: 20. February 2007, 06:39:24 am »

Sigh....

I worked with the link in the sticky forum entry in the news subforum.
http://www.xith.org/forum/index.php?topic=136.0

..Checking trunk out now..
Logged
oliver1974
Just dropped in

Offline Offline

Posts: 21


View Profile
« Reply #20 on: 20. February 2007, 08:18:24 am »

So, build-wise this looks MUCH better.. Thank you. Where did i overlook that info which svn - link to choose?

Both projects (xith3d and xith-tk) open and build in netbeans, but you may have
to adapt build-defaults.properties of xith-tk before, don't you?

(EDIT: No, you don't have to... But you've got to get your directories right
of course.. both root directories have to be on the same level and
you've got to avoid deeper "nesting".. something like this
(...) Projects/xith3d/xith3d/  in conjunction with Projects/xith-tk/ won't work
because core.location, core.classes and core.deps entries of build-defaults-properties will get invalid..)

The last hurdle is starting the demos within the xith-tk project.
I get the launcher, but after selecting the BaseStart demo..

Code:
java.lang.ClassCastException: org.xith3d.scenegraph.TransformGroup
        at org.xith3d.render.base.Xith3DEnvironment.addChild(Xith3DEnvironment.java:694)
        at org.xith3d.test.base.BaseTest.initBeforeCanvas(BaseTest.java:107)
        at org.xith3d.test.base.BaseTest.<init>(BaseTest.java:142)
        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
        at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
        at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
sdfsdsdf
        at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
        at org.xith3d.test.Xith3DTestLauncher.runTest(Xith3DTestLauncher.java:807)
        at org.xith3d.test.Xith3DTestLauncher.onStartButtonClicked(Xith3DTestLauncher.java:178)
        at org.xith3d.utility.canvas.DisplayOptions.waitForStart(DisplayOptions.java:977)
        at org.xith3d.utility.canvas.DisplayOptions.<init>(DisplayOptions.java:1006)
        at org.xith3d.test.Xith3DTestLauncher.<init>(Xith3DTestLauncher.java:709)
        at org.xith3d.test.Xith3DTestLauncher.main(Xith3DTestLauncher.java:861)


Another issue (but minor) is the case that teststarter.bat and teststarter.sh
are broken, there's still a classpath to vecmath/vecmath.jar in there and
not to math/openmali.jar, and Xith3DTestStarter is called not Xith3DTestLauncher...
But maybe i'm overlooking something again.

AND ANOTHER EDIT:
Hmmm, it seems that the "run" target doesn't work for me, maybe because i didn't check out within the IDE but via "Tortoise" (yes, i'm on a windows machine at the moment..) and exported the directories in my projects directory... I've got
to check the classpath stuff, i think.
It's definitely a classpath problem, while im within the xith-tk project the
demo projects don't get the packages of the xith3d core...


By the way: The project.xml files still contains a link to the old vecmath stuff?
Code:
<classpath mode="compile">third-party/jogl/jogl.jar;third-party/joal/windows/joal.jar;third-party/lwjgl/lwjgl.jar;third-party/misc/log4j.jar;third-party/misc/vorbis.jar;third-party/vecmath/vecmath-kh.jar
</classpath>
« Last Edit: 20. February 2007, 09:57:16 am by oliver1974 » Logged
oliver1974
Just dropped in

Offline Offline

Posts: 21


View Profile
« Reply #21 on: 20. February 2007, 10:55:50 am »

Hmmm, not so sure about the classpath problem any more....
I created a xith3d.jar and added it to the xith-tk classpath,
which worked fine and there doesn't seem to be any more
missing classpaths.. but i still get those ClassCastExceptions..
Logged
Marvin Fröhlich
Xith Lord
Administrator
Guru
*****
Online Online

Posts: 4381


May the 4th, be with you...


View Profile
« Reply #22 on: 20. February 2007, 11:19:41 am »

The last hurdle is starting the demos within the xith-tk project.
I get the launcher, but after selecting the BaseStart demo..

Code:
java.lang.ClassCastException: org.xith3d.scenegraph.TransformGroup
        at org.xith3d.render.base.Xith3DEnvironment.addChild(Xith3DEnvironment.java:694)
        at org.xith3d.test.base.BaseTest.initBeforeCanvas(BaseTest.java:107)
        at org.xith3d.test.base.BaseTest.<init>(BaseTest.java:142)
        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
        at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
        at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
sdfsdsdf
        at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
        at org.xith3d.test.Xith3DTestLauncher.runTest(Xith3DTestLauncher.java:807)
        at org.xith3d.test.Xith3DTestLauncher.onStartButtonClicked(Xith3DTestLauncher.java:178)
        at org.xith3d.utility.canvas.DisplayOptions.waitForStart(DisplayOptions.java:977)
        at org.xith3d.utility.canvas.DisplayOptions.<init>(DisplayOptions.java:1006)
        at org.xith3d.test.Xith3DTestLauncher.<init>(Xith3DTestLauncher.java:709)
        at org.xith3d.test.Xith3DTestLauncher.main(Xith3DTestLauncher.java:861)


Sorry. That was a result of a yesterday's quickfix. It is fixed now.

Another issue (but minor) is the case that teststarter.bat and teststarter.sh
are broken, there's still a classpath to vecmath/vecmath.jar in there and
not to math/openmali.jar, and Xith3DTestStarter is called not Xith3DTestLauncher...
But maybe i'm overlooking something again.

Wow, I didn't even remind, that these ones are on SVN. Never mind... It's fixed.

AND ANOTHER EDIT:
Hmmm, it seems that the "run" target doesn't work for me, maybe because i didn't check out within the IDE but via "Tortoise" (yes, i'm on a windows machine at the moment..) and exported the directories in my projects directory... I've got
to check the classpath stuff, i think.
It's definitely a classpath problem, while im within the xith-tk project the
demo projects don't get the packages of the xith3d core...


By the way: The project.xml files still contains a link to the old vecmath stuff?
Code:
<classpath mode="compile">third-party/jogl/jogl.jar;third-party/joal/windows/joal.jar;third-party/lwjgl/lwjgl.jar;third-party/misc/log4j.jar;third-party/misc/vorbis.jar;third-party/vecmath/vecmath-kh.jar
</classpath>

I have fixed this vecmath thing in project.xml. But the run target thing should work. Cannot tell you, if that works, if imported from turtoise. Did you know, there's a NetBeans SVN plugin?

Marvin
Logged
horati
Global Moderator
Getting respectable
*****
Offline Offline

Posts: 393


View Profile
« Reply #23 on: 20. February 2007, 11:32:40 am »

Hmmm, it seems that the "run" target doesn't work for me, maybe because i didn't check out within the IDE but via "Tortoise" (yes, i'm on a windows machine at the moment..) and exported the directories in my projects directory... I've got to check the classpath stuff, i think.

Cannot tell you, if that works, if imported from turtoise. Did you know, there's a NetBeans SVN plugin?

I use the Mac OS X equivalent of Tortoise without any problems at all.  I had one of the guys working for me on my project use Tortoise to check out and compile Xith 3D and it worked fine.  So, I don't think that's the issue.  Here is the trick:

  • create projects named xith3d and xith-tk (case sensitive) in Eclipse
  • exit Eclipse
  • do your checkout on top of the newly created directories
  • start Eclipse and watch it detect all the new files Smiley

Like you Oliver, I prefer IDEs to be IDEs and version control tools to be version control tools; however, I'm going to break down and install Subclipse one of these days soon.  Then, I'll be using Subclipse, SCplugin (Mac version of TortoiseSVN), and command line SVN all at the same time.
Logged

Kevin
"It may not seem like a big deal, but ignorance of character encoding issues leads to insidious code rot akin to y2k."
http://stackoverflow.com/users/3474/sylvarking
oliver1974
Just dropped in

Offline Offline

Posts: 21


View Profile
« Reply #24 on: 20. February 2007, 01:08:45 pm »

Well, MUCH better know, i finally got xith-tk working!!  Grin

Quote
    * create projects named xith3d and xith-tk (case sensitive) in Eclipse
    * exit Eclipse
    * do your checkout on top of the newly created directories
    * start Eclipse and watch it detect all the new files Smiley

... I already figured that out myself, but thanks! (It's very similar in netbeans).
But instead of projects you just have to create directories named xith3d and
xith-tk, check the projects out into them and open the projects in Netbeans (because
there's already a project file within these freshly checked out packages..)



And yes, i know the netbeans svn plugin... You still need the commandline
svn executables though! The plugin is just a kind of wrapper/frontend..
(Don't know about subclipse, still got to look at it..)

There are some examples which don't work on my notebook here,
but i guess this is just a graphics hardware problem... But i wonder
what is so special about "BulletTest" so that it doesn't work?
I don't get bullets there, just a

Code:
java.lang.NullPointerException: Null RenderAtom... FrustumCuller.addShapeAtom()

exception after some hacking on SPACE...

On a sidenote.. Some demos don't return to the launcher, although the corresponding checkbox
in the launcher is active? Is this a known behaviour?

But i think that doesn't belong in "problems compiling" any more....
Logged
Marvin Fröhlich
Xith Lord
Administrator
Guru
*****
Online Online

Posts: 4381


May the 4th, be with you...


View Profile
« Reply #25 on: 20. February 2007, 06:40:56 pm »

Well, MUCH better know, i finally got xith-tk working!!  Grin

Cool Smiley.

And yes, i know the netbeans svn plugin... You still need the commandline
svn executables though! The plugin is just a kind of wrapper/frontend..
(Don't know about subclipse, still got to look at it..)

Subclipse is a full featured SVN client. So you don't need to use any other tool together with it.

There are some examples which don't work on my notebook here,
but i guess this is just a graphics hardware problem... But i wonder
what is so special about "BulletTest" so that it doesn't work?
I don't get bullets there, just a

Code:
java.lang.NullPointerException: Null RenderAtom... FrustumCuller.addShapeAtom()

exception after some hacking on SPACE...

I will have a look at the null RenderAtom thing. You don't see anything because on some graphics cards (or drivers) the OpenGL LineArray doesn't seem to work. That's known.

Are there any other tests, that don't work?

Marvin
Logged
oliver1974
Just dropped in

Offline Offline

Posts: 21


View Profile
« Reply #26 on: 20. February 2007, 09:25:42 pm »

Quote

Are there any other tests, that don't work?


..Well, i will have to do a list, to get that together...
It's not of very high importance to me, because i think this is
just an issue with my weak intel based graphics chipset on the notebook,
i didn't expect to see every demo working, i knew that before....

I will see if i can do this list, but i'll start working through
some examples now, my click-and-try phase is (hopefully) over now
and i will start coding. So don't expect results too early.
Logged
Mathias 'cylab' Henze
Fierce Warrior
****
Offline Offline

Posts: 540

1064620
View Profile WWW
« Reply #27 on: 20. February 2007, 11:47:00 pm »

Both projects (xith3d and xith-tk) open and build in netbeans, but you may have
to adapt build-defaults.properties of xith-tk before, don't you?

(EDIT: No, you don't have to... But you've got to get your directories right
of course.. both root directories have to be on the same level and
you've got to avoid deeper "nesting".. something like this
(...) Projects/xith3d/xith3d/  in conjunction with Projects/xith-tk/ won't work
because core.location, core.classes and core.deps entries of build-defaults-properties will get invalid..)
You can also adapt the build properties by creating a "xith3d.properties"/"xith3d-tk.properties" in your HOME or create a "developer-settings/<your username>/user.properties" under the projects main directory. This way you can have organize your projects as you like.
Logged

Mathias 'cylab' Henze
Fierce Warrior
****
Offline Offline

Posts: 540

1064620
View Profile WWW
« Reply #28 on: 21. February 2007, 12:14:30 am »

Quote
Hmmm, it seems that the "run" target doesn't work for me, maybe because i didn't check out within the IDE but via "Tortoise" (yes, i'm on a windows machine at the moment..) and exported the directories in my projects directory...
If you set up your build properties according to your directory layout (use one of the scenarios for user related settings, don't edit the build-defaults.properties) the run target should start the org.xith3d.test.Xith3DTestLauncher class. You have to build xith3d first using it's "build" target, since the toolkit assumes xith3ds compiled classes under it's "bin" folder as long as you don't change the core.classes property. If you plan to use the "build.core" property to automatically build xith3d along with xith3d-tk, you should update xith3d-tks build.xml, since I made a typo that cleans the core classes just before launching the Xith3DTestLauncher  Roll Eyes

Quote
I've got to check the classpath stuff, i think.
It's definitely a classpath problem, while im within the xith-tk project the
demo projects don't get the packages of the xith3d core...
Yeah the netbeans project depends on the directory layout on my machine, which unfortunately has an extra "trunk" directory under each project :/ But this should only affect the editor and be independent of the ant compilation. I'll dig into the netbeans freeform project documentation to come up with a solution. In the meantime, just build the core and add it's "bin" folder to xith3d-tks "source classpath" via "build" node in netbeans "project properties" dialog.
Logged

Pages: 1 [2]
Print
Jump to:  

Theme orange-lt created by panic