Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
VTK
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Michael Migliore
VTK
Commits
3cfad373
Commit
3cfad373
authored
7 years ago
by
Ben Boeckel
Browse files
Options
Downloads
Patches
Plain Diff
cmake: move wrapping settings to its own module
parent
2b0bae20
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
CMake/vtkWrapSettings.cmake
+51
-0
51 additions, 0 deletions
CMake/vtkWrapSettings.cmake
CMakeLists.txt
+1
-63
1 addition, 63 deletions
CMakeLists.txt
with
52 additions
and
63 deletions
CMake/vtkWrapSettings.cmake
0 → 100644
+
51
−
0
View file @
3cfad373
# Configure files with settings for use by the build.
# Add the option for build the Python wrapping to VTK.
option
(
VTK_WRAP_PYTHON
"Should VTK Python wrapping be built?"
OFF
)
set
(
VTK_PYTHON_VERSION 2 CACHE STRING
"Python version to use"
)
set_property
(
CACHE VTK_PYTHON_VERSION
PROPERTY
STRINGS
"2;2.7;3;3.3;3.4;3.5;3.6;3.7;"
)
# Force reset of hints file location in cache if it was moved
if
(
VTK_WRAP_HINTS AND NOT EXISTS
${
VTK_WRAP_HINTS
}
)
set
(
VTK_WRAP_HINTS
"VTK_WRAP_HINTS-NOTFOUND"
)
endif
()
find_file
(
VTK_WRAP_HINTS hints
${
VTK_SOURCE_DIR
}
/Wrapping/Tools
NO_CMAKE_FIND_ROOT_PATH
)
mark_as_advanced
(
VTK_WRAP_HINTS
)
if
(
BUILD_TESTING OR VTK_WRAP_PYTHON
)
# Need PYTHON_EXECUTABLE for HeaderTesting or python wrapping
find_package
(
PythonInterp
${
VTK_PYTHON_VERSION
}
QUIET
)
mark_as_advanced
(
PYTHON_EXECUTABLE
)
endif
()
if
(
VTK_WRAP_PYTHON
)
set
(
VTK_WRAP_PYTHON_EXE vtkWrapPython
)
set
(
VTK_WRAP_PYTHON_INIT_EXE vtkWrapPythonInit
)
endif
()
# Force the WrappingPythonCore module to on if wrapping is on
set
(
Module_vtkWrappingPythonCore
${
VTK_WRAP_PYTHON
}
CACHE BOOL
"Core Python wrapping library"
FORCE
)
option
(
VTK_WRAP_JAVA
"Should VTK Java wrapping be built?"
OFF
)
if
(
VTK_WRAP_JAVA
)
set
(
VTK_WRAP_JAVA3_INIT_DIR
"
${
VTK_SOURCE_DIR
}
/Wrapping/Java"
)
# Wrapping executables.
set
(
VTK_WRAP_JAVA_EXE vtkWrapJava
)
set
(
VTK_PARSE_JAVA_EXE vtkParseJava
)
# Java package location.
set
(
VTK_JAVA_JAR
${
CMAKE_LIBRARY_OUTPUT_DIRECTORY
}
/vtk.jar
)
set
(
VTK_JAVA_HOME
${
VTK_BINARY_DIR
}
/java/vtk
)
file
(
MAKE_DIRECTORY
${
VTK_JAVA_HOME
}
)
endif
()
set
(
Module_vtkWrappingJava
${
VTK_WRAP_JAVA
}
CACHE BOOL
"Core Java wrapping library"
FORCE
)
if
(
VTK_WRAP_PYTHON OR VTK_WRAP_JAVA OR VTK_WRAP_HIERARCHY
)
set
(
VTK_WRAP_HIERARCHY_EXE vtkWrapHierarchy
)
endif
()
This diff is collapsed.
Click to expand it.
CMakeLists.txt
+
1
−
63
View file @
3cfad373
...
...
@@ -26,6 +26,7 @@ include(vtkMobileDevices)
include
(
vtkCrossCompiling
)
include
(
vtkThirdParty
)
include
(
vtkThreads
)
include
(
vtkWrapSettings
)
include
(
vtkModuleMacros
)
...
...
@@ -71,69 +72,6 @@ TEST_BIG_ENDIAN(CMAKE_WORDS_BIGENDIAN)
include
(
CheckTypeSize
)
#-----------------------------------------------------------------------------
# Configure files with settings for use by the build.
# Add the option for build the Python wrapping to VTK.
option
(
VTK_WRAP_PYTHON
"Should VTK Python wrapping be built?"
OFF
)
set
(
VTK_PYTHON_VERSION 2 CACHE STRING
"Python version to use: 2, 2.x, 3, 3.x, or empty"
)
# Add the option for build the Python wrapping to VTK.
option
(
VTK_WRAP_JAVA
"Should VTK Java wrapping be built?"
OFF
)
# Force reset of hints file location in cache if it was moved
if
(
VTK_WRAP_HINTS
)
if
(
NOT EXISTS
${
VTK_WRAP_HINTS
}
)
set
(
VTK_WRAP_HINTS
"VTK_WRAP_HINTS-NOTFOUND"
)
endif
()
endif
()
find_file
(
VTK_WRAP_HINTS hints
${
VTK_SOURCE_DIR
}
/Wrapping/Tools
NO_CMAKE_FIND_ROOT_PATH
)
mark_as_advanced
(
VTK_WRAP_HINTS
)
if
(
BUILD_TESTING OR VTK_WRAP_PYTHON
)
# Need PYTHON_EXECUTABLE for HeaderTesting or python wrapping
find_package
(
PythonInterp
${
VTK_PYTHON_VERSION
}
QUIET
)
mark_as_advanced
(
PYTHON_EXECUTABLE
)
endif
()
if
(
VTK_WRAP_PYTHON
)
set
(
VTK_WRAP_PYTHON_EXE vtkWrapPython
)
set
(
VTK_WRAP_PYTHON_INIT_EXE vtkWrapPythonInit
)
# Force the WrappingPythonCore module to on if wrapping is on
set
(
Module_vtkWrappingPythonCore ON CACHE BOOL
"Core Python wrapping library"
FORCE
)
else
()
# if wrapping is not on then force WrappingPythonCore module to be off
set
(
Module_vtkWrappingPythonCore OFF CACHE BOOL
"Core Python wrapping library"
FORCE
)
endif
()
if
(
VTK_WRAP_JAVA
)
set
(
VTK_WRAP_JAVA3_INIT_DIR
"
${
VTK_SOURCE_DIR
}
/Wrapping/Java"
)
# Wrapping executables.
set
(
VTK_WRAP_JAVA_EXE vtkWrapJava
)
set
(
VTK_PARSE_JAVA_EXE vtkParseJava
)
set
(
Module_vtkWrappingJava ON CACHE BOOL
"Core Java wrapping library"
FORCE
)
# Java package location.
set
(
VTK_JAVA_JAR
${
CMAKE_LIBRARY_OUTPUT_DIRECTORY
}
/vtk.jar
)
set
(
VTK_JAVA_HOME
${
VTK_BINARY_DIR
}
/java/vtk
)
file
(
MAKE_DIRECTORY
${
VTK_JAVA_HOME
}
)
else
()
set
(
Module_vtkWrappingJava OFF CACHE BOOL
"Core Java wrapping library"
FORCE
)
endif
()
option
(
VTK_WRAP_HIERARCHY
"Create wrap hierarchy even if languages are disabled."
OFF
)
mark_as_advanced
(
VTK_WRAP_HIERARCHY
)
if
(
VTK_WRAP_PYTHON OR VTK_WRAP_JAVA OR VTK_WRAP_HIERARCHY
)
set
(
VTK_WRAP_HIERARCHY_EXE vtkWrapHierarchy
)
endif
()
# Kits bundle multiple modules together into a single library, this
# is used to dramatically reduce the number of generated libraries.
option
(
VTK_ENABLE_KITS
"Build VTK using kits instead of modules."
OFF
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment