Compilation failed for package with Rcpp
<p>I have a <code>.cpp</code> file which can be compiled by <code>sourceRcpp()</code> successfully. Now I use <code>Rcpp.package.skeleton()</code> for it, and it generates the related directory. Then I run the code R CMD Install on the command line, but it showed a warning with an ERROR: </p>

<blockquote>
  <p>compilation failed for package...</p>
</blockquote>

<p>I'm Windows user and use RStudio. I've followed some advice and found the file <code>Makevars.win</code>, it has only one line</p>

<pre><code>PKG_LIBS = $(LAPACK_LIBS) $(BLAS_LIBS) $(FLIBS)
</code></pre>

<p>Maybe I need to add <code>Rcpp:::LdFlags()</code> or something. I've already install Rtools before because I can compile and install my own packages without using <code>Rcpp</code>.</p>

<p>Could you give me some advice how to deal with it?</p>