Mercurial > hg > sv-dependency-builds
annotate src/libsndfile-1.0.27/tests/sfversion.c @ 127:7867fa7e1b6b
Current fftw source
author | Chris Cannam <cannam@all-day-breakfast.com> |
---|---|
date | Tue, 18 Oct 2016 13:40:26 +0100 |
parents | cd6cdf86811e |
children |
rev | line source |
---|---|
cannam@125 | 1 /* |
cannam@125 | 2 ** Copyright (C) 1999-2011 Erik de Castro Lopo <erikd@mega-nerd.com> |
cannam@125 | 3 ** |
cannam@125 | 4 ** This program is free software; you can redistribute it and/or modify |
cannam@125 | 5 ** it under the terms of the GNU General Public License as published by |
cannam@125 | 6 ** the Free Software Foundation; either version 2 of the License, or |
cannam@125 | 7 ** (at your option) any later version. |
cannam@125 | 8 ** |
cannam@125 | 9 ** This program is distributed in the hope that it will be useful, |
cannam@125 | 10 ** but WITHOUT ANY WARRANTY; without even the implied warranty of |
cannam@125 | 11 ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
cannam@125 | 12 ** GNU General Public License for more details. |
cannam@125 | 13 ** |
cannam@125 | 14 ** You should have received a copy of the GNU General Public License |
cannam@125 | 15 ** along with this program; if not, write to the Free Software |
cannam@125 | 16 ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
cannam@125 | 17 */ |
cannam@125 | 18 |
cannam@125 | 19 #include <stdio.h> |
cannam@125 | 20 #include <stdlib.h> |
cannam@125 | 21 #include <string.h> |
cannam@125 | 22 #include <stdint.h> |
cannam@125 | 23 |
cannam@125 | 24 #include <sndfile.h> |
cannam@125 | 25 |
cannam@125 | 26 #define BUFFER_SIZE (256) |
cannam@125 | 27 |
cannam@125 | 28 |
cannam@125 | 29 int |
cannam@125 | 30 main (void) |
cannam@125 | 31 { static char strbuffer [BUFFER_SIZE] ; |
cannam@125 | 32 const char * ver ; |
cannam@125 | 33 |
cannam@125 | 34 sf_command (NULL, SFC_GET_LIB_VERSION, strbuffer, sizeof (strbuffer)) ; |
cannam@125 | 35 ver = sf_version_string () ; |
cannam@125 | 36 |
cannam@125 | 37 if (strcmp (ver, strbuffer) != 0) |
cannam@125 | 38 { printf ("Version mismatch : '%s' != '%s'\n\n", ver, strbuffer) ; |
cannam@125 | 39 exit (1) ; |
cannam@125 | 40 } ; |
cannam@125 | 41 |
cannam@125 | 42 printf ("%s", strbuffer) ; |
cannam@125 | 43 |
cannam@125 | 44 return 0 ; |
cannam@125 | 45 } /* main */ |
cannam@125 | 46 |