diff options
author | Pietro Cerutti <gahr@FreeBSD.org> | 2010-04-03 15:34:44 +0000 |
---|---|---|
committer | Pietro Cerutti <gahr@FreeBSD.org> | 2010-04-03 15:34:44 +0000 |
commit | a75ba61095c358ef211379230b13b83562c395f3 (patch) | |
tree | 1eccaeff12bfc8c6d6cacbb8d369c9bfff3d76f8 /math/vtk5/Makefile | |
parent | d3694db1c3cc84feb30af4df932720d8aa88fd10 (diff) | |
download | ports-a75ba61095c358ef211379230b13b83562c395f3.tar.gz ports-a75ba61095c358ef211379230b13b83562c395f3.zip |
- Update to 5.4.2
Notes
Notes:
svn path=/head/; revision=252131
Diffstat (limited to 'math/vtk5/Makefile')
-rw-r--r-- | math/vtk5/Makefile | 154 |
1 files changed, 78 insertions, 76 deletions
diff --git a/math/vtk5/Makefile b/math/vtk5/Makefile index 1cce7aedebe4..5a57bfdda816 100644 --- a/math/vtk5/Makefile +++ b/math/vtk5/Makefile @@ -7,14 +7,12 @@ # PORTNAME= vtk -PORTVERSION= 5.0.4 -PORTREVISION= 7 +PORTVERSION= 5.4.2 CATEGORIES= math graphics MASTER_SITES= http://www.vtk.org/files/release/${PORTVERSION:R}/ \ http://www.neuro.mcw.edu/Ports/distfiles/VTK5/ -DISTNAME?= vtk-${PORTVERSION} -MAINTAINER= ports@FreeBSD.org +MAINTAINER= gahr@FreeBSD.org COMMENT= The Visualization Toolkit LIB_DEPENDS= expat.[5-6]:${PORTSDIR}/textproc/expat2 \ @@ -24,131 +22,135 @@ LIB_DEPENDS= expat.[5-6]:${PORTSDIR}/textproc/expat2 \ LATEST_LINK= vtk5 -USE_QT_VER= 3 -USE_TCL= 84 -USE_TK= 84 -USE_PYTHON= yes -INSTALLS_EGGINFO= yes - -VTKSRCDIR= ${WRKDIR}/VTK -VTKDATAROOT= ${EXAMPLESDIR}/VTKData -PYDISTUTILS_PKGNAME= VTK +WRKSRC= ${WRKDIR}/VTK CONFLICTS= vtk-4* vtk-5.0.[012356789]* -NO_FILTER_SHLIBS= yes - -VTK_KITS= Common Filtering GenericFiltering Graphics \ - Hybrid IO Imaging Parallel Rendering VolumeRendering \ - Widgets -SUB_FILES= pkg-message vtk.3 -PKGMESSAGE= ${WRKDIR}/pkg-message +SUB_FILES= vtk.3 USE_CMAKE= yes USE_GMAKE= yes USE_GL= yes USE_LDCONFIG= yes +MAKE_JOBS_SAFE= no -OPTIONS= MANGLEDMESA "Use off-screen (Mangled) Mesa" Off \ - VTKMPEG2 "Install patented MPEG2 encoder module" Off \ - GL2PS "Install support conversion OpenGL to PostScript" On +OPTIONS= VTKMPEG2 "Install patented MPEG2 encoder module" Off \ + GL2PS "Install support conversion OpenGL to PostScript" On \ + QT "Enable Qt gui support" On \ + WRAP_PYTHON "Enable Python wrapping" On \ + WRAP_TCLTK "Enable Tcl/Tk wrapping" On -PLIST_SUB= VER=${PORTVERSION} VER1=${PORTVERSION:R} VER2=${PORTVERSION:R:R} +PLIST_SUB= VER1="${PORTVERSION:R}" \ + VER2="${PORTVERSION}" MAN3= vtk.3 - -.include <bsd.port.pre.mk> +PORTDOCS= README.html CMAKE_USE_PTHREAD= yes -CMAKE_SOURCE_PATH= ../VTK -CMAKE_ARGS+= ${VTKSRCDIR} \ - -DBUILD_SHARED_LIBS:BOOL=ON \ +CMAKE_OUTSOURCE= yes + +CMAKE_ARGS+= -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON \ + -DBUILD_SHARED_LIBS:BOOL=ON \ -DBUILD_DOCUMENTATION:BOOL=ON \ -DBUILD_TESTING:BOOL=OFF \ - -DVTK_USE_RENDERING:BOOL=ON \ - -DVTK_USE_HYBRID:BOOL=ON \ - -DVTK_USE_PARALLEL:BOOL=ON \ -DVTK_USE_SYSTEM_EXPAT:BOOL=ON \ -DVTK_USE_SYSTEM_JPEG:BOOL=ON \ -DVTK_USE_SYSTEM_PNG:BOOL=ON \ -DVTK_USE_SYSTEM_TIFF:BOOL=ON \ -DVTK_USE_SYSTEM_ZLIB:BOOL=ON \ -DVTK_USE_GUISUPPORT:BOOL=ON \ - -DVTK_USE_QVTK:BOOL=ON \ - -DVTK_WRAP_PYTHON:BOOL=ON \ - -DVTK_WRAP_TCL:BOOL=ON \ - -DTCL_INCLUDE_PATH=${TCL_INCLUDEDIR} \ - -DTK_INCLUDE_PATH=${TK_INCLUDEDIR} \ - -DDESIRED_QT_VERSION:STRING=3 \ -DVTK_HAVE_GETSOCKNAME_WITH_SOCKLEN_T:BOOL=ON \ - -DVTK_DATA_ROOT:PATH=${VTKDATAROOT} \ + -DVTK_DATA_ROOT:PATH=${EXAMPLESDIR}/VTKData \ -DOPENGL_INCLUDE_DIR:PATH=${LOCALBASE}/include \ -DOPENGL_gl_LIBRARY:FILEPATH=${LOCALBASE}/lib/libGL.so \ -DOPENGL_glu_LIBRARY:FILEPATH=${LOCALBASE}/lib/libGLU.so -.if defined(WITH_MANGLEDMESA) -LIB_DEPENDS+= MesaGL.14:${PORTSDIR}/graphics/mesagl -CMAKE_ARGS+= -DVTK_OPENGL_HAS_OSMESA:BOOL=OFF \ - -DVTK_USE_MANGLED_MESA:BOOL=ON \ - -DMANGLED_MESA_INCLUDE_DIR:PATH=${LOCALBASE}/include/Mesa \ - -DMANGLED_MESA_LIBRARY:FILEPATH=${LOCALBASE}/lib/libMesaGL.so \ - -DMANGLED_OSMESA_INCLUDE_DIR:PATH=${LOCALBASE}/include/Mesa \ - -DMANGLED_OSMESA_LIBRARY:FILEPATH=${LOCALBASE}/lib/libMesaOSMesa.so -#.else -#CMAKE_ARGS+= -DVTK_OPENGL_HAS_OSMESA:BOOL=ON \ -# -DOSMESA_LIBRARY:FILEPATH=${LOCALBASE}/lib/libOSMesa.so -.endif +.include <bsd.port.options.mk> .if defined(WITH_VTKMPEG2) LIB_DEPENDS+= vtkMPEG2Encode.5:${PORTSDIR}/multimedia/vtkmpeg2encode -PLIST_FILES+= include/vtk-5.0/vtkMPEG2Writer.h -CMAKE_ARGS+= -DvtkMPEG2Encode_INCLUDE_PATH=${LOCALBASE}/include/vtk-5.0 \ - -DvtkMPEG2Encode_LIBRARIES=vtkMPEG2Encode \ - -DVTK_USE_PATENTED:BOOL=ON \ - -DVTK_USE_MPEG2_ENCODER:BOOL=ON +PLIST_SUB+= MPEG="" +CMAKE_ARGS+= -DVTK_USE_PATENTED:BOOL=ON \ + -DVTK_USE_MPEG2_ENCODER:BOOL=ON \ + -DvtkMPEG2Encode_INCLUDE_PATH=${LOCALBASE}/include/vtk-5.4 \ + -DvtkMPEG2Encode_LIBRARIES=${LOCALBASE}/lib/libvtkMPEG2Encode.so +.else +PLIST_SUB+= MPEG="@comment " .endif .if defined(WITH_GL2PS) LIB_DEPENDS+= gl2ps.1:${PORTSDIR}/print/gl2ps CMAKE_ARGS+= -DVTK_USE_GL2PS:BOOL=ON -PLIST_FILES+= include/vtk-5.0/vtkGL2PSExporter.h +PLIST_SUB+= GL2PS="" +.else +PLIST_SUB+= GL2PS="@comment " .endif -post-extract: - ${MKDIR} ${WRKSRC} - ${REINPLACE_CMD} -e 's|malloc.h|stdlib.h|g' \ - ${VTKSRCDIR}/Hybrid/vtkVRMLImporter.cxx +.if defined(WITH_QT) +USE_QT_VER= 4 +QT_COMPONENTS= qmake corelib assistant assistantclient designer uic +CMAKE_ARGS+= -DVTK_USE_GUISUPPORT:BOOL=ON \ + -DVTK_USE_QVTK:BOOL=ON \ + -DDESIRED_QT_VERSION:STRING=4 \ + -DQT_QMAKE_EXECUTABLE:FILEPATH=${QMAKE} +PLIST_SUB+= QT="" +.else +CMAKE_ARGS+= -DVTK_USE_GUISUPPORT:BOOL=OFF +PLIST_SUB+= QT="@comment " +.endif -post-patch: - @${REINPLACE_CMD} -e 's|png_set_gray_1_2_4_to_8|png_set_expand_gray_1_2_4_to_8|' \ - ${VTKSRCDIR}/IO/vtkPNGReader.cxx +.if defined(WITH_WRAP_PYTHON) +USE_PYTHON= yes +PYDISTUTILS_PKGNAME= VTK +INSTALLS_EGGINFO= yes +CMAKE_ARGS+= -DVTK_WRAP_PYTHON:BOOL=ON \ + -DVTK_PYTHON_SETUP_ARGS:STRING='--prefix="${PREFIX}"' +PLIST_SUB+= PYTHON="" +.else +CMAKE_ARGS+= -DVTK_WRAP_PYTHON:BOOL=OFF +PLIST_SUB+= PYTHON="@comment " +.endif +.if defined(WITH_WRAP_TCLTK) +USE_TCL= 84+ +USE_TK= 84+ +CMAKE_ARGS+= -DVTK_WRAP_TCL:BOOL=ON \ + -DTCL_INCLUDE_PATH=${TCL_INCLUDEDIR} \ + -DTK_INCLUDE_PATH=${TK_INCLUDEDIR} +PLIST_SUB+= TCLTK="" \ + TCLTK_VER="${TCL_VER}" +.else +CMAKE_ARGS+= -DVTK_WRAP_TCL:BOOL=OFF +PLIST_SUB+= TCLTK="@comment " +.endif + +post-patch: + ${REINPLACE_CMD} -e 's|malloc.h|stdlib.h|g' \ + ${WRKSRC}/Hybrid/vtkVRMLImporter.cxx + ${REINPLACE_CMD} -e '222s|)|) \&\& !defined(__FreeBSD__)|' \ + ${WRKSRC}/Utilities/kwsys/SharedForward.h.in + ${REINPLACE_CMD} -e '25,30d' ${WRKSRC}/Wrapping/Python/setup.py.in + ${REINPLACE_CMD} -e 's|png_set_gray_1_2_4_to_8|png_set_expand_gray_1_2_4_to_8|' \ + ${WRKSRC}/IO/vtkPNGReader.cxx # FSL links directly to libQVTKWidgetPlugin.so, so put it in a standard # library directory. pre-install: - ${MKDIR} ${PREFIX}/lib/vtk-5.0 - ${INSTALL_DATA} ${WRKSRC}/bin/libQVTKWidgetPlugin.so ${PREFIX}/lib + ${MKDIR} ${PYTHONPREFIX_SITELIBDIR} + ${MKDIR} ${MANPREFIX}/man/man3 ${INSTALL_MAN} ${WRKDIR}/vtk.3 ${MANPREFIX}/man/man3 .if !defined(NOPORTDOCS) ${MKDIR} ${DOCSDIR} - ${INSTALL_DATA} ${VTKSRCDIR}/README.html ${DOCSDIR} + ${INSTALL_DATA} ${WRKSRC}/README.html ${DOCSDIR} .endif # Ports system wants us to conform to lib.so.x format, but VTK5 # only installs lib.so.x.y and lib.so.5.x.y.z. post-install: - @for lib in ${PREFIX}/lib/libvtk*.so ${PREFIX}/lib/libQVTK*.so; do \ - ${RM} -f $$lib; \ - ${LN} -sf $$lib.${PORTVERSION} $$lib; \ - ${LN} -sf $$lib.${PORTVERSION} $$lib.5; \ - done - @${ECHO_CMD} - @${CAT} ${PKGMESSAGE} - @${ECHO_CMD} .if defined(WITH_VTKMPEG2) + @${ECHO_CMD} @${ECHO_CMD} "This port uses the patented MPEG2 encoder." @${ECHO_CMD} .endif -.include <bsd.port.post.mk> +.include <bsd.port.mk> |