bug fixes

This commit is contained in:
jusax23 2023-11-06 21:21:11 +01:00
parent 600900468d
commit c17fbb11af
Signed by: jusax23
GPG key ID: 499E2AA870C1CD41
3 changed files with 4 additions and 2 deletions

1
.gitignore vendored
View file

@ -31,6 +31,7 @@ build/
trash trash
.github .github
.vscode .vscode
.vs
# Files from build # Files from build
**/*.o **/*.o

View file

@ -6,7 +6,7 @@ cmake_minimum_required(VERSION 3.18)
project(flutter_stockfish_plugin VERSION 0.0.1 LANGUAGES CXX) project(flutter_stockfish_plugin VERSION 0.0.1 LANGUAGES CXX)
file(GLOB_RECURSE cppPaths "Stockfish/src/*.cpp") file(GLOB_RECURSE cppPaths "Stockfish/src/*.cpp")
set(CMAKE_CXX_STANDARD 17) set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3 -flto -DNDEBUG -fPIC") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++17 -O3 -flto -DNDEBUG -fPIC")
set(NNUE_NAME nn-5af11540bbfe.nnue) set(NNUE_NAME nn-5af11540bbfe.nnue)
add_library(flutter_stockfish_plugin SHARED add_library(flutter_stockfish_plugin SHARED

View file

@ -19,8 +19,9 @@ bool fake_get_pgmptr(char** ptr) {
WideCharToMultiByte(CP_UTF8, 0, buffer, -1, narrowBuffer, MAX_PATH, WideCharToMultiByte(CP_UTF8, 0, buffer, -1, narrowBuffer, MAX_PATH,
NULL, NULL); NULL, NULL);
*ptr = narrowBuffer; *ptr = narrowBuffer;
return false;
} }
return false; return true;
} }
#endif #endif
#endif #endif