<div dir="ltr">Hi!<div><br></div><div>One solution is to write a wrapper script in your favourite scripting language (Ruby, Python etc) that pretend that it's a compiler. It could recognise the -I option and start the RX compiler with the --include option. It would not hurt to make it recognise other standard flags like "-o" and "-c" in case the RX compiler doesn't support them either.</div><div><br></div><div>    -- Anders</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Nov 22, 2017 at 10:33 AM,  <span dir="ltr"><<a href="mailto:oliver.zabel@egoproducts.com" target="_blank">oliver.zabel@egoproducts.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><font size="2" face="sans-serif">Hi Eric, </font>
<br>
<br><font size="2" face="sans-serif">thanks a lot for your help! i'm going
to try it on the dev mailing list.</font>
<br>
<br><font size="2" face="sans-serif">Cheers, </font>
<br><font size="2" face="sans-serif">Oliver</font>
<br>
<br>
<br>
<br><font size="1" color="#5f5f5f" face="sans-serif">Von:      
 </font><font size="1" face="sans-serif">Eric Noulard <<a href="mailto:eric.noulard@gmail.com" target="_blank">eric.noulard@gmail.com</a>></font>
<br><font size="1" color="#5f5f5f" face="sans-serif">An:      
 </font><font size="1" face="sans-serif"><a href="mailto:oliver.zabel@egoproducts.com" target="_blank">oliver.zabel@egoproducts.com</a></font>
<br><font size="1" color="#5f5f5f" face="sans-serif">Kopie:      
 </font><font size="1" face="sans-serif">CMake Mailinglist <<a href="mailto:cmake@cmake.org" target="_blank">cmake@cmake.org</a>></font>
<br><font size="1" color="#5f5f5f" face="sans-serif">Datum:      
 </font><font size="1" face="sans-serif">22.11.2017 09:49</font>
<br><font size="1" color="#5f5f5f" face="sans-serif">Betreff:    
   </font><font size="1" face="sans-serif">Re: Re: [CMake]
Antwort: Antwort: Re:Antwort: Re: Toolchain with non-gcc argument format</font>
<br>
<hr noshade><div class="HOEnZb"><div class="h5">
<br>
<br>
<br><font size="3">Hi Olivier,</font>
<br>
<br><font size="3">Putting the list back.</font>
<br><font size="3">You may try developer list as well.</font>
<br>
<br>
<br><font size="3">2017-11-22 9:02 GMT+01:00 <</font><a href="mailto:oliver.zabel@egoproducts.com" target="_blank"><font size="3" color="blue"><u>oliver.zabel@egoproducts.com</u></font></a><font size="3">><wbr>:</font>
<br><font size="2" face="sans-serif">Hi, </font><font size="3"><br>
</font><font size="2" face="sans-serif"><br>
Is there really no way to override this var with a toolchain file? that
seems somehow strange to me, since CMAKE is so configurable that i can't
change "-I" to "-include=" .... what do i have to do?</font>
<br>
<br>
<br><font size="3">I'm sorry I'm a little short in time to investigate that
with you at the moment and I hope some other people may step in.</font>
<br><font size="3">The var "CMAKE_INCLUDE_FLAG_C" is NOT a toolchain
file variable and it won't end-up in the cache file.</font>
<br><font size="3">AFAIK It is **only** used in compiler detection, e.g.
at early stage of project configuration when processing project(...)</font>
<br><font size="3">or enable_language(..)</font>
<br>
<br><font size="3">Adding new toolchain is not as flexible as adding a new
**kind** of compiler.</font>
<br><font size="3">The knobs accessing for writing a toolchain are described
here:</font>
<br><a href="https://cmake.org/cmake/help/v3.10/manual/cmake-toolchains.7.html" target="_blank"><font size="3" color="blue"><u>https://cmake.org/cmake/help/<wbr>v3.10/manual/cmake-toolchains.<wbr>7.html</u></font></a>
<br>
<br><font size="3">There you can see that:</font>
<br><font size="3">"Languages are enabled by the project() command.
Language-specific built-in variables, such as CMAKE_CXX_COMPILER, CMAKE_CXX_COMPILER_ID
etc are set by invoking the project() command."</font>
<br>
<br><font size="3">Unless I'm wrong the toolchain mechanism does not include
the capability to change "-I" to "-include".</font>
<br>
<br><font size="3">Now adding a new "kind" of compiler, a.k.a.
compiler ID, enables you to specify that include directive flag is "
-include" (and many other things as well)</font>
<br><font size="3">Adding a new compiler ID requires to add files in </font>
<br><font size="3"><CMakePrefix>/Modules/Compiler (see </font><a href="https://github.com/Kitware/CMake/tree/master/Modules/Compiler" target="_blank"><font size="3" color="blue"><u>https://github.com/Kitware/<wbr>CMake/tree/master/Modules/<wbr>Compiler</u></font></a><font size="3">)</font>
<br>
<br><font size="3">as you can see it requires at least a couple of file to
find a compiler and one file per supported language (C, CXX, etc...)</font>
<br><font size="3">in the C or CXX specific file you may use CMAKE_INCLUDE_FLAG_C
and other variables:</font>
<br>
<br><font size="3">see e.g.:</font>
<br><a href="https://github.com/Kitware/CMake/blob/master/Modules/Compiler/TI-C.cmake" target="_blank"><font size="3" color="blue"><u>https://github.com/Kitware/<wbr>CMake/blob/master/Modules/<wbr>Compiler/TI-C.cmake</u></font></a><font size="3"> </font>
<br>
<br><font size="3">I did never add a new kind of compiler so I hope people
with more knowlegde than me in this area will explain that part better
than me.</font>
<br>
<br><font size="3">Eric</font>
<br>
<br><font size="3"> </font>
<br><font size="3"><br>
<br>
<br>
2017-11-16 9:44 GMT+01:00 <</font><a href="mailto:oliver.zabel@egoproducts.com" target="_blank"><font size="3" color="blue"><u>oliver.zabel@egoproducts.com</u></font></a><font size="3">><wbr>:
</font><font size="2" face="sans-serif"><br>
I did not find the CMAKE_INCLUDE_FLAG_C in the CMake cache - is it possible
that this is somehow ignored?</font><font size="3"> <br>
<br>
This variable is used by CMake **builtin compiler** discovery and configuration.
<br>
The file are are put in "Modules/Compiler" there is one per-langage
and per-compiler ID: </font><font size="3" color="blue"><u><br>
</u></font><a href="https://cmake.org/cmake/help/v3.7/variable/CMAKE_LANG_COMPILER_ID.html" target="_blank"><font size="3" color="blue"><u>https://cmake.org/cmake/help/<wbr>v3.7/variable/CMAKE_LANG_<wbr>COMPILER_ID.html</u></font></a><font size="3">
<br>
<br>
I don't know the exact processing order of this set of files. <br>
<br>
Toolchain files: </font><font size="3" color="blue"><u><br>
</u></font><a href="https://cmake.org/cmake/help/v3.7/manual/cmake-toolchains.7.html" target="_blank"><font size="3" color="blue"><u>https://cmake.org/cmake/help/<wbr>v3.7/manual/cmake-toolchains.<wbr>7.html</u></font></a><font size="3">
<br>
does not use or contain such variables. <br>
<br>
-- <br>
Eric <br>
</font>
<br><font size="3"><br>
</font>
<br>
<br><font size="3">-- </font>
<br><font size="3">Eric</font>
<br>
<br></div></div><br>--<br>
<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Please keep messages on-topic and check the CMake FAQ at: <a href="http://www.cmake.org/Wiki/CMake_FAQ" rel="noreferrer" target="_blank">http://www.cmake.org/Wiki/<wbr>CMake_FAQ</a><br>
<br>
Kitware offers various services to support the CMake community. For more information on each offering, please visit:<br>
<br>
CMake Support: <a href="http://cmake.org/cmake/help/support.html" rel="noreferrer" target="_blank">http://cmake.org/cmake/help/<wbr>support.html</a><br>
CMake Consulting: <a href="http://cmake.org/cmake/help/consulting.html" rel="noreferrer" target="_blank">http://cmake.org/cmake/help/<wbr>consulting.html</a><br>
CMake Training Courses: <a href="http://cmake.org/cmake/help/training.html" rel="noreferrer" target="_blank">http://cmake.org/cmake/help/<wbr>training.html</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/<wbr>opensource/opensource.html</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://public.kitware.com/mailman/listinfo/cmake" rel="noreferrer" target="_blank">http://public.kitware.com/<wbr>mailman/listinfo/cmake</a><br></blockquote></div><br></div>