<font class="Apple-style-span" face="georgia, serif">Dear Dirk,</font><div><font class="Apple-style-span" face="georgia, serif"><br></font></div><div><font class="Apple-style-span" face="georgia, serif">Thank you so much for your kind help. I would like to reply to your questions.</font></div>
<div><font class="Apple-style-span" face="georgia, serif"><br></font></div><div><font class="Apple-style-span" face="georgia, serif">Q1) Did you install Rtools as well?</font></div><div><font class="Apple-style-span" face="georgia, serif">Of course, I installed Rtools 2.12.</font></div>
<div><font class="Apple-style-span" face="georgia, serif"><br></font></div><div><font class="Apple-style-span" face="georgia, serif">Q2) Have you ever compiled an R package from source on Windows?</font></div><div><font class="Apple-style-span" face="georgia, serif">Yes. Before compiling the package &quot;mypackage&quot;  in the Windows Command Prompt, I opened the package from Eclipse as a project, and I ran its R function in R console as follows.</font></div>
<div><font class="Apple-style-span" face="georgia, serif"><br></font></div><div><font class="Apple-style-span" face="georgia, serif">&gt; Rcpp_hello_world()</font></div><div><font class="Apple-style-span" face="georgia, serif"><br>
</font></div><div><font class="Apple-style-span" face="georgia, serif">But, nothing happened. Thus, I tried to build a package from the skeleton.</font></div><div><font class="Apple-style-span" face="georgia, serif"><br></font></div>
<div><font class="Apple-style-span" face="georgia, serif">Q3) the command you executed</font></div><div><font class="Apple-style-span" face="georgia, serif">Please, refer to the above answer.</font></div><div><font class="Apple-style-span" face="georgia, serif"><br>
</font></div><div><font class="Apple-style-span" face="georgia, serif">Q4) the errors you got</font></div><div><font class="Apple-style-span" face="georgia, serif">In the Windows Command Prompt, I had the following error message.</font></div>
<div><font class="Apple-style-span" face="georgia, serif"><br></font></div><div><font class="Apple-style-span" face="georgia, serif">&gt; R CMD build mypackage</font></div><div><div><font class="Apple-style-span" face="georgia, serif">checking for file &#39;mypackage/DESCRIPTION&#39; ... OK</font></div>
<div><font class="Apple-style-span" face="georgia, serif">preparing &#39;mypackage&#39;:</font></div><div><font class="Apple-style-span" face="georgia, serif">checking DESCRIPTION meta-information ... OK</font></div><div>
<font class="Apple-style-span" face="georgia, serif">cleaning src</font></div><div><font class="Apple-style-span" face="georgia, serif">ERROR</font></div><div><font class="Apple-style-span" face="georgia, serif">copying to build directory failed</font></div>
</div><div><font class="Apple-style-span" face="georgia, serif"><br></font></div><div><font class="Apple-style-span" face="georgia, serif">Also, a popup window opened with the error message &quot;the operation of &#39;make.exe&#39; was stopped.&quot;</font></div>
<div><font class="Apple-style-span" face="georgia, serif">Then, it suggested to refer the following files, but I could not find them in the specified folder.</font></div><div><font class="Apple-style-span" face="georgia, serif"><br>
</font></div><div><div><font class="Apple-style-span" face="georgia, serif">\AppData\Local\Temp\WER9159.tmp.WERInternalMetadata.xml</font></div><div><font class="Apple-style-span" face="georgia, serif">\AppData\Local\Temp\WER9D1D.tmp.appcompat.txt</font></div>
<div><font class="Apple-style-span" face="georgia, serif">\AppData\Local\Temp\WERA078.tmp.mdmp</font></div></div><div><font class="Apple-style-span" face="georgia, serif"><br></font></div><div><font class="Apple-style-span" face="georgia, serif">I attached some codes of the package.</font></div>
<div><font class="Apple-style-span" face="georgia, serif"><br></font></div><div><font class="Apple-style-span" face="georgia, serif">-- rcpp_hello_world.R</font></div><div><font class="Apple-style-span" face="georgia, serif"><br>
</font></div><div><font class="Apple-style-span" face="georgia, serif">rcpp_hello_world &lt;- function(){</font></div><div><font class="Apple-style-span" face="georgia, serif">     .Call(&quot;rcpp_hello_world&quot;, PACKAGE=&quot;mypackage&quot;)</font></div>
<div><font class="Apple-style-span" face="georgia, serif">}</font></div><div><font class="Apple-style-span" face="georgia, serif"><br></font></div><div><font class="Apple-style-span" face="georgia, serif">-- rcpp_hello_world.cpp</font></div>
<div><font class="Apple-style-span" face="georgia, serif"><br></font></div><div><font class="Apple-style-span" face="georgia, serif">#include &quot;rcpp_hello_world.h&quot;</font></div><div><font class="Apple-style-span" face="georgia, serif"><br>
</font></div><div><font class="Apple-style-span" face="georgia, serif">SEXP rcpp_hello_world(){</font></div><div><font class="Apple-style-span" face="georgia, serif">     using namespace Rcpp;</font></div><div><font class="Apple-style-span" face="georgia, serif">     CharacterVector x = CharacterVector::create( &quot;foo&quot;, &quot;bar&quot; )  ;</font></div>
<div><font class="Apple-style-span" face="georgia, serif">     NumericVector y   = NumericVector::create( 0.0, 1.0 ) ;</font></div><div><font class="Apple-style-span" face="georgia, serif">     List z            = List::create( x, y ) ;    </font></div>
<div><font class="Apple-style-span" face="georgia, serif">     return z ;     </font></div><div><font class="Apple-style-span" face="georgia, serif">}</font></div><div>
<br><br><div class="gmail_quote">2011/1/17 Dirk Eddelbuettel <span dir="ltr">&lt;<a href="mailto:edd@debian.org">edd@debian.org</a>&gt;</span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<br>
Dear Wonsang,<br>
<div class="im"><br>
On 17 January 2011 at 16:34, Wonsang You wrote:<br>
| Dear Rcpp developers,<br>
|<br>
| I am not familiar with Rcpp package. To integrate R and C++, I installed the<br>
| &#39;Rcpp&#39; package on Windows. Then, I created a template skeleton according to the<br>
<br>
</div>Did you install Rtools as well?<br>
<br>
Have you ever compiled an R package from source on Windows?<br>
<div class="im"><br>
| documentation (<a href="http://dirk.eddelbuettel.com/code/rcpp/Rcpp-package.pdf" target="_blank">http://dirk.eddelbuettel.com/code/rcpp/Rcpp-package.pdf</a>) as<br>
| follows.<br>
|<br>
| &gt; Rcpp.package.skeleton(&quot;mypackage&quot;)<br>
|<br>
| Then, I had a set of files, and I tried to build a package by the following<br>
| command in the Command Prompt.<br>
|<br>
| c:\workspace&gt; R CMD build mypackage<br>
|<br>
| But, I always had an error when it called &#39;make.exe&#39;.  Can anyone help me to<br>
| solve such a problem?<br>
<br>
</div>We do not have mind readers.  So unless you show us<br>
<br>
   i)   the command you executed<br>
<br>
   ii)  the errors you got<br>
<br>
we are in not position to help.<br>
<br>
Cheers, Dirk<br>
<div class="im"><br>
<br>
| Best Regards,<br>
| Wonsang You<br>
|<br>
| --<br>
| Leibniz Institute for Neurobiology<br>
|<br>
</div>| ----------------------------------------------------------------------<br>
| _______________________________________________<br>
| Rcpp-devel mailing list<br>
| <a href="mailto:Rcpp-devel@lists.r-forge.r-project.org">Rcpp-devel@lists.r-forge.r-project.org</a><br>
| <a href="https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel" target="_blank">https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel</a><br>
<font color="#888888"><br>
--<br>
Dirk Eddelbuettel | <a href="mailto:edd@debian.org">edd@debian.org</a> | <a href="http://dirk.eddelbuettel.com" target="_blank">http://dirk.eddelbuettel.com</a><br>
</font></blockquote></div><br></div>