edits to allow building on linux 32bit