]>
Commit | Line | Data |
---|---|---|
b5c6f486 KZ |
1 | #!/bin/sh |
2 | ||
3 | # | |
4 | # This script checkd for #ifdef HAVE_DECL_SYMBOL in code. | |
5 | # | |
6 | # Autoconf docs: | |
7 | # | |
8 | # Unlike the other autoconf ‘AC_CHECK_*S’ macros, when a symbol is not | |
9 | # declared, HAVE_DECL_symbol is defined to ‘0’ instead of leaving | |
10 | # HAVE_DECL_symbol undeclared. When you are sure that the check was performed, | |
11 | # use HAVE_DECL_symbol in #if. | |
12 | # | |
13 | ||
14 | if [ ! -f ./configure ]; then | |
15 | echo "Not found configure script" | |
16 | exit 1 | |
17 | fi | |
18 | ||
19 | for decl in $(awk '/HAVE_DECL_.*ac_have_decl/ { print $2 }' configure); do | |
20 | git grep -nE '[[:blank:]]*#[[:blank:]]*if(ndef|def)[[:blank:]]*'$decl; | |
21 | done | sort -u |