Properly export `vtkXArray` classes
The following discussion from !5429 (closed) should be addressed:
-
@robertmaynard started a discussion: (+1 comment) You need to have the general case of any arbitrary
T
be an general export for Linux/OSX and nothing on windows, for VTK-m we have aVTKM_ALWAYS_EXPORT
that does this ( https://gitlab.kitware.com/vtk/vtk-m/blob/master/vtkm/internal/ExportMacros.h#L36 ).Than you have it mark the explicit template instantiations that are created inside vtk common core with
VTKCOMMONCORE_EXPORT
. If you you use theextern
keyword for this, you will need to use a custom macro sinceextern
on a template class implies declspec(export) and cant be marked up. ( see https://gitlab.kitware.com/vtk/vtk-m/blob/master/CMake/VTKmExportHeaderTemplate.h.in#L46 )