Closed sergioferrari closed 3 years ago
The date.cpp was recently changed. I had to revert the change to get XInt to compile. I'm using g++.exe (x86_64-posix-seh-rev0, Built by MinGW-W64 project) 8.1.0. Visual Studio 2019 works because (if memory serves) it automatically defines _MSC_VER.
The standard requires 9 attributes It would be better to change the conditional compilation logic to gate the >9 attribute code to the specific compilers that support the extra attributes, and leave the 9 attribute code as the fall-through case.
An easier way to solve this problem is to add a define at the beginning of the file.
For me it works well with mingw64.
mkdir build
cd build
cmake -DSTATIC=ON -DTESTS=OFF -G "MSYS Makefiles" ..
cmake --build . --config Release
I didn't consider the usage of GCC with Visual Studio. This should be easy to fix by changing some of the #ifdef
guards. I'll fix it soon.
This should be fixed with 7f51eed1079c7194d9cbbefd9fb7309b44abf073 in the master
branch. Please let me know if it doesn't work for you.
I'm trying to compile the Xlnt library with GCC (10.2.0), but I get the following error:
..\xlnt\source\utils\date.cpp:130:73 error: too many initializers for 'tm' 130 | std::tm tm{0,0,0,day,month -1,year -1900,0,0,0,0, nullptr}
Using Visual Studio 2019, all went well I'm on Windows 10 (64 bit)