update build.sdm.r