Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cpp runtime does not build using CMake 3.2 #1809

Closed
ryanbinns opened this issue Apr 4, 2017 · 0 comments
Closed

Cpp runtime does not build using CMake 3.2 #1809

ryanbinns opened this issue Apr 4, 2017 · 0 comments

Comments

@ryanbinns
Copy link

cmake complains with:

CMake Error at CMakeLists.txt:31 (CMAKE_POLICY):
  Policy "CMP0059" is not known to this version of CMake.

when using CMake 3.2. Policy CMP0059 was only introduced with CMake 3.3, although the README.md specifies a minimum CMake version of 2.8. This block of code is the issue:

if(CMAKE_VERSION VERSION_EQUAL "3.0.0" OR
   CMAKE_VERSION VERSION_GREATER "3.0.0")
  CMAKE_POLICY(SET CMP0026 OLD)
  CMAKE_POLICY(SET CMP0045 OLD)
  CMAKE_POLICY(SET CMP0042 OLD)
  CMAKE_POLICY(SET CMP0059 OLD)
endif()

I have changed it to the following and it compiled fine:

if(CMAKE_VERSION VERSION_EQUAL "3.0.0" OR
   CMAKE_VERSION VERSION_GREATER "3.0.0")
  CMAKE_POLICY(SET CMP0026 OLD)
  CMAKE_POLICY(SET CMP0045 OLD)
  CMAKE_POLICY(SET CMP0042 OLD)
endif()
if(CMAKE_VERSION VERSION_EQUAL "3.3.0" OR
   CMAKE_VERSION VERSION_GREATER "3.3.0")
  CMAKE_POLICY(SET CMP0059 OLD)
endif()
@parrt parrt closed this as completed in 1503821 Apr 17, 2017
parrt added a commit that referenced this issue Apr 17, 2017
Small fix in cmake file. Fixes #1809.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant