|  |  | 
|  | found=0 | 
|  |  | 
|  | echo 'Checking for uint64_t' | 
|  |  | 
|  | echo '#include <sys/types.h>' > autotest.c | 
|  | echo 'int main() { uint64_t i = 0; return 0; }' >> autotest.c | 
|  |  | 
|  | eval "${CC} -o autotest autotest.c > /dev/null 2>&1" | 
|  |  | 
|  | if [ -x autotest ]; then | 
|  | echo ' + uint64_t found' | 
|  | found=1 | 
|  | else | 
|  | echo ' + uint64_t not found' | 
|  | fi | 
|  |  | 
|  | rm autotest* | 
|  |  | 
|  |  | 
|  | if [ $found = 0 ]; then | 
|  |  | 
|  | echo '#include <sys/types.h>' > autotest.c | 
|  | echo 'int main() { u_int64_t i = 0; return 0; }' >> autotest.c | 
|  |  | 
|  | eval "${CC} -o autotest autotest.c > /dev/null 2>&1" | 
|  |  | 
|  | if [ -x autotest ]; then | 
|  | echo ' + u_int64_t used' | 
|  | type='typedef u_int64_t  uint64_t;' | 
|  | found=2 | 
|  | else | 
|  | echo ' + u_int64_t not found' | 
|  | fi | 
|  |  | 
|  | rm autotest* | 
|  |  | 
|  | fi | 
|  |  | 
|  |  | 
|  | if [ $found = 0 ]; then | 
|  | echo "$0: error: uint64_t not found" | 
|  | exit 1 | 
|  | fi | 
|  |  | 
|  |  | 
|  | if [ $found = 2 ]; then | 
|  | echo $type >> ngx_auto_config.h | 
|  | echo >> ngx_auto_config.h | 
|  | fi |