Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [cdt-dev] CMake support in Eclipse CDT

My plan is to only support Makefile generation for now. So if we can get something there then we’re good.

From: <cdt-dev-bounces@xxxxxxxxxxx> on behalf of Alexander Neundorf <neundorf@xxxxxxx>
Reply-To: "CDT General developers list." <cdt-dev@xxxxxxxxxxx>
Date: Thursday, December 3, 2015 at 5:03 PM
To: "cdt-dev@xxxxxxxxxxx" <cdt-dev@xxxxxxxxxxx>
Subject: Re: [cdt-dev] CMake support in Eclipse CDT

On Thursday, December 03, 2015 22:53:17 Martin Weber wrote:

> Am Mittwoch, 2. Dezember 2015, 01:21:38 schrieb Doug Schaefer:

> > toolchain definition file to use with CMake. Then how to get the compile

> > options from CMake to feed scanner discovery. Hopefully it’s similar to

> > qmake which I can dump pretty much every variable that feeds into the

> > Makefile generation.

>

> Getting the compile options (preprocessor-macros and include paths) to feed

> the indexer is nearly impossible. Cmake has no option to dump these

> (CMAKE_EXPORT_COMPILE_COMMANDS works only for makefiles). cmake places that

> information in the generated build scripts, which may be makefiles or

> ninja.rules-files or whatever-build-tool files.

> If you want to give end users a choice for the build tool, you will end up

> in writing parsers for these build scripts plus adding mechanics to find

> these.

 

AFAIK the plan here is to read/parse them from the compile commands json file.

The existing CDT-project generator (which is mainly limited by Eclipses stubborness wrt. to the VCS plugin only working in subdirs of the location of the .project file), already puts the compile flags and include dirs into the .cproject file, so CDT knows about them.

What I want to say, CMake can put that information into some file, so it can be used.

 

> My cmake4eclipse plugin tries to feed the indexer by parsing the build

> output. But that fails on windows or if users chose to use ninja instead of

> make.

>

> IMHO, all IDE developer teams that want to integrate cmake into their IDE,

> should stick heads together, find consent on the required information (at

> least for the C/C++ language) and talk to the cmake team. According to [1],

> they are aware of the problem, but (my guess) they need input from the IDE

> developr side.

>

> I see these IDE developer teams:

> - CDT

> - Kdevelop (<neundorf@xxxxxxx>, already on his list and on the make

> developers list)

 

I'm not part of the kdevelop team.

 

Alex

 


Back to the top