openimageio: fix build error

authored by

illustris and committed by
Dmitry Kalinkin
3bf443d4 e9eee4a9

+36
+31
pkgs/applications/graphics/openimageio/2539_backport.patch
··· 1 + diff --git a/src/libOpenImageIO/exif.cpp b/src/libOpenImageIO/exif.cpp 2 + index 10b75c21..0287d9c5 100644 3 + --- a/src/libOpenImageIO/exif.cpp 4 + +++ b/src/libOpenImageIO/exif.cpp 5 + @@ -213,6 +213,9 @@ static const EXIF_tag_info exif_tag_table[] = { 6 + 7 + 8 + 9 + +// libtiff > 4.1.0 defines these in tiff.h. For older libtiff, let's define 10 + +// them ourselves. 11 + +#ifndef GPSTAG_VERSIONID 12 + enum GPSTag { 13 + GPSTAG_VERSIONID = 0, 14 + GPSTAG_LATITUDEREF = 1, GPSTAG_LATITUDE = 2, 15 + @@ -237,6 +240,7 @@ enum GPSTag { 16 + GPSTAG_DIFFERENTIAL = 30, 17 + GPSTAG_HPOSITIONINGERROR = 31 18 + }; 19 + +#endif 20 + 21 + static const EXIF_tag_info gps_tag_table[] = { 22 + { GPSTAG_VERSIONID, "GPS:VersionID", TIFF_BYTE, 4 }, 23 + @@ -270,7 +274,7 @@ static const EXIF_tag_info gps_tag_table[] = { 24 + { GPSTAG_AREAINFORMATION, "GPS:AreaInformation", TIFF_UNDEFINED, 1 }, 25 + { GPSTAG_DATESTAMP, "GPS:DateStamp", TIFF_ASCII, 0 }, 26 + { GPSTAG_DIFFERENTIAL, "GPS:Differential", TIFF_SHORT, 1 }, 27 + - { GPSTAG_HPOSITIONINGERROR, "GPS:HPositioningError",TIFF_RATIONAL, 1 }, 28 + + { GPSTAG_GPSHPOSITIONINGERROR, "GPS:HPositioningError",TIFF_RATIONAL, 1 }, 29 + { -1, NULL } // signal end of table 30 + }; 31 +
+5
pkgs/applications/graphics/openimageio/default.nix
··· 33 33 "dist_dir=" 34 34 ]; 35 35 36 + patches = [ 37 + # Backported from https://github.com/OpenImageIO/oiio/pull/2539 for 1.8.17 38 + ./2539_backport.patch 39 + ]; 40 + 36 41 meta = with lib; { 37 42 homepage = "http://www.openimageio.org"; 38 43 description = "A library and tools for reading and writing images";