summaryrefslogtreecommitdiffstats
path: root/cmake (follow)
Commit message (Collapse)AuthorAgeFilesLines
...
* | cmake: add ndctl and daxctl to build pmdkYin Congmin2022-07-121-7/+11
| | | | | | | | | | | | | | | | | | | | | | In order to enable the pmem character device, add ndctl=y to the parameter of compiling the pmdk library when WITH_BLUESTORE_PMEM is ON. Because after find_ndctl and find_daxctl are added, the dependency packages required by WITH_BLUESTORE_PMEM and WITH_RBD_RWL become more different. So separated these two. libpmem has no version required. libpmemobj required version >=1.8. Signed-off-by: Yin Congmin <congmin.yin@intel.com>
* | cmake: add findndctl and finddaxctl functionYin Congmin2022-07-122-0/+84
| | | | | | | | | | | | | | | | | | | | | | | | In order to support the character device of pmem usage in bluestore via libpmem built by Ceph itself, we need to enable daxctl and ndctl dependency. add the installation of ndctl and find it. the version of ndctl and daxctl library requires >63. "apt-get install" meet the version under ubuntu focal. the installation of ndctl-devel in ceph.spec.in has not been verified. Signed-off-by: Yin Congmin <congmin.yin@intel.com>
* | Merge pull request #46835 from CongMinYin/wip-install-pmdkKefu Chai2022-06-283-68/+68
|\ \ | | | | | | | | | | | | | | | install-deps: install pmdk libraries Reviewed-by: Ilya Dryomov <idryomov@gmail.com> Reviewed-by: Kefu Chai <tchaikov@gmail.com>
| * | cmake: rename a series of pmem libraries to pmdkYin Congmin2022-06-273-68/+68
| | | | | | | | | | | | | | | | | | | | | | | | At first, libpmem was the only library. Later, pmem related libraries such as libpmemobj and libpmem2 were gradually added. These libraries were also integrated into one named pmdk. So rename to pmdk. Signed-off-by: Yin Congmin <congmin.yin@intel.com>
* | | cmake: remove git fetch and use submodule for building opentelemetry libDeepika Upadhyay2022-06-221-8/+4
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We were using git fetch and an unofficial remote to fetch opentelemetry-cpp, as it needed additional patch to include boost headers, with the merge of open-telemetry/opentelemetry-cpp#1100 open-telemetry/opentelemetry-cpp#1020 we do not require to maintain our own patched version. Also, we were using git fetch as a temporary change, now that tracing is always on, it should be right time to adapt to using opentelemetry-cpp as a submodule. This removes compile time fetch for opentelemetry-cpp instead use official opentelemetry-cpp lib as a submodule. Signed-off-by: Deepika Upadhyay <dupadhya@redhat.com>
* / cmake: pass -Wno-error when building PMDKIlya Dryomov2022-06-091-1/+1
|/ | | | | | | | | It's hitting pacific with a nuisance -Werror=array-parameter= const char * vs const char[37] mismatch. Follow commit 91a616b26e83 ("cmake: pass RTE_DEVEL_BUILD=n when building dpdk") and just disable -Werror. Fixes: https://tracker.ceph.com/issues/55977 Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
* Merge pull request #44684 from zenomri/wip-omri-tracing-compiledYuval Lifshitz2022-06-021-8/+10
|\ | | | | tracer: set tracing compiled in by default
| * cmake: change build type of opentelemtry to ReleaseOmri Zeneva2022-05-171-0/+1
| | | | | | | | Signed-off-by: Omri Zeneva <ozeneva@redhat.com>
| * cmake: use BOOST_ROOT if building with system boostDeepika Upadhyay2022-05-171-3/+5
| | | | | | | | Signed-off-by: Deepika Upadhyay <dupadhya@redhat.com>
| * cmake: create jaeger_base target for consuming tracing librariesDeepika Upadhyay2022-05-171-2/+2
| | | | | | | | Signed-off-by: Deepika Upadhyay <dupadhya@redhat.com>
| * cmake: include opentelemetry include directoriesDeepika Upadhyay2022-05-171-4/+3
| | | | | | | | Signed-off-by: Deepika Upadhyay <dupadhya@redhat.com>
* | Merge pull request #44264 from tchaikov/wip-mipelKefu Chai2022-05-211-3/+17
|\ \ | |/ |/| | | | | cmake: do not use GCC extension when detecting 16-byte atomic op Reviewed-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
| * cmake: do not use GCC extension when detecting 16-bit atomic opKefu Chai2022-03-101-3/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | we have following error when trying to compile the C++ source file on mipsel: /usr/bin/c++ -DHAVE_CXX11_ATOMIC -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -g1 -Wdate-time -D_FORTIFY_SOURCE=2 -std=c++11 -fPIE -o CMakeFiles/cmTC_9f34f.dir/src.cxx.o -c /<<PKGBUILDDIR>>/obj-mipsel-linux-gnu/CMakeFiles/CMakeTmp/src.cxx /<<PKGBUILDDIR>>/obj-mipsel-linux-gnu/CMakeFiles/CMakeTmp/src.cxx:15:44: error: template argument 1 is invalid 15 | bool atomic16(std::atomic<unsigned __int128> *ptr) | ^ /<<PKGBUILDDIR>>/obj-mipsel-linux-gnu/CMakeFiles/CMakeTmp/src.cxx:15:44: error: template argument 1 is invalid /<<PKGBUILDDIR>>/obj-mipsel-linux-gnu/CMakeFiles/CMakeTmp/src.cxx:15:44: error: template argument 1 is invalid /<<PKGBUILDDIR>>/obj-mipsel-linux-gnu/CMakeFiles/CMakeTmp/src.cxx:15:44: error: template argument 1 is invalid /<<PKGBUILDDIR>>/obj-mipsel-linux-gnu/CMakeFiles/CMakeTmp/src.cxx:15:47: error: ‘ptr’ was not declared in this scope 15 | bool atomic16(std::atomic<unsigned __int128> *ptr) | ^~~ the compiler was GCC 11.2.0. in this change, instead of detecting the architecture, check for the macro of `__SIZEOF_INT128__`, which is respected by GCC and Clang. so it's more readable. also, instead of using the `unsigned __int128` type provided as a GCC extension, use a struct to mimic the use case of boost::lockfree library. Signed-off-by: Kefu Chai <tchaikov@gmail.com>
* | Merge pull request #46103 from tchaikov/cmake-alloc-cleanupKefu Chai2022-05-041-3/+9
|\ \ | | | | | | | | | | | | cmake: re-enable TCMalloc and allocator related cleanups Reviewed-by: Samuel Just <sjust@redhat.com>
| * | cmake/modules/BuildFIO: specify the full path to alloc librariesKefu Chai2022-05-021-3/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | before this change, we assume that "ALLOCATOR" is the library name which can be found by linker with "ld -l <namespec>". but ideally, cmake can find a library in a more sophiscated way used by its "find_library()" implementation. so, in this change, instead of relying on the default paths looked up by "ld", use the path found by cmake. Signed-off-by: Kefu Chai <tchaikov@gmail.com>
* | | Merge pull request #45845 from SUSE/wip-fix-55237Ilya Dryomov2022-05-041-9/+11
|\ \ \ | |/ / |/| | | | | | | | | | | ceph.spec.in: openSUSE: require gcc11-c++, disable parquet Reviewed-by: Ilya Dryomov <idryomov@gmail.com> Reviewed-by: Kefu Chai <tchaikov@gmail.com>
| * | ceph.spec.in: openSUSE: require gcc11-c++, disable parquetTim Serong2022-04-291-9/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit also explicilty sets the toolset when calling boost's bootstrap.sh, because the latter is only capable of autodetecting gcc if you have an unversioned `g++` in the path, which may not be the case if only gcc11-c++ is installed (the unversioned gcc-c++ package includes the /usr/bin/g++ symlink, but depending on which version of openSUSE we build on, that might point to a different gcc version, so we don't want to use that). Fixes: https://tracker.ceph.com/issues/55237 Signed-off-by: Tim Serong <tserong@suse.com>
* | | cmake/modules: use exact version of python3 when finding cythonKefu Chai2022-04-212-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * CMakeLists.txt: always pass "EXACT" to find_package(Python3). because per cmake document, "EXACT" only takes effect when <Package>_FIND_VERSION_COUNT is greater than 1, where <Package> is "Python3". see also cmake/modules/FindPython/Support.cmake * cmake/modules/AddCephTest.cmake: drop redundant find_package(Python3) calls. since Python3 is a mandatory requirement for building Ceph, we only need a single call of find_package(Python3..) in the top of the source tree. the only possible case to repeat it is to ensure that we have the correct version of Python3 used in following CMake script. but there is no need to repeat it if we just want to ensure that we have a python3 interpretor in place. * cmake/modules/Distutils.cmake: always pass "EXACT" to find_package(Python3). we should always pass EXACT to find_package() when finding python3, this is a follow-up of e2babdfae8c99f39f99a7c8a8f966299b2e62b19 Signed-off-by: Kefu Chai <tchaikov@gmail.com>
* | | Merge pull request #44230 from optimistyzy/122_add_dmlKefu Chai2022-04-201-0/+58
|\ \ \ | | | | | | | | | | | | | | | | blk/pmem: use DML library to offload read/write operations in pmem Reviewed-by: Kefu Chai <tchaikov@gmail.com>
| * | | Add the support to use DML library for PMEM device.Ziye Yang2022-04-191-0/+58
| |/ / | | | | | | | | | | | | | | | | | | | | | The purpose of this patch is to add the initial support to offload memory/pmem operations by sync usage through hardware path in DML library. Signed-off-by: Ziye Yang <ziye.yang@intel.com>
* / / cmake/modules: always use the python3 specified in command lineKefu Chai2022-04-161-0/+11
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | if another python3 with higher version is found by find_package(Python3), the cmake's install script would just install the python modules/extensions into that python3's dist-package directory, and the packaging script would fail to find these artifacts when trying to package them. so we need to ensure that the install directories for python modeules/extensions are always "versioned" with WITH_PYTHON3 cmake option. Signed-off-by: Kefu Chai <tchaikov@gmail.com>
* | cmake/modules: avoid using distutilsKefu Chai2022-03-251-1/+1
| | | | | | | | | | | | | | | | | | to address following warning from python 3.9: <string>:1: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives <string>:1: DeprecationWarning: The distutils.sysconfig module is deprecated, use sysconfig instead Signed-off-by: Kefu Chai <tchaikov@gmail.com>
* | cmake/modules: drop a cmake variableKefu Chai2022-03-251-2/+1
| | | | | | | | | | | | less redirections Signed-off-by: Kefu Chai <tchaikov@gmail.com>
* | cmake: move Arrow targets into find_package modulesCasey2022-03-142-0/+22
| | | | | | | | Signed-off-by: Casey <cbodley@redhat.com>
* | cmake: use arrow's find_package modulesCasey2022-03-142-0/+592
| | | | | | | | Signed-off-by: Casey <cbodley@redhat.com>
* | cmake: add submodule for utf8proc at v2.2.0Casey Bodley2022-03-142-0/+168
| | | | | | | | | | | | | | | | | | | | | | | | | | | | adds utf8proc submodule, needed by the arrow submodule in centos. add a WITH_SYSTEM_UTF8PROC option that controls whether or not utf8proc is built from submodule non-system utf8proc is built as a static library to avoid conflicts with system-provided libraries ceph.spec.in sets WITH_SYSTEM_UTF8PROC=OFF until it's available in centos Signed-off-by: Casey Bodley <cbodley@redhat.com>
* | cmake: add submodule for Apache Arrow at v6.0.1Casey Bodley2022-03-142-2/+148
|/ | | | | | | | adds an arrow submodule. when WITH_RADOSGW_SELECT_PARQUET is enabled, the submodule is built as an external project and rgw links against its imported Arrow::Parquet target Signed-off-by: Casey Bodley <cbodley@redhat.com>
* cmake: pass RTE_DEVEL_BUILD=n when building dpdkKefu Chai2022-03-051-1/+1
| | | | | | | | | | | | | | | | | | | | ceph is still using the Makefile based building system for building DPDK. and DPDK enables -Werror if RTE_DEVEL_BUILD is 'y' which is enabled by default when the dpdk is built from a git repo. but newer GCC is more picky than the older versions, to prevent the possible FTBFS when we switch to newer GCC for building old branches whose dpdk submodule might be include the changes addressing those warnings. let's just disable this option. the only effect of this option is to add -Werror to CFLAGS. but the building warnings from DPDK is not our focus when developing Ceph in the most cases. so it should be fine. see also https://github.com/ceph/dpdk/blob/eac901ce29be559b1bb5c5da33fe2bf5c0b4bfd6/doc/build-sdk-quick.txt#L18 Signed-off-by: Kefu Chai <tchaikov@gmail.com>
* cmake: use string(JOIN ..) to compose URL for boost downloadKefu Chai2022-03-021-8/+4
| | | | | | | | | * since the minimum required cmake version is now 3.16, there is no need to check for cmake version for using multiple URLs for downloading external project. * use string(JOIN ..) to compose URL option for downloading boost Signed-off-by: Kefu Chai <tchaikov@gmail.com>
* compressor: fix compilation issues about QATzipMiaomiao Liu2022-02-181-10/+17
| | | | | Signed-off-by: Miaomiao Liu <miaomiao.liu@intel.com> Signed-off-by: Hualong Feng <hualong.feng@intel.com>
* cmake: replace BuildQatDrv.cmake with FindQatDrv.cmakeMiaomiao Liu2022-02-082-33/+80
| | | | | | | | because QAT driver with version v1.7.l.4.14.0 or higher cannot be dowmloaded directly by URL, FindQatDrv.cmake can find the locally installed QAT package and libraries Signed-off-by: Miaomiao Liu <miaomiao.liu@intel.com> Signed-off-by: Hualong Feng <hualong.feng@intel.com>
* cmake/modules/BuildSPDK.cmake: link whole-archiveTongliang Deng2022-01-201-6/+8
| | | | | | | | | | | We build spdk as static library, linking against them requires the use of `-Wl,--whole-archive` as argument, otherwise we will have error `nvme.c: nvme_probe_internal: *ERROR*: NVMe trtype 256 not available`. This is due to the use of constructor functions in spdk to register NVMe transports. So we need to do so to ensure we call all the constructors. Signed-off-by: Tongliang Deng <dengtongliang@sensetime.com>
* cmake: dpdk: only append common dir if it has been foundClément Péron2022-01-131-1/+1
| | | | Signed-off-by: Clément Péron <peron.clem@gmail.com>
* cmake: dpdk: use STREQUAL and not EQUAL when comparing stringsClément Péron2022-01-131-1/+1
| | | | Signed-off-by: Clément Péron <peron.clem@gmail.com>
* cmake: dpdk: fix typo in HINTS when looking for DPDKClément Péron2022-01-131-1/+1
| | | | Signed-off-by: Clément Péron <peron.clem@gmail.com>
* cmake: detect linux/blk/zoned supportKefu Chai2021-12-251-0/+18
| | | | | | | | | | | | | | | * add find_package() support for detecting the existence of linux/blkzoned.h before using it. * link against Linux::ZNS for adding the compilation definition of HAVE_ZNS instead of including it in the global config.h * move the CMake option closer to where it is used for better readability. as this option takes effect only if crimson is compiled. * make WITH_ZNS an option which depends on the value of CMAKE_SYSTEM_NAME. it is hidden and off if CMAKE_SYSTEM_NAME is not "Linux". Signed-off-by: Kefu Chai <tchaikov@gmail.com>
* Merge pull request #43598 from ideepika/wip-opentelemetryJosh Durgin2021-12-223-124/+87
|\ | | | | | | | | | | migrate from using opentracing-cpp to opentelemetry-cpp static as distributed tracing API Reviewed-by: Yuval Lifshitz <ylifshit@redhat.com> Reviewed-by: Josh Durgin <jdurgin@redhat.com>
| * cmake: cleanup BuildJaeger as external projectDeepika Upadhyay2021-11-241-85/+0
| | | | | | | | | | | | | | | | | | | | replaced by Opentelemetry project, remove building and linking of jaeger libraries. * remove externalProject building * linking of jaegertracing dependencies to ceph project Signed-off-by: Deepika Upadhyay <dupadhya@redhat.com>
| * debian: remove libjaeger packagingDeepika Upadhyay2021-11-241-1/+1
| | | | | | | | | | | | | | we no longer need to package libjaeger, as we would be using libopentelemetry static libraries(until we support shared). Signed-off-by: Deepika Upadhyay <dupadhya@redhat.com>
| * cmake: replace opentracing-cpp with opentelemetry-cppDeepika Upadhyay2021-11-243-46/+94
| | | | | | | | | | | | | | | | | | | | | | | | | | | | we build and use targets needed for jaeger to work with opentelemetry referring: https://github.com/open-telemetry/opentelemetry-cpp/blob/main/examples/jaeger/CMakeLists.txt right now we need a patch for using thrift from distro packages, hence we are using GIT_FETCH based externalProject method, for development purpose, which will be replace by more reliable method in future. NOTE: phase 1, still needs to be tested. Signed-off-by: Deepika Upadhyay <dupadhya@redhat.com>
* | Merge pull request #43612 from adamemerson/wip-unlevelingYuri Weinstein2021-12-111-18/+0
|\ \ | | | | | | | | | | | | build: Remove LevelDB support Reviewed-by: Kefu Chai <kchai@redhat.com>
| * | build: Remove LevelDB supportAdam C. Emerson2021-11-011-18/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Whereas new LevelDB packages are build with -fno-rtti and break our attempts to compile against them, and whereas LevelDB has been deprecated for some time, with the Ceph team expending great effort to migrating OSDs off of it, let it be therefore removed. Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
* | | cmake: test for 16-byte atomic support on mips alsoKefu Chai2021-11-231-1/+1
| |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | it's reported that a mips64el build host is able to pass the test of CheckCxxAtomic without linking against libatomic, while librbd.so fails to link due to failures like /usr/bin/ld: ../../../lib/librbd.so.1.16.0: undefined reference to `__atomic_store_16' /usr/bin/ld: ../../../lib/librbd.so.1.16.0: undefined reference to `__atomic_load_16' /usr/bin/ld: ../../../lib/librbd.so.1.16.0: undefined reference to `__atomic_compare_exchange_16' so we have to check the existence of __atomic_load_16 instruction on mips architecture. Signed-off-by: Kefu Chai <tchaikov@gmail.com>
* | cmake: check for python(\d)\.(\d+) when building boostKefu Chai2021-11-181-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | now that python3.10 has two digits as its minor version, we should be able to match it. this change fixes the build with python3.10. without this change, we'd have error: wrong library name 'python310' in the --with-<library> option. when building with python3.10 Signed-off-by: Kefu Chai <tchaikov@gmail.com>
* | Merge pull request #31877 from rosinL/wip-fix-dpdk-linkKefu Chai2021-10-291-7/+5
|\ \ | | | | | | | | | | | | cmake: link against DPDK shared libraries to avoid DPDK EAL double initialization Signed-off-by: Kefu Chai <tchaikov@gmail.com>
| * | cmake: link DPDK shared libraries to avoid DPDK initialization failureChunsong Feng2021-10-141-7/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The common_async_dpdk library depends on the dpdk librte_eal file. If the static library is used, the dependency is transferred to libceph-common. By default, libceph-common uses the PUBLIC keyword, the keyword PUBLIC determines that both the application and libceph-common link to dpdk librte_eal.a. As a result, the global variables in dpdk librte_eal.a has two copies. So link DPDK shared libs to avoid DPDK initialization failure. Fixes: https://tracker.ceph.com/issues/42861 Signed-off-by: Chunsong Feng <fengchunsong@huawei.com> Signed-off-by: luorixin <luorixin@huawei.com>
* | | cmake: add support for python 3.10Kai Kang2021-10-221-1/+1
| |/ |/| | | | | Signed-off-by: Kai Kang <Kai.Kang@windriver.com>
* | cmake: only pass --verbose when VERBOSE env variable is setKefu Chai2021-10-141-3/+9
|/ | | | | | | so that the setuptools is less chatty by default when building python bindings. Signed-off-by: Kefu Chai <tchaikov@gmail.com>
* cmake,rgw: use jaeger-base target, as a dependency for building dbstoreDeepika Upadhyay2021-10-042-2/+2
| | | | | | | | | | * dbstore also has tracing dependencies and missing linking for libraries * use `using` keyword in common/tracer.cc to silence unused method warnings * log building of external project jaegertracing, opentracing into build file, (done to reduce external project build verbosity) Signed-off-by: Deepika Upadhyay <dupadhya@redhat.com>
* Merge pull request #42870 from ktdreyer/cmake-thread-libs-initKefu Chai2021-09-041-1/+2
|\ | | | | | | | | | | cmake: link Threads::Threads instead of CMAKE_THREAD_LIBS_INIT Reviewed-by: Deepika Upadhyay <dupadhya@redhat.com> Reviewed-by: Kefu Chai <tchaikov@gmail.com>