summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergei Trofimovich <slyfox@gentoo.org>2017-02-27 21:55:27 +0000
committerSergei Trofimovich <slyfox@gentoo.org>2017-02-27 21:55:36 +0000
commitb0465fee65e55231c624512248aa6637d7569198 (patch)
treecd22cbc056d578660e155266cf0026a91eeed5ec /media-libs/smpeg2
parentsys-kernel/ck-sources: v.bump (4.9.13 & 4.10.1) (diff)
downloadgentoo-b0465fee65e55231c624512248aa6637d7569198.tar.gz
gentoo-b0465fee65e55231c624512248aa6637d7569198.tar.bz2
gentoo-b0465fee65e55231c624512248aa6637d7569198.zip
media-libs/smpeg2: fix build failure against gcc-6, bug #594912
Reported-by: Toralf Förster Bug: https://bugs.gentoo.org/594912 Package-Manager: Portage-2.3.3, Repoman-2.3.1
Diffstat (limited to 'media-libs/smpeg2')
-rw-r--r--media-libs/smpeg2/files/smpeg2-2.0.0-gcc6.patch23
-rw-r--r--media-libs/smpeg2/smpeg2-2.0.0-r3.ebuild1
2 files changed, 24 insertions, 0 deletions
diff --git a/media-libs/smpeg2/files/smpeg2-2.0.0-gcc6.patch b/media-libs/smpeg2/files/smpeg2-2.0.0-gcc6.patch
new file mode 100644
index 000000000000..4094c61ba432
--- /dev/null
+++ b/media-libs/smpeg2/files/smpeg2-2.0.0-gcc6.patch
@@ -0,0 +1,23 @@
+gcc-6 is more strict WRT narrowing:
+error: narrowing conversion of ‘-1’ from ‘int’ to ‘unsigned int’ inside { } [-Wnarrowing]
+
+https://bugs.gentoo.org/594912
+diff --git a/audio/hufftable.cpp b/audio/hufftable.cpp
+index 6bc8e86..5414ae3 100644
+--- a/audio/hufftable.cpp
++++ b/audio/hufftable.cpp
+@@ -552,3 +552,3 @@ const HUFFMANCODETABLE MPEGaudio::ht[HTN]=
+ {
+- { 0, 0-1, 0-1, 0, 0, htd33},
++ { 0, ~0u, ~0u, 0, 0, htd33},
+ { 1, 2-1, 2-1, 0, 7,htd01},
+@@ -556,3 +556,3 @@ const HUFFMANCODETABLE MPEGaudio::ht[HTN]=
+ { 3, 3-1, 3-1, 0, 17,htd03},
+- { 4, 0-1, 0-1, 0, 0, htd33},
++ { 4, ~0u, ~0u, 0, 0, htd33},
+ { 5, 4-1, 4-1, 0, 31,htd05},
+@@ -566,3 +566,3 @@ const HUFFMANCODETABLE MPEGaudio::ht[HTN]=
+ {13,16-1,16-1, 0,511,htd13},
+- {14, 0-1, 0-1, 0, 0, htd33},
++ {14,~0u, ~0u, 0, 0, htd33},
+ {15,16-1,16-1, 0,511,htd15},
diff --git a/media-libs/smpeg2/smpeg2-2.0.0-r3.ebuild b/media-libs/smpeg2/smpeg2-2.0.0-r3.ebuild
index 71994bba5a98..5e39a34756f7 100644
--- a/media-libs/smpeg2/smpeg2-2.0.0-r3.ebuild
+++ b/media-libs/smpeg2/smpeg2-2.0.0-r3.ebuild
@@ -24,6 +24,7 @@ S=${WORKDIR}/${MY_P}
src_prepare() {
epatch "${FILESDIR}"/${P}-smpeg2-config.patch
+ epatch "${FILESDIR}"/${P}-gcc6.patch
epatch_user
# avoid file collision with media-libs/smpeg