Game Development Community

linux IDE for torque

by Tim Newell · in Torque Game Engine · 02/05/2002 (2:51 am) · 33 replies

Can anyone recommend an IDE that can be used with GCC that could be configured to work with torque...I have tried many of them and have not succeeded in finding one that will work yet.

-Tim aka Spock
Page «Previous 1 2
#1
02/05/2002 (5:13 am)
emacs? ;P
#3
02/05/2002 (3:44 pm)
I wrestled with kdevelop 2.0 briefly a few weeks ago, but couldn't get it to work to my satisfaction. I've settled on using xemacs, but I really don't think its a good solution for most people due to its unnecessarily steep learning curve.

After the linux feature development settles down I'll probably take another look at kdevelop, since I would really like to use it for torque. If you manage to make any progress with it or another IDE, please let me know.

- jq
#4
02/05/2002 (4:15 pm)
Emacs rocks! =)

I had to use VI today... VERY hard to figure out... very hard indeed.
#5
02/05/2002 (4:28 pm)
Bah, VI owns emacs for editing, but emacs is more flexable. I use both extensivly.

/1,$s/arrr/booya
#6
02/05/2002 (6:11 pm)
I have KDevelop working with torque.

It takes a few minutes to open the project due to a large number of files. Also if you make changes to a .h file it doesnt seem to want to recompile the files associated with it....is this due to the dependency thing in the make files talked about in the docs? You can edit a cc file and then click make and it will compile it and rebuild torque.

-Tim aka Spock
#7
02/06/2002 (7:09 am)
hah, when i telnet to the suns on campus, i use emacs exclusively, but my prof sings the praises of VI... heh, personal preference.... vi is easier to type from the console :) but who would work on a video game from the console...
ryan
#8
02/06/2002 (12:32 pm)
Tim, its great that you got kdevelop working! Are you able to debug as well? Is it reasonably stable?

Kdevelop can only support dependencies (AFAIK) with its own generated makefiles. It can use the existing torque makefiles but they have no support for dependency tracking. Thus we either need to add dependency tracking to the existing makefiles, or generate a kdevelop-compatible set of makefiles (hopefully in a way that doesn't pollute the entire source tree with kdevelop files.) I'm more a fan of the former, if it doesn't impair the use of kdevelop.
#9
02/06/2002 (2:51 pm)
As of right now I can't debug because I can't run the app in Kdevelop. The reason is because the app must be run from the example dir or it will get a segmentation fault...kdevelop wants to run it in the dir above example where the project file is. Right now I have it hackish to run the demo by putting a shell script as the executable and cding to the example dir in it and running the app. Do you know why you HAVE to be in the example dir to run the Demo? Make works fine and I added a clean option to the make files so Clean works now too. In Gnome it seems to run solid as long as you dont try to open conf.common.mk, it will crash if you do.

If we can't figure out a solution we might can get the source code to kdevelop and modify it for torque...not sure how tough that would be and if it would be worth it.

-Tim aka Spock
#10
02/06/2002 (5:59 pm)
The reason torque fails if it isn't in the example directory is because on line 380 of main.cc, it returns false and ultimately exits the program if it can't console exec "main.cs" in the current working directory. By the time it figures out that main.cs isn't there, though, its already initialized all of torque, but in returning it doesn't shut it all down properly, resulting in the infamous "some object not out of bins" assertion and a crash.

The windows behavior is similarly ugly, however I believe you do get an assert dialog on windows (on linux you don't probably because the platform windowing system hasn't been initialized yet; I might fix this).

I don't think I want to start messing around with kdevelop's source code. Another solution might be to add a -setcwd flag to the linux platform which could change the working directory on startup easily by issuing a setcwd() call.

If your pretty confident in that make clean modification you did, might as well check it in. I've grown accustomed to rm -rf 'find . -name "out.*"' but that way is fraught with peril.
#11
02/06/2002 (6:03 pm)
Well my simple clean is simply:


clean:
@-rm -rf engine/out.GCC2.DEBUG
@-rm -rf engine/out.GCC2.RELEASE
@-rm -rf lib/out.GCC2.DEBUG
@-rm -rf lib/out.GCC2.RELEASE


Im still messing around with kdevelop to see if I can get it to switch directories....Ive tried several things with no luck yet on the debugging front. If I can get to where I can add options to the debugger i can simple put a -cd=example which is supposed to switch working directories for the debugger (gdb)...I havent succeeded yet.

-Tim aka Spock
#12
02/06/2002 (6:06 pm)
I'll drop those make commands into the makefile in my next checkin.
#13
02/06/2002 (7:12 pm)
Quote:Another solution might be to add a -setcwd flag to the linux platform which could change the working directory on startup easily by issuing a setcwd() call.

I want to try this...can you elaborate more?

-Tim aka Spock
#14
02/07/2002 (12:46 pm)
Sure. In x86unixwindow.cc, there is a ParseCommandLine() function. This is called from main() in the same file. You just need to modify ParseCommandLine to look for a -chdir flag (or whatever you want to call it), and the value of the flag. Then you can issue a chdir() call to change to that directory immediately. Do "man chdir" for more information about this function.

Just a heads up: the existing code in ParseCommandLine is slightly broken, I think. It doesn't check for NULL before it strcpy's argument values.

Normally in torque, command line parameters are handle by .cs files, but in this case I think its ok to have the c++ code handle it. (Since finding the main.cs file is one of the problems you're trying to solve).
#15
02/07/2002 (2:53 pm)
Success!!!

It now runs from in Kdevelop and debugs fine too. I'm working on a doc right now on how to Get a Fully working Enviroment for Torque with a fresh install of Mandrake 8.1

Here is the outline:

1. Installing NVidia drivers.
2. Installing Torqe dependencies.
3. Getting and compiling OpenAL from loki cvs.
4. Getting and setting up Torque from GG CVS.
5. Setting up KDevelop to work with torque.
6. Compiling and Debugging Torque with KDevelop.

-Tim aka Spock
#16
02/07/2002 (3:00 pm)
Thanks a lot. When this doc is ready I'll try setting up Kdevelop. I like emacs for editing files but debugging with xxgdb isn't very user friendly :)
#17
02/07/2002 (3:03 pm)
Kdevelop adds a Visual C++ like interface....pretty nice.

-Tim aka Spock
#18
02/07/2002 (3:09 pm)
BTW, have you heard about the AMD Athlon bug that's causing crashes with nvidia drivers? It would be nice to include that in your tutorial so that people can know the workaround.
#19
02/07/2002 (3:18 pm)
Yeah I have heard about it but it hasnt affected me...not that I know of, I play Quake3, UT, and of course torque works. (I have both an nvidia card and an AMD processor) I'll put the bug fix at the end of the tutorial for people it does affect...thanks for the suggestion.

-Tim aka Spock
#20
02/08/2002 (2:21 pm)
Hey Tim, I checked in a -chdir command line parameter switch, please check it out and let me know if it works with kdevelop. I also fixed the existing make clean targets.

Thanks,

- jq
Page «Previous 1 2