I want to build OpenImageIO on windows using cmake but I am stuck with the following problem: cmake stops the project generation process because it cannot find the third party libraries required by OpenImageIO.
Here is what I did (I followed the official guide for building OIIO on windows) :
- Downloaded the current OpenImageIO release branch from their github repo. And copied it to D:/libraries/oiio
- Downloaded the precompiled external libraries Put them into D:/libraries/oiio/external
- Downloaded Qt4 binaries for windows. Put them to D:/qt and added the path D:/libraries/qt/bin to my PATH.
- Downlodaded precompiled BOOST libraries (version 1.60) They reside in D:/libraries/BOOST.
- Installed cmake and ran cmake-gui:
- Set the source path to the OIIO root directory containing the CMake
- Set the output path to D:/oiio/
- Added THIRD_PARTY_TOOLS_HOME which points to D:/libraries/oiio/external/windows/dist
- Added BOOST_ROOT and made it point to D:/libraries/BOOST
- Set USE_PYTHON = 0 and USE_TBB = 0
So basically from my point of view I did everything what the install instructions told me to do. But then when I hit "configure" I get the following ouput form cmake-gui :
The C compiler identification is MSVC 19.0.23918.0
The CXX compiler identification is MSVC 19.0.23918.0
Check for working C compiler using: Visual Studio 14 2015 Win64
Check for working C compiler using: Visual Studio 14 2015 Win64 -- works
Detecting C compiler ABI info
Detecting C compiler ABI info - done
Check for working CXX compiler using: Visual Studio 14 2015 Win64
Check for working CXX compiler using: Visual Studio 14 2015 Win64 -- works
Detecting CXX compiler ABI info
Detecting CXX compiler ABI info - done
Detecting CXX compile features
Detecting CXX compile features - done
Project build dir = P:/libraries/oiio/build
CMAKE_CXX_COMPILER is C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/bin/x86_amd64/cl.exe
CMAKE_CXX_COMPILER_ID is MSVC
Setting Namespace to: OpenImageIO
platform = windows
CMake Error at C:/Program Files (x86)/CMake/share/cmake-3.5/Modules/FindPackageHandleStandardArgs.cmake:148 (message):
Could NOT find ZLIB (missing: ZLIB_LIBRARY ZLIB_INCLUDE_DIR)
Call Stack (most recent call first):
C:/Program Files (x86)/CMake/share/cmake-3.5/Modules/FindPackageHandleStandardArgs.cmake:388 (_FPHSA_FAILURE_MESSAGE)
C:/Program Files (x86)/CMake/share/cmake-3.5/Modules/FindZLIB.cmake:124 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
src/cmake/modules/FindOpenEXR.cmake:22 (find_package)
src/cmake/externalpackages.cmake:70 (find_package)
CMakeLists.txt:303 (include)
Configuring incomplete, errors occurred!
See also "P:/libraries/oiio/build/CMakeFiles/CMakeOutput.log".
I've tried a lot of things including setting ZLIB_LIBRARY and ZLIB_INCLUDE_DIR manually but then it complains either about not finding one of the above or it complains about not finding the next third party libary.
I've also tried adding CMAKE_PREFIX_PATH to cmake-gui and setting it to the paths it cannot find but it helped nothing.
Then I've tried using only backslashes because I read something about that this might be an issue but it also did not help.
I'm using a Windows 7 64 bit machine with cmake 3.5.2
Id really appreciate any help as by now I don't know what I could do.
Thanks in advance !