buildlib.sh: fixed standard flag value

GCC does not have a c++11 value for the standard, instead it should be c++0x.
Also added the rm flag -f to ensure that rm does not fail when any of the
globbed files are absent.