devel:vtk
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
devel:vtk [2015/02/23 17:24] – wautelet | devel:vtk [2017/05/15 11:55] (current) – removed boman | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== Compiler VTK pour Metafor ====== | ||
- | |||
- | memo comment compiler vtk (5.10.1) pour les Libs | ||
- | |||
- | |||
- | ===== Windows : Release & Debug / Wrapper vtk-python (r&d) / Luc (version 140109) ===== | ||
- | |||
- | * Détarer les sources : VTK\vtk-5.10.1 | ||
- | * Créer le répertoire de compilation : VTK\VTKBuild | ||
- | * Modifier les sources VTK : | ||
- | * VTK Debug : ajout du postfix " | ||
- | |||
- | < | ||
- | # Append the library version information to the library target | ||
- | # properties. | ||
- | # block this. | ||
- | IF(NOT VTK_NO_LIBRARY_VERSION) | ||
- | SET(VTK_LIBRARY_PROPERTIES ${VTK_LIBRARY_PROPERTIES} | ||
- | VERSION " | ||
- | SOVERSION " | ||
- | ) | ||
- | | ||
- | |||
- | SET(VTK_LIBRARY_PROPERTIES ${VTK_LIBRARY_PROPERTIES} DEBUG_POSTFIX _d ) | ||
- | </ | ||
- | |||
- | * Wrappers Python debug : postfix " | ||
- | < | ||
- | # Python extension modules on Windows must have the extension " | ||
- | # instead of " | ||
- | # this suffix. | ||
- | IF(WIN32 AND NOT CYGWIN) | ||
- | SET_TARGET_PROPERTIES(vtk${KIT}Python PROPERTIES SUFFIX " | ||
- | SET_TARGET_PROPERTIES(vtk${KIT}Python PROPERTIES DEBUG_POSTFIX " | ||
- | ENDIF(WIN32 AND NOT CYGWIN) | ||
- | </ | ||
- | |||
- | * installation des wrappers python_d : modifier VTK\vtk-5.10.1\Wrapping\Python\setup.py.in | ||
- | |||
- | lignes 85-100 : | ||
- | < | ||
- | def get_libs(): | ||
- | """ | ||
- | libs = [] | ||
- | |||
- | # Select platform-specific components of the module file names. | ||
- | if os.name == ' | ||
- | dir = vtk_lib_dir | ||
- | prefix = ' | ||
- | suffix = get_config_var(' | ||
- | else: | ||
- | dir = vtk_bin_dir.replace('/', | ||
- | prefix = ' | ||
- | if vtk_build_type == ' | ||
- | suffix = ' | ||
- | else: | ||
- | suffix = ' | ||
- | </ | ||
- | |||
- | * patcher vtktclutil.cxx pour utilisation tcltk8.6: | ||
- | http:// | ||
- | "/ | ||
- | < | ||
- | ligne 21 - 24 : | ||
- | #include < | ||
- | #include < | ||
- | |||
- | extern " | ||
- | |||
- | devient 21-30 : | ||
- | #include < | ||
- | #include < | ||
- | |||
- | #if (TCL_MAJOR_VERSION == 8) && (TCL_MINOR_VERSION < 6) | ||
- | #define vtkTclGetErrorLine(m) (m-> | ||
- | #else | ||
- | #define vtkTclGetErrorLine(m) (Tcl_GetErrorLine(m)) | ||
- | #endif | ||
- | |||
- | extern " | ||
- | |||
- | ligne 488-500 : | ||
- | if (Tcl_GetVar(arg2-> | ||
- | { | ||
- | vtkGenericWarningMacro(" | ||
- | | ||
- | | ||
- | " | ||
- | } | ||
- | else | ||
- | { | ||
- | vtkGenericWarningMacro(" | ||
- | | ||
- | " | ||
- | } | ||
- | | ||
- | devient 494-506: | ||
- | |||
- | if (Tcl_GetVar(arg2-> | ||
- | { | ||
- | vtkGenericWarningMacro(" | ||
- | | ||
- | | ||
- | " | ||
- | } | ||
- | else | ||
- | { | ||
- | vtkGenericWarningMacro(" | ||
- | | ||
- | " | ||
- | } | ||
- | |||
- | ligne 721-732 : | ||
- | if (Tcl_GetVar(this-> | ||
- | { | ||
- | vtkGenericWarningMacro(" | ||
- | | ||
- | | ||
- | " | ||
- | } | ||
- | else | ||
- | { | ||
- | vtkGenericWarningMacro(" | ||
- | | ||
- | " | ||
- | } | ||
- | } | ||
- | vtkGenericWarningMacro(" | ||
- | | ||
- | | ||
- | " | ||
- | devient 727-739: | ||
- | if (Tcl_GetVar(this-> | ||
- | { | ||
- | vtkGenericWarningMacro(" | ||
- | | ||
- | | ||
- | " | ||
- | } | ||
- | else | ||
- | { | ||
- | vtkGenericWarningMacro(" | ||
- | | ||
- | " | ||
- | } | ||
- | } | ||
- | </ | ||
- | |||
- | * Executer CMake : modifier les options suivante | ||
- | * BUILD_SHARED_LIBS : ON | ||
- | * CMAKE_INSTALL_PREFIX : '' | ||
- | * CMAKE_CXX_MP_FLAG : ON (permet de compiler en parallele en local) | ||
- | * VTK_DEBUG_LEAKS : OFF (pour une version à distribuer, peut-être ON pour developpement) | ||
- | * VTK_USE_GL2PS : ON (advanced option) | ||
- | * VTK_USE_QT : ON | ||
- | * VTK_WRAP_PYTHON : ON | ||
- | * VTK_WRAP_TCL : ON | ||
- | * Les autres options doivent " | ||
- | |||
- | |||
- | * Compiler ALL_BUILD (Debug) (Commencer par debug) | ||
- | * Installer | ||
- | * Compiler ALL_BUILD (Release) | ||
- | * Installer | ||
- | |||
- | <note warning> Attention : certains fichiers debug seront écrasés par leur version release, mais normalement c'est les même ... raison pour laquelle on démarre par la version debug </ | ||
- | |||
- | |||
- | * Modifier les chemins relatifs des librairies en variables d' | ||
- | * remplacer le lieu d' | ||
- | * '' | ||
- | * '' | ||
- | * '' | ||
- | * '' | ||
- | * idem pour les chemins vers tcl/ | ||
- | * '' | ||
- | * includes de vtk_freetype, | ||
- | * '' | ||
- | * '' | ||
- | * '' | ||
- | * enlever les chemins absolu vers " | ||
- | | ||
- | * Copier le répertoire '' | ||
- | * Installer les wrappers python (crée le répertoire LibsVS2012\Python\Lib\site_packages\VTK-5.10.1-py2.6.egg): | ||
- | * ouvrir une invite de commande et aller dans '' | ||
- | * '' | ||
- | * '' | ||
- | * Vérification: | ||
- | |||
- | |||
- | |||
- | ===== Windows : Release & Debug / Wrapper vtk-python (r&d) / Marlène & Luc ===== | ||
- | |||
- | * Détarer les sources : VTK\vtk-5.10.1 | ||
- | * Créer le répertoire de compilation : VTK\VTKBuild | ||
- | * Modifier les sources VTK : link_directories modifier " | ||
- | < | ||
- | ligne 28-29 : | ||
- | # Add include directories needed to use VTK. | ||
- | INCLUDE_DIRECTORIES(${VTK_INCLUDE_DIRS}) | ||
- | devient 28-31: | ||
- | # Add include directories needed to use VTK. | ||
- | INCLUDE_DIRECTORIES(${VTK_INCLUDE_DIRS}) | ||
- | # Add link directories needed to use VTK. | ||
- | LINK_DIRECTORIES(${VTK_LIBRARY_DIRS}) | ||
- | </ | ||
- | |||
- | * VTK Debug : ajout du postfix " | ||
- | < | ||
- | ligne 95-103 : | ||
- | |||
- | # Append the library version information to the library target | ||
- | # properties. | ||
- | # block this. | ||
- | IF(NOT VTK_NO_LIBRARY_VERSION) | ||
- | SET(VTK_LIBRARY_PROPERTIES ${VTK_LIBRARY_PROPERTIES} | ||
- | VERSION " | ||
- | SOVERSION " | ||
- | ) | ||
- | ENDIF(NOT VTK_NO_LIBRARY_VERSION) | ||
- | |||
- | devient ligne 95-104: | ||
- | |||
- | # Append the library version information to the library target | ||
- | # properties. | ||
- | # block this. | ||
- | IF(NOT VTK_NO_LIBRARY_VERSION) | ||
- | SET(VTK_LIBRARY_PROPERTIES ${VTK_LIBRARY_PROPERTIES} | ||
- | VERSION " | ||
- | SOVERSION " | ||
- | ) | ||
- | SET(VTK_LIBRARY_PROPERTIES ${VTK_LIBRARY_PROPERTIES} DEBUG_POSTFIX _d ) | ||
- | ENDIF(NOT VTK_NO_LIBRARY_VERSION) | ||
- | </ | ||
- | |||
- | * Wrappers Python debug : postfix " | ||
- | < | ||
- | ligne 58-63 | ||
- | |||
- | # Python extension modules on Windows must have the extension " | ||
- | # instead of " | ||
- | # this suffix. | ||
- | IF(WIN32 AND NOT CYGWIN) | ||
- | SET_TARGET_PROPERTIES(vtk${KIT}Python PROPERTIES SUFFIX " | ||
- | ENDIF(WIN32 AND NOT CYGWIN) | ||
- | |||
- | devient 58-64: | ||
- | |||
- | # Python extension modules on Windows must have the extension " | ||
- | # instead of " | ||
- | # this suffix. | ||
- | IF(WIN32 AND NOT CYGWIN) | ||
- | SET_TARGET_PROPERTIES(vtk${KIT}Python PROPERTIES SUFFIX " | ||
- | SET_TARGET_PROPERTIES(vtk${KIT}Python PROPERTIES DEBUG_POSTFIX " | ||
- | ENDIF(WIN32 AND NOT CYGWIN) | ||
- | </ | ||
- | |||
- | * installation des wrappers python_d : modifier VTK\vtk-5.10.1\Wrapping\Python\setup.py.in | ||
- | < | ||
- | ligne 85-97 : | ||
- | |||
- | def get_libs(): | ||
- | """ | ||
- | libs = [] | ||
- | | ||
- | # Select platform-specific components of the module file names. | ||
- | if os.name == ' | ||
- | dir = vtk_lib_dir | ||
- | prefix = ' | ||
- | suffix = get_config_var(' | ||
- | else: | ||
- | dir = vtk_bin_dir.replace('/', | ||
- | prefix = ' | ||
- | suffix = ' | ||
- | |||
- | devient 85-100 : | ||
- | |||
- | def get_libs(): | ||
- | """ | ||
- | libs = [] | ||
- | |||
- | # Select platform-specific components of the module file names. | ||
- | if os.name == ' | ||
- | dir = vtk_lib_dir | ||
- | prefix = ' | ||
- | suffix = get_config_var(' | ||
- | else: | ||
- | dir = vtk_bin_dir.replace('/', | ||
- | prefix = ' | ||
- | if vtk_build_type == ' | ||
- | suffix = ' | ||
- | else: | ||
- | suffix = ' | ||
- | |||
- | </ | ||
- | * patcher vtktclutil.cxx pour utilisation tcltk8.6: | ||
- | http:// | ||
- | "/ | ||
- | < | ||
- | ligne 21 - 24 : | ||
- | #include < | ||
- | #include < | ||
- | |||
- | extern " | ||
- | |||
- | devient 21-30 : | ||
- | #include < | ||
- | #include < | ||
- | |||
- | #if (TCL_MAJOR_VERSION == 8) && (TCL_MINOR_VERSION < 6) | ||
- | #define vtkTclGetErrorLine(m) (m-> | ||
- | #else | ||
- | #define vtkTclGetErrorLine(m) (Tcl_GetErrorLine(m)) | ||
- | #endif | ||
- | |||
- | extern " | ||
- | |||
- | ligne 488-500 : | ||
- | if (Tcl_GetVar(arg2-> | ||
- | { | ||
- | vtkGenericWarningMacro(" | ||
- | | ||
- | | ||
- | " | ||
- | } | ||
- | else | ||
- | { | ||
- | vtkGenericWarningMacro(" | ||
- | | ||
- | " | ||
- | } | ||
- | | ||
- | devient 494-506: | ||
- | |||
- | if (Tcl_GetVar(arg2-> | ||
- | { | ||
- | vtkGenericWarningMacro(" | ||
- | | ||
- | | ||
- | " | ||
- | } | ||
- | else | ||
- | { | ||
- | vtkGenericWarningMacro(" | ||
- | | ||
- | " | ||
- | } | ||
- | |||
- | ligne 721-732 : | ||
- | if (Tcl_GetVar(this-> | ||
- | { | ||
- | vtkGenericWarningMacro(" | ||
- | | ||
- | | ||
- | " | ||
- | } | ||
- | else | ||
- | { | ||
- | vtkGenericWarningMacro(" | ||
- | | ||
- | " | ||
- | } | ||
- | } | ||
- | vtkGenericWarningMacro(" | ||
- | | ||
- | | ||
- | " | ||
- | devient 727-739: | ||
- | if (Tcl_GetVar(this-> | ||
- | { | ||
- | vtkGenericWarningMacro(" | ||
- | | ||
- | | ||
- | " | ||
- | } | ||
- | else | ||
- | { | ||
- | vtkGenericWarningMacro(" | ||
- | | ||
- | " | ||
- | } | ||
- | } | ||
- | </ | ||
- | |||
- | * Executer CMake : modifier les options suivante | ||
- | * BUILD_SHARED_LIBS : ON | ||
- | * CMAKE_INSTALL_PREFIX : '' | ||
- | * CMAKE_CXX_MP_FLAG : ON (permet de compiler en parallele en local) | ||
- | * VTK_DEBUG_LEAKS : OFF (pour une version à distribuer, peut-être ON pour developpement) | ||
- | * VTK_USE_GL2PS : ON (advanced option) | ||
- | * VTK_USE_QT : ON | ||
- | * VTK_WRAP_PYTHON : ON | ||
- | * VTK_WRAP_TCL : ON | ||
- | * Les autres options doivent " | ||
- | |||
- | |||
- | * Compiler ALL_BUILD (Debug) (Commencer par debug) | ||
- | * Installer | ||
- | * Compiler ALL_BUILD (Release) | ||
- | * Installer | ||
- | |||
- | <note warning> Attention : certains fichiers debug seront écrasés par leur version release, mais normalement c'est les même ... raison pour laquelle on démarre par la version debug </ | ||
- | |||
- | |||
- | * Modifier les chemins relatifs des librairies en variables d' | ||
- | * remplacer '' | ||
- | * '' | ||
- | * '' | ||
- | * '' | ||
- | * Copier le répertoire '' | ||
- | * Installer les wrappers python (crée le répertoire LibsVS2012\Python\Lib\site_packages\VTK-5.10.1-py2.6.egg): | ||
- | * ouvrir une invite de commande et aller dans '' | ||
- | * '' | ||
- | * '' | ||
- | * Vérification: | ||
devel/vtk.1424708648.txt.gz · Last modified: 2016/03/30 15:22 (external edit)