Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 99830 - sox-12.17.7-r1 ignores -x parameter
Summary: sox-12.17.7-r1 ignores -x parameter
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo Sound Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-07-21 13:21 UTC by G.K.MacGregor
Modified: 2006-01-22 05:30 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description G.K.MacGregor 2005-07-21 13:21:11 UTC
sox-12.17.7-r1 ignores the -x parameter, which is supposed to swap the 
byte-order between the input sample and the output sample. I discovered this 
when trying to make LPCM raw audio files for DVD authoring, which worked fine 
with version 12.17.5-r1, but doesn't work for this version where the -x 
parameter is needed.  
  
This is a known bug with this version that was reported in Debian here...  
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=316346  
  
The remedy is to either update to version 12.17.8 which fixes this bug, or to  
use the Debian patch to fix this version...  
http://bugs.debian.org/cgi-bin/bugreport.cgi/sox-12.17.7-x.diff?bug=316346&msg=6&att=1  

Reproducible: Always
Steps to Reproduce:
Since the resulting .lpcm cannot be played easily without further steps, a 
simple md5sum demonstrates that -x has no effect on the output. Take any short 
WAV input file... 
1. sox audio.wav -t raw audio1.lpcm 
2. sox audio.wav -t raw -x audio2.lpcm 
3. md5sum audio1.lpcm audio2.lpcm 
Actual Results:  
Since the -x option has no effect, both LPCM files have the same md5sum. This 
indicates that swapping the byte-order did not occur when -x was specified. 

Expected Results:  
Both LPCM should have different md5sums, since the -x parameter should have  
swapped the byte-order correctly.  

# emerge --info 
Portage 2.0.51.22-r2 (default-linux/x86/2005.0, gcc-3.3.5-20050130, 
glibc-2.3.5-r0, 2.6.10-gentoo-r4 i686) 
================================================================= 
System uname: 2.6.10-gentoo-r4 i686 AMD Athlon(tm) XP 2000+ 
Gentoo Base System version 1.6.13 
distcc 2.18.3 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) 
[disabled] 
dev-lang/python:     2.3.5 
sys-apps/sandbox:    1.2.11 
sys-devel/autoconf:  2.13, 2.59-r6 
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.5 
sys-devel/binutils:  2.15.92.0.2-r10 
sys-devel/libtool:   1.5.18-r1 
virtual/os-headers:  2.6.11-r2 
ACCEPT_KEYWORDS="x86" 
AUTOCLEAN="yes" 
CBUILD="i686-pc-linux-gnu" 
CFLAGS="-march=athlon-xp -O2 -pipe -fomit-frame-pointer -frename-registers 
-ftracer" 
CHOST="i686-pc-linux-gnu" 
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.4/env /usr/kde/3.4/share/config /usr/kde/3.4/shutdown /usr/kde/3/share/config /usr/lib/X11/xkb /usr/share/config /usr/share/texmf/dvipdfm/config/ /usr/share/texmf/dvips/config/ /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/ /usr/share/texmf/xdvi/ /var/qmail/control" 
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d" 
CXXFLAGS="-march=athlon-xp -O2 -pipe -fomit-frame-pointer -frename-registers 
-ftracer" 
DISTDIR="/usr/distfiles" 
FEATURES="autoconfig distlocks fixpackages sandbox sfperms strict userpriv 
usersandbox" 
GENTOO_MIRRORS="http://ftp.heanet.ie/pub/gentoo/ 
http://www.mirrorservice.org/sites/www.ibiblio.org/gentoo/ 
http://www.mirror.ac.uk/mirror/www.ibiblio.org/ http://gentoo.oregonstate.edu/ 
http://distfiles.gentoo.org/ 
http://www.ibiblio.org/pub/Linux/distributions/gentoo" 
LDFLAGS="-Wl,-O1 -Wl,--enable-new-dtags -Wl,--sort-common -Wl,--as-needed 
-Wl,--relax" 
LINGUAS="en_GB" 
PKGDIR="/usr/local/portage/packages" 
PORTAGE_TMPDIR="/var/tmp" 
PORTDIR="/usr/portage" 
PORTDIR_OVERLAY="/usr/local/portage" 
SYNC="rsync://rsync.gentoo.org/gentoo-portage" 
USE="x86 3dnow 3dnowext X a52 aac alsa apm arts avi bitmap-fonts cdparanoia 
cdr cjk crypt cups curl dga divx4linux dts dvd dvdr dvdread emboss encode fam 
ffmpeg flac foomaticdb gdbm gif gimpprint gtk gtk2 guile imagemagick imlib 
java joystick jpeg kde kdeenablefinal libg++ libwww live lm_sensors lzo mad 
mikmod mmx mmxext motif mozilla mp3 mpeg ncurses network nls nptl nptlonly 
nvidia ogg oggvorbis opengl oss pdflib perl png povray python qt quicktime 
readline real rtc samba sdl speex spell sse ssl tcltk tcpd tetex tiff truetype 
truetype-fonts type1-fonts v4l v4l2 vcd vorbis win32codecs xine xml2 xmms xv 
xvid xvmc zlib linguas_en_GB userland_GNU kernel_linux elibc_glibc" 
Unset:  ASFLAGS, CTARGET, LANG, LC_ALL, MAKEOPTS
Comment 1 Steve Sinclair 2005-12-09 12:53:45 UTC
I recently had to convert between big-endian and little-endian samples in a wave
file where the header was corrupt, and needed the -x flag to work.

I copied the folder /usr/portage/media-sound/sox into my local portage overlay
and performed the following commands:

cp sox-12.17.7-r2.ebuild sox-12.17.9.ebuild
cp files/sox-12.17.7-destdir.patch files/sox-12.17.9-destdir.patch
cp files/sox-12.17.7-largefile.patch files/sox-12.17.9-largefile.patch

After using the ebuild command to re-build the Manifest and digests, I emerged
the new version of sox without problems.  The -x option now works.

I would recommend including this new version in portage.
Comment 2 Tony Vroon (RETIRED) gentoo-dev 2006-01-22 05:30:26 UTC
The newer 12.17.9 version that just got added to the portage tree should resolve this issue. If not, I would like to hear from you.