问题描述
我正在尝试在CentOS 7上构建。不幸的是,我有尝试猜测依赖项,因为它们未在 p>
I am attempting to build massif-visualizer on CentOS 7. Unfortunately I'm having to try to guess at dependencies as they are not all listed in the INSTALL file. So far:
yum install git yum install kdelibs-devel extra-cmake-modules \ qt5-qtsvg-devel qt5-qtxmlpatterns-devel \ kf5-kparts-devel kf5-karchive-devel git clone https://github.com/KDE/massif-visualizer cd massif-visualizer mkdir build (cd build && cmake .. && make && make install)
Those Qt5 and KF5 packages were added to the yum command largely by trial and error, and some pattern-matching from CMake error messages … but I cannot seem to figure out how to resolve these last errors:
-- Could not set up the appstream test. appstreamcli is missing. CMake Error at /usr/lib64/cmake/KF5Archive/KF5ArchiveConfig.cmake:37 (include): include could not find load file: CMakeFindDependencyMacro Call Stack (most recent call first): /usr/share/ECM/find-modules/FindKF5.cmake:74 (find_package) CMakeLists.txt:34 (find_package) CMake Error at /usr/lib64/cmake/KF5Archive/KF5ArchiveConfig.cmake:38 (find_dependency): Unknown CMake command "find_dependency". Call Stack (most recent call first): /usr/share/ECM/find-modules/FindKF5.cmake:74 (find_package) CMakeLists.txt:34 (find_package)
Is this because, on CentOS 7, CMake (2.8.12.2) is too old? Or something else?
Yes, CMake 2.8.12.2 is too old. Use CMake 3 instead:
yum install epel-release yum install cmake3 (cd build && cmake3 .. && make && make install) # ^
Now the installation complains about KChart but that's a separate issue.
In the end, here are my complete steps:
yum install epel-release yum install subversion git cmake3 tar wget yum install boost boost-devel yum install kdelibs-devel extra-cmake-modules \ graphviz-devel kdepim-devel \ qt5-qtsvg-devel qt5-qtxmlpatterns-devel \ kf5-kparts-devel kf5-karchive-devel \ kf5-kiconthemes-devel kf5-kdoctools-devel git clone https://github.com/KDE/massif-visualizer wget https://download.kde.org/stable/kgraphviewer/2.4.0/kgraphviewer-2.4.0.tar.xz wget https://download.kde.org/stable/kdiagram/2.6.0/src/kdiagram-2.6.0.tar.xz tar xf kgraphviewer-2.4.0.tar.xz tar xf kdiagram-2.6.0.tar.xz for DIR in kgraphviewer-2.4.0 kdiagram-2.6.0 massif-visualizer do cd $DIR mkdir build (cd build && cmake3 .. && make && make install) cd - done
Then valgrind --tool=massif myApp and finally massif-visualiser massif.out.<PID> from a terminal inside a KDE session.
这篇关于构建Massif-Visualizer:包含找不到加载文件CMakeFindDependencyMacro的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!