Changeset 3993 for libcaca/trunk/tests/check-build
- Timestamp:
- Nov 21, 2009, 6:01:30 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
libcaca/trunk/tests/check-build
r3907 r3993 1 1 #!/bin/sh 2 2 3 failure=0 3 ret=0 4 5 # 6 # Check that the Win32 config.h is in sync with config.h.in 7 # 4 8 5 9 config_h_in=$(dirname "$0")/../config.h.in 6 10 win32_config_h=$(dirname "$0")/../win32/config.h 7 11 12 failure=0 8 13 for key in $(sed -ne 's/.*#undef *\([A-Za-z0-9_]*\).*/\1/p' "$config_h_in"); 9 14 do … … 13 18 fi 14 19 done 15 16 20 if test "$failure" != "0"; then 17 exit121 ret=1 18 22 else 19 23 echo "0 errors in Win32 config.h" 20 24 fi 21 25 26 # 27 # Check that we have no tabs or trailing spaces in the source code 28 # 29 failure=0 30 for dir in caca cxx examples ruby tools; do 31 pushd ../$dir >/dev/null 32 # Dirty hack to print the $(SOURCES) variable 33 for x in $(make -s ID SHELL='echo @@$(SOURCES)@@' | tr -d '\n' | sed 's/.*@@\([^@]*\)@@.*/\1/'); 34 do 35 if grep '[[:space:]]$' "$x" >/dev/null 2>&1; then 36 echo "error: $dir/$x contains trailing spaces" 37 failure=1 38 fi 39 if grep ' ' "$x" >/dev/null 2>&1; then 40 echo "error: $dir/$x contains tabs" 41 failure=1 42 fi 43 done 44 popd >/dev/null 45 done 46 if test "$failure" != "0"; then 47 ret=1 48 else 49 echo "0 errors in source code" 50 fi 51 52 if test "$ret" != "0"; then 53 exit 1 54 fi 55 22 56 exit 0 23 57
Note: See TracChangeset
for help on using the changeset viewer.