mapillary / mapillary/OpenSfM

Deviations from the upstream pybind11

Open
#871 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

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

Description

TLDR:

  • pybind_utils.h assume different template signatures than upstream
  • cmake links to pybind11 instead of pybind11::module, confusing cmake sometimes to try and -lpybind11 (which it needn't and which fails) instead of using the pybind11 cmake target
  • cmake links to pybind11 even pybind11_add_module targets (these link automatically)

The pinned pybind11 submodule is relatively old. In the upstream pybind11 there already are provided some of the utilities from pybind_utils.h, like make_value_iterator, iterator_state, but they have different signatures (e.g. 5 template parameters against 4). I hoped to build OpenSfM without submodules with the (newer) pybind11 version pinned outside the repo, but this would require modifications to the template definitions

  • Would you consider updating to the newer pybind11 before the next release?
  • Do you need the in-tree pybind11 in the first place?

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 by reading pybind_utils.h and the CMake configuration that links pybind11, then compare them with the newer upstream pybind11 interfaces and CMake targets. The work is done when the newer dependency can be used without signature conflicts and CMake uses the appropriate target without redundant or erroneous linking.

Written by the indexing model from the issue text.

Assessment

Tech stack
cmake, python
Domain
build-system
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.