Skip to content

Commit

Permalink
CMake: Enable WIN32 on MINGW
Browse files Browse the repository at this point in the history
Strangely, this doesn't seem to be automatic; but when compiling with
MinGW we really are compiling for Windows, so set the WIN32 variable to
ON.

Signed-off-by: Paul Cercueil <[email protected]>
  • Loading branch information
pcercuei committed Apr 22, 2021
1 parent f8aeded commit 33fad06
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ message(STATUS "cmake version: ${CMAKE_VERSION}")
cmake_minimum_required(VERSION 2.8.7)
project(libiio C)

if (MINGW)
set(WIN32 ON)
endif()

set(LIBIIO_VERSION_MAJOR 0)
set(LIBIIO_VERSION_MINOR 21)
set(VERSION "${LIBIIO_VERSION_MAJOR}.${LIBIIO_VERSION_MINOR}")
Expand Down

0 comments on commit 33fad06

Please sign in to comment.