From 14a25c8510ece24a738bf9c60419d05d8968a1a6 Mon Sep 17 00:00:00 2001 From: Natalia Portillo Date: Thu, 11 Mar 2021 13:35:13 +0000 Subject: [PATCH] Add cmake file for cross compiling using MingW. --- setter/CMakeLists.txt | 2 +- setter/src/win32/CMakeLists.txt | 16 ++++++++++++++++ 2 files changed, 17 insertions(+), 1 deletion(-) create mode 100644 setter/src/win32/CMakeLists.txt diff --git a/setter/CMakeLists.txt b/setter/CMakeLists.txt index 1a42865..9859079 100644 --- a/setter/CMakeLists.txt +++ b/setter/CMakeLists.txt @@ -9,5 +9,5 @@ add_subdirectory(src) add_subdirectory(src/dos) add_subdirectory(src/unix) add_subdirectory(src/linux) - +add_subdirectory(src/win32) diff --git a/setter/src/win32/CMakeLists.txt b/setter/src/win32/CMakeLists.txt new file mode 100644 index 0000000..7cf01d2 --- /dev/null +++ b/setter/src/win32/CMakeLists.txt @@ -0,0 +1,16 @@ +if(NOT ${CMAKE_SYSTEM_NAME} MATCHES "Windows") + return() +endif() + +project( + fssetter-win32 + DESCRIPTION "Filesystem test creator for 32-bit and 64-bit Windows" + LANGUAGES C) + +set(PLATFORM_SOURCES win32.c) + +set(EXECUTABLE_NAME "fssetter-${CMAKE_SYSTEM_NAME}-${CMAKE_SYSTEM_PROCESSOR}") + +add_executable(${EXECUTABLE_NAME} ${PLATFORM_SOURCES}) + +target_link_libraries(${EXECUTABLE_NAME} core) \ No newline at end of file