Yes, you must compile the code on the server (or a very similar environment, i.e. the same Linux distribution/version). You could use Tools | Shell from within RStudio Server to drop to something (badly) approximating a shell prompt, and manually call make/g++/whatever from there.
The better long-term solution though, is to put your C++ code (and the rest of your analysis?) in a package, with or without Rcpp. Not only is R well designed to compile and/or distribute native code this way, but RStudio will do the compilation and installation for you when you do "Build and Reload" on the Build pane (only available if your current project is an R package).
Here's Hadley's take on the Rcpp way of doing things (in particular, note "Using Rcpp in a Package"):