[Rcpp-devel] Compilation on MAC OS X 10.7.2

Romain François romain at r-enthusiasts.com
Wed Dec 7 17:28:11 CET 2011


(please keep ccing the list)

neither do we use unordered_map, IIRC.
Without a reproducible example, there is very little I can do to help. I 
have no idea what is in clusteringMain.

Romain

Le 07/12/11 17:22, Rémi Lebret a écrit :
> Cher Romain,
>
> I don't use any tr1::unordered_map function in my program.
>
> The error comes from the inclusion of <Rcpp.h> (line 91) in my main.cpp
>
> And the package compiles fine under Linux.
>
> Rémi
>
> Le 7 déc. 2011 à 16:59, Romain François a écrit :
>
>> Bonjour Remi,
>>
>> Could you send a reproducible example using tr1::unordered_map so 
>> that we can help you.
>>
>> Cordialement,
>>
>> Romain
>>
>> Le 07/12/11 16:55, Rémi Lebret a écrit :
>>> Hi,
>>>
>>> I got this error when I'm trying to compile my package using Rcpp :
>>>
>>> g++-4.2 -arch i386 
>>> -I/Library/Frameworks/R.framework/Resources/include 
>>> -I/Library/Frameworks/R.framework/Resources/include/i386 
>>>  -I/usr/local/include 
>>> -I"/Library/Frameworks/R.framework/Versions/2.14/Resources/library/Rcpp/include" 
>>>   -fPIC  -g -O2 -c clusteringMain.cpp -o clusteringMain.o
>>> In file included from /usr/include/c++/4.2.1/tr1/unordered_map:38,
>>>                  from 
>>> /Library/Frameworks/R.framework/Versions/2.14/Resources/library/Rcpp/include/RcppCommon.h:130,
>>>                  from 
>>> /Library/Frameworks/R.framework/Versions/2.14/Resources/library/Rcpp/include/Rcpp.h:27,
>>>                  from clusteringMain.cpp:91:
>>> /usr/include/c++/4.2.1/tr1/functional_hash.h: In member function 
>>> ‘size_t std::tr1::hash<std::basic_string<char, 
>>> std::char_traits<char>, std::allocator<char> > >::operator()(const 
>>> std::string&) const’:
>>> /usr/include/c++/4.2.1/tr1/functional_hash.h:144: error: ‘const 
>>> struct std::basic_string<char, std::char_traits<char>, 
>>> std::allocator<char> >’ has no member named ‘Rf_length’
>>> /usr/include/c++/4.2.1/tr1/functional_hash.h: In member function 
>>> ‘size_t std::tr1::hash<std::basic_string<wchar_t, 
>>> std::char_traits<wchar_t>, std::allocator<wchar_t> > 
>>> >::operator()(const std::wstring&) const’:
>>> /usr/include/c++/4.2.1/tr1/functional_hash.h:156: error: ‘const 
>>> struct std::basic_string<wchar_t, std::char_traits<wchar_t>, 
>>> std::allocator<wchar_t> >’ has no member named ‘Rf_length’
>>> make: *** [clusteringMain.o] Error 1
>>>
>>> It looks like there is a problem with the tr1::unordered_map
>>>
>>> Any help ?
>>>
>>> Rémi
>>>
>>> Rémi Lebret
>>> Ingénieur de recherche CNRS
>>> Laboratoire de mathématiques de Lille1 - UMR 8524
>>> Batiment M3 - Bureau 322
>>> Tel: 03 20 43 67 82
>>> remi.lebret at math.univ-lille1.fr <mailto:remi.lebret at math.univ-lille1.fr>
>>>
>>>
>>>
>>> _______________________________________________
>>> Rcpp-devel mailing list
>>> Rcpp-devel at lists.r-forge.r-project.org
>>> https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel
>>
>>
>> -- 
>> Romain Francois
>> Professional R Enthusiast
>> http://romainfrancois.blog.free.fr
>> _______________________________________________
>> Rcpp-devel mailing list
>> Rcpp-devel at lists.r-forge.r-project.org 
>> <mailto:Rcpp-devel at lists.r-forge.r-project.org>
>> https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel
>
> Rémi Lebret
> Ingénieur de recherche CNRS
> Laboratoire de mathématiques de Lille1 - UMR 8524
> Batiment M3 - Bureau 322
> Tel: 03 20 43 67 82
> remi.lebret at math.univ-lille1.fr <mailto:remi.lebret at math.univ-lille1.fr>
>


-- 
Romain Francois
Professional R Enthusiast
http://romainfrancois.blog.free.fr

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.r-forge.r-project.org/pipermail/rcpp-devel/attachments/20111207/c1220c1f/attachment-0001.htm>


More information about the Rcpp-devel mailing list