Skip to content

Setting up irony mode on Windows using MSVC

Guillaume Papin edited this page Feb 10, 2016 · 20 revisions

TODO: do a proper recap of this page: https://github.com/Sarcasm/irony-mode/issues/280#issuecomment-182476498

.clang_complete example:

Using unix-style flags:

-target
i686-pc-windows-msvc
-fms-extensions
-fms-compatibility
-fms-compatibility-version=17.00
-fdelayed-template-parsing
-Iinc
-D_MSC_VER
-DWITH_UNIT_TESTS
-D_DEBUG
-std=c++11
-IMULTIPLEINCLUDESHERETO_BOOST_AND_OTHER_THINGS

To use Windows-style flags use --driver-mode=cl such as:

-target
i686-pc-windows-msvc
-fms-extensions
-fms-compatibility
-fms-compatibility-version=17.00
-fdelayed-template-parsing
-Iinc
-D_MSC_VER
-DWITH_UNIT_TESTS
-D_DEBUG
-std=c++11
-IMULTIPLEINCLUDESHERETO_BOOST_AND_OTHER_THINGS

--driver-mode=cl
/nologo
/DWIN32
/D_WINDOWS
/W3
/GR
/EHsc
/EHs
/D_HAS_EXCEPTIONS=0

Known issues: generated headers (stdafx.h?) may cause scaring issues if not properly setup, see: https://github.com/Sarcasm/irony-mode/issues/280#issuecomment-181845794

Clone this wiki locally