← Back to team overview

kicad-developers team mailing list archive

Commit c8a6878 breaks compilation on msys2

 

common.h does not compile with msys2/gcc 9.1.0

Here is the error message:

In file included from D:/wxWidgets-3.1.1/include/wx/defs.h:851,
                 from D:/wxWidgets-3.1.1/include/wx/wx.h:14,
                 from E:/kicad-launchpad/gerber_dev/include/common.h:37,
                 from
E:/kicad-launchpad/gerber_dev/polygon/math_for_graphics.cpp:8:
E:/kicad-launchpad/gerber_dev/include/common.h: In function 'constexpr
ret_type KiROUND(fp_type)':
E:/kicad-launchpad/gerber_dev/include/common.h:118:5: error: 'asm' in
'constexpr' function
  118 |     wxASSERT( ret <= std::numeric_limits<ret_type>::max()

Looks to me using wxASSERT here creates this issue.
(I replaced wxASSERT by a printf controlled by the same condition to
compile Kicad)

-- 
Jean-Pierre CHARRAS


Follow ups