[Rd] reproducible segmentation fault installing packages on FreeBSD 11.1

Joseph Mingrone jrm at ftfl.ca
Tue Aug 1 19:09:27 CEST 2017

Dirk Eddelbuettel <edd at debian.org> writes:

> On 31 July 2017 at 19:38, Joseph Mingrone wrote:
> | This happens when attempting to install any package. There were no such
> | problems on 11.0.
> | 
> | Some other ways to trigger the problem:
> [...]
> | trying URL 'https://cloud.r-project.org/src/contrib/Rcpp_0.12.12.tar.gz'
> | [New LWP 100854 of process 56011]
> | 
> | Thread 7 received signal SIGSEGV, Segmentation fault.
> | [Switching to LWP 100854 of process 56011]
> | uw_frame_state_for (context=context at entry=0x7fffdfffde20, fs=fs at entry=0x7fffdfffdb70)
> |     at /usr/ports/lang/gcc5/work/gcc-5.4.0/libgcc/unwind-dw2.c:1249
> | 1249          return MD_FALLBACK_FRAME_STATE_FOR (context, fs);

> Looks like a gcc error to me. Rcpp itself is pretty widely used and tested
> and I am not aware of it having issue per se on any of the *BSDs.

The problem isn't specific to any package or packages in general, but
seems related to libcurl and/or gfortran.

The third call to

CURLcode ret = curl_easy_perform(hnd);

in in_do_curlGetHeaders() from src/modules/internet/libcurl.c triggers
the problem _unless_ R is built with flang instead of gfortran.

For FreeBSD 11.1 R users, there are two workarounds [1].

1) Build the FreeBSD R package with the FLANG option instead of
   GFORTRAN.  FLANG may be the default soon.

2) Add


   to ~/.Rprofile with a newline after it.  Ensure ftp/wget is
   installed, because it is not pulled in by math/R.


[1] Both these workarounds prevent a predictable crash, but have only
been lightly tested.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 962 bytes
Desc: not available
URL: <https://stat.ethz.ch/pipermail/r-devel/attachments/20170801/ad211bef/attachment.sig>

More information about the R-devel mailing list