upgpkg: ufw 0.36.2-1
[ArchLinux/community.git] / superslicer / trunk / superslicer-openexr3.patch
blob8ae71c13f4d322519d8f84b335ad1e72d67a4565
1 diff --git a/cmake/modules/FindOpenVDB.cmake b/cmake/modules/FindOpenVDB.cmake
2 index 4fde5fa4a..566e73a5e 100644
3 --- a/cmake/modules/FindOpenVDB.cmake
4 +++ b/cmake/modules/FindOpenVDB.cmake
5 @@ -347,28 +347,10 @@ macro(just_fail msg)
6 return()
7 endmacro()
9 -find_package(IlmBase QUIET)
10 -if(NOT IlmBase_FOUND)
11 - pkg_check_modules(IlmBase QUIET IlmBase)
12 -endif()
13 -if (IlmBase_FOUND AND NOT TARGET IlmBase::Half)
14 - message(STATUS "Falling back to IlmBase found by pkg-config...")
16 - find_library(IlmHalf_LIBRARY NAMES Half)
17 - if(IlmHalf_LIBRARY-NOTFOUND OR NOT IlmBase_INCLUDE_DIRS)
18 - just_fail("IlmBase::Half can not be found!")
19 - endif()
21 - add_library(IlmBase::Half UNKNOWN IMPORTED)
22 - set_target_properties(IlmBase::Half PROPERTIES
23 - IMPORTED_LOCATION "${IlmHalf_LIBRARY}"
24 - INTERFACE_INCLUDE_DIRECTORIES "${IlmBase_INCLUDE_DIRS}")
25 -elseif(NOT IlmBase_FOUND)
26 - just_fail("IlmBase::Half can not be found!")
27 -endif()
28 find_package(TBB ${_quiet} ${_required} COMPONENTS tbb)
29 find_package(ZLIB ${_quiet} ${_required})
30 find_package(Boost ${_quiet} ${_required} COMPONENTS iostreams system )
31 +find_package(Imath CONFIG)
33 # Use GetPrerequisites to see which libraries this OpenVDB lib has linked to
34 # which we can query for optional deps. This basically runs ldd/otoll/objdump
35 @@ -419,7 +401,7 @@ foreach(PREREQUISITE ${_OPENVDB_PREREQUISITE_LIST})
36 set(OpenVDB_USES_LOG4CPLUS ON)
37 endif()
39 - string(FIND ${PREREQUISITE} "IlmImf" _HAS_DEP)
40 + string(FIND ${PREREQUISITE} "OpenEXR" _HAS_DEP)
41 if(NOT ${_HAS_DEP} EQUAL -1)
42 set(OpenVDB_USES_ILM ON)
43 endif()
44 @@ -450,11 +432,7 @@ if(OpenVDB_USES_LOG4CPLUS)
45 find_package(Log4cplus ${_quiet} ${_required})
46 endif()
48 -if(OpenVDB_USES_ILM)
49 - find_package(IlmBase ${_quiet} ${_required})
50 -endif()
52 -if(OpenVDB_USES_EXR)
53 +if(OpenVDB_USES_ILM OR OpenVDB_USES_EXR)
54 find_package(OpenEXR ${_quiet} ${_required})
55 endif()
57 @@ -471,7 +449,7 @@ endif()
58 set(_OPENVDB_VISIBLE_DEPENDENCIES
59 Boost::iostreams
60 Boost::system
61 - IlmBase::Half
62 + Imath::Imath
65 set(_OPENVDB_DEFINITIONS)
66 @@ -481,10 +459,7 @@ endif()
68 if(OpenVDB_USES_EXR)
69 list(APPEND _OPENVDB_VISIBLE_DEPENDENCIES
70 - IlmBase::IlmThread
71 - IlmBase::Iex
72 - IlmBase::Imath
73 - OpenEXR::IlmImf
74 + OpenEXR::OpenEXR
76 list(APPEND _OPENVDB_DEFINITIONS "-DOPENVDB_TOOLS_RAYTRACER_USE_EXR")
77 endif()