Code::Blocks Forums

User forums => General (but related to Code::Blocks) => Topic started by: skirby on January 08, 2007, 11:28:15 am

Title: Possibility to support another compiler (Pelles C)
Post by: skirby on January 08, 2007, 11:28:15 am
Hello,

Do you think it would be possible for Code::Blocks to support another compiler: Pelles C
You can find it here: http://smorgasbordet.com/pellesc/

It only supports C file (not C++) but it is very very good.
I encourage you to visit its web site in order to see the capabilities of that compiler.
It create fast and small executable.
It can compile ASM file.

Some people will say: "yes, it is cool but it already have a IDE. Why do you want to add it into Code::Blocks?"
They are right but the Pelles C IDE is not very powerful and some nasty bug still persits since months.
The author prefer improve the compiler rather than the IDE (and I think he is right)

I hope Code::Blocks authors could do something because this compiler worth it.


Happy new year and have a nice day.
Title: Re: Possibility to support another compiler (Pelles C)
Post by: stahta01 on January 08, 2007, 11:56:49 am
I am willing to try making C::B work with "Pelles C", but if it takes more than 2 or 3 days will have to give up because of the other tasks I am working on.

Is it open source? Found the FAQ, it is closed source.

Tim S
Title: Re: Possibility to support another compiler (Pelles C)
Post by: killerbot on January 08, 2007, 12:59:04 pm
what would be of good help to us so we don't need to go through the manual :
- have a look at the compiler options (and advanced options) for GCC and provide us with a list for the options, then we can put them in code. This is probably easier for you since you know that compiler.

You can even go all the way, have a look at the compiler code in the compiler plug-in of CB (get sources from svn repos)

Title: Re: Possibility to support another compiler (Pelles C)
Post by: skirby on January 08, 2007, 01:21:03 pm
Thanks for your answer.

Firstly, I am going to ask for the Pelles C author if it is agree.
If yes, I will make a list with all compiler options.
Title: Re: Possibility to support another compiler (Pelles C)
Post by: David Perfors on January 08, 2007, 01:35:13 pm
I wonder why you need any permision of the author. When it is free, we can support it...
Title: Re: Possibility to support another compiler (Pelles C)
Post by: killerbot on January 08, 2007, 01:44:52 pm
just do it ;-) we can always convince the author later on the recommend CB :-) :-)
Title: Re: Possibility to support another compiler (Pelles C)
Post by: severach on January 08, 2007, 09:23:56 pm
This should be an easy compiler to add. The command structure is almost the same as any Microsoft compiler. I don't see any way to add debugging support.
Title: Re: Possibility to support another compiler (Pelles C)
Post by: killerbot on January 08, 2007, 09:46:00 pm
debugging wil be much harder I guess, first focus on the compiler support
Title: Re: Possibility to support another compiler (Pelles C)
Post by: skirby on January 09, 2007, 02:52:25 pm
OK, this author is agree.
We can integrate Pelles C compiler into Code:Blocks  :D

I am creating a list of all compiler command line options.
It should be ready in one or two days.
Title: Re: Possibility to support another compiler (Pelles C)
Post by: tiwag on January 09, 2007, 05:23:08 pm
...We can integrate Pelles C compiler into Code:Blocks  :D...

why should one do that ?

Pelles C comes with its own nice IDE, well designed and powerful built in debugger ...
Title: Re: Possibility to support another compiler (Pelles C)
Post by: RJP Computing on January 09, 2007, 06:07:56 pm
why should one do that ?

Pelles C comes with its own nice IDE, well designed and powerful built in debugger ...
True, PellesC does come with an IDE, but I think it would be nice (not mandatory) to have one common development environment.

Plus if the idea was never to add support for compilers with good IDE's then Visual C++ 8.0 wouldn't be supported. ;)
Title: Re: Possibility to support another compiler (Pelles C)
Post by: Phatency on January 09, 2007, 08:11:35 pm
Plus if the idea was never to add support for compilers with good IDE's then Visual C++ 8.0 wouldn't be supported. ;)
Good IDE!? What are you on?
Title: Re: Possibility to support another compiler (Pelles C)
Post by: lubos on January 09, 2007, 08:18:30 pm
Plus if the idea was never to add support for compilers with good IDE's then Visual C++ 8.0 wouldn't be supported. ;)
Good IDE!? What are you on?
some people love it, some hate it, as always.
Title: Re: Possibility to support another compiler (Pelles C)
Post by: RJP Computing on January 09, 2007, 08:20:18 pm
Good IDE!? What are you on?
Come on. You and I both know that good is subjective and yes everybody that is here on the Code::Blocks forum is here because they like Code::Blocks. I didn't say that it is the best and everything else stinks, I was just meaning that it had a full IDE already that had a code editor, debugger and visual designer just like PellesC.

 :D
Title: Re: Possibility to support another compiler (Pelles C)
Post by: killerbot on January 09, 2007, 08:46:04 pm
calm calm.
If we can support another compiler (so not debugging), then that's a good thing. Several of the compilers we support have their own IDE (eg . M$ , Borland, Watcom, Intel ,..), but if you can stay within the same IDE when working on different projects, it's nice. Plus also for CB it's nice to have a wide support. But let's take step for step, since it is difficult to know all compiler settings, and the logic has to be simple (eg : mutual exclusive settings, we don't do that), so you tick a whole bunch of options where the compiler might tell you in then end the mix is not correct. But we offer the settings, the user with sound knowledge ticks what he wants.
So once we have a substantial set of settins for a compiler we can start and later on adjust or expand.
Title: Re: Possibility to support another compiler (Pelles C)
Post by: RJP Computing on January 09, 2007, 08:52:51 pm
calm calm.
Oh I am not mad, just wanted to restate what I meant.  :)

If we can support another compiler (so not debugging), then that's a good thing. Several of the compilers we support have their own IDE (eg . M$ , Borland, Watcom, Intel ,..), but if you can stay within the same IDE when working on different projects, it's nice. Plus also for CB it's nice to have a wide support. But let's take step for step, since it is difficult to know all compiler settings, and the logic has to be simple (eg : mutual exclusive settings, we don't do that), so you tick a whole bunch of options where the compiler might tell you in then end the mix is not correct. But we offer the settings, the user with sound knowledge ticks what he wants.
So once we have a substantial set of settins for a compiler we can start and later on adjust or expand.
Sounds like a great idea.

EDIT:
Thanks SethJackson  :D
Title: Re: Possibility to support another compiler (Pelles C)
Post by: sethjackson on January 09, 2007, 09:14:38 pm
calm calm.
Oh I am mad, just wanted to restate what I meant.  :)

I think you mean not mad. ;)
Title: Re: Possibility to support another compiler (Pelles C)
Post by: MortenMacFly on January 09, 2007, 11:37:38 pm
If we can support another compiler (so not debugging), then that's a good thing.
[...]
So once we have a substantial set of settins for a compiler we can start and later on adjust or expand.
I still maintain support for the LCC (both, LCC and the Matlab LCC) compiler in the backhand (works fine for me)... but mandrav told me better not to commit due to some remaining issues that should better be fixed inside LCC itself. Just to let you know and to prevent from re-inventing the wheel.
With regards, Morten.
Title: Re: Possibility to support another compiler (Pelles C)
Post by: skirby on January 11, 2007, 11:00:57 am
I have done a complete list of all Pelles C command line tools.

I have contact the author in order to know all necessary and optional command line tools.
You can find the result in a Word document here:
http://www.mytempdir.com/1254553

Is it sufficient for you to integrate Pelles C compiler into Code::Blocks?

I you think that my document is incomplete or useless, please let me know what you would like and I will update the document.
I have joined the help file in the zip archive.

If you need help to test the integration, I am your man  :)

Have a nice day.


Edit: Word document link update
Title: Re: Possibility to support another compiler (Pelles C)
Post by: MortenMacFly on January 11, 2007, 11:12:38 am
I have done a complete list of all Pelles C command line tools.
Looks good to me. One question I have: There is a POASM tool included. Is it common to write ASM code in development or is this just some special case?
Why I'm asking: I wonder how to attach the ASM compiler nicely. (You know: C::B is primary a C/C++ IDE). I could imagine to use the C++ compiler therefore... but this may lead to some misunderstanding. Otherwise I'd rather skip this ASM stuff.
With regards, Morten.

Ps.: Oh: And why is "POBIND" useless?!
Title: Re: Possibility to support another compiler (Pelles C)
Post by: skirby on January 11, 2007, 11:54:33 am
Writting full asm code could be very nice in some case.
More, it is one of the nice feature of Pelles C compiler.

Isn't it possible to simply add a ASM compiler entry into "Program Files" tab like "C ompiler", "Debugger" or "Resource compiler"
But if you can't or don't want to integrate POASM, I will respect your choice.

POBIND seems not to be necessary.
Here is the answer from the author about POBIND:
Quote
POBIND can be used to (possibly) decrease the startup time of an program by
'patching' the executable file. This will take some work off the Windows
loader. It's an optimization that few programs need. And since it's an
optimization, it's never *needed*...

But, how can you integrate this POBIND tool into Code::Blocks?
Where are you putting this tools into Compiler and Debugger setting window?
Title: Re: Possibility to support another compiler (Pelles C)
Post by: killerbot on January 11, 2007, 12:25:44 pm
we are gonna add a asm program in the set of programs, and register assembler exentions (.s)
But first some other things ;-)
Title: Re: Possibility to support another compiler (Pelles C)
Post by: skirby on January 11, 2007, 12:36:47 pm
Is my Word document about Command line tools and options OK for you killerbot?

Do you need more informations about Pelles C compiler?
Title: Re: Possibility to support another compiler (Pelles C)
Post by: killerbot on January 23, 2007, 08:48:22 pm
good enough info, now finding time to implement and test ;-)
Title: Re: Possibility to support another compiler (Pelles C)
Post by: skirby on January 26, 2007, 10:31:12 am
I am your man if you need some testers  :D
Please, let me know when you will be ready and I will be glad to help you.
Title: Re: Possibility to support another compiler (Pelles C)
Post by: skirby on April 04, 2007, 02:18:03 pm
Hello,

I would like to try to add Pelles C compiler by myself into C::B

So I begun by duplicate a compiler in menu "Settings" and "Compiler and Debugger"
I have modified "Search directories" and "Toolchain executables" but now, what is the way to modify compiler settings ?

If I have a parameter like this:
/V<n> : Set verbosity level 0, 1 or 2 (default: n = 0)

Do I have to create three entries like that:
/V0 : Set verbosity level 0
/V1 : Set verbosity level 1
/V1 : Set verbosity level 2

or is it possible to create an entry where I could enter my value ?

Also, what is the way to manage an option like this:
/I<path> : Add a search path for #include files


Thanks in advance and have a nice day.