fix compilation problems under centos 6