|
|
|
Re: Run mingw with Eclispe CDT. How to specify which compiler? [message #1833087 is a reply to message #1833085] |
Fri, 02 October 2020 05:07 |
David Vavra Messages: 1426 Registered: October 2012 |
Senior Member |
|
|
Maybe this article will help.
Scroll down to "Console View" to see the dialog.
The article is somewhat out of date
The shown "Discovery" tab is now found with
Project --> Properties --> C/C++ General --> Preprocessor Include Paths, Macros etc. --> Providers tab
https://www.eclipse.org/community/eclipse_newsletter/2013/october/article4.php
You likely need to change the command used to get compiler builtins.
Typically it is: ${COMMAND} ${FLAGS} -E -P -v -dD "${INPUTS}"
with ${COMMAND} being the compiler in the current toolchain (gcc derivative assumed).
You could try changing it to x86_64-w64-mingw32-gcc ${FLAGS} -E -P -v -dD "${INPUTS}"
x86_64-w64-mingw32-g++ might also work.
gcc will call the correct compiler (C or C++) depending on the extent in ${INPUTS}
g++ might not.
You might want to add the correct path to the compiler here (/usr/bin/ ?) so you won't have to rely on the system path.
Note: the path depends on how Eclipse was started (e.g., from a cygwin command prompt vs. system prompt)
You could use the "Allocate console" flag to verify it.
----
You can also add the builtin paths manually to
Project --> Properties --> C/C++ General --> Preprocessor Include Paths, Macros etc. --> Entries tab
but you likely will need to set the Contains system headers flag
and maybe the Treat as built-in flag as well
https://help.eclipse.org/2020-06/index.jsp?topic=%2Forg.eclipse.cdt.doc.user%2Freference%2Fcdt_u_prop_general_sd_entries.htm&cp%3D10_4_7_0_4_6_0
Scroll down to "Adding and Editing entries"
This is also in the article that I linked but, again, that is out-of-date.
Unfortunately, so is the current documentation in places as the dialogs have been moved and/or modified.
But the topics covered are still valid
[Updated on: Fri, 02 October 2020 05:29] Report message to a moderator
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03816 seconds