
# Prepare GCCXML to compile with VTK
# by updating the variables GCCXML_INCLUDES and GCCXML_DEFS
MACRO( GCCXML_USE_VTK )
  # VTK compilation flags
  IF   (VTK_FOUND)
    IF   (VTK_INCLUDE_DIRS)
      FOREACH( inc ${VTK_INCLUDE_DIRS})
        SET( GCCXML_VTK_INCLUDES  -I${inc}  ${GCCXML_VTK_INCLUDES} )
      ENDFOREACH(inc ${VTK_INCLUDE_DIRS})
    ENDIF(VTK_INCLUDE_DIRS)
    MESSAGE("GCCXML_VTK_INCLUDES='${GCCXML_VTK_INCLUDES}'")
    IF   (VTK_REQUIRED_CXX_FLAGS)
      FOREACH( def ${VTK_REQUIRED_CXX_FLAGS})
        SET( GCCXML_VTK_DEFS  ${def}  ${GCCXML_VTK_DEFS} )
      ENDFOREACH(def ${VTK_REQUIRED_CXX_FLAGS})
      MESSAGE("GCCXML_VTK_DEFS=${VTK_DEFS}")
    ENDIF(VTK_REQUIRED_CXX_FLAGS)
    SET( GCCXML_INCLUDES ${GCCXML_INCLUDES}  ${GCCXML_VTK_INCLUDES})
    # don't include flags since all of them are not supported
    #SET( GCCXML_DEFS     ${GCCXML_DEFS}      ${GCCXML_VTK_DEFS}    )
  ENDIF ( VTK_FOUND)
ENDMACRO( GCCXML_USE_VTK )

