[Rcpp-devel] Rcpp 0.12.3 does not compile properly under Solaris 11.2/sparc Error: Could not find a match for std::wstring::basic_string(const char*, const char*) needed in

Dimitar Vassilev dimitar.vassilev at gmail.com
Wed Feb 10 11:52:59 CET 2016


Thanks Dirk,
Tried today with gcc-4.8.2 and g++ - 4.8.2

> install.packages("ggplot2");
also installing the dependencies 'Rcpp', 'plyr', 'reshape2', 'scales'

trying URL 'http://cran.uni-muenster.de/src/contrib/Rcpp_0.12.3.tar.gz'
Content type 'application/x-gzip' length 2374320 bytes (2.3 MB)
==================================================
downloaded 2.3 MB

trying URL 'http://cran.uni-muenster.de/src/contrib/plyr_1.8.3.tar.gz'
Content type 'application/x-gzip' length 392337 bytes (383 KB)
==================================================
downloaded 383 KB

trying URL 'http://cran.uni-muenster.de/src/contrib/reshape2_1.4.1.tar.gz'
Content type 'application/x-gzip' length 34693 bytes (33 KB)
==================================================
downloaded 33 KB

trying URL 'http://cran.uni-muenster.de/src/contrib/scales_0.3.0.tar.gz'
Content type 'application/x-gzip' length 57030 bytes (55 KB)
==================================================
downloaded 55 KB

trying URL 'http://cran.uni-muenster.de/src/contrib/ggplot2_2.0.0.tar.gz'
Content type 'application/x-gzip' length 1546130 bytes (1.5 MB)
==================================================
downloaded 1.5 MB

* installing *source* package 'Rcpp' ...
** package 'Rcpp' successfully unpacked and MD5 sums checked
** libs
g++ -I/usr/local/R/include -DNDEBUG -I../inst/include/     -KPIC  -g  -c
Date.cpp -o Date.o
g++: error: unrecognized command line option '-KPIC'
gmake: *** [Date.o] Error 1
ERROR: compilation failed for package 'Rcpp'
* removing '/usr/local/R/library/Rcpp'
ERROR: dependency 'Rcpp' is not available for package 'plyr'
* removing '/usr/local/R/library/plyr'
ERROR: dependencies 'plyr', 'Rcpp' are not available for package 'reshape2'
* removing '/usr/local/R/library/reshape2'
ERROR: dependencies 'plyr', 'Rcpp' are not available for package 'scales'
* removing '/usr/local/R/library/scales'
ERROR: dependencies 'plyr', 'reshape2', 'scales' are not available for
package 'ggplot2'
* removing '/usr/local/R/library/ggplot2'

The downloaded source packages are in
        '/tmp/RtmpZmVEUH/downloaded_packages'
Updating HTML index of packages in '.Library'
Making 'packages.html' ... done
Warning messages:
1: In install.packages("ggplot2") :
  installation of package 'Rcpp' had non-zero exit status
2: In install.packages("ggplot2") :
  installation of package 'plyr' had non-zero exit status
3: In install.packages("ggplot2") :
  installation of package 'reshape2' had non-zero exit status
4: In install.packages("ggplot2") :
  installation of package 'scales' had non-zero exit status
5: In install.packages("ggplot2") :
  installation of package 'ggplot2' had non-zero exit status

  -bash-4.1# /usr/bin/g
Display all 349 possibilities? (y or n)
-bash-4.1# /usr/bin/g++
g++: fatal error: no input files
compilation terminated.
-bash-4.1# /usr/bin/g++  -v
Using built-in specs.
COLLECT_GCC=/usr/bin/g++
COLLECT_LTO_WRAPPER=/usr/gcc/4.8/lib/gcc/sparc-sun-solaris2.11/4.8.2/lto-wrapper
Target: sparc-sun-solaris2.11
Configured with:
/export/home/hudson/workspace/nightly-update/build/sparc/components/gcc48/gcc-4.8.2/configure
CC=/usr/gcc/4.7/bin/gcc CXX=/usr/gcc/4.7/bin/g++ --prefix=/usr/gcc/4.8
--mandir=/usr/gcc/4.8/share/man --bindir=/usr/gcc/4.8/bin
--libdir=/usr/gcc/4.8/lib --sbindir=/usr/gcc/4.8/sbin
--infodir=/usr/gcc/4.8/share/info --libexecdir=/usr/gcc/4.8/lib
--enable-languages=c,c++,fortran,objc --enable-shared
--with-gmp-include=/usr/include/gmp --with-mpfr-include=/usr/include/mpfr
--without-gnu-ld --with-ld=/usr/bin/ld --without-gnu-as
--with-as=/usr/bin/as CFLAGS='-g -O2  -mtune=ultrasparc -mcpu=ultrasparc
-mno-unaligned-doubles' CXXFLAGS='-g -O2 -mtune=ultrasparc -mcpu=ultrasparc
-mno-unaligned-doubles'
Thread model: posix
gcc version 4.8.2 (GCC)

Barfing at KPIC. Any idea how to go further?
Regards,
Dimitar

2016-02-09 13:54 GMT+01:00 Dirk Eddelbuettel <edd at debian.org>:

>
> On 9 February 2016 at 13:41, Dimitar Vassilev wrote:
> | Thanks gents,
> | I will use gcc for the future. Got version 4.8 in the official
> repository. What
> | I'm afraid of that I may hit a nice dependency hell/soup when you have
> things
> | compiled in Sun Studio ( Oracle R community edition) and on top you're
> | compiling things with gcc.
>
> I am wondering about that too ... but it could just work (as everything is
> behind 'export "C"' layers making it a more portable C interface).  Very
> worst case just drop the 'community R' from your "friendly neighbourhood
> database seller" and install R from source. It will still talk to the db
> backends.
>
> Cheers,  Dirk
>
> | Best,
> | Dimitar
> |
> | 2016-02-09 13:31 GMT+01:00 JJ Allaire <jj.allaire at gmail.com>:
> |
> |     Yes, all the checks pass on CRAN because they use the gcc toolchain
> for
> |     Rcpp and all packages that depend on it:
> |
> |     https://cran.r-project.org/web/checks/check_results_Rcpp.html
> |
> |
> |     On Tue, Feb 9, 2016 at 7:28 AM, Dirk Eddelbuettel <edd at debian.org>
> wrote:
> |
> |
> |         Hi Dimitar,
> |
> |         On 9 February 2016 at 12:08, Dimitar Vassilev wrote:
> |         | Hello,
> |         | I’m building on top of Oracle R Community edition 3.2, Sun
> Studio
> |         12.4 and
> |         | Solaris 11.2 some packages for internal use.
> |
> |         The problem is likely the Sun Studio compiler. 'Nobody here'
> uses that
> |         anymore, and even CRAN / Oxford which tests on Solaris
> (x86,sparc) uses
> |         gcc
> |         per the tests page:
> |
> |
> https://cloud.r-project.org/web/checks/check_results_Rcpp.html
> |
> |         | The error I get when trying to install Rcpp is:
> |         | >  install.packages("dplyr");
> |         | also installing the dependency 'Rcpp'
> |         |
> |         | trying URL 'http://cran.uni-muenster.de/src/contrib/
> |         Rcpp_0.12.3.tar.gz'
> |         | Content type 'application/x-gzip' length 2374320 bytes (2.3 MB)
> |         | ==================================================
> |         | downloaded 2.3 MB
> |         |
> |         | trying URL 'http://cran.uni-muenster.de/src/contrib/
> |         dplyr_0.4.3.tar.gz'
> |         | Content type 'application/x-gzip' length 655997 bytes (640 KB)
> |         | ==================================================
> |         | downloaded 640 KB
> |         |
> |         | * installing *source* package 'Rcpp' ...
> |         | ** package 'Rcpp' successfully unpacked and MD5 sums checked
> |         | ** libs
> |         | /opt/SunProd/studio12u3/solarisstudio12.3/bin/CC -m64
> -I/usr/local/R/
> |         include
> |         | -DNDEBUG -I../inst/include/     -KPIC  -g  -c Date.cpp -o
> Date.o
> |         | "../inst/include/Rcpp/Interrupt.h", line 60: Warning
> (Anachronism):
> |         Using void
> |         | (*)(void*) to initialize extern "C" void(*)(void*).
> |         | "../inst/include/Rcpp/vector/MatrixRow.h", line 43: Error:
> |         iterator_traits is
> |         | not a member of std.
> |
> |         We are doing things in C++ which are standard now, but for which
> Sun
> |         Studio
> |         does not seem to have caught up.
> |
> |         Maybe you need to look into installing the gcc toolchain.
> |
> |         Maybe another list reader has a better idea but I fear that is
> all we
> |         can say
> |         here.
> |
> |         Greetings,  Dirk
> |
> |         | "../inst/include/Rcpp/vector/MatrixRow.h", line 43: Error: A
> |         declaration does
> |         | not specify a tag or an identifier.
> |         | "../inst/include/Rcpp/vector/MatrixRow.h", line 43: Error: Use
> ";" to
> |         terminate
> |         | declarations.
> |         | "../inst/include/Rcpp/vector/MatrixRow.h", line 43: Error: "}"
> |         expected instead
> |         | of "<".
> |         | "../inst/include/Rcpp/vector/MatrixRow.h", line 188: Error:
> |         iterator_traits is
> |         | not a member of std.
> |         | "../inst/include/Rcpp/vector/MatrixRow.h", line 188: Error: A
> |         declaration does
> |         | not specify a tag or an identifier.
> |         | "../inst/include/Rcpp/vector/MatrixRow.h", line 188: Error:
> Use ";"
> |         to
> |         | terminate declarations.
> |         | "../inst/include/Rcpp/vector/MatrixRow.h", line 188: Error: "}"
> |         expected
> |         | instead of "<".
> |         | "../inst/include/Rcpp/String.h", line 67: Warning: enc hides
> |         Rcpp::String::enc.
> |         | "../inst/include/Rcpp/String.h", line 81: Warning: enc hides
> |         Rcpp::String::enc.
> |         | "../inst/include/Rcpp/String.h", line 95: Warning: enc hides
> |         Rcpp::String::enc.
> |         | "../inst/include/Rcpp/String.h", line 107: Warning: enc hides
> |         | Rcpp::String::enc.
> |         | "../inst/include/Rcpp/String.h", line 378: Error: Could not
> find a
> |         match for
> |         | std::wstring::basic_string(const char*, const char*) needed in
> |         | Rcpp::String::operator std::wstring () const.
> |         | 9 Error(s) and 5 Warning(s) detected.
> |         | *** Error code 2
> |         | make: Fatal error: Command failed for target `Date.o'
> |         | ERROR: compilation failed for package 'Rcpp'
> |         | * removing '/usr/local/R/library/Rcpp'
> |         | ERROR: dependency 'Rcpp' is not available for package 'dplyr'
> |         | * removing '/usr/local/R/library/dplyr'
> |         |
> |         | The downloaded source packages are in
> |         |         '/tmp/RtmpPbHqdD/downloaded_packages'
> |         | Updating HTML index of packages in '.Library'
> |         | Making 'packages.html' ... done
> |         | Warning messages:
> |         | 1: In install.packages("dplyr") :
> |         |   installation of package 'Rcpp' had non-zero exit status
> |         | 2: In install.packages("dplyr") :
> |         |   installation of package 'dplyr' had non-zero exit status
> |         | > q();
> |         |
> |         | Can you point me what should I do further?
> |         | My .Renviron is as follows
> |         | TZ=CET
> |         | TERM=vt220
> |         | TAR=/usr/bin/tar
> |         | R_UNZIPCMD=/usr/bin/unzip
> |         | R_ZIPCMD=/usr/bin/zip
> |         | MAKE=/usr/bin/make
> |         | LD_LIBRARY_PATH=/usr/lib:/usr/local/R/lib:/lib:/usr/local/lib
> |         | PAGER=/usr/bin/less
> |         | R_BZIPCMD=/usr/bin/bzip2
> |         | R_GZIPCMD=/usr/bin/gzip
> |         | I made a symlink so that the compilation works. Unfortunately
> the R
> |         modules
> |         | have hard-coded the path to the compiler.
> |         | -bash-4.1# ls -la
> /opt/SunProd/studio12u3/solarisstudio12.3/bin
> |         | lrwxrwxrwx   1 root     root          26 Feb  4 15:22
> /opt/SunProd/
> |         studio12u3/
> |         | solarisstudio12.3/bin -> /opt/solarisstudio12.4/bin
> |         |
> |         | Can someone point me which compiler options/configure
> arguments are
> |         needed so
> |         | that the conversion and compilation is successful?
> |         | Thanks!
> |         |
> |         | _______________________________________________
> |         | 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
> |
> |         --
> |         http://dirk.eddelbuettel.com | @eddelbuettel | edd at debian.org
> |         _______________________________________________
> |         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
> |
> |
> |
> |
>
> --
> http://dirk.eddelbuettel.com | @eddelbuettel | edd at debian.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.r-forge.r-project.org/pipermail/rcpp-devel/attachments/20160210/3430764b/attachment-0001.html>


More information about the Rcpp-devel mailing list