• Jean-Christophe Fillion-Robin's avatar
    Do not force manifest selection for vtkhdf5 libraries · e6e67374
    Jean-Christophe Fillion-Robin authored
    Following e16fac17, hdf5 libraries are build with -D_BIND_TO_CURRENT_VCLIBS_VERSION=1.
    When building VTK using VS2008, the result of this is that
    (1) VTK libraries all reference "9.0.21022.8" manifest expect the hdf5
    ones that reference "9.0.30729.1" and (2) in some case prevent application
    built against VTK from starting.
    The problem can also be detected when running CMakeVerifyManifest.cmake
    against the application install tree. It basically returns a message
    similar to the following one:
    ERROR: C:/Program Files/AwesomeApp 1.0.0/bin/vtkhdf5_hl-6.2.dll uses 9.0.30729.6161 not found in shipped manifests:[9.0.21022.8].
    CMake Error at C:/D/Support/cmake-3.2.2-win32-x86/share/cmake-3.2/Modules/CMakeVerifyManifest.cmake:118 (message):
      This distribution embeds dll versions that it does not ship, and may not
      work on other machines.
    Here are some more information copied from the convenience script allowing
    to patch the manifest from VS2008.
    Source:  https://gist.github.com/jcfr/3c7bef3f8b32f9f6ad4b
        Patch manifests in the redist folder of Visual Studio 9 (2008)
        To avoid the dll hell associated with runtime libraries distribution. There are
        two approaches:
         (1) edit the manifest file to have "9.0.21022.8" from the "9.0.30729.XXX" that is there, you "trick"
             your executable into using the newer dlls.  There appears to be no ill effects from this.
             The executables work, and you are using a newer version of the run time library.
         (2) add -D_BIND_TO_CURRENT_VCLIBS=1 to ALL files being compiled, then all of your executable files
             and dll files will refer to "9.0.30729.XXX" and you can use the redist files without any edits.
             However, you have to be careful here to recompile everything with this.  By default the compiler
             will build for "9.0.21022.8".
        This script will consider approach (1). If not already done, this script will first backup the
        manifest files and then patch them.
          * http://www.kitware.com/blog/home/post/4
          * http://stackoverflow.com/questions/8097733/how-to-distribute-c-run-time-crt-libraries
Last commit
Last update
vtkhdf5 Loading commit data...
CMakeLists.txt Loading commit data...
module.cmake Loading commit data...
vtk_hdf5.h.in Loading commit data...