[etoys/f19] add patch

Daniel Drake dsd at fedoraproject.org
Fri Apr 26 20:20:45 UTC 2013


commit 5a9cd21e8c463c5e582e774e58e013965ca9bb56
Author: Daniel Drake <dsd at laptop.org>
Date:   Fri Apr 26 14:18:28 2013 -0600

    add patch

 launcher-alsa.patch |   72 +++++++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 72 insertions(+), 0 deletions(-)
---
diff --git a/launcher-alsa.patch b/launcher-alsa.patch
new file mode 100644
index 0000000..bb190e0
--- /dev/null
+++ b/launcher-alsa.patch
@@ -0,0 +1,72 @@
+From: Daniel Drake <dsd at laptop.org>
+To: <bert at freudenbergs.de>
+Message-Id: <20130327191008.892E6FA976 at dev.laptop.org>
+Date: Wed, 27 Mar 2013 15:10:08 -0400 (EDT)
+X-Spam-Status: No, score=-3.6 required=3.5 tests=RCVD_IN_DNSWL_MED,
+	RP_MATCHES_RCVD autolearn=unavailable version=3.3.2
+X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on
+	sunjammer.sugarlabs.org
+X-Topics: Patches and patch reviews
+Cc: sugar-devel at lists.sugarlabs.org
+Subject: [Sugar-devel] [PATCH Etoys] Use ALSA sound backend if available
+X-BeenThere: sugar-devel at lists.sugarlabs.org
+X-Mailman-Version: 2.1.13
+MIME-Version: 1.0
+Content-Type: text/plain; charset="us-ascii"
+Content-Transfer-Encoding: 7bit
+Sender: sugar-devel-bounces at lists.sugarlabs.org
+Errors-To: sugar-devel-bounces at lists.sugarlabs.org
+
+Extend the sound backend selection code to consider using ALSA.
+On XO-1.75 and XO-4 this fixes sound in etoys with squeak-vm-4.x.
+It also fixes XO-4 sound recording which was not working on any previous
+version.
+
+Index: etoys-5.0.2408/etoys.in
+===================================================================
+--- etoys-5.0.2408.orig/etoys.in	2013-03-27 15:06:22.000000000 -0400
++++ etoys-5.0.2408/etoys.in	2013-03-27 15:06:33.000000000 -0400
+@@ -6,6 +6,7 @@
+ 
+ VM="squeak"
+ VMOPTIONS="-encoding UTF-8 -vm-display-x11 -xshm"
++VMSOUND=""
+ IMAGE="@prefix@/share/etoys/etoys.image"
+ IMOPTIONS=""
+ DOCUMENT=""
+@@ -85,18 +86,24 @@
+ # make Compose input methods work
+ [ -z "$LC_ALL" ] && export LC_ALL="$LANG"
+ 
+-# if pulseaudio is running, use it if VM has the driver, or fall back to OSS
++# if pulseaudio is running, use it if VM has the driver
+ if pulseaudio --check 2>/dev/null ; then
+     if "$VM" -help 2> /dev/null | grep -q vm-sound-pulse ; then
+-        VMOPTIONS="$VMOPTIONS -vm-sound-pulse"
++        VMSOUND="-vm-sound-pulse"
+     else
+-        VMOPTIONS="$VMOPTIONS -vm-sound-oss"
+         if padsp true 2>/dev/null ; then
++            VMSOUND="-vm-sound-oss"
+             WRAPPER=padsp
+         fi
+     fi
+ fi
+ 
++# Otherwise use ALSA if available
++[ -z "$VMSOUND" -a -e /proc/asound/cards ] && VMSOUND="-vm-sound-ALSA"
++
++# Fall back on OSS
++[ -n "$VMSOUND" ] || VMSOUND="-vm-sound-oss"
++
+ # enable compositioninput 
+ case "$LANG" in 
+     bn* | gu* | hi* | kn* | ml* | mr* | ta* | te* | sa* )
+@@ -110,5 +117,5 @@
+ 
+ # VM, Image, and Document are non-optional
+ # Document has to be present even if empty for IMOPTIONS to work
+-$DEBUG $WRAPPER "$VM" $VMOPTIONS "$IMAGE" "$DOCUMENT" $IMOPTIONS
+-exec $WRAPPER "$VM" $VMOPTIONS "$IMAGE" "$DOCUMENT" $IMOPTIONS
++$DEBUG $WRAPPER "$VM" $VMOPTIONS $VMSOUND "$IMAGE" "$DOCUMENT" $IMOPTIONS
++exec $WRAPPER "$VM" $VMOPTIONS $VMSOUND "$IMAGE" "$DOCUMENT" $IMOPTIONS


More information about the scm-commits mailing list