TimothyGu/libilbc

CMake will fail if it is lower than CMake 3.12

ccodere opened this issue · 2 comments

When trying to build using CMake 3.9.6 it will fail because it does not recognize the HOMEPAGE_URL in the project() command in CMakeLists.txt. Recommendation is to either update cmake_minimum_required to version 3.12, which seems the first time the HOMEPAGE_URL keyword is recognized, or as i did to build on my side, remove the HOMEPAGE_URL in project() command.

Exact error in CMake GUI 3.9.6:
Missing variable is:
CMAKE_HOMEPAGE_URL_COMPILER_ENV_VAR
CMake Error: Error required internal CMake variable not set, cmake may not be built correctly.
Missing variable is:
CMAKE_HOMEPAGE_URL_COMPILER

Thank you for this note. I'm trying to gauge how important it is to keep compatibility with older CMake versions. ​How did you install CMake? did you do so through a package manager or did you install it yourself? Would it be possible for you to upgrade to a higher CMake version?

I think the whole cmake_minimum_required idea is good, but hard to execute in practice, since we have no way of regularly testing ~15 different CMake versions from 3.5–3.19. My personal preference would be to just bump the minimum required version.

I installed and downloaded it manually, and i just downloaded CMake version 3.12.4 (3.12) and it worked perfectly with no change, so i have no issue if you bump the minimum required version on my side.