Skip to content

Commit

Permalink
Merge pull request #76 from benjaminhuth/fix/build-on-gcc
Browse files Browse the repository at this point in the history
fix: Fix build on GCC 13/14 and add option to CMake
  • Loading branch information
asalzburger authored Jul 4, 2024
2 parents a357e0e + ac484b1 commit 81e34ec
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -82,8 +82,10 @@ if (ACTSVG_BUILD_TESTING OR ACTSVG_BUILD_EXAMPLES)
endif()
endif()

option(ACTSVG_BUILD_PYTHON_BINDINGS "Build the python bindings of ACTSVG" OFF)
if(ACTSVG_BUILD_PYTHON_BINDINGS)
find_package(Python 3.8 REQUIRED COMPONENTS Interpreter Development)
option(ACTSVG_USE_SYSTEM_PYBIND11 "Pick up an existing installation of pybind11")
if(ACTSVG_USE_SYSTEM_PYBIND11)
find_package(pybind11 CONFIG REQUIRED)
else()
Expand Down
4 changes: 2 additions & 2 deletions python/src/display.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ void add_display_module(context& ctx) {
/// @return an object (sterile if now matching view type is found)
d.def(
"surfaces_as_oriented_polygons",
[](const std::vector<const surface>& ss, const std::string& view) {
[](const std::vector<surface>& ss, const std::string& view) {
std::vector<svg::object> polygons;
for (const auto& s : ss) {
polygons.push_back(surface_as_oriented_polygon(
Expand Down Expand Up @@ -350,7 +350,7 @@ void add_display_module(context& ctx) {
///
/// @return an object (sterile if now matching view type is found)
d.def("surfaces_as_oriented_polygons",
[](const std::vector<const surface>& ss, const style::fill& f,
[](const std::vector<surface>& ss, const style::fill& f,
const style::stroke& str, const std::string& view) {
std::vector<svg::object> polygons;
for (const auto& s : ss) {
Expand Down

0 comments on commit 81e34ec

Please sign in to comment.