diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 29e4a8a7..7423a956 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -528,6 +528,9 @@ jobs: name: Windows 2022 Emulation Root path: build/release/artifacts/root + - name: Copy Test Sample + run: cp build/release/artifacts/test-sample.exe build/release/artifacts/root/filesys/c/ + - name: CMake Test run: cd build/release/artifacts && ./windows-emulator-test.exe env: diff --git a/cmake/compiler-env.cmake b/cmake/compiler-env.cmake index c94b21b1..d6d1739e 100644 --- a/cmake/compiler-env.cmake +++ b/cmake/compiler-env.cmake @@ -64,6 +64,13 @@ endif() ########################################## if(MINGW) + add_link_options( + -static-libstdc++ + -static-libgcc + -static + -lwinpthread + ) + momo_add_c_and_cxx_compile_options( -Wno-array-bounds ) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 6c71b182..300b763d 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -9,9 +9,6 @@ momo_add_subdirectory_and_get_targets("backends" BACKEND_TARGETS) momo_targets_set_folder("backends" ${BACKEND_TARGETS}) if (NOT MOMO_BUILD_AS_LIBRARY) - if (MINGW) - add_link_options(-static-libstdc++ -static -lwinpthread) - endif() add_subdirectory(analyzer) add_subdirectory(debugger) add_subdirectory(fuzzing-engine)