Fix some gcc compile issues, so it builds for openSUSE_13.1 with newest gcc