Code::Blocks Forums

User forums => Help => Topic started by: d3vid on July 24, 2015, 06:05:37 pm

Title: [ANSWERED] Why would CB add dependencies to libgomp? (Ans: It's CMake)
Post by: d3vid on July 24, 2015, 06:05:37 pm
Hi,

I am generating CB project files using CMake. When I do this dependencies to GOMP/libgomp are added to the project makefiles. If I remove them manually, then open the project in CB and try to build it, they are added again (and the build fails because they are there).

Is there any reason why CB would add these dependencies to GOMP?

Given that they are being added, is there any way to suppress/inhibit them? Perhaps by adding a flag to my compiler via CB?

(A full explanation of my build attempt is given here http://stackoverflow.com/questions/31614268 , but I was wondering if there was a CB-specific cause or workaround.)

Thanks.
Title: Re: Why would CB add dependencies to libgomp?
Post by: oBFusCATed on July 24, 2015, 06:48:24 pm
CB doesn't add any dependencies and in case of makefile projects doesn't execute the compiler at all.
The make program is executing the compiler with the command line options specified in the makefile.

Inspect the generated makefile and also the cmake build system.

My guess is that the problem will happen even if you run make from a terminal.
Title: Re: Why would CB add dependencies to libgomp?
Post by: Jenna on July 24, 2015, 06:49:50 pm
As far as I know cmake creates makefiles anduses them with C::B.
Code::blocks does not touch any makefiles or add/remive anything to/fromthem.
So this seems to be a a problem with  cmake (or more likely your cmake-configuration).
Title: Re: Why would CB add dependencies to libgomp?
Post by: d3vid on July 25, 2015, 09:08:26 am
Thanks for pointing me in the right direction!