FS-4657 --resolve update libsndfile to its latest master

This commit is contained in:
Jeff Lenk
2014-02-21 16:09:43 -06:00
parent 0c1f6ef2ed
commit 199a64bf6a
291 changed files with 25966 additions and 5745 deletions

View File

@@ -1,5 +1,5 @@
/*
** Copyright (C) 1999-2009 Erik de Castro Lopo <erikd@mega-nerd.com>
** Copyright (C) 1999-2011 Erik de Castro Lopo <erikd@mega-nerd.com>
**
** This program is free software; you can redistribute it and/or modify
** it under the terms of the GNU General Public License as published by
@@ -347,9 +347,9 @@ main (int argc, char **argv)
} ;
if (do_all || ! strcmp (argv [1], "sds"))
{ pcm_test_char ("char.sds" , SF_FORMAT_SDS | SF_FORMAT_PCM_S8, SF_TRUE) ;
pcm_test_short ("short.sds" , SF_FORMAT_SDS | SF_FORMAT_PCM_16, SF_TRUE) ;
pcm_test_24bit ("24bit.sds" , SF_FORMAT_SDS | SF_FORMAT_PCM_24, SF_TRUE) ;
{ pcm_test_char ("char.sds" , SF_FORMAT_SDS | SF_FORMAT_PCM_S8, SF_FALSE) ;
pcm_test_short ("short.sds" , SF_FORMAT_SDS | SF_FORMAT_PCM_16, SF_FALSE) ;
pcm_test_24bit ("24bit.sds" , SF_FORMAT_SDS | SF_FORMAT_PCM_24, SF_FALSE) ;
empty_file_test ("empty_char.sds", SF_FORMAT_SDS | SF_FORMAT_PCM_S8) ;
empty_file_test ("empty_short.sds", SF_FORMAT_SDS | SF_FORMAT_PCM_16) ;
@@ -435,8 +435,8 @@ static void write_seek_extend_test (const char * filename, int format) ;
static void
pcm_test_char (const char *filename, int format, int long_file_ok)
{ SF_INFO sfinfo ;
short *orig, *test ;
int k, items, allow_fd ;
short *orig ;
int k, allow_fd ;
/* Sd2 files cannot be opened from an existing file descriptor. */
allow_fd = ((format & SF_FORMAT_TYPEMASK) == SF_FORMAT_SD2) ? SF_FALSE : SF_TRUE ;
@@ -451,13 +451,10 @@ pcm_test_char (const char *filename, int format, int long_file_ok)
gen_windowed_sine_double (orig_data.d, DATA_LENGTH, 32000.0) ;
orig = orig_data.s ;
test = test_data.s ;
/* Make this a macro so gdb steps over it in one go. */
CONVERT_DATA (k, DATA_LENGTH, orig, orig_data.d) ;
items = DATA_LENGTH ;
/* Some test broken out here. */
mono_char_test (filename, format, long_file_ok, allow_fd) ;
@@ -954,8 +951,8 @@ static void write_seek_extend_test (const char * filename, int format) ;
static void
pcm_test_short (const char *filename, int format, int long_file_ok)
{ SF_INFO sfinfo ;
short *orig, *test ;
int k, items, allow_fd ;
short *orig ;
int k, allow_fd ;
/* Sd2 files cannot be opened from an existing file descriptor. */
allow_fd = ((format & SF_FORMAT_TYPEMASK) == SF_FORMAT_SD2) ? SF_FALSE : SF_TRUE ;
@@ -970,13 +967,10 @@ pcm_test_short (const char *filename, int format, int long_file_ok)
gen_windowed_sine_double (orig_data.d, DATA_LENGTH, 32000.0) ;
orig = orig_data.s ;
test = test_data.s ;
/* Make this a macro so gdb steps over it in one go. */
CONVERT_DATA (k, DATA_LENGTH, orig, orig_data.d) ;
items = DATA_LENGTH ;
/* Some test broken out here. */
mono_short_test (filename, format, long_file_ok, allow_fd) ;
@@ -1473,8 +1467,8 @@ static void write_seek_extend_test (const char * filename, int format) ;
static void
pcm_test_24bit (const char *filename, int format, int long_file_ok)
{ SF_INFO sfinfo ;
int *orig, *test ;
int k, items, allow_fd ;
int *orig ;
int k, allow_fd ;
/* Sd2 files cannot be opened from an existing file descriptor. */
allow_fd = ((format & SF_FORMAT_TYPEMASK) == SF_FORMAT_SD2) ? SF_FALSE : SF_TRUE ;
@@ -1489,13 +1483,10 @@ pcm_test_24bit (const char *filename, int format, int long_file_ok)
gen_windowed_sine_double (orig_data.d, DATA_LENGTH, (1.0 * 0x7F000000)) ;
orig = orig_data.i ;
test = test_data.i ;
/* Make this a macro so gdb steps over it in one go. */
CONVERT_DATA (k, DATA_LENGTH, orig, orig_data.d) ;
items = DATA_LENGTH ;
/* Some test broken out here. */
mono_24bit_test (filename, format, long_file_ok, allow_fd) ;
@@ -1992,8 +1983,8 @@ static void write_seek_extend_test (const char * filename, int format) ;
static void
pcm_test_int (const char *filename, int format, int long_file_ok)
{ SF_INFO sfinfo ;
int *orig, *test ;
int k, items, allow_fd ;
int *orig ;
int k, allow_fd ;
/* Sd2 files cannot be opened from an existing file descriptor. */
allow_fd = ((format & SF_FORMAT_TYPEMASK) == SF_FORMAT_SD2) ? SF_FALSE : SF_TRUE ;
@@ -2008,13 +1999,10 @@ pcm_test_int (const char *filename, int format, int long_file_ok)
gen_windowed_sine_double (orig_data.d, DATA_LENGTH, (1.0 * 0x7F000000)) ;
orig = orig_data.i ;
test = test_data.i ;
/* Make this a macro so gdb steps over it in one go. */
CONVERT_DATA (k, DATA_LENGTH, orig, orig_data.d) ;
items = DATA_LENGTH ;
/* Some test broken out here. */
mono_int_test (filename, format, long_file_ok, allow_fd) ;
@@ -2511,8 +2499,8 @@ static void write_seek_extend_test (const char * filename, int format) ;
static void
pcm_test_float (const char *filename, int format, int long_file_ok)
{ SF_INFO sfinfo ;
float *orig, *test ;
int k, items, allow_fd ;
float *orig ;
int k, allow_fd ;
/* Sd2 files cannot be opened from an existing file descriptor. */
allow_fd = ((format & SF_FORMAT_TYPEMASK) == SF_FORMAT_SD2) ? SF_FALSE : SF_TRUE ;
@@ -2527,13 +2515,10 @@ pcm_test_float (const char *filename, int format, int long_file_ok)
gen_windowed_sine_double (orig_data.d, DATA_LENGTH, 1.0) ;
orig = orig_data.f ;
test = test_data.f ;
/* Make this a macro so gdb steps over it in one go. */
CONVERT_DATA (k, DATA_LENGTH, orig, orig_data.d) ;
items = DATA_LENGTH ;
/* Some test broken out here. */
mono_float_test (filename, format, long_file_ok, allow_fd) ;
@@ -3030,8 +3015,8 @@ static void write_seek_extend_test (const char * filename, int format) ;
static void
pcm_test_double (const char *filename, int format, int long_file_ok)
{ SF_INFO sfinfo ;
double *orig, *test ;
int k, items, allow_fd ;
double *orig ;
int k, allow_fd ;
/* Sd2 files cannot be opened from an existing file descriptor. */
allow_fd = ((format & SF_FORMAT_TYPEMASK) == SF_FORMAT_SD2) ? SF_FALSE : SF_TRUE ;
@@ -3046,13 +3031,10 @@ pcm_test_double (const char *filename, int format, int long_file_ok)
gen_windowed_sine_double (orig_data.d, DATA_LENGTH, 1.0) ;
orig = orig_data.d ;
test = test_data.d ;
/* Make this a macro so gdb steps over it in one go. */
CONVERT_DATA (k, DATA_LENGTH, orig, orig_data.d) ;
items = DATA_LENGTH ;
/* Some test broken out here. */
mono_double_test (filename, format, long_file_ok, allow_fd) ;