Anyone using Code::Blocks to compile their objects?
- what's your IDE of choice?
Ricky
Code::Blocks
Anyone using Code::Blocks to compile their objects?
Ricky
I just use the Makefile template for compiling externals. I've never been formally trained in programming, so I find IDEs a bit confusing. I'll pretty much use anything with text highlighting and just use the Makefile template when I'm done. Lately I've been using Kate. I'll probably use something else next month.
Kate looks pretty neat. I've been teaching myself over the summer, slowly. I've been working with XCode and Code::Blocks. I really like the latter. Would it be a good idea to have sticky threads dedicated to Makefile templates, IDE guides and the like?
Hmm...it would be nice to perhaps make some posts in Tutorials about using the Makefile and setting up certain IDEs, then we can link them in the sticky in the extra~ section. I can probably throw together one for the Makefile.
That would be great! I'll be building some really simple externals over this coming semester and will post step-by-step guides. That's the intention, at least.
Hey Ricky,
With Pd stuff and cross platform open source software in general an IDE is rarely needed, because everything is supposed to be distributed with it's own build system, based on GNU make and possibly the autotools. It's better to invest some time and learn GNU make, than base your projects on some IDE which other people may not use. Once you master GNU make (which may be frustrating initially), you can distribute your Pd projects as source code with a build system that will build for many operating systems and all sorts of hardware platforms. You don't need to distribute all the binary builds yourself, but only a few which are mainstream like Windows, MacOSX fat binary, Linux 32 and 64 bit for Intel. Then you can leave the Raspberry Pi build etc. up to the user, if only the build system supports it. There's just too many platforms nowadays.
To my knowledge, an IDE (XCode, Netbeans, CodeBlocks) will not produce a cross platform build system, so for cross platform projects any fine code editor will do, in combination with a GNU make based build system. That's how I think about it.
Katja
Hi Katja,
I get where you are coming from. I know GNU make in combination with terminal works well (I have used this approach to compile objects before) and that this is the most useful approach when developing externals across multiple platforms. I am wondering, though, is this not a similar compiler/compilation to using the GNC GCC compiler within an IDE? Granted, using terminal and a makefile is more complicated but I am curious as to whether or not there are any significant similarities?
I think a step-by-step GNU make guide for this forum would be extremely helpful and encourage Pd users to delve more deeply into more sophisticated concepts.
All the best,
Ricky
@Ricky said:
I am wondering, though, is this not a similar compiler/compilation to using the GNC GCC compiler within an IDE?
I'm not an expert on this topic, but what I know is this: under the hood, IDE's produce a build system for each project, but they do not always export it as a makefile. Netbeans can do that, but only for the platform where the project is developed. Netbeans can also import a project based on makefiles. My friend Fred Jan is a fan of Netbeans. It's available for all operating systems, and more advanced than CodeBlocks. I've installed Netbeans several times, but never really used it, since I found that it can not produce cross platform makefiles anyway.
About makefiles: this is really the smoothest way to build a cross platform project. Think of a makefile as a script, and GNU make as a scripting language. If the script is well written, it will work wherever GNU make and GCC are installed. A makefile can call another makefile. The whole of Pd-extended is built in this fashion, every night on a multitude of platforms, automatically.
I agree that it is more complicated to produce a makefile or set of makefiles by hand than leaving this job to an IDE. But if your aim is to distribute a cross platform project, like is the case with Pd classes, I see no alternative. The template makefile in Pd-extended may suit your needs, after all it was made for the purpose. Or at least you can learn a lot from the template, if you have requirements which are not fulfilled by the template.
For my Pd projects I developed a flexible build system which can build all executables for a project with a single command. If you download SliceJockey2test2 (http://www.katjaas.nl/slicejockey/slicejockey.htm) and look in the src directory of you can see how it is organized.
@Ricky said:
I think a step-by-step GNU make guide for this forum would be extremely helpful and encourage Pd users to delve more deeply into more sophisticated concepts.
It took me two weeks to learn enough of GNU make to develop my build system. But now that it is there, it's easy to use. I guess this is the case with the template makefile as well. It is intended for use within the context of a Pd-extended build, and if you want to use it outside that context, you'll need to emulate part of the directory structure of a Pd-extended build. If your project has a one-file-per-class structure, it should not be too hard to use the template makefile. There is no manual yet, I guess that Hans Christoph Steiner would be happy if you do a write up.
Katja
Thanks, Katja. I will look into it.
Revisiting this again before I never come back to it. .mmb, any chance of a Makefile tutorial, you legend?
Oops! Looks like something went wrong!