Fixes for 32-bit linux