cancel
Showing results for 
Search instead for 
Did you mean: 

Cosmic Compiler - how to run from command line

Posted on November 03, 2017 at 15:09

HI,

I have a project which contains 12 different 'targets' defined by different &sharpdefines. Now i need to edit .h file manually, uncomment one of 12 defines, build it and do the same for all the targets.

What is best approach to trigger building project for different configuration by single click/single command...

It would be also nice to have output files (s19) named according to selected target.

Thank you in advance

Krzysiek

#cosmic-compiler #stm8
1 REPLY 1
Philipp Krause
Senior II
Posted on November 05, 2017 at 07:29

For a similar task, I use GNU make. The Makefile uses pattern rules, static patterns and pattern-specific variables. I have 3 programs, each compiled for 8 targets each with 4 different sets of compiler options. I use SDCC on GNU/Linux, but the approach should work with any compiler. AFAIR, Cosmic has a section 'Compiler Command Line Options' in the manual.

Philipp