Use CXX to compile .c files

apuder
Posts: 53
Joined: Mon Mar 26, 2018 7:27 pm

Use CXX to compile .c files

Postby apuder » Thu May 23, 2019 4:49 pm

Hi,
is it possible to make CXX the default compiler for .c files for a specific component? I'm looking/hoping for some component.mk magic that would allow me to do that.
TIA,
AP

ESP_Sprite
Posts: 9766
Joined: Thu Nov 26, 2015 4:08 am

Re: Use CXX to compile .c files

Postby ESP_Sprite » Fri May 24, 2019 4:10 am

I looked into it; there is no easy way. The most doable way would involve generating recipes to compile each and every .c file you waqnt treated in this way to an .o file manually. If you want to do this, the generalized recipe generators are in component_wrapper.mp, near 'define GenerateCompileTargets'. I'd say the easiest way to tackle this is to just rename your source files.

Who is online

Users browsing this forum: Google [Bot] and 142 guests