diff options
| author | xoviat <xoviat@users.noreply.github.com> | 2017-11-01 15:20:00 -0500 |
|---|---|---|
| committer | Robert Schumacher <roschuma@microsoft.com> | 2017-11-01 13:20:00 -0700 |
| commit | 7ac8622265cf1154daac61ed4165365701e9e848 (patch) | |
| tree | 8654686e05af10c56eec6ef1c929c8a334463b2c | |
| parent | 93400414b05da83a4f615723b880650d845cfa7d (diff) | |
| download | vcpkg-7ac8622265cf1154daac61ed4165365701e9e848.tar.gz vcpkg-7ac8622265cf1154daac61ed4165365701e9e848.zip | |
VTK: implement features (#2071)
* [vtk/portfile] add OpenVR option
* [vtk/control] add OpenVR feature
* [vtk/portfile] Add OpenVR feature to portfile
* [vtk/CONTROL] add features
* [vtk/portfile] implement features
* [vtk/CONTROL] fix syntax
* [vtk/CONTROL] fix case
* [vtk/portfile] fix case
* [vtk/CONTROL] fix syntax
* [vtk/CONTROL] fix syntax
* [vtk/portfile] fix module name
* [vtk] Bump version
| -rw-r--r-- | ports/vtk/CONTROL | 20 | ||||
| -rw-r--r-- | ports/vtk/portfile.cmake | 34 |
2 files changed, 48 insertions, 6 deletions
diff --git a/ports/vtk/CONTROL b/ports/vtk/CONTROL index 1c9095d34..d30e61506 100644 --- a/ports/vtk/CONTROL +++ b/ports/vtk/CONTROL @@ -1,4 +1,20 @@ Source: vtk -Version: 8.0.1 +Version: 8.0.1-1 Description: Software system for 3D computer graphics, image processing, and visualization -Build-Depends: zlib, libpng, tiff, libxml2, jsoncpp, glew, freetype, expat, hdf5, qt5, msmpi, libjpeg-turbo, proj4, lz4, libtheora, libharu +Build-Depends: zlib, libpng, tiff, libxml2, jsoncpp, glew, freetype, expat, hdf5, libjpeg-turbo, proj4, lz4, libtheora, libharu + +Feature: openvr +Description: OpenVR functionality for VTK +Build-Depends: sdl2, openvr + +Feature: qt +Description: Qt functionality for VTK +Build-Depends: qt5 + +Feature: mpi +Description: MPI functionality for VTK +Build-Depends: msmpi + +Feature: python +Description: Python functionality for VTK +Build-Depends: python3 diff --git a/ports/vtk/portfile.cmake b/ports/vtk/portfile.cmake index 463ce6981..0a407e9ae 100644 --- a/ports/vtk/portfile.cmake +++ b/ports/vtk/portfile.cmake @@ -13,12 +13,32 @@ vcpkg_from_github( # ============================================================================= # Options: These should be set by feature-packages when they become available -set(VTK_WITH_QT ON ) # IMPORTANT: if ON make sure `qt5` is listed as dependency in the CONTROL file -set(VTK_WITH_MPI ON ) # IMPORTANT: if ON make sure `mpi` is listed as dependency in the CONTROL file -set(VTK_WITH_PYTHON OFF) # IMPORTANT: if ON make sure `python3` is listed as dependency in the CONTROL file + +if ("qt" IN_LIST FEATURES) + set(VTK_WITH_QT ON ) # IMPORTANT: if ON make sure `qt5` is listed as dependency in the CONTROL file +else() + set(VTK_WITH_QT OFF ) # IMPORTANT: if ON make sure `qt5` is listed as dependency in the CONTROL file +endif() + +if ("mpi" IN_LIST FEATURES) + set(VTK_WITH_MPI ON ) # IMPORTANT: if ON make sure `mpi` is listed as dependency in the CONTROL file +else() + set(VTK_WITH_MPI OFF ) # IMPORTANT: if ON make sure `mpi` is listed as dependency in the CONTROL file +endif() + +if ("python" IN_LIST FEATURES) + set(VTK_WITH_PYTHON ON) # IMPORTANT: if ON make sure `python3` is listed as dependency in the CONTROL file +else() + set(VTK_WITH_PYTHON OFF) # IMPORTANT: if ON make sure `python3` is listed as dependency in the CONTROL file +endif() +if("openvr" IN_LIST FEATURES) + set(VTK_WITH_OPENVR ON) # IMPORTANT: if ON make sure `OpenVR` is listed as dependency in the CONTROL file +else() + set(VTK_WITH_OPENVR OFF) +endif() + set(VTK_WITH_ALL_MODULES OFF) # IMPORTANT: if ON make sure `qt5`, `mpi`, `python3`, `ffmpeg`, `gdal`, `fontconfig`, # `libmysql` and `atlmfc` are listed as dependency in the CONTROL file - # ============================================================================= # Apply patches to the source code vcpkg_apply_patches( @@ -78,6 +98,12 @@ if(VTK_WITH_PYTHON) ) endif() +if(VTK_WITH_OPENVR) + list(APPEND ADDITIONAL_OPTIONS + -DModule_vtkRenderingOpenVR=ON + ) +endif() + if(VTK_WITH_ALL_MODULES) list(APPEND ADDITIONAL_OPTIONS -DVTK_BUILD_ALL_MODULES=ON |
