Bug 454109

Summary: Audio broken on big endian archs
Product: [Fedora] Fedora Reporter: Ian Chapman <packages>
Component: frozen-bubbleAssignee: Matthias Saou <matthias>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: low Docs Contact:
Priority: low    
Version: 9CC: hdegoede
Target Milestone: ---   
Target Release: ---   
Hardware: powerpc   
OS: Linux   
Whiteboard:
Fixed In Version: 2.1.0-9.fc9 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2008-07-09 02:47:32 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Patch to fix audio on big endian archs none

Description Ian Chapman 2008-07-04 18:03:38 UTC
Description of problem:

Audio appears broken on big endian archs. Just lots of hissing.

Version-Release number of selected component (if applicable):


How reproducible:

Run frozen bubble

Steps to Reproduce:
1. Run frozen bubble
2.
3.
  
Actual results:

Broken audio

Expected results:

Working audio

Additional info:

See attached patch.

Comment 1 Ian Chapman 2008-07-04 18:05:06 UTC
Created attachment 311051 [details]
Patch to fix audio on big endian archs

A quick patch which fixes audio on big endian archs and should continue to work
on little endian archs although I can't test that. It should also be 64bit
compatible.

Comment 2 Ian Chapman 2008-07-04 18:08:02 UTC
Oops, forgot.. the version is:

frozen-bubble-2.1.0-8.fc9.ppc

Comment 3 Hans de Goede 2008-07-05 07:37:37 UTC
I think it would be better to just replace:

$mixer = eval { SDL::Mixer->new(-frequency => 44100, -channels => 2, -size =>
1024); };

With:

$mixer = eval { SDL::Mixer->new(-frequency => 44100, -format => &AUDIO_S16SYS,
-channels => 2, -size => 1024); };

Ian, can you give that a try on your ppc?

BTW, good to have you back online!


Comment 4 Ian Chapman 2008-07-05 17:13:33 UTC
(In reply to comment #3)

> $mixer = eval { SDL::Mixer->new(-frequency => 44100, -format => &AUDIO_S16SYS,
> -channels => 2, -size => 1024); };
> 
> Ian, can you give that a try on your ppc?

I tried to do that at first but there's no such subroutine as &AUDIO_S16SYS,
hence the reason for the slightly more complicated patch. Essentially the SDL
headers assign the AUDIO_S16SYS value based upon a byte test anyway and either
make it equal to AUDIO_S16MSB or AUDIO_S16LSB depending on the arch but the perl
SDL modules used here don't appear to inherit it. If there is a better patch
though, I'll certainly test it on this machine.

> BTW, good to have you back online!

Thanks but I've got about 10 days before I leave for Australia :-) I'm just in
the position now where I've packed up my life, resigned from my job and after a
hectic few months I'm just sitting around now waiting to go. So I'm trying to
kill time. :-)


Comment 5 Hans de Goede 2008-07-05 17:25:39 UTC
Ah, in that case I think the patch is fine and should be applied as is, Matthias?


Comment 6 Hans de Goede 2008-07-06 11:56:59 UTC
I've applied the patch to CVS and a new version is currently building for F-8,
F-9 and rawhide.

Matthias, as you're in good contact with upstream, can you send the patch for
this upstream please?


Comment 7 Fedora Update System 2008-07-06 12:46:52 UTC
frozen-bubble-2.1.0-9.fc9 has been submitted as an update for Fedora 9

Comment 8 Fedora Update System 2008-07-06 12:47:41 UTC
frozen-bubble-2.1.0-9.fc8 has been submitted as an update for Fedora 8

Comment 9 Matthias Saou 2008-07-07 10:29:14 UTC
Thanks, Hans! :-)

Comment 10 Fedora Update System 2008-07-09 02:47:30 UTC
frozen-bubble-2.1.0-9.fc9 has been pushed to the Fedora 9 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 11 Fedora Update System 2008-07-09 02:48:12 UTC
frozen-bubble-2.1.0-9.fc8 has been pushed to the Fedora 8 stable repository.  If problems still persist, please make note of it in this bug report.