Update compile-dll.r

I think there is a mistake line 37: "inst" must be inst.
Otherwise file.copy quietly fails.
I also suggest to look at the returned boolean and throw an error.