From owner-svn-ports-all@freebsd.org Fri Jan 5 11:13:14 2018 Return-Path: Delivered-To: svn-ports-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id F2E41EC46E8; Fri, 5 Jan 2018 11:13:13 +0000 (UTC) (envelope-from jbeich@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C7DD63B63; Fri, 5 Jan 2018 11:13:13 +0000 (UTC) (envelope-from jbeich@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id w05BDCgW035432; Fri, 5 Jan 2018 11:13:12 GMT (envelope-from jbeich@FreeBSD.org) Received: (from jbeich@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id w05BDCLB035431; Fri, 5 Jan 2018 11:13:12 GMT (envelope-from jbeich@FreeBSD.org) Message-Id: <201801051113.w05BDCLB035431@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jbeich set sender to jbeich@FreeBSD.org using -f From: Jan Beich Date: Fri, 5 Jan 2018 11:13:12 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-branches@freebsd.org Subject: svn commit: r458128 - branches/2018Q1/graphics/libraw/files X-SVN-Group: ports-branches X-SVN-Commit-Author: jbeich X-SVN-Commit-Paths: branches/2018Q1/graphics/libraw/files X-SVN-Commit-Revision: 458128 X-SVN-Commit-Repository: ports MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 05 Jan 2018 11:13:14 -0000 Author: jbeich Date: Fri Jan 5 11:13:12 2018 New Revision: 458128 URL: https://svnweb.freebsd.org/changeset/ports/458128 Log: MFH: r458127 graphics/libraw: unbreak build with Clang 6 (C++14 by default) In file included from src/libraw_cxx.cpp:5472: src/../internal/libraw_x3f.cpp:1404:19: error: non-constant-expression cannot be narrowed from type 'int' to 'int16_t' (aka 'short') in initializer list [-Wc++11-narrowing] int16_t c[3] = {offset,offset,offset}; ^~~~~~ src/../internal/libraw_x3f.cpp:1404:19: note: insert an explicit cast to silence this issue int16_t c[3] = {offset,offset,offset}; ^~~~~~ static_cast( ) src/../internal/libraw_x3f.cpp:1404:26: error: non-constant-expression cannot be narrowed from type 'int' to 'int16_t' (aka 'short') in initializer list [-Wc++11-narrowing] int16_t c[3] = {offset,offset,offset}; ^~~~~~ src/../internal/libraw_x3f.cpp:1404:26: note: insert an explicit cast to silence this issue int16_t c[3] = {offset,offset,offset}; ^~~~~~ static_cast( ) src/../internal/libraw_x3f.cpp:1404:33: error: non-constant-expression cannot be narrowed from type 'int' to 'int16_t' (aka 'short') in initializer list [-Wc++11-narrowing] int16_t c[3] = {offset,offset,offset}; ^~~~~~ src/../internal/libraw_x3f.cpp:1404:33: note: insert an explicit cast to silence this issue int16_t c[3] = {offset,offset,offset}; ^~~~~~ static_cast( ) Reported by: antoine (via bug 224669) Obtained from: upstream Approved by: ports-secteam blanket Added: branches/2018Q1/graphics/libraw/files/patch-internal_libraw__x3f.cpp - copied unchanged from r458127, head/graphics/libraw/files/patch-internal_libraw__x3f.cpp Modified: Directory Properties: branches/2018Q1/ (props changed) Copied: branches/2018Q1/graphics/libraw/files/patch-internal_libraw__x3f.cpp (from r458127, head/graphics/libraw/files/patch-internal_libraw__x3f.cpp) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ branches/2018Q1/graphics/libraw/files/patch-internal_libraw__x3f.cpp Fri Jan 5 11:13:12 2018 (r458128, copy of r458127, head/graphics/libraw/files/patch-internal_libraw__x3f.cpp) @@ -0,0 +1,39 @@ +In file included from src/libraw_cxx.cpp:5472: +src/../internal/libraw_x3f.cpp:1404:19: error: non-constant-expression cannot be narrowed from type + 'int' to 'int16_t' (aka 'short') in initializer list [-Wc++11-narrowing] + int16_t c[3] = {offset,offset,offset}; + ^~~~~~ +src/../internal/libraw_x3f.cpp:1404:19: note: insert an explicit cast to silence this issue + int16_t c[3] = {offset,offset,offset}; + ^~~~~~ + static_cast( ) +src/../internal/libraw_x3f.cpp:1404:26: error: non-constant-expression cannot be narrowed from type + 'int' to 'int16_t' (aka 'short') in initializer list [-Wc++11-narrowing] + int16_t c[3] = {offset,offset,offset}; + ^~~~~~ +src/../internal/libraw_x3f.cpp:1404:26: note: insert an explicit cast to silence this issue + int16_t c[3] = {offset,offset,offset}; + ^~~~~~ + static_cast( ) +src/../internal/libraw_x3f.cpp:1404:33: error: non-constant-expression cannot be narrowed from type + 'int' to 'int16_t' (aka 'short') in initializer list [-Wc++11-narrowing] + int16_t c[3] = {offset,offset,offset}; + ^~~~~~ +src/../internal/libraw_x3f.cpp:1404:33: note: insert an explicit cast to silence this issue + int16_t c[3] = {offset,offset,offset}; + ^~~~~~ + static_cast( ) + +https://github.com/LibRaw/LibRaw/commit/6d4b3ea + +--- internal/libraw_x3f.cpp.orig 2017-09-22 06:23:54 UTC ++++ internal/libraw_x3f.cpp +@@ -1401,7 +1401,7 @@ static void huffman_decode_row(x3f_info_t *I, + x3f_image_data_t *ID = &DEH->data_subsection.image_data; + x3f_huffman_t *HUF = ID->huffman; + +- int16_t c[3] = {offset,offset,offset}; ++ int16_t c[3] = {(int16_t)offset,(int16_t)offset,(int16_t)offset}; + int col; + bit_state_t BS; +