Closed d3vv closed 6 years ago
Can you make the changes and turn this into a pull request?
@mstembera No, I can't
Changing C++11 to C++14 can be done only after SF9 is out because it is a big change and will make many compilers obsolete, so it is really not something you want to do now.
Let's reopen this one after we have decided to switch to C++14
Native Clang 5 for Windows (not mingw/msys/cygwin) using msvc libraries if its installed. Such clang will produce a "static" binary as well. Consequently we need "-Xclang -flto-visibility-public-std" CXXFLAGS into Makefile for successfully compilation. Moreover we need to remove -latomic and -lpthread from LDFLAGS. That is not all :)) If you have modern includes from Visual Studio 2017 for example, we need to replace -std=c++11 with -std=c++14 which is logical. In this case we will see characteristic warnings such as:
In file included from benchmark.cpp:26: In file included from ./position.h:29: In file included from ./bitboard.h:26: ./types.h:64:11: warning: 'IS_64BIT' macro redefined [-Wmacro-redefined]
define IS_64BIT
define IS_64BIT 1
1 warning generated.
As for mingw/msys/cygwin for -static LDFLAGS, we need CXXFLAGS="-Xclang -flto-visibility-public-std" too.
Unfortunately "profile-build" doesn't work for clang on windows. We can use just "build" only.
Would you like to do changes for Makefile with my suggestions? :)))