diff options
author | Miroslav Šulc <fordfrog@gentoo.org> | 2020-09-08 10:30:12 +0200 |
---|---|---|
committer | Miroslav Šulc <fordfrog@gentoo.org> | 2020-09-08 10:30:31 +0200 |
commit | 877d04a251b527dd22730b95457353af1a8a20dd (patch) | |
tree | cf5e331b70227ccc5e390c8b7a3dd1ae18e15fc8 /media-sound/milkytracker | |
parent | app-emulation/qemu: enable sdl-image only for softmmu (diff) | |
download | gentoo-877d04a251b527dd22730b95457353af1a8a20dd.tar.gz gentoo-877d04a251b527dd22730b95457353af1a8a20dd.tar.bz2 gentoo-877d04a251b527dd22730b95457353af1a8a20dd.zip |
media-sound/milkytracker: fixed compilation with clang++ in 1.02.00-r1
Closes: https://bugs.gentoo.org/740394
Package-Manager: Portage-3.0.6, Repoman-3.0.1
Signed-off-by: Miroslav Šulc <fordfrog@gentoo.org>
Diffstat (limited to 'media-sound/milkytracker')
-rw-r--r-- | media-sound/milkytracker/files/milkytracker-1.02.00-clang.patch | 85 | ||||
-rw-r--r-- | media-sound/milkytracker/milkytracker-1.02.00-r1.ebuild | 1 |
2 files changed, 86 insertions, 0 deletions
diff --git a/media-sound/milkytracker/files/milkytracker-1.02.00-clang.patch b/media-sound/milkytracker/files/milkytracker-1.02.00-clang.patch new file mode 100644 index 000000000000..48e6dc39cb5a --- /dev/null +++ b/media-sound/milkytracker/files/milkytracker-1.02.00-clang.patch @@ -0,0 +1,85 @@ +diff --git a/src/tracker/EQConstants.cpp b/src/tracker/EQConstants.cpp +index ffbf6ea..fa6fdce 100644 +--- a/src/tracker/EQConstants.cpp ++++ b/src/tracker/EQConstants.cpp +@@ -27,9 +27,9 @@ + + const float EQConstants::EQ3bands[3] = + { +- p(5), // 32 Hz +- p(9), // 522 Hz +- p(12), // 4181.5 Hz ++ (float) p(5), // 32 Hz ++ (float) p(9), // 522 Hz ++ (float) p(12), // 4181.5 Hz + }; + + const float EQConstants::EQ3bandwidths[3] = +@@ -41,28 +41,28 @@ const float EQConstants::EQ3bandwidths[3] = + + const float EQConstants::EQ10bands[10] = + { +- p(3), // 8 Hz +- p(4), // 16 Hz +- p(5), // 32 Hz +- p(6), // 65 Hz +- p(7), // 130 Hz +- p(8), // 261 Hz +- p(9), // 522 Hz +- p(10), // 1 kHz +- p(11), // 2 kHz +- p(12), // 4181.5 Hz ++ (float) p(3), // 8 Hz ++ (float) p(4), // 16 Hz ++ (float) p(5), // 32 Hz ++ (float) p(6), // 65 Hz ++ (float) p(7), // 130 Hz ++ (float) p(8), // 261 Hz ++ (float) p(9), // 522 Hz ++ (float) p(10), // 1 kHz ++ (float) p(11), // 2 kHz ++ (float) p(12), // 4181.5 Hz + }; + + const float EQConstants::EQ10bandwidths[10] = + { + 16, +- p(3)*1.5f, +- p(4)*1.5f, +- p(5)*1.5f, +- p(6)*1.5f, +- p(7)*1.5f, +- p(8)*1.0f, +- p(9)*1.0f, ++ (float) p(3)*1.5f, ++ (float) p(4)*1.5f, ++ (float) p(5)*1.5f, ++ (float) p(6)*1.5f, ++ (float) p(7)*1.5f, ++ (float) p(8)*1.0f, ++ (float) p(9)*1.0f, + 600.0f, + 800.0f + }; +diff --git a/src/tracker/sdl/SDL_Main.cpp b/src/tracker/sdl/SDL_Main.cpp +index 420b4d9..d404f08 100644 +--- a/src/tracker/sdl/SDL_Main.cpp ++++ b/src/tracker/sdl/SDL_Main.cpp +@@ -609,7 +609,7 @@ void translateKeyDownEvent(const SDL_Event& event) + printf ("DEBUG: Key pressed: VK: %d, SC: %d, Scancode: %d\n", toVK(keysym), toSC(keysym), keysym.sym); + #endif + +- pp_uint16 chr[3] = {toVK(keysym), toSC(keysym), keysym.sym}; ++ pp_uint16 chr[3] = {(pp_uint16) toVK(keysym), (pp_uint16) toSC(keysym), (pp_uint16) keysym.sym}; + + PPEvent myEvent(eKeyDown, &chr, sizeof(chr)); + RaiseEventSerialized(&myEvent); +@@ -621,7 +621,7 @@ void translateKeyUpEvent(const SDL_Event& event) + + preTranslateKey(keysym); + +- pp_uint16 chr[3] = {toVK(keysym), toSC(keysym), keysym.sym}; ++ pp_uint16 chr[3] = {(pp_uint16) toVK(keysym), (pp_uint16) toSC(keysym), (pp_uint16) keysym.sym}; + + PPEvent myEvent(eKeyUp, &chr, sizeof(chr)); + RaiseEventSerialized(&myEvent); diff --git a/media-sound/milkytracker/milkytracker-1.02.00-r1.ebuild b/media-sound/milkytracker/milkytracker-1.02.00-r1.ebuild index b27c6c5260b4..b86251123c51 100644 --- a/media-sound/milkytracker/milkytracker-1.02.00-r1.ebuild +++ b/media-sound/milkytracker/milkytracker-1.02.00-r1.ebuild @@ -33,6 +33,7 @@ PATCHES=( "${FILESDIR}/${P}-CVE-2019-1449x.patch" "${FILESDIR}/${P}-CVE-2020-15569.patch" "${FILESDIR}/${P}-fix-hard-dependency-on-rtmidi.patch" + "${FILESDIR}/${P}-clang.patch" ) S="${WORKDIR}/MilkyTracker-${PV}" |