Be warned: this is gonna get geeky!
So I got my Squeezebox: it’s working fine, and Gentoo came through (as usual) when I had to install the server end (Slimserver). All good and well. Until I tried playing my music ripped with iTunes: AAC sounded horrible.
Apparently somebody forgot so send a single newline of debug output from the converter (faad2-2.20) to stderr: The bug is well known, but hadn’t been added to gentoo’s system because of some license issues.
Anyways: this prompted me for my first portage hacking!
``
jaw@jarnen ~/portage/media-libs/faad2 $ cat files/jaw_stdoutfix.patch
--- faad2-2.0.orig/frontend/main.c 2004-01-06 04:59:47.000000000 -0700
+++ faad2-2.0/frontend/main.c 2007-08-16 08:47:16.000000000 -0600
@@ -832,7 +832,7 @@
}
}
}
- if (j > 0) printf("\n");
+ if (j > 0) printf(stderr,"\n");
#endif
}
jaw@jarnen ~/portage/media-libs/faad2 $ diff -Narc faad2-2.0-r14.ebuild /usr/portage/media-libs/faad2/faad2-2.0-r13.ebuild
*** faad2-2.0-r14.ebuild Sun Aug 19 21:52:47 2007
--- /usr/portage/media-libs/faad2/faad2-2.0-r13.ebuild Mon May 21 15:05:54 2007
***************
*** 1,6 ****
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
! # $Header: /var/cvsroot/gentoo-x86/media-libs/faad2/faad2-2.0-r14.ebuild,v 1.14 2007/05/21 21:03:56 armin76 Exp $
inherit eutils libtool flag-o-matic autotools
--- 1,6 ----
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
! # $Header: /var/cvsroot/gentoo-x86/media-libs/faad2/faad2-2.0-r13.ebuild,v 1.14 2007/05/21 21:03:56 armin76 Exp $
inherit eutils libtool flag-o-matic autotools
***************
*** 26,33 ****
cd ${S}
EPATCH_SUFFIX="patch" epatch "${WORKDIR}/patches"
- # My patches...
- epatch "${FILESDIR}/jaw_stdoutfix.patch"
eautoreconf
}
--- 26,31 ----