]>
Commit | Line | Data |
---|---|---|
d8f41ccd A |
1 | #! /bin/csh -f |
2 | # | |
3 | # Generate CSSM_RETURN error string table from specified tla root, place | |
4 | # result in specified header file. | |
5 | # | |
6 | # This is used to generate the error table in utilLib/cssmErrorStrings.h. | |
7 | # Normally this only needs to be run when a new error is added and a test | |
8 | # verifies that error using certcrl or the certVerify() function. | |
9 | # | |
10 | if ( $#argv != 2 ) then | |
11 | echo Usage: genStrings tla_source header_dest | |
12 | echo "The most common usage of this script is like so:" | |
13 | echo "genStrings ../../../ ../utilLib/cssmErrorStrings.h" | |
14 | exit(1) | |
15 | endif | |
16 | ||
17 | set TLA_SRC=$argv[1] | |
18 | set DST=$argv[2] | |
19 | set CSSM_SRC=$TLA_SRC/libsecurity_cssm/lib | |
20 | ||
21 | if ( ! -e $CSSM_SRC ) then | |
22 | echo "$CSSM_SRC not found. Try another tla directory." | |
23 | echo "The most common usage of this script is like so:" | |
24 | echo "genStrings ../../../ ../utilLib/cssmErrorStrings.h" | |
25 | exit(1) | |
26 | endif | |
27 | ||
28 | set ERRFILE1=$CSSM_SRC/cssmerr.h | |
29 | set ERRFILE2=$CSSM_SRC/cssmapple.h | |
30 | ||
31 | ./genErrorStrings $ERRFILE1 $ERRFILE2 > $DST || exit(1) | |
32 | ||
33 | echo "=== Error strings generated in $DST. ===" |