tests/pedantic-header-test.sh.in : New file to test whether sndfile.h can be compiled with gcc's -pedantic flag.

This commit is contained in:
Erik de Castro Lopo 2010-04-21 18:13:26 +10:00
parent 8cabcb3522
commit d1484cf543
2 changed files with 28 additions and 0 deletions

View File

@ -1,3 +1,9 @@
2010-04-21 Erik de Castro Lopo <erikd AT mega-nerd DOT com>
* tests/pedantic-header-test.sh.in
New file to test whether sndfile.h can be compiled with gcc's -pedantic
flag.
2010-04-19 Erik de Castro Lopo <erikd AT mega-nerd DOT com>
* programs/sndfile-salvage.c programs/Makefile.am

View File

@ -0,0 +1,22 @@
#!/bin/bash
echo -n " Pedantic header test : "
# Only do this if the compiler is GCC.
if test -n "@GCC_MAJOR_VERSION@" ; then
# Compile with -Werror and -pedantic.
@ac_ct_CC@ -Werror -pedantic -I@top_srcdir@/src -c sfversion.c -o /dev/null
# Check compiler return status.
if test $? -ne 0 ; then
echo
exit 1
fi
echo "ok"
else
echo "n/a"
fi
exit 0