Commit 713595f0 authored by Mark OLESEN's avatar Mark OLESEN Committed by Andrew Heather
Browse files

COMP: adjust common paraview library name to vtkPVFoamCommon

- similar prefixing as the dependent readers, making it easier to
  identify

- add FOAM_API information as server module version
parent 8495e8e9
......@@ -7,7 +7,7 @@ cd ${0%/*} || exit 1 # Run from this directory
get_pvplugin_api || echo "No ParaView plugin information found" 1>&2
# Cleanup libraries
wclean libso foamPv
wclean libso common
wclean libso blockMeshReader/library
wclean libso foamReader/library
......
......@@ -15,7 +15,7 @@ warnIncomplete()
if have_pvplugin_support
then
(
wmakeLibPv foamPv
wmakeLibPv common
wmakeLibPv blockMeshReader/library
wmakeLibPv foamReader/library
......
......@@ -10,7 +10,7 @@ include_directories(
${LIB_SRC}/OpenFOAM/lnInclude
${LIB_SRC}/OSspecific/${WM_OSTYPE}/lnInclude
${LIB_SRC}/meshing/blockMesh/lnInclude
${PROJECT_SOURCE_DIR}/../foamPv
${PROJECT_SOURCE_DIR}/../common
${PROJECT_SOURCE_DIR}/library
${PROJECT_SOURCE_DIR}/plugin
${PROJECT_SOURCE_DIR}/plugin/reader
......@@ -37,7 +37,7 @@ add_paraview_property_group_widget(IFACES0 IFACES0_SRCS
)
add_paraview_plugin(
PVblockMeshReader_SM "1.0"
PVblockMeshReader_SM "${foam_api}"
SERVER_MANAGER_XML
plugin/PVblockMeshReader_SM.xml
SERVER_MANAGER_SOURCES
......@@ -53,7 +53,7 @@ add_paraview_plugin(
target_link_libraries(
PVblockMeshReader_SM
LINK_PUBLIC
foamPv${foamPvLibQualifier}
vtkPVFoamCommon${foamPvLibQualifier}
vtkPVblockMesh${foamPvLibQualifier}
${OPENFOAM_LIBNAMES}
)
......
......@@ -32,16 +32,29 @@ else()
endif()
endif()
# Pass through the OpenFOAM API value to the reader
set(foam_api "$ENV{FOAM_API}")
if (NOT "${foam_api}")
set(foam_api "2.0")
endif()
set(foamPvLibQualifier "-pv${pv_api}")
message("OpenFOAM libraries qualified with ${foamPvLibQualifier}")
#-----------------------------------------------------------------------------
message("================")
message("Using ParaView = $ENV{ParaView_DIR}")
message("OpenFOAM api = ${foam_api}, libs = ${foamPvLibQualifier}")
#-----------------------------------------------------------------------------
include(CMakeLists-OpenFOAM.txt)
if (${ParaView_VERSION} GREATER_EQUAL 5.7)
message("================")
include(CMakeLists-Project57.txt)
else()
message("================")
include(${PARAVIEW_USE_FILE})
include(CMakeLists-Project.txt)
endif()
......
......@@ -6,11 +6,11 @@ EXE_INC = \
-I$(LIB_SRC)/mesh/blockMesh/lnInclude \
-I$(PARAVIEW_INC_DIR) \
-I$(PARAVIEW_INC_DIR)/vtkkwiml \
-I../../foamPv \
-I../../common \
-I../plugin/reader
LIB_LIBS = \
-lmeshTools \
-lblockMesh \
-L$(FOAM_LIBBIN) -lfoamPv-pv${PARAVIEW_API} \
-L$(FOAM_LIBBIN) -lvtkPVFoamCommon-pv${PARAVIEW_API} \
$(GLIBS)
foamPvCore.C
LIB = $(FOAM_LIBBIN)/libvtkPVFoamCommon-pv${PARAVIEW_API}
foamPvCore.C
LIB = $(FOAM_LIBBIN)/libfoamPv-pv${PARAVIEW_API}
......@@ -13,7 +13,7 @@ include_directories(
${LIB_SRC}/conversion/lnInclude
${LIB_SRC}/finiteArea/lnInclude
${LIB_SRC}/finiteVolume/lnInclude
${PROJECT_SOURCE_DIR}/../foamPv
${PROJECT_SOURCE_DIR}/../common
${PROJECT_SOURCE_DIR}/library
${PROJECT_SOURCE_DIR}/plugin
${PROJECT_SOURCE_DIR}/plugin/reader
......@@ -43,7 +43,7 @@ add_paraview_property_group_widget(IFACES0 IFACES0_SRCS
)
add_paraview_plugin(
PVFoamReader_SM "1.0"
PVFoamReader_SM "${foam_api}"
SERVER_MANAGER_XML
plugin/PVFoamReader_SM.xml
SERVER_MANAGER_SOURCES
......@@ -56,11 +56,10 @@ add_paraview_plugin(
plugin/pqFoamReaderControls.cxx
)
target_link_libraries(
PVFoamReader_SM
LINK_PUBLIC
foamPv${foamPvLibQualifier}
vtkPVFoamCommon${foamPvLibQualifier}
vtkPVFoam${foamPvLibQualifier}
${OPENFOAM_LIBNAMES}
)
......
......@@ -32,16 +32,27 @@ else()
endif()
endif()
# Pass through the OpenFOAM API value to the reader
set(foam_api "$ENV{FOAM_API}")
if (NOT "${foam_api}")
set(foam_api "2.0")
endif()
set(foamPvLibQualifier "-pv${pv_api}")
message("OpenFOAM libraries qualified with ${foamPvLibQualifier}")
#-----------------------------------------------------------------------------
message("================")
message("Using ParaView = $ENV{ParaView_DIR}")
message("OpenFOAM api = ${foam_api}, libs = ${foamPvLibQualifier}")
include(CMakeLists-OpenFOAM.txt)
if (${ParaView_VERSION} GREATER_EQUAL 5.7)
message("================")
include(CMakeLists-Project57.txt)
else()
message("================")
include(${PARAVIEW_USE_FILE})
include(CMakeLists-Project.txt)
endif()
......
......@@ -9,7 +9,7 @@ EXE_INC = \
-I$(LIB_SRC)/lagrangian/basic/lnInclude \
-I$(PARAVIEW_INC_DIR) \
-I$(PARAVIEW_INC_DIR)/vtkkwiml \
-I../../foamPv \
-I../../common \
-I../plugin/reader
LIB_LIBS = \
......@@ -21,5 +21,5 @@ LIB_LIBS = \
-ldynamicMesh \
-lgenericPatchFields \
-llagrangian \
-L$(FOAM_LIBBIN) -lfoamPv-pv${PARAVIEW_API} \
-L$(FOAM_LIBBIN) -lvtkPVFoamCommon-pv${PARAVIEW_API} \
$(GLIBS)
Supports Markdown
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