Hi Robin,
Those exact linker errors occur if you use a different version of MinGW than
the Rcpp static library. Could that possibly be the case?
If so make sure to install Rcpp from source. For example:
install.packages("C:/CRAN/Rcpp_0.10.3.tar.gz", repos=NULL, type="source")
Make sure you have the Rtools bin directory and the MinGW version you are using
in your path.
You said you don't have C++11; are you using a version of GCC older than that
supplied with Rtools? In that case you may have issues compiling for R 64-bit
in my experience. Run this from R i386:
install.packages("C:/CRAN/Rcpp_0.10.3.tar.gz", repos=NULL, type="source",
INSTALL_opts=c("--no-multiarch"))
Best of luck,
John
-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Robin
Girard
Sent: Wednesday, April 17, 2013 10:44 AM
To: [email protected]
Subject: [Rcpp-devel] linking fail when building examples of my local copy of
Rcpp gallery (windows)
Salut list,
I'm trying to become soon a (small) contributor to Rcpp Gallery and I would
like to be able to visualize the result before pushing it. I'm on windows...
I managed to install jeckyll and made it work (this
http://bradleygrainger.com/2011/09/07/how-to-use-github-pages-on-windows.html
helped me if other people want to do the same).
I removed all src that are c++11 since I don't have it (that would be another
question about having it on windows but I did not try yet)
I did "make" in the src folder
but it appeared that I had to change the first two line, my dumb guess was that
it did not like the relative path stuff, I changed the first two line of the
makefile to KNIT = /c/GitHub/rcpp-gallery/_scripts/knit.sh
POSTS_DIR = /c/GitHub/rcpp-gallery/_posts
then I did "make" again and got a lot of ...
library/Rcpp/lib/i386/libRcpp.a(api.o):api.cpp:(.text+0x160c): undefined
reference to `__gxx_personality_sj0'
library/Rcpp/lib/i386/libRcpp.a(api.o):api.cpp:(.text+0x162b): undefined
reference to `_Unwind_SjLj_Register'
library/Rcpp/lib/i386/libRcpp.a(api.o):api.cpp:(.text+0x166f): undefined
reference to `_Unwind_SjLj_Unregister'
library/Rcpp/lib/i386/libRcpp.a(api.o):api.cpp:(.text+0x1726): undefined
reference to `_Unwind_SjLj_Resume'
...
endding with
make[1]: Entering directory `/tmp/RtmpIDf7mh/sourcecpp_15c479677107' g++
-I"c:/R/R-215~1.2/include" -DNDEBUG -I"c:/R/R-2.15.2/library/Rcpp/include"
-O2 -Wall -mtune=core2 -c file15c426717ca8.cpp
-o file15c426717ca8.o g++ -shared -s -static-libgcc -o sourceCpp_78831.dll
tmp.def file15c426717ca8.o c:/R/R-2.15.2/library/Rcpp/lib/i386/libRcpp.a
-Lc:/R/R-215~1.2/bin/i386 -lR make[1]: Leaving directory `/
tmp/RtmpIDf7mh/sourcecpp_15c479677107'
Quitting from lines 11-56 ()
Erreur dans function (file = "", code = NULL, env = globalenv(), rebuild =
FALSE, :
Error occurred building shared library.
Calls: knit ... block_exec -> in_dir -> <Anonymous> -> do.call -> <Anonymous>
I know this has to do with my library path (and actually when I launch the
function "knit(input,output)" in R for a given Rcpp example this works and
generate the markdown file) but don't find where this comes from.
any idea of what I'm doing wrong ?
Best
Robin
Dr. Girard Robin
Chargé de Recherche
MINES-ParisTech / Département Energétique et Procédés / PERSEE / Groupe ERSEI
Centre Procédés, Energies Renouvelables et Systèmes Energétiques (PERSEE)
Center for Processes, Renewables Energies and Energy Systems
Renewable Energies & Smartgrids (ERSEI)
1 Rue Claude Daunesse - CS 10207 - F-06904 Sophia Antipolis Cedex
Tel: +33.4.93.67.89.64 (~99), Fax: +33.4.93.95.75.35
e-mail : [email protected]
web page perso http://www.mines-paristech.fr/Services/Annuaire/&?id=8828
statoverflow : http://stats.stackexchange.com/users/223/robin-girard
web page centre PERSEE : http://www.cep.mines-paristech.fr/
linkedin : http://www.linkedin.com/profile/view?id=14907272&trk=tab_pro
Le lien vaut mieux que le bien.
________________________________________________________
CONFIDENTIALITY : This e-mail and any attachments are
confidential and may be privileged. If you are not a
named recipient, please notify the sender immediately and
do not disclose the contents to another person, use it for
any purpose or store or copy the information in any medium.
CONFIDENTIALITE : Ce message et les éventuelles pièces
attachées sontconfidentiels et peuvent être une
communication protégée. Si vous n'êtes pas dans la liste
des destinataires, veuillez informer l'expéditeur
immédiatement et ne pas ouvrir ni divulguer le contenu
à une tierce personne, ne pas l'utiliser pour quelque
raison que ce soit, ne pas stocker ou copier l'information
qu'il contient sur un quelconque support.
_______________________________________________
Rcpp-devel mailing list
[email protected]
https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel
_______________________________________________
Rcpp-devel mailing list
[email protected]
https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel