For a school project I am trying to set up SFML on my computer that runs Windows 10. The assignment is developing a small engine, based on SFML, in a few weeks. I am very new to C++, and I am not used to the working pipeline and the ways of C++ development yet.
At the moment I am trying to set things up so that I can work on the project from home, but I have a lot of trouble understanding and setting things up, since it's very different to what I'm use to.
My CMakeLists.txt file looks like the following:
cmake_minimum_required(VERSION 2.8.4)
project(CppEngine)
set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/cmake_modules")
if(WIN32)
set(SFML_ROOT "$ENV{PROGRAMFILES(x86)}/SFML")
endif(WIN32)
set(CMAKE_BUILD_TYPE Release)
find_package(SFML 2.1 COMPONENTS system window graphics REQUIRED)
include_directories(${SFML_INCLUDE_DIR} ${PROJECT_SOURCE_DIR})
set(SOURCE_FILES main.cpp )
set(HEADER_FILES )
add_executable(CppEngine ${SOURCE_FILES} ${HEADER_FILES})
target_link_libraries(CppEngine ${SFML_LIBRARIES})
I get a very strange error message, as a result, whenever I try to compile and run. It is particularly strange, because I am running on Windows:
error: #error This UNIX operating system is not supported by SFML library #error This UNIX operating system is not supported by SFML library
How can I fix this error?