1. 22 Sep, 2021 1 commit
  2. 08 Sep, 2021 1 commit
  3. 13 Jul, 2021 1 commit
    • Antony Lee's avatar
      Add helper to build in-tree extensions. (#2831) · 1be0a0a6
      Antony Lee authored
      
      
      For single-file extensions, a convenient pattern offered by cython
      is to place the source files directly in the python source tree
      (`foo/__init__.py`, `foo/ext.pyx`), deriving the package names from
      their filesystem location.  Adapt this pattern for pybind11, using an
      `intree_extensions` helper, which should be thought of as the moral
      equivalent to `cythonize`.
      
      Differences with cythonize: I chose not to include globbing support
      (`intree_extensions(glob.glob("**/*.cpp"))` seems sufficient), nor to
      provide extension-customization kwargs (directly setting the attributes
      on the resulting Pybind11Extension objects seems sufficient).
      
      We could choose to have `intree_extension` (singular instead) and make
      users write `[*map(intree_extension, glob.glob("**/*.cpp"))]`; no strong
      opinion here.
      Co-authored-by: default avatarAaron Gokaslan <skylion.aaron@gmail.com>
      1be0a0a6
  4. 04 Jul, 2021 1 commit
  5. 17 Jun, 2021 1 commit
  6. 17 Jan, 2021 1 commit
  7. 24 Dec, 2020 1 commit
    • Steve Siano's avatar
      docs: add a note about compiling the example (#2737) · 6f66e760
      Steve Siano authored
      * docs: mention PYTHONPATH in installing.rst
      
      When pybind11 is included as a submodule, the user needs to update their
      Python module search path.  Otherwise, the first c++ compilation command
      in docs/basics.rst will fail.
      
      * docs: add a note about compiling the example
      
      This note shows how to modify the compilation command for the example
      when the pybind11 source has been included as a Git submodule.
      
      * docs: add a note about compiling the example
      
      Added an internal link to the docs
      
      * docs: updated a note about compiling the example
      
      Also updated the command substitution syntax for consistency
      6f66e760
  8. 24 Nov, 2020 1 commit
  9. 11 Nov, 2020 1 commit
    • Henry Schreiner's avatar
      feat: way to only recompile changed files (#2643) · ebd5c5b4
      Henry Schreiner authored
      * feat: lazy compile
      
      * refactor: lazy -> only_changed
      
      * refactor: leave the changed function up to the user
      
      * refactor: pass a function, based on @YannickJadoul and @HDembinski's suggestions
      
      * refactor: old -> _old, as it's not intended for users
      
      * docs: slight improvmenent from @rwgk
      
      * docs: Ccache spelling, extra warning about pip caching
      
      Ccache spelling noted by @YannickJadoul
      ebd5c5b4
  10. 14 Oct, 2020 1 commit
  11. 08 Oct, 2020 2 commits
  12. 03 Oct, 2020 1 commit
  13. 02 Oct, 2020 1 commit
  14. 17 Sep, 2020 1 commit
  15. 16 Sep, 2020 2 commits
    • Henry Schreiner's avatar
      feat: setup.py redesign and helpers (#2433) · fd61f503
      Henry Schreiner authored
      * feat: setup.py redesign and helpers
      
      * refactor: simpler design with two outputs
      
      * refactor: helper file update and Windows support
      
      * fix: review points from @YannickJadoul
      
      * refactor: fixes to naming and more docs
      
      * feat: more customization points
      
      * feat: add entry point pybind11-config
      
      * refactor: Try Extension-focused method
      
      * refactor: rename alt/inplace to global
      
      * fix: allow usage with git modules, better docs
      
      * feat: global as an extra (@YannickJadoul's suggestion)
      
      * feat: single version location
      
      * fix: remove the requirement that setuptools must be imported first
      
      * fix: some review points from @wjacob
      
      * fix: use .in, add procedure to docs
      
      * refactor: avoid monkeypatch copy
      
      * docs: minor typos corrected
      
      * fix: minor points from @YannickJadoul
      
      * fix: typo on Windows C++ mode
      
      * fix: MSVC 15 update 3+ have c++14 flag
      
      See <https://docs.microsoft.com/en-us/cpp/build/reference/std-specify-language-standard-version?view=vs-2019>
      
      * docs: discuss making SDists by hand
      
      * ci: use pep517.build instead of manual setup.py
      
      * refactor: more comments from @YannickJadoul
      
      * docs: updates from @ktbarrett
      
      * fix: change to newly recommended tool instead of pep517.build
      
      This was intended as a proof of concept; build seems to be the correct replacement.
      
      See https://github.com/pypa/pep517/pull/83
      
      * docs: updates from @wjakob
      
      * refactor: dual version locations
      
      * docs: typo spotted by @wjakob
      fd61f503
    • Griffin Downs's avatar
      Add vcpkg installation instructions (#1936) · a4cee36b
      Griffin Downs authored
      
      
      * Add vcpkg installation instructions
      
      * Casing
      
      * Move instructions
      Co-authored-by: default avatarHenry Fredrick Schreiner <henry.fredrick.schreiner@cern.ch>
      a4cee36b
  16. 06 Sep, 2020 1 commit
  17. 19 Aug, 2020 1 commit
    • Henry Schreiner's avatar
      feat: new FindPython support (#2370) · 1729aae9
      Henry Schreiner authored
      * feat: FindPython support
      
      * refactor: rename to PYBIND11_FINDPYTHON
      
      * docs: Caps fixes
      
      * feat: NOPYTHON mode
      
      * test: check simple call
      
      * docs: add changelog/upgrade guide
      
      * feat: Support Python3 and Python2
      
      * refactor: Use targets in tests
      
      * fix: support CMake 3.4+
      
      * feat: classic search also finds virtual environments
      
      * docs: some updates from @wjakob's review
      
      * fix: wrong name for QUIET mode variable, reported by @skoslowski
      
      * refactor: cleaner output messaging
      
      * fix: support debug Python's in FindPython mode too
      
      * fixup! refactor: cleaner output messaging
      
      * fix: missing pybind11_FOUND and pybind11_INCLUDE_DIR restored to subdir mode
      
      * fix: nicer reporting of Python / PyPy
      
      * fix: out-of-order variable fix
      
      * docs: minor last-minute cleanup
      1729aae9
  18. 10 Aug, 2020 1 commit
  19. 31 Jul, 2020 3 commits
  20. 26 Apr, 2020 2 commits
  21. 10 Jun, 2019 1 commit
  22. 29 Aug, 2018 1 commit
    • Axel Huebl's avatar
      add_module: allow include as SYSTEM (#1416) · 435dbdd1
      Axel Huebl authored
      pybind11 headers passed via the `pybind11_add_module` CMake
      function can now be included as `SYSTEM` includes (`-isystem`).
      
      This allows to set stricter (or experimental) warnings in
      calling projects that might throw otherwise in headers
      a user of pybind11 can not influence.
      435dbdd1
  23. 30 Aug, 2017 1 commit
  24. 17 Aug, 2017 1 commit
    • Dean Moldovan's avatar
      Fix documentation build · 8665ee81
      Dean Moldovan authored
      * Doxygen needs `RECURSIVE = YES` in order to parse the `detail` subdir.
      
      * The `-W` warnings-as-errors option for sphinx doesn't work with the
        makefile build. Switched to calling sphinx directly.
      
      * Fix "citation [cppimport] is not referenced" warning.
      8665ee81
  25. 14 Aug, 2017 1 commit
    • Jason Rhinelander's avatar
      Compile with hidden visibility always; set via cmake property rather than compiler flag · 97aa54fe
      Jason Rhinelander authored
      This updates the compilation to always apply hidden visibility to
      resolve the issues with default visibility causing problems under debug
      compilations.  Moreover using the cmake property makes it easier for a
      caller to override if absolutely needed for some reason.
      
      For `pybind11_add_module` we use cmake to set the property; for the
      targets, we append to compilation option to non-MSVC compilers.
      97aa54fe
  26. 31 May, 2017 1 commit
  27. 28 May, 2017 1 commit
  28. 09 May, 2017 1 commit
    • Jason Rhinelander's avatar
      Make PYBIND11_CPP_STANDARD work under MSVC · 77710ff0
      Jason Rhinelander authored
      Under MSVC we were ignoring PYBIND11_CPP_STANDARD and simply not
      passing any standard (which makes MSVC default to its C++14 mode).
      
      MSVC 2015u3 added the `/std:c++14` and `/std:c++latest` flags; the
      latter, under MSVC 2017, enables some C++17 features (such as
      `std::optional` and `std::variant`), so it is something we need to
      start supporting under MSVC.
      
      This makes the PYBIND11_CPP_STANDARD cmake variable work under MSVC,
      defaulting it to /std:c++14 (matching the default -std=c++14 for
      non-MSVC).
      
      It also adds a new appveyor test running under MSVC 2017 with
      /std:c++latest, which runs (and passes) the
      `std::optional`/`std::variant` tests.
      
      Also updated the documentation to clarify the c++ flags and add show
      MSVC flag examples.
      77710ff0
  29. 26 Dec, 2016 1 commit
  30. 19 Dec, 2016 2 commits
  31. 13 Dec, 2016 2 commits
  32. 06 Sep, 2016 1 commit
  33. 03 Jun, 2016 1 commit