Adapted again for Linaro Toolchain 4.6 (hopefully)