将 OpenCV 构建为 deb 包:CPackDeb:文件实用程序不可用

building OpenCV as deb package: CPackDeb: file utility is not available

我正在 Ubuntu 18.04 上构建 OpenCV 4.1 作为 deb 包。建库成功后。我正在调用 make package 并收到以下错误:

CPack: Create package CMake Error at /usr/share/cmake-3.10/Modules/CPackDeb.cmake:622 (message): CPackDeb: file utility is not available. CPACK_DEBIAN_PACKAGE_SHLIBDEPS and CPACK_DEBIAN_PACKAGE_GENERATE_SHLIBS options are not available. Call Stack (most recent call first): /usr/share/cmake-3.10/Modules/CPackDeb.cmake:1119 (cpack_deb_prepare_package_vars)

有人知道如何解决吗?

只需要安装file包:apt install file