Dhondtguido / CalculiX

This repository contains the source files of CalculiX, a three-dimensional Finite Element Program (www.calculix.de).
GNU General Public License v2.0
75 stars 19 forks source link

Moved _set_output_format into function body #10

Closed victorkemp closed 1 year ago

victorkemp commented 1 year ago

so it compiles in Mingw on Windows.

3rav commented 1 year ago

_set_output_format this function causes an error in the UCRT64 environment:

https://github.com/msys2/MINGW-packages/issues/15607#issue-1579990450

possible solution:

#ifdef __MSVC
_set_output_format(_TWO_DIGIT_EXPONENT);
#endif

_set_output_format is it needed at all since "This function is obsolete. Beginning in Visual Studio 2015, it is not available in the CRT."?

lazka commented 1 year ago

Maybe #if defined(_WIN32) && !defined(_UCRT) ?

victorkemp commented 1 year ago

I hope it can be removed entirely. It's just a bodge to fix an old bug in a MS library. There's also an environment variable that does that anyway.

3rav commented 1 year ago

I confirm #if defined(_WIN32) && !defined(_UCRT) that the build goes 100%, but does ccx it works correctly?:

https://calculix.discourse.group/t/steady-state-dynamics-randomly-terminates-without-error/1279/44?u=rafal.brzegowy