Skip to content

Commit

Permalink
CMake: allow using latest SWIG
Browse files Browse the repository at this point in the history
  • Loading branch information
paroj committed Nov 6, 2022
1 parent b0b84ed commit f9bee98
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 4 deletions.
6 changes: 5 additions & 1 deletion Components/Csharp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,11 @@ else()
add_definitions(-Wno-strict-aliasing -Wno-cast-qual -Wno-shadow -Wno-missing-declarations -Wno-unused-but-set-variable)
endif()

set(CMAKE_SWIG_FLAGS -w401,314 -namespace org.ogre -Dfinal)
set(CMAKE_SWIG_FLAGS -w401,314 -namespace org.ogre)

if(SWIG_VERSION VERSION_LESS "4.1")
list(APPEND CMAKE_SWIG_FLAGS -Dfinal)
endif()

set(CMAKE_LIBRARY_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/csharp/")
set(CMAKE_SWIG_OUTDIR "${PROJECT_BINARY_DIR}/csharp/")
Expand Down
6 changes: 5 additions & 1 deletion Components/Java/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,11 @@ else()
endif()
endif()

set(CMAKE_SWIG_FLAGS -w401,314 -package org.ogre -Dfinal)
set(CMAKE_SWIG_FLAGS -w401,314 -package org.ogre)

if(SWIG_VERSION VERSION_LESS "4.1")
list(APPEND CMAKE_SWIG_FLAGS -Dfinal)
endif()

if (APPLE AND NOT ANDROID)
# we are using libc++ on OSX
Expand Down
6 changes: 5 additions & 1 deletion Components/Python/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,11 @@ if(SKBUILD)
set(PYTHON_SITE_PACKAGES Ogre/)
endif()

set(CMAKE_SWIG_FLAGS -w401,314 -builtin -Dfinal)
set(CMAKE_SWIG_FLAGS -w401,314 -builtin)

if(SWIG_VERSION VERSION_LESS "4.1")
list(APPEND CMAKE_SWIG_FLAGS -Dfinal)
endif()

if (APPLE AND NOT ANDROID)
# we are using libc++ on OSX
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
[build-system]
requires = ["setuptools", "wheel", "scikit-build", "cmake", "pip", "swig==4.0.2"]
requires = ["setuptools", "wheel", "scikit-build", "cmake", "pip", "swig"]

0 comments on commit f9bee98

Please sign in to comment.