Skip to content

Use add_definitions instead of set(CMAKE_CXX_FLAGS) to fix Windows build#14

Merged
cen1 merged 1 commit intoBNETDocs:masterfrom
nielsAD:cmake
Jul 1, 2018
Merged

Use add_definitions instead of set(CMAKE_CXX_FLAGS) to fix Windows build#14
cen1 merged 1 commit intoBNETDocs:masterfrom
nielsAD:cmake

Conversation

@nielsAD
Copy link
Copy Markdown
Contributor

@nielsAD nielsAD commented Jul 1, 2018

I was experiencing linking errors on Windows when building with MSYS2 x64. Using add_definitions instead of set(CMAKE_CXX_FLAGS) fixes this. I took the liberty to fix the following issues as well:

  • Fix indentation (tabs to spaces, as per CMake policy)
  • Use CMAKE_MODULE_PATH relative to PROJECT_SOURCE_DIR to fix builds outside of project directory

Other changes:
 * Fix indentation in CMakeLists.txt (tabs to spaces)
 * Fix CMake builds outside of project directory
@cen1 cen1 merged commit ac49c82 into BNETDocs:master Jul 1, 2018
@cen1
Copy link
Copy Markdown
Contributor

cen1 commented Jul 1, 2018

Looks good to me. Merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants