]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
cmake: require CMake v3.10.2 29291/head
authorKefu Chai <kchai@redhat.com>
Wed, 24 Jul 2019 16:57:27 +0000 (00:57 +0800)
committerKefu Chai <kchai@redhat.com>
Fri, 2 Aug 2019 14:09:12 +0000 (22:09 +0800)
commitbbb69fe793948d0791e29f547e18f8fa996c32ea
tree622e1fa7b99251567a3513daff25c00fbe0c052f
parentddacfcc0e04341fa9ff2de520fe04687de41ab22
cmake: require CMake v3.10.2

since we dropped the support of xenial, we now have the luxury of using
newer CMake! and by using CMake 3.10.2, we can prevent libfmt from
assuming that we are using C++11, and hence set `CMAKE_CXX_STANDARD` to
11, which will literally append `-std=gnu++11` to `CMAKE_CXX_FLAGS`.
the last `-std` option passed to `g++` takes precendence.
since we've switched over to C++17, and we are using C++17 features.
so, using cmake older than 3.8 breaks the build. because it is CMake 3.8
which stared support `CMAKE_CXX_STANDARD` 17.

- for bionic: https://packages.ubuntu.com/bionic/cmake : 3.10.2
- for CentOS7:
https://dl.fedoraproject.org/pub/epel/7/x86_64/Packages/c/ : 3.13.5

so in this change,

* bump up the required version to v3.10.2
* cleanups to wipe out the workaround for lower CMake versions
* use `PROJECT_VERSION` defined by `project()` command instead of
  `VERSION` explicitly defined.

Signed-off-by: Kefu Chai <kchai@redhat.com>
CMakeLists.txt
alpine/APKBUILD.in
ceph.spec.in
cmake/modules/FindStdFilesystem.cmake
make-dist
src/CMakeLists.txt
src/include/config-h.in.cmake
src/libcephfs.cc