I am trying to build a project using PCL with cmake. It used to build fine until today. Now I am getting the following error:
-- Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE)
CMake Error at /usr/local/share/pcl-1.9/PCLConfig.cmake:58 (message):
simulation is required but glew was not found
Call Stack (most recent call first):
/usr/local/share/pcl-1.9/PCLConfig.cmake:361 (pcl_report_not_found)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:6 (find_package)
I am using Mac OS X Mojave (10.14) and PCL (1.9) is installed through homebrew. Everything is up to date and brew doctor doesn't bring up any issues. All symlinks seem to be ok. GLEW is also installed under /usr/local/Cellar/glew/ and it's also the current version (2.1.0).
There seem to have been issues with the PCLConfig.cmake (see here). However this doesn't seem to fix the issue anymore.. can't find the required line as specified in the other thread.
Unfortunately I am not very firm in cmake and don't really know what to do. Any help is appreciated!
This is what the the full cmake output looks like:
/Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/bin/cmake -DCMAKE_BUILD_TYPE=Debug -G "CodeBlocks - Unix Makefiles" /Users/Matthias/Workspaces/CLion/PointCloudEdgeDetector2
-- Eigen found (include: /usr/local/include/eigen3, version: 3.3.7)
CMake Warning at /Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:847 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
/Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:963 (_Boost_COMPONENT_DEPENDENCIES)
/Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:1622 (_Boost_MISSING_DEPENDENCIES)
/usr/local/share/pcl-1.9/PCLConfig.cmake:140 (find_package)
/usr/local/share/pcl-1.9/PCLConfig.cmake:310 (find_boost)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:6 (find_package)
CMake Warning at /Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:847 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
/Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:963 (_Boost_COMPONENT_DEPENDENCIES)
/Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:1622 (_Boost_MISSING_DEPENDENCIES)
/usr/local/share/pcl-1.9/PCLConfig.cmake:140 (find_package)
/usr/local/share/pcl-1.9/PCLConfig.cmake:310 (find_boost)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:6 (find_package)
CMake Warning at /Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:847 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
/Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:963 (_Boost_COMPONENT_DEPENDENCIES)
/Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:1622 (_Boost_MISSING_DEPENDENCIES)
/usr/local/share/pcl-1.9/PCLConfig.cmake:140 (find_package)
/usr/local/share/pcl-1.9/PCLConfig.cmake:310 (find_boost)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:6 (find_package)
CMake Warning at /Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:847 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
/Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:963 (_Boost_COMPONENT_DEPENDENCIES)
/Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:1622 (_Boost_MISSING_DEPENDENCIES)
/usr/local/share/pcl-1.9/PCLConfig.cmake:140 (find_package)
/usr/local/share/pcl-1.9/PCLConfig.cmake:310 (find_boost)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:6 (find_package)
CMake Warning at /Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:847 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
/Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:963 (_Boost_COMPONENT_DEPENDENCIES)
/Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:1622 (_Boost_MISSING_DEPENDENCIES)
/usr/local/share/pcl-1.9/PCLConfig.cmake:140 (find_package)
/usr/local/share/pcl-1.9/PCLConfig.cmake:310 (find_boost)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:6 (find_package)
CMake Warning at /Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:847 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
/Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:963 (_Boost_COMPONENT_DEPENDENCIES)
/Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:1622 (_Boost_MISSING_DEPENDENCIES)
/usr/local/share/pcl-1.9/PCLConfig.cmake:140 (find_package)
/usr/local/share/pcl-1.9/PCLConfig.cmake:310 (find_boost)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:6 (find_package)
CMake Warning at /Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:847 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
/Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:963 (_Boost_COMPONENT_DEPENDENCIES)
/Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:1622 (_Boost_MISSING_DEPENDENCIES)
/usr/local/share/pcl-1.9/PCLConfig.cmake:140 (find_package)
/usr/local/share/pcl-1.9/PCLConfig.cmake:310 (find_boost)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:6 (find_package)
CMake Warning at /Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:847 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
/Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:963 (_Boost_COMPONENT_DEPENDENCIES)
/Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:1622 (_Boost_MISSING_DEPENDENCIES)
/usr/local/share/pcl-1.9/PCLConfig.cmake:140 (find_package)
/usr/local/share/pcl-1.9/PCLConfig.cmake:310 (find_boost)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:6 (find_package)
CMake Warning at /Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:847 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
/Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:963 (_Boost_COMPONENT_DEPENDENCIES)
/Applications/apps/CLion/ch-0/182.4892.24/CLion.app/Contents/bin/cmake/mac/share/cmake-3.12/Modules/FindBoost.cmake:1622 (_Boost_MISSING_DEPENDENCIES)
/usr/local/share/pcl-1.9/PCLConfig.cmake:140 (find_package)
/usr/local/share/pcl-1.9/PCLConfig.cmake:310 (find_boost)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:6 (find_package)
-- Boost version: 1.69.0
-- Found the following Boost libraries:
-- system
-- filesystem
-- thread
-- date_time
-- iostreams
-- serialization
-- chrono
-- atomic
-- regex
-- FLANN found (include: /usr/local/Cellar/flann/1.9.1_7/include, lib: optimized;/usr/local/Cellar/flann/1.9.1_7/lib/libflann_cpp.dylib;debug;/usr/local/Cellar/flann/1.9.1_7/lib/libflann_cpp.dylib)
-- FLANN found (include: /usr/local/Cellar/flann/1.9.1_7/include, lib: optimized;/usr/local/Cellar/flann/1.9.1_7/lib/libflann_cpp.dylib;debug;/usr/local/Cellar/flann/1.9.1_7/lib/libflann_cpp.dylib)
** WARNING ** io features related to pcap will be disabled
** WARNING ** io features related to png will be disabled
** WARNING ** io features related to libusb-1.0 will be disabled
-- QHULL found (include: /usr/local/include, lib: optimized;/usr/local/lib/libqhull_p.dylib;debug;/usr/local/lib/libqhull_p.dylib)
-- Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE)
CMake Error at /usr/local/share/pcl-1.9/PCLConfig.cmake:58 (message):
simulation is required but glew was not found
Call Stack (most recent call first):
/usr/local/share/pcl-1.9/PCLConfig.cmake:361 (pcl_report_not_found)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:6 (find_package)
-- Configuring incomplete, errors occurred!
See also "/Users/Matthias/Workspaces/CLion/PointCloudEdgeDetector2/cmake-build-debug/CMakeFiles/CMakeOutput.log".
[Failed to reload]
I have another suggestion based on another user report. From my tests on our CI, the current master is failing to build under Mojave, but just the simulation module it seems (things which use opengl, glew, glu, glut), so if you're not using that we can side step things. The second thing that I notice is your use of CLion. Can you try things on a regular CMake/make combo as a quick test?
Sorry for taking so long... but by the time you replied I had already switched back to a backup.
Out of sheer curiosity I have switched back now though... reinstalled all of the packages and updated them to the newest versions. For some reason or other it is working now. Not sure if that might have been the culprit, but this time I also updated cmake to the newest version (3.14.2), doesn't seem likely though.
I am interested in your suggested workaround however... might come in handy in the future if it happens again, since I still don't know what caused the initial problem.
Weirdly enough with everything updated to the newest available versions in homebrew I ran into another old issue now though... #2601.
I think this might be the issue, see my comment here https://github.com/PointCloudLibrary/pcl/issues/2997#issuecomment-508894327
I have another suggestion based on another user report. From my tests on our CI, the current master is failing to build under Mojave, but just the simulation module it seems (things which use opengl, glew, glu, glut), so if you're not using that we can side step things. The second thing that I notice is your use of CLion. Can you try things on a regular CMake/make combo as a quick test?
I tried with cmake and make similar error.
CMake Warning at /usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:905 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
/usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:1027 (_Boost_COMPONENT_DEPENDENCIES)
/usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:1709 (_Boost_MISSING_DEPENDENCIES)
/usr/local/share/pcl-1.9/PCLConfig.cmake:140 (find_package)
/usr/local/share/pcl-1.9/PCLConfig.cmake:310 (find_boost)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:5 (find_package)
CMake Warning at /usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:905 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
/usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:1027 (_Boost_COMPONENT_DEPENDENCIES)
/usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:1709 (_Boost_MISSING_DEPENDENCIES)
/usr/local/share/pcl-1.9/PCLConfig.cmake:140 (find_package)
/usr/local/share/pcl-1.9/PCLConfig.cmake:310 (find_boost)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:5 (find_package)
CMake Warning at /usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:905 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
/usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:1027 (_Boost_COMPONENT_DEPENDENCIES)
/usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:1709 (_Boost_MISSING_DEPENDENCIES)
/usr/local/share/pcl-1.9/PCLConfig.cmake:140 (find_package)
/usr/local/share/pcl-1.9/PCLConfig.cmake:310 (find_boost)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:5 (find_package)
CMake Warning at /usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:905 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
/usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:1027 (_Boost_COMPONENT_DEPENDENCIES)
/usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:1709 (_Boost_MISSING_DEPENDENCIES)
/usr/local/share/pcl-1.9/PCLConfig.cmake:140 (find_package)
/usr/local/share/pcl-1.9/PCLConfig.cmake:310 (find_boost)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:5 (find_package)
CMake Warning at /usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:905 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
/usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:1027 (_Boost_COMPONENT_DEPENDENCIES)
/usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:1709 (_Boost_MISSING_DEPENDENCIES)
/usr/local/share/pcl-1.9/PCLConfig.cmake:140 (find_package)
/usr/local/share/pcl-1.9/PCLConfig.cmake:310 (find_boost)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:5 (find_package)
CMake Warning at /usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:905 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
/usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:1027 (_Boost_COMPONENT_DEPENDENCIES)
/usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:1709 (_Boost_MISSING_DEPENDENCIES)
/usr/local/share/pcl-1.9/PCLConfig.cmake:140 (find_package)
/usr/local/share/pcl-1.9/PCLConfig.cmake:310 (find_boost)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:5 (find_package)
CMake Warning at /usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:905 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
/usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:1027 (_Boost_COMPONENT_DEPENDENCIES)
/usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:1709 (_Boost_MISSING_DEPENDENCIES)
/usr/local/share/pcl-1.9/PCLConfig.cmake:140 (find_package)
/usr/local/share/pcl-1.9/PCLConfig.cmake:310 (find_boost)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:5 (find_package)
CMake Warning at /usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:905 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
/usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:1027 (_Boost_COMPONENT_DEPENDENCIES)
/usr/local/Cellar/cmake/3.14.3/share/cmake/Modules/FindBoost.cmake:1709 (_Boost_MISSING_DEPENDENCIES)
/usr/local/share/pcl-1.9/PCLConfig.cmake:140 (find_package)
/usr/local/share/pcl-1.9/PCLConfig.cmake:310 (find_boost)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:5 (find_package)
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - found
-- Found Threads: TRUE
-- Boost version: 1.71.0
-- Found the following Boost libraries:
-- system
-- filesystem
-- thread
-- date_time
-- iostreams
-- serialization
-- chrono
-- atomic
-- regex
-- Found FLANN: /usr/local/Cellar/flann/1.9.1_7/lib/libflann_cpp.dylib
-- FLANN found (include: /usr/local/Cellar/flann/1.9.1_7/include, lib: optimized;/usr/local/Cellar/flann/1.9.1_7/lib/libflann_cpp.dylib;debug;/usr/local/Cellar/flann/1.9.1_7/lib/libflann_cpp.dylib)
-- FLANN found (include: /usr/local/Cellar/flann/1.9.1_7/include, lib: optimized;/usr/local/Cellar/flann/1.9.1_7/lib/libflann_cpp.dylib;debug;/usr/local/Cellar/flann/1.9.1_7/lib/libflann_cpp.dylib)
* WARNING * io features related to pcap will be disabled
* WARNING * io features related to png will be disabled
-- Found libusb-1.0: /usr/local/include
* WARNING * io features related to libusb-1.0 will be disabled
-- Found Qhull: optimized;/usr/local/lib/libqhull_p.dylib;debug;/usr/local/lib/libqhull_p.dylib
-- QHULL found (include: /usr/local/include, lib: optimized;/usr/local/lib/libqhull_p.dylib;debug;/usr/local/lib/libqhull_p.dylib)
-- Found OpenGL: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/OpenGL.framework
-- Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE)
CMake Error at /usr/local/share/pcl-1.9/PCLConfig.cmake:58 (message):
simulation is required but glew was not found
Call Stack (most recent call first):
/usr/local/share/pcl-1.9/PCLConfig.cmake:361 (pcl_report_not_found)
/usr/local/share/pcl-1.9/PCLConfig.cmake:545 (find_external_library)
CMakeLists.txt:5 (find_package)
CMake Warning (dev) in /usr/local/share/pcl-1.9/PCLConfig.cmake:
Policy CMP0011 is not set: Included scripts do automatic cmake_policy PUSH
and POP. Run "cmake --help-policy CMP0011" for policy details. Use the
cmake_policy command to set the policy and suppress this warning.
The included script
/usr/local/share/pcl-1.9/PCLConfig.cmake
affects policy settings. CMake is implying the NO_POLICY_SCOPE option for
compatibility, so the effects are applied to the including context.
Call Stack (most recent call first):
CMakeLists.txt:5 (find_package)
This warning is for project developers. Use -Wno-dev to suppress it.
-- Configuring incomplete, errors occurred!
See also "/Users/mayank/Code/Repos/pcl_test/build/CMakeFiles/CMakeOutput.log".
Kindly help asap
Having the same problem. Please help anyone! :D
Solved for PCL v 1.9.1_4. Problem is resolved on the latest version aka HEAD of master branch
Most helpful comment
Sorry for taking so long... but by the time you replied I had already switched back to a backup.
Out of sheer curiosity I have switched back now though... reinstalled all of the packages and updated them to the newest versions. For some reason or other it is working now. Not sure if that might have been the culprit, but this time I also updated cmake to the newest version (3.14.2), doesn't seem likely though.
I am interested in your suggested workaround however... might come in handy in the future if it happens again, since I still don't know what caused the initial problem.
Weirdly enough with everything updated to the newest available versions in homebrew I ran into another old issue now though... #2601.