Adding optimization flags to compilation