Developer forums (C::B DEVELOPMENT STRICTLY!) > Development

Support for CodeBlocks in CMake

<< < (2/7) > >>

alex.neundorf:
No, it's not yet released yet, if it gets enough testing and fixes it will be in CMake 2.6.0.
The file is Source/cmExtraCodeBlocksGenerator.cxx.
Currently there are no nightly snapshots to download.
For which platform do you need it ?

Building cmake on any UNIX is easy, on Windows you need to install a binary release of cmake (e.g. 2.4.7) and then configure the cmake from cvs with this one.


Biplab:

--- Quote from: alex.neundorf on August 27, 2007, 09:23:11 pm ---No, it's not yet released yet, if it gets enough testing and fixes it will be in CMake 2.6.0.
The file is Source/cmExtraCodeBlocksGenerator.cxx.
Currently there are no nightly snapshots to download.
For which platform do you need it ?

Building cmake on any UNIX is easy, on Windows you need to install a binary release of cmake (e.g. 2.4.7) and then configure the cmake from cvs with this one.

--- End quote ---

Thanks Alex. I found the file.

I'd try to build a Windows Executable. Otherwise I'll request you for a build. :)

Had a quick look at the source.
1. Compiler is hard-coded to GCC.
2. Compiler vars of source files are not exported. (Though this may not be necessary for C/C++ header/sources)

I'll post my feedback later. It's late night here and now I'll sleep. :)

alex.neundorf:
> Had a quick look at the source.
> 1. Compiler is hard-coded to GCC.

Yes. I tested only with gcc on Linux, that's also the reason why under Windows right now only the MinGW makefile generator is enabled. CMake supports also MS nmake, Borland make and MSYS and cygwin Makefiles, they should probably work too if CodeBlocks can handle the slight differences.

> 2. Compiler vars of source files are not exported. (Though this may not be necessary for C/C++
> header/sources)

What does that mean ?

The project generator work so that it creates makefiles accompanied by CodeBlocks projects for custom makefile based projects, completely set up with all available targets, source files etc. This is the same way as it is done for the KDevelop and Eclipse project generators in CMake.
Are the include directories required, i.e. does CodeBlocks do autocompletion where they would be needed ?
In theory it would also be possible to write a project generator for the native CodeBlocks build system, but this requires several orders of magnitude more work (and that there is no real CodeBlocks release doesn"t make it easier).

Alex

Biplab:

--- Quote from: alex.neundorf on August 27, 2007, 09:47:25 pm ---> Had a quick look at the source.
> 1. Compiler is hard-coded to GCC.

Yes. I tested only with gcc on Linux, that's also the reason why under Windows right now only the MinGW makefile generator is enabled. CMake supports also MS nmake, Borland make and MSYS and cygwin Makefiles, they should probably work too if CodeBlocks can handle the slight differences.

--- End quote ---

Code::Blocks identifies the Compilers from the project file. So if an appropriate compiler name (GCC = gcc, Borland = bcc, MSVC 6 = msvc, etc) is provided, it can use that one. :)


--- Quote from: alex.neundorf on August 27, 2007, 09:47:25 pm ---> 2. Compiler vars of source files are not exported. (Though this may not be necessary for C/C++
> header/sources)

What does that mean ?

--- End quote ---

These are used by Compiler plugin to prepare appropriate command. They are assigned automatically by C::B based on file extensions. E.g., CC for C files. As CMake doesn't generate a native project, this can be ignored.


--- Quote from: alex.neundorf on August 27, 2007, 09:47:25 pm ---The project generator work so that it creates makefiles accompanied by CodeBlocks projects for custom makefile based projects, completely set up with all available targets, source files etc. This is the same way as it is done for the KDevelop and Eclipse project generators in CMake.
Are the include directories required, i.e. does CodeBlocks do autocompletion where they would be needed ?

--- End quote ---

For auto-completion, it is necessary to have the additional include directories to be added at Project level or Target level.


--- Quote from: alex.neundorf on August 27, 2007, 09:47:25 pm ---In theory it would also be possible to write a project generator for the native CodeBlocks build system, but this requires several orders of magnitude more work (and that there is no real CodeBlocks release doesn"t make it easier).

--- End quote ---

I'm unable to give any idea about next release. But the file format will not be changed drastically. :)

Best Regards,

Biplab

alex.neundorf:
> Code::Blocks identifies the Compilers from the project file. So if an appropriate compiler name (GCC = gcc,
> Borland = bcc, MSVC 6 = msvc, etc) is provided, it can use that one.

Which compilers (with which names) are supported ?

> For auto-completion, it is necessary to have the additional include directories to be added at Project level or
> Target level.

So CodeBlocks does autocompletion ? Cool :-)
How does it do that ? Does it parse the code itself or does it use some tool ?
I think I can add the include directories at target level.
How does the xml look for that ?

Alex

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version