Welcome, Guest. Please login or register.

Login with username, password and session length

 
Advanced search

12045 Posts in 1593 Topics- by 594 Members - Latest Member: Rooreplarie

25. May 2013, 12:49:08 pm
Xith3D CommunityGeneral CategoryFeature Requests & Brilliant Ideas (Moderators: Marvin Fröhlich, 'n ddrylliog)Switching the ant build over to a full fleged NetBeans project?
Pages: [1] 2
Print
Author Topic: Switching the ant build over to a full fleged NetBeans project?  (Read 6784 times)
Mathias 'cylab' Henze
Fierce Warrior
****
Offline Offline

Posts: 540

1064620
View Profile WWW
« on: 13. May 2008, 02:37:16 pm »

This one goes to all ant/netbeans users out there.

I am currently thinking of dumping the generic ant build file and the netbeans freeform project and create a full netbeans project for xith and xith-tk. With the introduction of the shared libraries in netbeans 6.1, we could just use the netbeans generated build.xml instead of our hand rolled.

Benefits:
- better project management in netbeans
- augmentation of third-party libs with source and javadoc locations
- easier debugger and profiler runs

Some downfalls:
- won't work in Netbeans prior to 6.1!
- the netbeans extra ant tasks have to be added to the repository
- build settings will get a bit more complicated for non-netbeans ant users

So what do you think - change it or leave it?
Logged

badboyboogey
Enjoying the stay
*
Offline Offline

Posts: 40



View Profile
« Reply #1 on: 13. May 2008, 06:06:28 pm »

well i'm all for it because i have some major problems getting things to work smoothly the way it is Smiley (i have never been able to get xith-tk examples to work at all)
Logged
horati
Global Moderator
Getting respectable
*****
Offline Offline

Posts: 393


View Profile
« Reply #2 on: 13. May 2008, 07:44:52 pm »

I'm completely against it.  Build tools are naturally separate from editing tools.  We shouldn't do anything that restricts or implies restriction of users' choice of IDE -- or simple text editor.  While rolling the extra tags into the repository mitigates this, we would also need to roll in the documentation and make sure users are comfortable using these extended Ant tags.

I've never had any problems with the Ant build although I also use my own Eclipse project build for convenience.  What if we treat the ant build at the "true" build but also allow IDE-specific project files to be checked in to an IDE extras location?  This means the IDE builds will be behind the "true" build and some users will have localizations for their own projects that end up on the support forum anyway; however, it also seems to provide IDE independence while supporting the extras desired by various minorities in the Xith community.
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
Mathias 'cylab' Henze
Fierce Warrior
****
Offline Offline

Posts: 540

1064620
View Profile WWW
« Reply #3 on: 13. May 2008, 10:25:38 pm »

Thanks for your opinion. Actually I had the same arguments in mind, when I designed the current ant build scripts. And I also wanted to promote the ant project as the main build system, but it seems time proved otherwise, well...

Furthermore I don't think that a netbeans generated build file would undermine the build/editing tools separation:
netbeans standard build files are quite ok and well suited for modularity. Afaik only the copylibs task is needed, which has to do with the projects library configuration. From my experience ant builds tend to inclusion of extensions anyway and I am nopt talking about maven integration here Wink

Also the current build files documentation is nonexistent (despite of me answering posts and pms) and the netbeans build file at least has some doku, and I could add a quick-guide for "ant-only" usage.

Having said that, I think such a move has to be put to the test before officially applying it. Also I would like some more opinions, since its 1:1 right now (I abstain from voting for now)
Logged

horati
Global Moderator
Getting respectable
*****
Offline Offline

Posts: 393


View Profile
« Reply #4 on: 13. May 2008, 10:58:57 pm »

If it's truly only a copy libs task, then I wouldn't care.

As far as documentation of the build, I was actually referring to the ant task documentation I can find at apache.  I hope a copy libs task would be pretty self explanatory... not that I'm saying the build shouldn't be documented as well.  I just didn't want an undocumented build with lots of undocumented tasks making it very annoying to reverse engineer.

Edit:

I forgot to mention: Troubleshooting any problems reported on the forum cannot be "Step 1: Download NetBeans"
« Last Edit: 13. May 2008, 11:09:40 pm by horati » 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
Mathias 'cylab' Henze
Fierce Warrior
****
Offline Offline

Posts: 540

1064620
View Profile WWW
« Reply #5 on: 13. May 2008, 11:20:01 pm »

I forgot to mention: Troubleshooting any problems reported on the forum cannot be "Step 1: Download NetBeans"

No certainly not. If it isn't possible to create a self contained ant build project from the standard netbeans project which can be fully configured outside of netbeans, it would be a no-go.
Logged

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

Posts: 540

1064620
View Profile WWW
« Reply #6 on: 05. August 2008, 02:12:29 pm »

I just finished some tests on this. The Netbeans standard buildfiles are reasonable self contained and allow to build without Netbeans (commandline or ant integration of other IDEs). While the "build-impl.xml" file generated by Netbeans seems to be fairly complex (and should not be edited due to regeneration on any project change), the import/derive paradigma is quite nice and allows for all customization we would need. The only downside I can see so far is, that if you want to work with Netbeans, you have to use at least version 6.1.

So if there aren't any objections on this (such as users still working wioth NB 5.5 or 6.0), I will port the release generation to the Netbeans build-file and commit the changes in the next few days.
Logged

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

Posts: 540

1064620
View Profile WWW
« Reply #7 on: 08. August 2008, 10:27:18 am »

I committed the changes. Please everyone using ant or netbeans try it out and report problems.

Just calling "ant" in xith-tk will create a full distribution file set under "xith-tk/dist/release". "ant release" will create a release zip.

To run the testlauncher you can use "ant run". To make it run with linux/macosx you have to open the "nbproject" folder and copy (please don't just rename it!) the desired "nblibraries-private-<platform>.properties" to "nblibraries-private.properties". This way you will override the standard classpath/library.path settings without having to change the build itself.
Logged

Marvin Fröhlich
Xith Lord
Administrator
Guru
*****
Offline Offline

Posts: 4403


May the 4th, be with you...


View Profile
« Reply #8 on: 08. August 2008, 12:58:05 pm »

"ant release" will create a release zip.

A zip Huh This is not so good. I switched away fro .zip to .tar.bz2 some releases ago, since zip compresses way too bad. Is there a way to make ant compress with .tar.bz2?

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

Posts: 540

1064620
View Profile WWW
« Reply #9 on: 08. August 2008, 01:14:46 pm »

Sure. Just comitted the change, but since it only saved < 10% space and is not very familar for windows and macos users, I would prefer using a zip archive.
« Last Edit: 08. August 2008, 01:27:19 pm by Mathias 'cylab' Henze » Logged

Marvin Fröhlich
Xith Lord
Administrator
Guru
*****
Offline Offline

Posts: 4403


May the 4th, be with you...


View Profile
« Reply #10 on: 08. August 2008, 01:40:59 pm »

Sure. Just comitted the change, but since it only saved < 10% space and is not very familar for windows and macos users, I would prefer using a zip archive.

I just checked it with an older release and it saved 20%. But I thought I remembered larger savings. And your'e right. zip should be used.

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

Posts: 4403


May the 4th, be with you...


View Profile
« Reply #11 on: 08. August 2008, 02:44:23 pm »

I just tried to call "ant" in the xith-tk folder and got this:
Code:
-do-compile:
    [javac] Compiling 946 source files to /media/sda6/workspace/xith3d/build/classes
    [javac] /media/sda6/workspace/xith3d/src/org/xith3d/ui/hud/menusystem/menus/settings/InputBindingsSettingsMenu.java:373: cannot find symbol
    [javac] symbol  : constructor InputBindingsSettingsMenu(float,float,int,org.jagatoo.commands.CommandsRegistry<capture of ? extends org.jagatoo.input.actions.LabeledInputAction>)
    [javac] location: class org.xith3d.ui.hud.menusystem.menus.settings.InputBindingsSettingsMenu
    [javac]         this( width, height, 0, commandsReg );
    [javac]         ^
    [javac] /media/sda6/workspace/xith3d/src/org/xith3d/ui/hud/menusystem/menus/settings/InputBindingsSettingsMenu.java:385: cannot find symbol
    [javac] symbol  : constructor InputBindingsSettingsMenu(float,float,int,org.jagatoo.commands.CommandsRegistry<capture of ? extends org.jagatoo.input.actions.LabeledInputAction>)
    [javac] location: class org.xith3d.ui.hud.menusystem.menus.settings.InputBindingsSettingsMenu
    [javac]         this( width, 0f, 0, commandsReg );
    [javac]         ^
    [javac] /media/sda6/workspace/xith3d/src/org/xith3d/ui/hud/menusystem/menus/settings/InputBindingsSettingsMenu.java:397: cannot find symbol
    [javac] symbol  : constructor InputBindingsSettingsMenu(float,int,org.jagatoo.commands.CommandsRegistry<capture of ? extends org.jagatoo.input.actions.LabeledInputAction>)
    [javac] location: class org.xith3d.ui.hud.menusystem.menus.settings.InputBindingsSettingsMenu
    [javac]         this( width, 0, commandsReg );
    [javac]         ^
    [javac] 3 errors

BUILD FAILED
/media/sda6/workspace/xith-tk/build.xml:137: The following error occurred while executing this line:
/media/sda6/workspace/xith3d/nbproject/build-impl.xml:337: The following error occurred while executing this line:
/media/sda6/workspace/xith3d/nbproject/build-impl.xml:174: Compile failed; see the compiler error output for details.

But the code compiles fine in eclipse. Any idea?

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

Posts: 540

1064620
View Profile WWW
« Reply #12 on: 10. August 2008, 11:16:00 pm »

What java version did you use? It compiles fine with 1.6 b06, but I get the same error with 1.5. The problem seems to be a bug in the sun compiler, so you have to use the latest jdk 1.6 (or the one bundled with eclipse) to compile with ant :/ The resulting bytecode is still 1.5 nonetheless. I think we had problems with this or something similar before: http://xith.org/forum/index.php/topic,609.0.html
Logged

Marvin Fröhlich
Xith Lord
Administrator
Guru
*****
Offline Offline

Posts: 4403


May the 4th, be with you...


View Profile
« Reply #13 on: 10. August 2008, 11:26:27 pm »

Yes, I am using 1.5. And you're right. We had these problems once ago. I will try it with 1.6.

Marvin
Logged
'n ddrylliog
Moderator
Guru
*****
Offline Offline

Posts: 1188



View Profile WWW Email
« Reply #14 on: 14. October 2008, 04:39:44 pm »

@Mathias : is it hard to produce both .zip and .tar.bz2 archives ? I have often seen that in open source projects.
Logged
Pages: [1] 2
Print
Jump to:  

Theme orange-lt created by panic