fix build with gcc 4.7

Hi,

while building fine with gcc 4.6, some additional changes are needed to build with gcc 4.7.