Skip to content
Back to formatted view

Raw Message

Message-ID: <22585.37964.185139.135703@max.nulle.part>
Date: 2016-11-26T13:55:24Z
From: Dirk Eddelbuettel
Subject: [Rcpp-devel] Large size of libs directory on some systems
In-Reply-To: <CAJvk7RbhvhO5Gb92=anXZ8UhDb=Zp5kiahBbu+A26rUwk9g27g@mail.gmail.com>

On 26 November 2016 at 12:22, Dean Bodenham wrote:
| Dear Dirk,?
| 
| Thank you very much for your detailed replies!?
| 
| The Ubuntu system does indeed seem to be using the -g flag. I did try a local
| compile/installation with the ~/.R/Makevars file you suggested, but couldn't
| quite get it to work - I get warnings "linking not done" for the .o files, and
| then an error that the "ffstream.so" file is not found.

Well "it worked me for" but a better approach entirely outside of your
package may be to take

  edd at max:~$ grep shared /etc/R/Makeconf 
  DYLIB_LDFLAGS = -shared -fopenmp# $(CFLAGS) $(CPICFLAGS)
  SHLIB_CXXLDFLAGS = -shared
  SHLIB_CXX1XLDFLAGS = -shared
  SHLIB_FCLDFLAGS = -shared
  SHLIB_LDFLAGS = -shared# $(CFLAGS) $(CPICFLAGS)
  edd at max:~$ 

and add them to ~/.R/Makevars as

  DYLIB_LDFLAGS = -shared -fopenmp# $(CFLAGS) $(CPICFLAGS)
  SHLIB_CXXLDFLAGS = -shared
  SHLIB_CXX1XLDFLAGS = -shared
  SHLIB_FCLDFLAGS = -shared
  SHLIB_LDFLAGS = -shared# $(CFLAGS) $(CPICFLAGS)

When I do that without/with the change I get

  edd at max:/tmp/ffstream$ ls -lh ffstream*/src/ffstream.so
  -rwxrwxr-x 1 edd edd 9.0M Nov 26 07:52 ffstream.orig/src/ffstream.so
  -rwxrwxr-x 1 edd edd 734K Nov 26 07:52 ffstream/src/ffstream.so
  edd at max:/tmp/ffstream$ 

I think it is an issue worth raising with on r-devel and I may do so.

Dirk

-- 
http://dirk.eddelbuettel.com | @eddelbuettel | edd at debian.org