Commit 361d7b65 authored by Ben Boeckel's avatar Ben Boeckel
Browse files

paraview: remove vestigial of external plugin support

ParaView now supports building plugins outside of ParaView much better,
so drop old code which supported that mode.
parent 859493a6
......@@ -32,7 +32,6 @@ function (superbuild_find_projects var)
set(projects
cxx11
paraview
paraviewpluginsexternal
python
python2
python3)
......
......@@ -14,81 +14,3 @@ macro (paraview_superbuild_add_pdf name outname)
set("${name}_pdf" "${superbuild_install_location}/doc/${outname}")
endif ()
endmacro ()
function (paraview_add_plugin _name)
set(plugin_name)
set(ep_arguments)
set(grab)
foreach (arg IN LISTS ARGN)
if (arg STREQUAL "PLUGIN_NAME")
set(grab plugin_name)
elseif (arg MATCHES "${_ep_keywords_ExternalProject_Add}")
set(grab ep_arguments)
list(APPEND ep_arguments
"${arg}")
elseif (grab)
list(APPEND "${grab}"
"${arg}")
endif ()
endforeach ()
superbuild_add_project("${_name}"
${ep_arguments}
CONFIGURE_COMMAND ""
BUILD_COMMAND ""
INSTALL_COMMAND "")
if (NOT plugin_name)
set(plugin_name "${_name}")
endif ()
superbuild_add_extra_cmake_args(
"-DPARAVIEW_BUILD_PLUGIN_${plugin_name}:BOOL=ON")
if (NOT superbuild_build_phase)
set_property(GLOBAL APPEND
PROPERTY
paraview_plugins "${_name}")
endif ()
set("${_name}_arguments"
"${${_name}_arguments}"
PARENT_SCOPE)
endfunction ()
function (paraview_add_plugins_external)
set(paraview_PLUGINS_EXTERNAL ""
CACHE STRING "List of plugins to build externally")
set(plugin_cmake_args)
set(plugin_paths)
foreach (plugin IN LISTS paraview_PLUGINS_EXTERNAL)
set("paraview_PLUGIN_${plugin}_PATH" ""
CACHE PATH "Path to the source directory of the ${name} plugin")
if (NOT EXISTS "${paraview_PLUGIN_${plugin}_PATH}")
message(FATAL_ERROR
"The path for the ${plugin} plugin does not exist: "
"${paraview_PLUGIN_${plugin}_PATH}.")
endif ()
list(APPEND plugin_cmake_args
"-DPARAVIEW_BUILD_PLUGIN_${plugin}:BOOL=ON")
list(APPEND plugin_paths
"${paraview_PLUGIN_${plugin}_PATH}")
endforeach ()
superbuild_add_dummy_project(paraviewpluginsexternal)
superbuild_add_extra_cmake_args(${plugin_cmake_args})
if (NOT superbuild_build_phase)
set_property(GLOBAL
PROPERTY
paraview_plugin_dirs_external "${plugin_paths}")
endif ()
set(paraviewpluginsexternal_arguments
"${paraviewpluginsexternal_arguments}"
PARENT_SCOPE)
endfunction ()
......@@ -27,25 +27,6 @@ endif()
set(paraview_all_plugins)
if (superbuild_build_phase)
get_property(paraview_plugins GLOBAL
PROPERTY paraview_plugins)
get_property(paraview_plugin_dirs_external GLOBAL
PROPERTY paraview_plugin_dirs_external)
set(paraview_plugin_dirs
"${paraview_plugin_dirs_external}")
foreach (paraview_plugin IN LISTS paraview_plugins)
if (${paraview_plugin}_enabled AND TARGET "${paraview_plugin}")
set(plugin_source_dir "<SOURCE_DIR>")
_ep_replace_location_tags("${paraview_plugin}" plugin_source_dir)
list(APPEND paraview_plugin_dirs
"${plugin_source_dir}")
endif ()
endforeach ()
string(REPLACE ";" "${_superbuild_list_separator}" paraview_plugin_dirs "${paraview_plugin_dirs}")
endif ()
set(paraview_smp_backend "Sequential")
if (tbb_enabled)
set(paraview_smp_backend "TBB")
......@@ -217,9 +198,6 @@ superbuild_add_project(paraview
# ParFlow
-DPARAVIEW_PLUGIN_ENABLE_ParFlow:BOOL=${nlohmannjson_enabled}
# add additional plugin directories
-DPARAVIEW_EXTERNAL_PLUGIN_DIRS:STRING=${paraview_plugin_dirs}
${paraview_extra_cmake_options}
${PARAVIEW_EXTRA_CMAKE_ARGUMENTS})
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment