mapillary / mapillary/OpenSfM

Build error: OpenMP_libomp_LIBRARY on MacOs

Open
#681 12 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

installation
Dominant language
Python
Stars
3.8k
Forks
899
PR merge metrics
No merged PRs in 30d

Description

Not sure, if this dependency is optional? If so, how to force Cmake to ignore the error?

-- Could NOT find OpenMP_C (missing: OpenMP_C_FLAGS OpenMP_C_LIB_NAMES) 
-- Could NOT find OpenMP_CXX (missing: OpenMP_CXX_FLAGS OpenMP_CXX_LIB_NAMES) 
-- Could NOT find OpenMP (missing: OpenMP_C_FOUND OpenMP_CXX_FOUND) 
-- Found AMD library: /opt/local/lib/libamd.dylib
-- Found AMD header in: /opt/local/include
-- Found CAMD library: /opt/local/lib/libcamd.dylib
-- Found CAMD header in: /opt/local/include
-- Found COLAMD library: /opt/local/lib/libcolamd.dylib
-- Found COLAMD header in: /opt/local/include
-- Found CCOLAMD library: /opt/local/lib/libccolamd.dylib
-- Found CCOLAMD header in: /opt/local/include
-- Found CHOLMOD library: /opt/local/lib/libcholmod.dylib
-- Found CHOLMOD header in: /opt/local/include
-- Found CXSPARSE library: /opt/local/lib/libcxsparse.dylib
-- Found SuiteSparseQR library: /opt/local/lib/libspqr.dylib
-- Found SuiteSparseQR header in: /opt/local/include
-- Did not find Intel TBB library, assuming SuiteSparseQR was not compiled with TBB.
-- Found SuiteSparse_config library: /opt/local/lib/libsuitesparseconfig.dylib
-- Found SuiteSparse_config header in: /opt/local/include
-- Found METIS library: /opt/local/lib/libmetis.dylib.
CMake Warning (dev) at /opt/local/share/cmake-3.19/Modules/FindPackageHandleStandardArgs.cmake:424 (message):
  The package name passed to `find_package_handle_standard_args` (ceres) does
  not match the name of the calling package (Ceres).  This can lead to
  problems in calling code that expects `find_package` result variables
  (e.g., `_FOUND`) to follow a certain pattern.
Call Stack (most recent call first):
  cmake/FindCeres.cmake:49 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
  CMakeLists.txt:38 (find_package)
This warning is for project developers.  Use -Wno-dev to suppress it.

-- No preference for use of exported gflags CMake configuration set, and no hints for include/library directories provided. Defaulting to preferring an installed/exported gflags CMake configuration if available.
-- Found installed version of gflags: /opt/local/lib/cmake/gflags
-- Detected gflags version: 2.2.2
-- Found OpenCV: /opt/local (found version "3.4.12") 
-- Found OpenCV: /opt/local (found version "3.4.12") found components: core imgproc calib3d imgcodecs 
-- pybind11 v2.2.4
-- Configuring done
CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
OpenMP_libomp_LIBRARY (ADVANCED)
    linked by target "foundation" in directory .../Source/OpenSfM/opensfm/src/foundation

-- Generating done
CMake Generate step failed.  Build files cannot be regenerated correctly.
Traceback (most recent call last):
  File "setup.py", line 36, in <module>
    configure_c_extension()
  File "setup.py", line 27, in configure_c_extension
    subprocess.check_call(cmake_command, cwd='cmake_build')
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/subprocess.py", line 364, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', '../opensfm/src', '-DPYTHON_EXECUTABLE=.../.virtualenvs/proto-sfm/bin/python']' returned non-zero exit status 1.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with setup.py and the CMake entry points named in the report, especially CMakeLists.txt, cmake/FindCeres.cmake, and the foundation target. Reproduce the macOS configuration command and trace how OpenMP_libomp_LIBRARY becomes NOTFOUND. Done means the dependency’s required or optional status is clear and CMake configuration completes successfully on the reported setup.

Written by the indexing model from the issue text.

Assessment

Tech stack
cmake, python
Domain
build-system
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.