integrated Rserve into compile script