View previous topic - View next topic |
Author |
Message |
DeveloperX 202192397
Joined: 04 May 2003 Posts: 1626 Location: Decatur, IL, USA
|
Posted: Thu Aug 25, 2005 9:57 am Post subject: KDevelop |
[quote] |
|
Ok, I absolutely hate this f**king piece of software!
To make a measly 'Simple KDE Application' displaying a "Hello World" string on a window, this damn program took 45 minutes to build the project, and then 2 minutes to execute the built project executable.
I checked the project directory, and its 7MB!!!!!! 98 Files for a f**king hello world program!
Is there a better linux project development tool out there? Or is there a way to make KDevelop ONLY generate the files I want? (*.cpp, *.h, executable binary)
Please, someone out there who builds anything on a linux platform has to know something I don't here, please offer up your advice. (No flamewars about this post, please.)
I cannot afford to waste 45 minutes to build a hello world project, much less waste 7MB of harddrive space on a test-application.
Thank GOD I didnt tell it to build a full-blown application framework project.....I dread that thought.
Anyone know any linux game programming tutorials? And how DO you get allegro up and running on linux?? I cannot seem to get it working..I installed an rpm for allegro, and tried to compile a simple test, using gcc.......noluck. :\
Bjorn, I know you're a linux user, share your secrets of success, please. _________________ Principal Software Architect
Rambling Indie Games, LLC
See my professional portfolio
|
|
Back to top |
|
|
DrunkenCoder Demon Hunter
Joined: 29 May 2002 Posts: 559
|
Posted: Thu Aug 25, 2005 1:26 pm Post subject: |
[quote] |
|
I belive code::blocks is available else Anjuta is quite nice. _________________ If there's life after death there is no death, if there's no death we never live. | ENTP
|
|
Back to top |
|
|
LeoDraco Demon Hunter
Joined: 24 Jun 2003 Posts: 584 Location: Riverside, South Cali
|
Posted: Thu Aug 25, 2005 9:18 pm Post subject: |
[quote] |
|
I am a little confused about exactly what you want; are you attempting to write some sort of console based application? (I don't think this is what you are attempting, but...) If that is the case, a simple text editor and a console is all you need. Open Vi/Emacs (whatever your preference) and write your c++ source; then, in another tab/editor/etc. write a Makefile to automate your build instructions. This will be (relatively) hairy at first, but you will fast loose interest in IDEs after a few goes at it. Then, from your console, simply type "make" in the directory containing your source/Makefile, and you should be in business.
As I don't use Allegro, I cannot be entirely helpful; however, are you sure you are linking in the library correctly? When linking libraries with gcc (assuming that the library binary is installed in the paths that gcc checks), you would simply have to include the flag "-llibname"; this would probably be something like "-lallegro". (But, as I don't use Allegro, it might be more difficult than that...)
Edit: Also, keep in mind that most applications in Linux come with man/info pages, which are actually quite helpful for figuring out how to use the systems. For the more graphical applications, I'm pretty sure the distro's/maintainers do a fair job of including good documentation. Consulting the help files, man/info pages, etc. is always a good idea... _________________ "...LeoDraco is a pompus git..." -- Mandrake
|
|
Back to top |
|
|
DeveloperX 202192397
Joined: 04 May 2003 Posts: 1626 Location: Decatur, IL, USA
|
Posted: Fri Aug 26, 2005 5:13 am Post subject: |
[quote] |
|
LeoDraco wrote: | I am a little confused about exactly what you want; are you attempting to write some sort of console based application? (I don't think this is what you are attempting, but...) If that is the case, a simple text editor and a console is all you need. Open Vi/Emacs (whatever your preference) and write your c++ source; then, in another tab/editor/etc. write a Makefile to automate your build instructions. This will be (relatively) hairy at first, but you will fast loose interest in IDEs after a few goes at it. Then, from your console, simply type "make" in the directory containing your source/Makefile, and you should be in business.
As I don't use Allegro, I cannot be entirely helpful; however, are you sure you are linking in the library correctly? When linking libraries with gcc (assuming that the library binary is installed in the paths that gcc checks), you would simply have to include the flag "-llibname"; this would probably be something like "-lallegro". (But, as I don't use Allegro, it might be more difficult than that...)
Edit: Also, keep in mind that most applications in Linux come with man/info pages, which are actually quite helpful for figuring out how to use the systems. For the more graphical applications, I'm pretty sure the distro's/maintainers do a fair job of including good documentation. Consulting the help files, man/info pages, etc. is always a good idea... |
1. I know about using Makefiles (sorta..its a bizarre concept for me really)
2. I'm linking correctly, it seems that allegro isn't getting installed 100%......but there are no errors installing. :\ no allegr.h file anywhere on the system, even after trying to install it 4 times.
3. the help system for KDevelop was useless to me. vague topics, and unrelated topics don't help.
I think I'm going to ditch IDEs as you say, as Makefiles seem to be much better, and cleaner.
Now if only I could get Allegro to install properly...Bjorn?... Mandrake? I know you two have had it running in linux..am I mistaken? _________________ Principal Software Architect
Rambling Indie Games, LLC
See my professional portfolio
|
|
Back to top |
|
|
LeoDraco Demon Hunter
Joined: 24 Jun 2003 Posts: 584 Location: Riverside, South Cali
|
Posted: Fri Aug 26, 2005 6:55 am Post subject: |
[quote] |
|
When you installed the allegro rpm, did you just install the allegro rpm, or did you also install the allegro-devel rpm? Many libraries packaged in rpm separate the .so's from the development files, which, obviously, would be packaged in the *-devel rpms. So, if you have not done that, my suggestion would be to attempt it. (I bring this up as the download page for the allegro sourceforge site lists separate packages. This is probably not an issue if you got a source rpm.)
edit: also! unless you grabbed the rpm from your distro's package management app (something like yum; I'm not familiar with SUSE, but maybe YaST?), you might have aquired an rpm that was not built intentionally for your distro. While this might not (always) be a problem, not all rpm-based distro's have the same directory hierarchy nor the same naming conventions.
edit2: After another brief search, I came across these notes regarding the linux version of allegro. They might be helpful to you. _________________ "...LeoDraco is a pompus git..." -- Mandrake
Last edited by LeoDraco on Fri Aug 26, 2005 8:52 am; edited 1 time in total
|
|
Back to top |
|
|
Rainer Deyke Demon Hunter
Joined: 05 Jun 2002 Posts: 672
|
Posted: Fri Aug 26, 2005 7:32 am Post subject: |
[quote] |
|
How to install just about anything on Linux or any other UNIX-like environment:- Grab the source distro and unpack it somewhere.
- Enter the directory where you unpacked the source.
- Run ./configure.
- Run make.
- Run make install as root.
- Optionally delete the unpacked directory, as it is no longer needed.
|
|
Back to top |
|
|
Bjorn Demon Hunter
Joined: 29 May 2002 Posts: 1425 Location: Germany
|
Posted: Fri Aug 26, 2005 9:21 am Post subject: |
[quote] |
|
Rainer Deyke wrote: | How to install just about anything on Linux or any other UNIX-like environment:- Grab the source distro and unpack it somewhere.
- Enter the directory where you unpacked the source.
- Run ./configure.
- Run make.
- Run make install as root.
- Optionally delete the unpacked directory, as it is no longer needed.
|
If you go installing software this way it can be potentially hard to upgrade or remove it later. The following software helps you to keep things you install from source organized:
http://www.gnu.org/software/sourceinstall/sourceinstall.html
It would however probably still be prefered to use the distribution specific packages when available, especially on systems like Debian or Arch Linux. As that makes it even easier to upgrade or remove the packages later.
|
|
Back to top |
|
|
Mandrake elementry school minded asshole
Joined: 28 May 2002 Posts: 1341 Location: GNARR!
|
Posted: Fri Aug 26, 2005 2:32 pm Post subject: |
[quote] |
|
Open up a terminal shell. Type in GCC. Lookie there! It's the exact same C/C++ you were probably using on Windows (if you were using MingW or Dev-Cpp) and it's the HEART of the Linux OS.
You don't need anything else.
Make is simple and efficient. But, if you can't handle a command line, you should stop using Linux. Hell, you should stop programming all together. A programmer should be familiar with his compiler, in fact, he should know his compiler inside and out. He should make love to his compiler, and never cheat on it. And, if he gets into a fight with his compiler, he should go cool off and have a smoke, becuase, after all, a compiler doesn't make mistakes.
End rant.
But yeah, if you want to make an allegro game, ignore KDevelop. Check to see if the right stuff is in the usr/local/bin and usr/local /includes. Make sure you have the LATEST bleeding edge WIP for that platform. Don't use RPM's, just use the classic tar.gz, unzip and untar it and then just do make install like you did on windows.
If you did the RPM, uninstall whatever it setup <before> you untar and unzip. I've only used the zip distros, and never had a problem with them installing properly. Note of warning, some allegro add-on libraries aren't too Linux (or OSX either) compatible. Another word of warning- Most Linux users don't have Allegro installed, so anyone that uses a program you make will have to go through extra steps to install it. Some Linux users hate this, and perfer to only use what comes with their distro.
I would suggest (if you want a system that will create one binary that can move across multiple OS's, rather than recompiling on each OS wondering if it will even work) to either use Java or target an emulator (like GBA, GBC, NES, SNES TG-16, etc).
Also, learn how to use make or a make like tool (like jam). It's a nice little idea that completely automates what you need. _________________ "Well, last time I flicked on a lighter, I'm pretty sure I didn't create a black hole."-
Xmark
http://pauljessup.com
|
|
Back to top |
|
|
DeveloperX 202192397
Joined: 04 May 2003 Posts: 1626 Location: Decatur, IL, USA
|
Posted: Fri Aug 26, 2005 6:08 pm Post subject: |
[quote] |
|
LeoDraco wrote: | When you installed the allegro rpm, did you just install the allegro rpm, or did you also install the allegro-devel rpm? Many libraries packaged in rpm separate the .so's from the development files, which, obviously, would be packaged in the *-devel rpms. So, if you have not done that, my suggestion would be to attempt it. (I bring this up as the download page for the allegro sourceforge site lists separate packages. This is probably not an issue if you got a source rpm.)
edit: also! unless you grabbed the rpm from your distro's package management app (something like yum; I'm not familiar with SUSE, but maybe YaST?), you might have aquired an rpm that was not built intentionally for your distro. While this might not (always) be a problem, not all rpm-based distro's have the same directory hierarchy nor the same naming conventions.
edit2: After another brief search, I came across these notes regarding the linux version of allegro. They might be helpful to you. |
Ahhhh......see, that part about the -devel rpms is something I didn't know.
I'll see if I can find a -devel rpm.
I didn't get this rpm from allegro's download page...I got it from rpmfind.net/com/whatever the hell google refers me to 99% of the time.
I've not had any trouble with any rpms that are built for i386 - i586.
so far the only rpm that failed when I tried to install was a i686.
I'll go read those notes on allegro & linux after I finish posting...
thanks for your active help. it is appreciated. _________________ Principal Software Architect
Rambling Indie Games, LLC
See my professional portfolio
|
|
Back to top |
|
|
Mandrake elementry school minded asshole
Joined: 28 May 2002 Posts: 1341 Location: GNARR!
|
Posted: Fri Aug 26, 2005 6:22 pm Post subject: |
[quote] |
|
There is a problem with the allegro RPM- it doesn't create a proper symlink for the .so file. _________________ "Well, last time I flicked on a lighter, I'm pretty sure I didn't create a black hole."-
Xmark
http://pauljessup.com
|
|
Back to top |
|
|
DeveloperX 202192397
Joined: 04 May 2003 Posts: 1626 Location: Decatur, IL, USA
|
Posted: Fri Aug 26, 2005 7:24 pm Post subject: |
[quote] |
|
Bjørn wrote: | Rainer Deyke wrote: | How to install just about anything on Linux or any other UNIX-like environment:- Grab the source distro and unpack it somewhere.
- Enter the directory where you unpacked the source.
- Run ./configure.
- Run make.
- Run make install as root.
- Optionally delete the unpacked directory, as it is no longer needed.
|
If you go installing software this way it can be potentially hard to upgrade or remove it later. The following software helps you to keep things you install from source organized:
http://www.gnu.org/software/sourceinstall/sourceinstall.html
It would however probably still be preferred to use the distribution specific packages when available, especially on systems like Debian or Arch Linux. As that makes it even easier to upgrade or remove the packages later. |
I'll look into that sourceinstall thing in a little bit. thanks for the tip. _________________ Principal Software Architect
Rambling Indie Games, LLC
See my professional portfolio
|
|
Back to top |
|
|
DeveloperX 202192397
Joined: 04 May 2003 Posts: 1626 Location: Decatur, IL, USA
|
Posted: Fri Aug 26, 2005 7:34 pm Post subject: |
[quote] |
|
Mandrake wrote: | Open up a terminal shell. Type in GCC. Lookie there! It's the exact same C/C++ you were probably using on Windows (if you were using MingW or Dev-Cpp) and it's the HEART of the Linux OS.
You don't need anything else.
|
I already knew about gcc on the commandline.. :D
I didn't use gcc in windows. I used Dev-C++.
Quote: |
Make is simple and efficient. But, if you can't handle a command line, you should stop using Linux. Hell, you should stop programming all together. A programmer should be familiar with his compiler, in fact, he should know his compiler inside and out. He should make love to his compiler, and never cheat on it. And, if he gets into a fight with his compiler, he should go cool off and have a smoke, because, after all, a compiler doesn't make mistakes.
End rant.
|
Stop programming? lol. never.
I can handle a commandline just fine. I just am not used to it, just will take some practice.
LOL. make love to a compiler? hahahaha. good one.
I dont smoke either.
I know I should be familiar with my compiler, thats what I am trying to do...figure out how to do everything I did in windows...on linux. :)
Quote: |
But yeah, if you want to make an allegro game, ignore KDevelop. Check to see if the right stuff is in the usr/local/bin and usr/local /includes. Make sure you have the LATEST bleeding edge WIP for that platform. Don't use RPM's, just use the classic tar.gz, unzip and untar it and then just do make install like you did on windows.
|
I agree, KDevelop is a pain in the ass. I wont be using it.
Obviously I don have the right files I need for allegro..as I did not know about the -devel rpm....still gotta look for it..
Dont use rpms? hmm.....we'll see I'm going to need to learn a bit more about where linux stores everything first.
'make install' on windows? never did that....hell never had 'make' on windows.
Quote: |
If you did the RPM, uninstall whatever it setup <before> you untar and unzip. I've only used the zip distros, and never had a problem with them installing properly. Note of warning, some allegro add-on libraries aren't too Linux (or OSX either) compatible. Another word of warning- Most Linux users don't have Allegro installed, so anyone that uses a program you make will have to go through extra steps to install it. Some Linux users hate this, and perfer to only use what comes with their distro.
|
I wonder how to uninstall rpms...
I wont be using allegro add-ons, I roll my own code, just use allegro as the base cross-platform api.
I'll use static builds so they wont need allegro.
Quote: |
I would suggest (if you want a system that will create one binary that can move across multiple OS's, rather than recompiling on each OS wondering if it will even work) to either use Java or target an emulator (like GBA, GBC, NES, SNES TG-16, etc).
Also, learn how to use make or a make like tool (like jam). It's a nice little idea that completely automates what you need. |
I would love to learn to write for the GBA. ~ have any good links? ~
I AM writing for the TG16, thanks to FrozenUtopia.
I've dabbled with the SNES, but got too frustrated with it.(course that was awhile ago, might be easier now that I understand the TG16, and console in general more)
NES isn't what I'm looking for :)
I've messed with Java, and I will be using Java to build some smaller side projects. _________________ Principal Software Architect
Rambling Indie Games, LLC
See my professional portfolio
|
|
Back to top |
|
|
DeveloperX 202192397
Joined: 04 May 2003 Posts: 1626 Location: Decatur, IL, USA
|
Posted: Fri Aug 26, 2005 7:42 pm Post subject: |
[quote] |
|
Mandrake wrote: | There is a problem with the allegro RPM- it doesn't create a proper symlink for the .so file. |
Ahh.
Okay, then I guess I will get that sourceinstall thingy, and try the src version... _________________ Principal Software Architect
Rambling Indie Games, LLC
See my professional portfolio
|
|
Back to top |
|
|
Mandrake elementry school minded asshole
Joined: 28 May 2002 Posts: 1341 Location: GNARR!
|
Posted: Fri Aug 26, 2005 7:44 pm Post subject: |
[quote] |
|
Quote: |
I didn't use gcc in windows. I used Dev-C++.
|
Which uses a port of the GCC called MingW32.
Quote: |
Dont use rpms? hmm.....we'll see I'm going to need to learn a bit more about where linux stores everything first
|
No, use RPM's, don't use the allegro RPM. As I said above, it doesn't create the sim link to the allegro.so properly.
Quote: |
'make install' on windows? never did that....hell never had 'make' on windows.
|
Make comes with GCC, which comes with Dev-CPP. So how did you install Allegro on windows? You never once had to make-install? What did you do? Use a Dev-CPP package?
Quote: |
I'll use static builds so they wont need allegro.
|
Should somebody else handle this one? Or should I?
Welcome to the world of Linux. A static build will get you nowhere. Why? Because you can't tell if the user has the proper dependancies, or even the same underlying architecture. Linux runs on many machines other than x86. Doing a static build and then forcing people to download your binaries will get you nowhere.
Quote: |
I would love to learn to write for the GBA. ~ have any good links? ~
|
Google gba dev. There you go. Tada! _________________ "Well, last time I flicked on a lighter, I'm pretty sure I didn't create a black hole."-
Xmark
http://pauljessup.com
|
|
Back to top |
|
|
DeveloperX 202192397
Joined: 04 May 2003 Posts: 1626 Location: Decatur, IL, USA
|
Posted: Sat Aug 27, 2005 1:37 am Post subject: |
[quote] |
|
Mandrake wrote: | Which uses a port of the GCC called MingW32.
|
oh. didnt know that. I knew that it used MingW32, but didnt know that MingW32 was a port of gcc.
Quote: |
No, use RPM's, don't use the allegro RPM. As I said above, it doesn't create the sim link to the allegro.so properly.
|
Oh, I misunderstood your post.
Quote: |
Make comes with GCC, which comes with Dev-CPP. So how did you install Allegro on windows? You never once had to make-install? What did you do? Use a Dev-CPP package?
|
once again, never knew that Dev-C++ had make.
Nope, not ever once typed anything for installing allegro.
I used the Package Manager in Dev-C++ to install the .Pak file on the CD that came with "Game Programming All In One: Second Edition by J. Harbour".
After that, Dev-C++ had an icon in "New Project" for creating a .DLL Allegro project, and a Static Allegro project.
Quote: |
Should somebody else handle this one? Or should I?
Welcome to the world of Linux. A static build will get you nowhere. Why? Because you can't tell if the user has the proper dependancies, or even the same underlying architecture. Linux runs on many machines other than x86. Doing a static build and then forcing people to download your binaries will get you nowhere.
|
Ooooooooh......I forgot about that..sorry. I knew that already, I wasnt thinking about the fact that its linux..heh, too many years on windows...static builds on windows solves dependancies, not for linux...right.
well, there are allegro projects out there, and honestly, if someone is going to play my games, then they aren't going to care about having to install the allergo runtime library too.
so, its not an issue really.
Quote: |
Google gba dev. There you go. Tada! |
[/quote]
real helpful there man...yeesh. :P
I'll look it up. heh.
oh, and sourceinstall is a royal pain in the ass.
I'll just learn the 'normal' way to do installs..
I started learning SDL (again) today.
I wrote my source, wrote the makefile, used make & presto the binary worked. its a good feeling when that happens. :)
I figured out how to use a single makefile for multiple projects...but
how do you use multiple source files for a single project?
I've never compiled a multi-source program on the commandline.
Like, say I have 2 source files and a header file:
main.c
functionlib.c
functionlib.h
how would I write the makefile for building it?
I think that its something like
gcc -c main.c functionlib.c main.o functionlib.o -o program
..help.. :D _________________ Principal Software Architect
Rambling Indie Games, LLC
See my professional portfolio
|
|
Back to top |
|
|
|
Page 1 of 2 |
All times are GMT Goto page 1, 2 Next
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|