From 9fe2804821a84cc63bc2e0147c1f5cd9c0557e7e Mon Sep 17 00:00:00 2001 From: miqlas Date: Sat, 4 Feb 2017 12:13:15 +0100 Subject: [PATCH] OpenImageIO: git fix (#1136) --- ....5.15.recipe => openimageio-1.7.11.recipe} | 20 ++-- .../patches/openimageio-1.5.15.patchset | 54 ----------- .../patches/openimageio-1.7.11.patchset | 95 +++++++++++++++++++ 3 files changed, 105 insertions(+), 64 deletions(-) rename media-libs/openimageio/{openimageio-1.5.15.recipe => openimageio-1.7.11.recipe} (95%) delete mode 100644 media-libs/openimageio/patches/openimageio-1.5.15.patchset create mode 100644 media-libs/openimageio/patches/openimageio-1.7.11.patchset diff --git a/media-libs/openimageio/openimageio-1.5.15.recipe b/media-libs/openimageio/openimageio-1.7.11.recipe similarity index 95% rename from media-libs/openimageio/openimageio-1.5.15.recipe rename to media-libs/openimageio/openimageio-1.7.11.recipe index 51d7f77fb..7fd96d6cb 100644 --- a/media-libs/openimageio/openimageio-1.5.15.recipe +++ b/media-libs/openimageio/openimageio-1.7.11.recipe @@ -8,12 +8,12 @@ world, and is also incorporated into several commercial products." HOMEPAGE="http://github.com/OpenImageIO/" COPYRIGHT="2008-2015 Larry Gritz et al." LICENSE="BSD (3-clause)" -REVISION="2" +REVISION="1" SOURCE_URI="https://github.com/OpenImageIO/oiio/archive/Release-$portVersion.tar.gz" -CHECKSUM_SHA256="e41e1d94ff2dc6029969b295a9eed83d6817807c741bde8a4f4947b74dc62222" +CHECKSUM_SHA256="52992720488fe255f77a6fdbc44d716e3b0db922e741fa4d13ac15841dc8331d" SOURCE_FILENAME="openimageio-$portVersion.tar.gz" SOURCE_DIR="oiio-Release-$portVersion" -PATCHES="openimageio-1.5.15.patchset" +PATCHES="openimageio-1.7.11.patchset" ARCHITECTURES="x86 x86_64" SECONDARY_ARCHITECTURES="!x86_gcc2 x86" @@ -31,13 +31,6 @@ PROVIDES=" " REQUIRES=" haiku$secondaryArchSuffix - lib:libhalf$secondaryArchSuffix - lib:libilmimf$secondaryArchSuffix - lib:libjpeg$secondaryArchSuffix - lib:libpng16$secondaryArchSuffix - lib:libtiff$secondaryArchSuffix - lib:libwebp$secondaryArchSuffix - lib:libz$secondaryArchSuffix lib:libboost_atomic$secondaryArchSuffix lib:libboost_chrono$secondaryArchSuffix lib:libboost_date_time$secondaryArchSuffix @@ -45,6 +38,13 @@ REQUIRES=" lib:libboost_regex$secondaryArchSuffix lib:libboost_system$secondaryArchSuffix lib:libboost_thread$secondaryArchSuffix + lib:libhalf$secondaryArchSuffix + lib:libilmimf$secondaryArchSuffix + lib:libjpeg$secondaryArchSuffix + lib:libpng16$secondaryArchSuffix + lib:libtiff$secondaryArchSuffix + lib:libwebp$secondaryArchSuffix + lib:libz$secondaryArchSuffix " PROVIDES_devel=" diff --git a/media-libs/openimageio/patches/openimageio-1.5.15.patchset b/media-libs/openimageio/patches/openimageio-1.5.15.patchset deleted file mode 100644 index 332238f0c..000000000 --- a/media-libs/openimageio/patches/openimageio-1.5.15.patchset +++ /dev/null @@ -1,54 +0,0 @@ -From 4718cb2a5bf8ab1936f738118d7235af5bd07073 Mon Sep 17 00:00:00 2001 -From: Jerome Duval -Date: Sun, 7 Jun 2015 22:05:26 +0000 -Subject: Haiku patch - - -diff --git a/src/libutil/sysutil.cpp b/src/libutil/sysutil.cpp -index de7b9ac..dc6e1be 100644 ---- a/src/libutil/sysutil.cpp -+++ b/src/libutil/sysutil.cpp -@@ -70,6 +70,12 @@ - # include - #endif - -+#if defined (__HAIKU__) -+# include -+# include -+# include -+#endif -+ - #include "OpenImageIO/dassert.h" - #include "OpenImageIO/sysutil.h" - -@@ -244,7 +250,7 @@ Sysutil::this_program_path () - size_t cb = sizeof(filename); - int r=1; - sysctl(mib, 4, filename, &cb, NULL, 0); --#elif defined(__GNU__) || defined(__OpenBSD__) -+#elif defined(__GNU__) || defined(__OpenBSD__) || defined(__HAIKU__) - int r = 0; - #else - // No idea what platform this is -diff --git a/src/make/detectplatform.mk b/src/make/detectplatform.mk -index bc29f4b..8d439ae 100644 ---- a/src/make/detectplatform.mk -+++ b/src/make/detectplatform.mk -@@ -46,6 +46,14 @@ ifeq (${platform},unknown) - endif - endif - -+ # Haiku -+ ifeq (${uname},haiku) -+ platform := haiku -+ ifeq (${hw},x86_64) -+ platform := haiku64 -+ endif -+ endif -+ - # Windows - ifeq (${uname},cygwin) - platform := windows --- -1.8.3.4 - diff --git a/media-libs/openimageio/patches/openimageio-1.7.11.patchset b/media-libs/openimageio/patches/openimageio-1.7.11.patchset new file mode 100644 index 000000000..e5801e29f --- /dev/null +++ b/media-libs/openimageio/patches/openimageio-1.7.11.patchset @@ -0,0 +1,95 @@ +From 4718cb2a5bf8ab1936f738118d7235af5bd07073 Mon Sep 17 00:00:00 2001 +From: Jerome Duval +Date: Sun, 7 Jun 2015 22:05:26 +0000 +Subject: Haiku patch + +--- + src/libutil/farmhash.cpp | 7 +++++++ + src/libutil/sysutil.cpp | 8 +++++++- + src/libutil/xxhash.cpp | 2 ++ + src/make/detectplatform.mk | 8 ++++++++ + 4 files changed, 24 insertions(+), 1 deletion(-) + +diff --git a/src/libutil/farmhash.cpp b/src/libutil/farmhash.cpp +index 256ce4d..e8baa21 100644 +--- a/src/libutil/farmhash.cpp ++++ b/src/libutil/farmhash.cpp +@@ -159,6 +159,13 @@ + #define bswap_64(x) bswap64(x) + #endif + ++#elif defined(__HAIKU__) ++ ++#undef bswap_32 ++#undef bswap_64 ++#define bswap_32 __builtin_bswap32 ++#define bswap_64 __builtin_bswap64 ++ + #else + + #undef bswap_32 +diff --git a/src/libutil/sysutil.cpp b/src/libutil/sysutil.cpp +index 0aa25c0..c061ccc 100644 +--- a/src/libutil/sysutil.cpp ++++ b/src/libutil/sysutil.cpp +@@ -77,6 +77,12 @@ + # include + #endif + ++#if defined (__HAIKU__) ++# include ++# include ++# include ++#endif ++ + #include + #include + #include +@@ -255,7 +261,7 @@ Sysutil::this_program_path () + size_t cb = sizeof(filename); + int r=1; + sysctl(mib, 4, filename, &cb, NULL, 0); +-#elif defined(__GNU__) || defined(__OpenBSD__) ++#elif defined(__GNU__) || defined(__OpenBSD__) || defined(__HAIKU__) + int r = 0; + #else + // No idea what platform this is +diff --git a/src/libutil/xxhash.cpp b/src/libutil/xxhash.cpp +index b17c7f8..4b00d09 100644 +--- a/src/libutil/xxhash.cpp ++++ b/src/libutil/xxhash.cpp +@@ -126,8 +126,10 @@ typedef unsigned long long U64; + #if defined(__GNUC__) && !defined(XXH_USE_UNALIGNED_ACCESS) + # define _PACKED __attribute__ ((packed)) + #else ++#ifndef __HAIKU__ + # define _PACKED + #endif ++#endif + + #if !defined(XXH_USE_UNALIGNED_ACCESS) && !defined(__GNUC__) + # ifdef __IBMC__ +diff --git a/src/make/detectplatform.mk b/src/make/detectplatform.mk +index dacdc2e..bd9ccb6 100644 +--- a/src/make/detectplatform.mk ++++ b/src/make/detectplatform.mk +@@ -46,6 +46,14 @@ ifeq (${platform},unknown) + endif + endif + ++ # Haiku ++ ifeq (${uname},haiku) ++ platform := haiku ++ ifeq (${hw},x86_64) ++ platform := haiku64 ++ endif ++ endif ++ + # Windows + ifeq (${uname},cygwin) + platform := windows +-- +2.11.0 + + +