pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/multimedia/x265 multimedia/x265: Fix build on SunOS.



details:   https://anonhg.NetBSD.org/pkgsrc/rev/b00be4d030ce
branches:  trunk
changeset: 375799:b00be4d030ce
user:      fhajny <fhajny%pkgsrc.org@localhost>
date:      Wed Feb 21 12:33:46 2018 +0000

description:
multimedia/x265: Fix build on SunOS.

diffstat:

 multimedia/x265/distinfo                          |   3 +-
 multimedia/x265/patches/patch-encoder_encoder.cpp |  24 +++++++++++++++++++++++
 2 files changed, 26 insertions(+), 1 deletions(-)

diffs (41 lines):

diff -r 2e9784177a12 -r b00be4d030ce multimedia/x265/distinfo
--- a/multimedia/x265/distinfo  Wed Feb 21 12:26:45 2018 +0000
+++ b/multimedia/x265/distinfo  Wed Feb 21 12:33:46 2018 +0000
@@ -1,7 +1,8 @@
-$NetBSD: distinfo,v 1.20 2017/11/30 07:38:55 adam Exp $
+$NetBSD: distinfo,v 1.21 2018/02/21 12:33:46 fhajny Exp $
 
 SHA1 (x265_2.6.tar.gz) = d3cb1066830b7fe779b6c9d8d774bbec7f8c1f5a
 RMD160 (x265_2.6.tar.gz) = 9bffc2a99c576a99a49d2ce8d8dd690c375a3972
 SHA512 (x265_2.6.tar.gz) = 35c3716313e3dfd1555dd725b60f2b3b00a615d8b8d8267439722b52021d47e34eebf94b837b92a92d40c7ffab7b3198d6391365d62672b257c0a87d1db8a736
 Size (x265_2.6.tar.gz) = 1271976 bytes
 SHA1 (patch-CMakeLists.txt) = fbf4d08133a48b342a060f1b45bab0253455a1b1
+SHA1 (patch-encoder_encoder.cpp) = 51bbbdaf7ae823237dfde5ca5480f683afbc1247
diff -r 2e9784177a12 -r b00be4d030ce multimedia/x265/patches/patch-encoder_encoder.cpp
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/multimedia/x265/patches/patch-encoder_encoder.cpp Wed Feb 21 12:33:46 2018 +0000
@@ -0,0 +1,24 @@
+$NetBSD: patch-encoder_encoder.cpp,v 1.1 2018/02/21 12:33:46 fhajny Exp $
+
+Remove ambiguous reference. Fixes build on at least SunOS.
+
+--- encoder/encoder.cpp.orig   2017-11-29 03:21:40.000000000 +0000
++++ encoder/encoder.cpp
+@@ -575,7 +575,7 @@ int Encoder::setAnalysisDataAfterZScan(x
+                             {
+                                 int mv_x = ((analysis_inter_data *)curFrame->m_analysisData.interData)->mv[k][(mbIndex * 16) + cuOffset].x;
+                                 int mv_y = ((analysis_inter_data *)curFrame->m_analysisData.interData)->mv[k][(mbIndex * 16) + cuOffset].y;
+-                                double mv = sqrt(mv_x*mv_x + mv_y*mv_y);
++                                double mv = std::sqrt(mv_x*mv_x + mv_y*mv_y);
+                                 if (numPU == PU_2Nx2N && ((srcInterData)->depth[cuPos + cuOffset] == (m_param->maxCUSize >> 5)) && mv <= MVTHRESHOLD)
+                                     memset(&curFrame->m_analysisData.modeFlag[k][cuPos + cuOffset], 1, bytes);
+                             }
+@@ -658,7 +658,7 @@ int Encoder::setAnalysisData(x265_analys
+                                     {
+                                         int mv_x = ((analysis_inter_data *)curFrame->m_analysisData.interData)->mv[i][count + pu].x;
+                                         int mv_y = ((analysis_inter_data *)curFrame->m_analysisData.interData)->mv[i][count + pu].y;
+-                                        double mv = sqrt(mv_x*mv_x + mv_y*mv_y);
++                                        double mv = std::sqrt(mv_x*mv_x + mv_y*mv_y);
+                                         if (numPU == PU_2Nx2N && m_param->num4x4Partitions <= 16 && mv <= MVTHRESHOLD)
+                                             memset(&curFrame->m_analysisData.modeFlag[i][count + pu], 1, bytes);
+                                     }



Home | Main Index | Thread Index | Old Index