Use libz
Add a gzread helper
Convert statinfo to the gzip apis
Update statinfo bounds check