graphics/openimageio: fix build on powerpc64 elfv2

Change if to explicit ifdef to prevent:
/wrkdirs/usr/ports/graphics/openimageio/work/oiio-Release-2.0.10/src/libutil/ustring.cpp:328:27: error: expected value in expression
#    if _LIBCPP_BIG_ENDIAN

PR:		242134
Approved by:	FreeBSD@ShaneWare.Biz (maintainer timeout)
This commit is contained in:
Piotr Kubaj 2020-01-27 22:01:49 +00:00
parent 615c00302c
commit 23456b73cc
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=524447

View File

@ -0,0 +1,20 @@
--- src/libutil/ustring.cpp.orig 2020-01-27 21:27:51 UTC
+++ src/libutil/ustring.cpp
@@ -314,7 +314,7 @@ struct libcpp_string__long {
std::string::size_type __size_;
std::string::size_type __cap_;
};
-# if _LIBCPP_BIG_ENDIAN
+# ifdef _LIBCPP_BIG_ENDIAN
enum { libcpp_string__long_mask = 0x1ul };
# else // _LIBCPP_BIG_ENDIAN
enum { libcpp_string__long_mask = ~(std::string::size_type(~0) >> 1) };
@@ -325,7 +325,7 @@ struct libcpp_string__long {
std::string::size_type __size_;
std::string::pointer __data_;
};
-# if _LIBCPP_BIG_ENDIAN
+# ifdef _LIBCPP_BIG_ENDIAN
enum { libcpp_string__long_mask = ~(std::string::size_type(~0) >> 1) };
# else // _LIBCPP_BIG_ENDIAN
enum { libcpp_string__long_mask = 0x1ul };