svn commit: r531422 - in head/emulators/rpcs3: . files
Jan Beich
jbeich at FreeBSD.org
Sat Apr 11 13:00:41 UTC 2020
Author: jbeich
Date: Sat Apr 11 13:00:40 2020
New Revision: 531422
URL: https://svnweb.freebsd.org/changeset/ports/531422
Log:
emulators/rpcs3: unbreak audio after r529285
INFO: OpenAudioDevice failed: Fragment size must be a power of two
Segfault reading location 00000000000000d4 at 0000000001de1abd.
Emu Thread Name: 'cellAudio Thread'.
Thread id = 0x89cf05700.
Added:
head/emulators/rpcs3/files/patch-3rdparty_FAudio_src_FAudio__platform__sdl2.c (contents, props changed)
Modified:
head/emulators/rpcs3/Makefile (contents, props changed)
Modified: head/emulators/rpcs3/Makefile
==============================================================================
--- head/emulators/rpcs3/Makefile Sat Apr 11 12:24:07 2020 (r531421)
+++ head/emulators/rpcs3/Makefile Sat Apr 11 13:00:40 2020 (r531422)
@@ -4,6 +4,7 @@ PORTNAME= rpcs3
DISTVERSIONPREFIX= v
DISTVERSION= 0.0.9-10152 # git rev-list --count HEAD
DISTVERSIONSUFFIX= -gcce946f10
+PORTREVISION= 1
CATEGORIES= emulators
MAINTAINER= jbeich at FreeBSD.org
@@ -58,7 +59,8 @@ EVDEV_BUILD_DEPENDS= evdev-proto>0:devel/evdev-proto
EVDEV_LIB_DEPENDS= libevdev.so:devel/libevdev
FAUDIO_DESC= FAudio audio support
-FAUDIO_LIB_DEPENDS= libFAudio.so:audio/faudio
+FAUDIO_USES= sdl
+FAUDIO_USE= SDL=sdl2
FAUDIO_CMAKE_BOOL= USE_FAUDIO
PULSEAUDIO_LIB_DEPENDS= libpulse-simple.so:audio/pulseaudio
Added: head/emulators/rpcs3/files/patch-3rdparty_FAudio_src_FAudio__platform__sdl2.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/emulators/rpcs3/files/patch-3rdparty_FAudio_src_FAudio__platform__sdl2.c Sat Apr 11 13:00:40 2020 (r531422)
@@ -0,0 +1,23 @@
+https://github.com/FNA-XNA/FAudio/issues/183
+
+--- 3rdparty/FAudio/src/FAudio_platform_sdl2.c.orig 2020-04-01 14:55:30 UTC
++++ 3rdparty/FAudio/src/FAudio_platform_sdl2.c
+@@ -100,6 +100,18 @@ void FAudio_PlatformInit(
+ want.samples = want.freq / 100;
+ }
+
++ /* SDL audio with arts/dsp backends expect ^2, so round up.
++ * For 48KHz this should be 512.
++ * https://graphics.stanford.edu/~seander/bithacks.html#RoundUpPowerOf2
++ */
++ want.samples--;
++ want.samples |= want.samples >> 1;
++ want.samples |= want.samples >> 2;
++ want.samples |= want.samples >> 4;
++ want.samples |= want.samples >> 8;
++ want.samples |= want.samples >> 16;
++ want.samples++;
++
+ /* Open the device (or at least try to) */
+ iosretry:
+ device = SDL_OpenAudioDevice(
More information about the svn-ports-all
mailing list