Open
fix build with system openjph #191
Funda WangAdd on 4 days ago
fix build with system openjph #191
Open
Merged fromfundawang/OpenEXRmasterintosrc-openeuler/OpenEXRmaster
Total: 2 files changed+18-1
| @@ -3,12 +3,13 @@ | |||
| 3 | Name: OpenEXR | 3 | Name: OpenEXR |
| 4 | Summary: A high dynamic-range (HDR) image file format for use in computer imaging applications | 4 | Summary: A high dynamic-range (HDR) image file format for use in computer imaging applications |
| 5 | Version: 3.5.3 | 5 | Version: 3.5.3 |
| 6 | -Release: 1 | 6 | +Release: 2 |
| 7 | License: BSD-3-Clause | 7 | License: BSD-3-Clause |
| 8 | URL: https://www.openexr.com/ | 8 | URL: https://www.openexr.com/ |
| 9 | Source0: https://github.com/AcademySoftwareFoundation/openexr/releases/download/v%{version}/openexr-%{version}.tar.gz | 9 | Source0: https://github.com/AcademySoftwareFoundation/openexr/releases/download/v%{version}/openexr-%{version}.tar.gz |
| 10 | # for test images | 10 | # for test images |
| 11 | Source1: https://github.com/AcademySoftwareFoundation/openexr-images/archive/refs/tags/v1.0.tar.gz | 11 | Source1: https://github.com/AcademySoftwareFoundation/openexr-images/archive/refs/tags/v1.0.tar.gz |
| 12 | +Patch0: openexr-Fix-building-with-system-OpenJPH.patch | ||
| 12 | BuildRequires: cmake >= 3.14 | 13 | BuildRequires: cmake >= 3.14 |
| 13 | BuildRequires: gcc gcc-c++ | 14 | BuildRequires: gcc gcc-c++ |
| 14 | BuildRequires: python3 | 15 | BuildRequires: python3 |
| @@ -79,6 +80,9 @@ cp -fr openexr-images-1.0/* %{__cmake_builddir}/src/test/bin/ | |||
| 79 | %{_libdir}/pkgconfig/OpenEXR.pc | 80 | %{_libdir}/pkgconfig/OpenEXR.pc |
| 80 | 81 | ||
| 81 | %changelog | 82 | %changelog |
| 83 | +* Tue Nov 03 2026 Funda Wang <fundawang@yeah.net> - 3.5.3-2 | ||
| 84 | +- fix build with system openjph | ||
| 85 | + | ||
| 82 | * Tue Nov 03 2026 Funda Wang <fundawang@yeah.net> - 3.5.3-1 | 86 | * Tue Nov 03 2026 Funda Wang <fundawang@yeah.net> - 3.5.3-1 |
| 83 | - update to 3.5.3 | 87 | - update to 3.5.3 |
| 84 | 88 | ||
| @@ -0,0 +1,13 @@ | |||
| 1 | +diff --git a/cmake/OpenEXRSetup.cmake b/cmake/OpenEXRSetup.cmake | ||
| 2 | +index 9d7ee1e..a02de4e 100644 | ||
| 3 | +--- a/cmake/OpenEXRSetup.cmake | ||
| 4 | ++++ b/cmake/OpenEXRSetup.cmake | ||
| 5 | +@@ -272,7 +272,7 @@ set(OPENEXR_USE_INTERNAL_OPENJPH 0 CACHE INTERNAL | ||
| 6 | + "Whether OpenEXR bundles vendored OpenJPH into OpenEXRCore (0 or 1)") | ||
| 7 | + | ||
| 8 | + if (NOT OPENEXR_FORCE_INTERNAL_OPENJPH) | ||
| 9 | +- find_package(openjph 0.32.0 CONFIG QUIET) | ||
| 10 | ++ find_package(openjph CONFIG QUIET) | ||
| 11 | + if(openjph_FOUND) | ||
| 12 | + message(STATUS "Using OpenJPH ${openjph_VERSION} from ${openjph_DIR}") | ||
| 13 | + set(EXR_OPENJPH_LIB openjph) | ||