Re: [Rd] shared libraries: missing soname

2016-11-24 Thread Joseph Mingrone
Dirk,

Dirk Eddelbuettel  writes:
> You assume that change == breakage.  Yet that assumption is baseless.

> Which is what someone like Martin (R Core, and "at it" since the 80s pre-R
> and 90s with the almost very beginning of R) and myself (around R since the
> late 90s, somewhat involved since the early 00s) keep telling you.

> At some point it might appear to be approproiiate for you to actually take
> our word for it.

It is not that I am not taking your word.  There are some unique (to me)
approaches in R and some of them are subtle.  I am also taking criticism from
the other side, because, as I said, some conventions collide.  When Martin said,

> All these libraries "belong to R" and are tied to a specific version of R...

I understood that "tied to a specific version of R" meant that (Debian/FreeBSD)
R packages should be updated in lock step with R.  So, on Debian, changes in the
r-core package never necessitate a bump of r-cran-*?  In other words, the
libR.so interface is guaranteed to be stable across releases?

> | I also notice that on Debian you make a soft link of /usr/lib/R/lib/libR.so 
> to
> | /usr/lib/libR.so.  Given all that has been discussed, I am unclear why.

> Well noticed -- yet a stricly personaly reason via two projects I have been
> (co-)authoring: littler and RInside. They both "embed" R via libR and we do
> both rpath ("somewhat" verboten by Debian Policy as it hard codes a path,
> hence the alternate of placing it where ldd / ldconfig find it).

> But please note that that is _me_ doing this, and the R Core gospel we have
> been trying for you to understand still stand: __what you insist is needed
> actually is not__.

Understood.

> | Thank you for sticking with the thread,

> Sorry for coming through as pedantic but you (and we're now at what, six
> posts in and counting?)  still start from the wrong (at least outside of the
> gilded confines of FreeBSD) premise. It. Just. Works.

> Just give us and the unknown-but-sometimes-estimated-to-be-in-the-millions of
> R users some credit. What is there __works__. Seriously.  Debian folks are
> pendantic for technical excellence __and even they have no issue with
> per-package and local shared libraries__.  Which is what this is. Really.

Pedantic is fine.  I give credit!  I would not be investing my (comparatively
minuscule) time if I did not appreciate R.  I would also not be doing anyone a
service if I released a flawed FreeBSD package that did not do the project
justice.

Joseph


signature.asc
Description: PGP signature
__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel

Re: [Rd] shared libraries: missing soname

2016-11-24 Thread Dirk Eddelbuettel

On 24 November 2016 at 22:09, Joseph Mingrone wrote:
| For a frequently-updated Debian package repository, I assume you _manually_ 
bump
| all the Debian R packages whenever the main R package is upgraded.  Is that
| correct?  That is, when a Debian user upgrades the r-base package from, say,
| version 3.2.5 to 3.3.1, then r-cran-tseries must/should be rebuilt/reinstalled
| against the new R package?  If so, maybe there is something useful we could

You assume that change == breakage.  Yet that assumption is baseless.

Which is what someone like Martin (R Core, and "at it" since the 80s pre-R
and 90s with the almost very beginning of R) and myself (around R since the
late 90s, somewhat involved since the early 00s) keep telling you.

At some point it might appear to be approproiiate for you to actually take
our word for it.

| submit.  I will have to study how R uses autotools, because that also seems a
| bit different than I am used to.
| 
| I also notice that on Debian you make a soft link of /usr/lib/R/lib/libR.so to
| /usr/lib/libR.so.  Given all that has been discussed, I am unclear why.

Well noticed -- yet a stricly personaly reason via two projects I have been
(co-)authoring: littler and RInside. They both "embed" R via libR and we do
both rpath ("somewhat" verboten by Debian Policy as it hard codes a path,
hence the alternate of placing it where ldd / ldconfig find it).

But please note that that is _me_ doing this, and the R Core gospel we have
been trying for you to understand still stand: __what you insist is needed
actually is not__.

| Thank you for sticking with the thread,

Sorry for coming through as pedantic but you (and we're now at what, six
posts in and counting?)  still start from the wrong (at least outside of the
gilded confines of FreeBSD) premise. It. Just. Works.

Just give us and the unknown-but-sometimes-estimated-to-be-in-the-millions of
R users some credit. What is there __works__. Seriously.  Debian folks are
pendantic for technical excellence __and even they have no issue with
per-package and local shared libraries__.  Which is what this is. Really.

Dirk

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

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] shared libraries: missing soname

2016-11-24 Thread Joseph Mingrone
Martin Maechler  writes:
> Well, Dirk has said to have given his last reply on this thread.
> I (as a member of R-core) am glad about people like Dirk who
> take some of our load and helpfully answer such
> questions/reports on R-devel.

I am glad too.  Thank you.  My ultimate goal is to ensure that R works as well
on FreeBSD as it does elsewhere.  It mostly just works (again, appreciative),
but there are a few challenges because some R conventions and some FreeBSD
conventions may collide.

Dirk Eddelbuettel  writes:
> Consider eg this:

>   edd@max:~$ locate Matrix.so
>   /usr/lib/R/library/Matrix/libs/Matrix.so
>   /usr/local/lib/R/site-library/Matrix/libs/Matrix.so
>   /usr/local/lib/R-devel/lib/R/library/Matrix/libs/Matrix.so
>   edd@max:~$

> I have three versions of Matrix.so. And still not problem.  The third one
> only enters for R-devel, not R.  The first two are distinguished by R itself
> _by virtue of different paths_ just like Martin and I told you.

> And _no_ other program on my system knows about Matrix.so:

>   edd@max:~$ ldconfig -p | grep Matrix.so
>   edd@max:~$ ldconfig -p | wc -l
>   2814
>   edd@max:~$

> ldd / ldconfig do NOT know Matrix.so -- as I told you before -- despite the
> fact that they know thousands of other things on this (development) machine.

For a frequently-updated Debian package repository, I assume you _manually_ bump
all the Debian R packages whenever the main R package is upgraded.  Is that
correct?  That is, when a Debian user upgrades the r-base package from, say,
version 3.2.5 to 3.3.1, then r-cran-tseries must/should be rebuilt/reinstalled
against the new R package?  If so, maybe there is something useful we could
submit.  I will have to study how R uses autotools, because that also seems a
bit different than I am used to.

I also notice that on Debian you make a soft link of /usr/lib/R/lib/libR.so to
/usr/lib/libR.so.  Given all that has been discussed, I am unclear why.

Thank you for sticking with the thread,

Joseph


signature.asc
Description: PGP signature
__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel

Re: [Rd] shared libraries: missing soname

2016-11-23 Thread Dirk Eddelbuettel

On 22 November 2016 at 22:21, Joseph Mingrone wrote:
| Is this a more appropriate example?
| 
| # ldd /usr/local/lib/R/library/tseries/libs/tseries.so | grep libR
| libRblas.so => /usr/local/lib/R/lib/libRblas.so (0x80120c000)
| libR.so => /usr/local/lib/R/lib/libR.so (0x801c0)

No it is not.  Do you see the /usr/local/lib/R/lib here?

The trailing R/lib is what Martin and talk about. It means ldd / ldconfig
does not know about it -- if you do `ldconfig -p | grep libR` chances are you
see nothing.

On 23 November 2016 at 06:22, Joseph Mingrone wrote:
| Martin Maechler  writes:
| > To the issue:  I also don't see what your point is.
| > R works with these so libraries  as intended  in all cases as
| > far as we know, and so I don't understand why anything needs to
| > be changed.
| > All these libraries "belong to R" and are tied to a specific
| > version of R  and are not be used outside of R,  so I also don't see
| > your point.
| 
| "are not to be used outside of R".  You are distributing shared libraries that
| aren't meant to be shared (outside of R)?  But they are.  And I gave an 
example.

A wrong one though.
 
| I will just patch the FreeBSD port.

Please do.

You currently are the only one with an itch to scratch, and everybody else is
busy. If / when you have a patch which puts a token soname onto every shared
library produced [ internally ] by R feel free to offer it to R Core.

As Martin told you, so far there is no reason to take it but maybe that will
change. Or not. 

Consider eg this:

  edd@max:~$ locate Matrix.so
  /usr/lib/R/library/Matrix/libs/Matrix.so
  /usr/local/lib/R/site-library/Matrix/libs/Matrix.so
  /usr/local/lib/R-devel/lib/R/library/Matrix/libs/Matrix.so
  edd@max:~$

I have three versions of Matrix.so. And still not problem.  The third one
only enters for R-devel, not R.  The first two are distinguished by R itself
_by virtue of different paths_ just like Martin and I told you.

And _no_ other program on my system knows about Matrix.so:

  edd@max:~$ ldconfig -p | grep Matrix.so
  edd@max:~$ ldconfig -p | wc -l
  2814
  edd@max:~$

ldd / ldconfig do NOT know Matrix.so -- as I told you before -- despite the
fact that they know thousands of other things on this (development) machine.

All that you said or quoted about soname is fine and handy, and we all
respect it __for public libraries like libpng or libxml2.

R is different. So if FreeBSD has a problem with that you may indeed have to
work around that on the FreeBSD side of things.

Dirk

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

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] shared libraries: missing soname

2016-11-23 Thread Joseph Mingrone
Martin Maechler  writes:
> To the issue:  I also don't see what your point is.
> R works with these so libraries  as intended  in all cases as
> far as we know, and so I don't understand why anything needs to
> be changed.
> All these libraries "belong to R" and are tied to a specific
> version of R  and are not be used outside of R,  so I also don't see
> your point.

"are not to be used outside of R".  You are distributing shared libraries that
aren't meant to be shared (outside of R)?  But they are.  And I gave an example.

This is the first sentence of section 3.1.1 [1] of the Linux Documentation
Project's -Program Library HOWTO-, "Every shared library has a special name
called the 'soname'".  I'll ask again, since this was ignored the two previous
times I asked it (but I don't expect an answer).  Are there any constructive
reasons not to include a proper soname in the shared libraries?

I will just patch the FreeBSD port.

Joseph

[1] http://www.tldp.org/HOWTO/Program-Library-HOWTO/shared-libraries.html#AEN46


signature.asc
Description: PGP signature
__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel

Re: [Rd] shared libraries: missing soname

2016-11-23 Thread Martin Maechler
> Joseph Mingrone 
> on Tue, 22 Nov 2016 22:21:49 -0400 writes:

> Dirk Eddelbuettel  writes:
>> On 22 November 2016 at 00:02, Joseph Mingrone wrote:
>> | These are also not fatal errors on FreeBSD, where everything, for now, 
also just
>> | works.  ...until a library's interface changes.  You seem to be 
arguing that
>> | sonmaes are pointless.  We disagree.

>> You are putting words in my mouth. In my very first reply to you, I 
pointed
>> out that (for non-BSD systems at least) the sonames do not matter as R 
loads
>> the libraries itself, rather than via ldd.  No more, no less.

> Let me restate.  You seem to be arguing that, because R itself doesn't 
consume
> it's shared libraries via ldd(), sonames serve no purpose, in this case.  
Please
> correct me if I'm putting words in your mouth.

>> | I can't say for certain (I'm not an rkward user), but looking at the 
build

>> Why did _you_ then bring up rkward as an example? That was your 
suggestion.

> Because you asked, "Yes, well, but are there other customers?"  Also, I'm 
trying
> to put myself in the perspective of package users.

> Is this a more appropriate example?

> # ldd /usr/local/lib/R/library/tseries/libs/tseries.so | grep libR
> libRblas.so => /usr/local/lib/R/lib/libRblas.so (0x80120c000)
> libR.so => /usr/local/lib/R/lib/libR.so (0x801c0)

Well, Dirk has said to have given his last reply on this thread.
I (as a member of R-core) am glad about people like Dirk who
take some of our load and helpfully answer such
questions/reports on R-devel.

To the issue:  I also don't see what your point is.
R works with these so libraries  as intended  in all cases as
far as we know, and so I don't understand why anything needs to
be changed.
All these libraries "belong to R" and are tied to a specific
version of R  and are not be used outside of R,  so I also don't see
your point.

Best regards,

Martin Maechler
ETH Zurich

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] shared libraries: missing soname

2016-11-22 Thread Joseph Mingrone
Dirk Eddelbuettel  writes:

> On 22 November 2016 at 00:02, Joseph Mingrone wrote:
> | These are also not fatal errors on FreeBSD, where everything, for now, also 
> just
> | works.  ...until a library's interface changes.  You seem to be arguing that
> | sonmaes are pointless.  We disagree.

> You are putting words in my mouth. In my very first reply to you, I pointed
> out that (for non-BSD systems at least) the sonames do not matter as R loads
> the libraries itself, rather than via ldd.  No more, no less.

Let me restate.  You seem to be arguing that, because R itself doesn't consume
it's shared libraries via ldd(), sonames serve no purpose, in this case.  Please
correct me if I'm putting words in your mouth.

> | I can't say for certain (I'm not an rkward user), but looking at the build

> Why did _you_ then bring up rkward as an example? That was your suggestion.

Because you asked, "Yes, well, but are there other customers?"  Also, I'm trying
to put myself in the perspective of package users.

Is this a more appropriate example?

# ldd /usr/local/lib/R/library/tseries/libs/tseries.so | grep libR
libRblas.so => /usr/local/lib/R/lib/libRblas.so (0x80120c000)
libR.so => /usr/local/lib/R/lib/libR.so (0x801c0)


signature.asc
Description: PGP signature
__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel

Re: [Rd] shared libraries: missing soname

2016-11-21 Thread Dirk Eddelbuettel

Joseph,

I will try to let this be my last message in this thread.  Just to clarify:

On 22 November 2016 at 00:02, Joseph Mingrone wrote:
| These are also not fatal errors on FreeBSD, where everything, for now, also 
just
| works.  ...until a library's interface changes.  You seem to be arguing that
| sonmaes are pointless.  We disagree.

You are putting words in my mouth. In my very first reply to you, I pointed
out that (for non-BSD systems at least) the sonames do not matter as R loads
the libraries itself, rather than via ldd.  No more, no less.

Just like just about everybody else, I believe strongly in common use of
sonames _for normal libraries_. R, however, uses dynamic loading of _its
extension modules_ outside of the system use and has its own system of
dependency management and versioning.

| I can't say for certain (I'm not an rkward user), but looking at the build

Why did _you_ then bring up rkward as an example? That was your suggestion.

| log, it seems to.  Do you have R built as a shared library?

Yes, always.
 
| Here are select lines from rkward's build log:

I am not sure what point you are trying to make.


Please consider myself withdrawn from this discussion.

Thank you,  Dirk

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

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] shared libraries: missing soname

2016-11-21 Thread Joseph Mingrone
Dirk,

Dirk Eddelbuettel  writes:
> On 21 November 2016 at 23:24, Joseph Mingrone wrote:
> | Dirk Eddelbuettel  writes:
> | > On 20 November 2016 at 21:49, Joseph Mingrone wrote:
> | > | Hello Dirk,
> | > | 
> | > | Dirk Eddelbuettel  writes:
> | > | 
> | > | > On 20 November 2016 at 19:28, Joseph Mingrone wrote:
> | > | > | Hello,
> | > | > | 
> | > | > | R's shared libraries are linked without setting the soname.  This 
> is causing problems for some consumers.
> | > | > | 
> | > | > | Error: /usr/local/lib/R/library/tseries/libs/tseries.so is 
> linked to
> | > | > | /usr/local/lib/R/lib/libRblas.so which does not have a 
> SONAME.  math/R needs
> | > | > | to be fixed.
> | > | > | 
> | > | > | What's the correct way to add the necessary linker flags?  I 
> believe it should be something like this.
> | > | > | 
> | > | > |cc -shared -Wl,-soname,...
> | > | 
> | > | > I think that may be true "in theory" (for libraries loaded by ldd(8) 
> via
> | > | > `/etc/ld.conf`) but not "in practice" for R which loads these shared
> | > | > libraries itself (via dlopen(3) etc).
> | > | 
> | > | R may use dlopen() but other customers may not.
> | 
> | > Yes, well, but are there other customers?
> | 
> | Yes.  Here is one example. https://rkward.kde.org/

> Really?  We had that eg in Debian too for a decade plus and it works just
> fine _as is_ and finds its libraries. Without requiring a change.

These are also not fatal errors on FreeBSD, where everything, for now, also just
works.  ...until a library's interface changes.  You seem to be arguing that
sonmaes are pointless.  We disagree.

> It (AFAIK) just embeds R "as is" (as does my much smaller RInside).

>   edd@bud:~$ ldd /usr/bin/rkward | grep R  # no R libs known to ldd
>   edd@bud:~$ ldd /usr/bin/rkward | wc -l   # lots other shared libraries
>   40
>   edd@bud:~$

I can't say for certain (I'm not an rkward user), but looking at the build
log, it seems to.  Do you have R built as a shared library?

Here are select lines from rkward's build log:

...
-- Checking for existence of R shared library
-- Exists at /usr/local/lib/R/lib/libR.so
-- Checking whether we should link against Rlapack library
-- Yes, /usr/local/lib/R/lib/libRlapack.so exists
-- Checking whether we should link against Rblas library
...
...
/usr/bin/c++   -O2 -pipe -I/usr/local/include -fstack-protector 
-fno-strict-aliasing -Wnon-virtual-dtor -Wno-long-long -Wundef -Wcast-align 
-Wchar-subscripts -Wall -W -Wpointer-arith -Wformat-security 
-Woverloaded-virtual -fno-common -fvisibility=hidden -Werror=return-type 
-fvisibility-inlines-hidden -Wno-return-type-c-linkage -O2 -DNDEBUG 
-DQT_NO_DEBUG   -Wl,-rpath=/usr/local/lib/gcc48  -L/usr/local/lib/gcc48 
-B/usr/local/bin -fstack-protector CMakeFiles/rkward.rbackend.dir/rkrbackend.o 
CMakeFiles/rkward.rbackend.dir/rksignalsupport.o 
CMakeFiles/rkward.rbackend.dir/rklocalesupport.o 
CMakeFiles/rkward.rbackend.dir/rkrsupport.o 
CMakeFiles/rkward.rbackend.dir/rkstructuregetter.o 
CMakeFiles/rkward.rbackend.dir/rkrbackendprotocol_backend.o 
CMakeFiles/rkward.rbackend.dir/rkreventloop.o 
CMakeFiles/rkward.rbackend.dir/rkrbackendprotocol_shared.o 
CMakeFiles/rkward.rbackend.dir/rdata.o 
CMakeFiles/rkward.rbackend.dir/rkbackendtransmitter.o 
CMakeFiles/rkward.rbackend.dir/rktransmitter.o  -o rkward.rbackend  
-L/usr/local/lib  -L/usr/local/lib/R/lib  
-L/wrkdirs/usr/ports/math/rkward-kde4/work/rkward-0.6.5/lib  
-L/usr/local/lib/qt4  ../../lib/librkgraphicsdevice.backend.a -lR -lRlapack 
-lRblas -pthread /usr/local/lib/qt4/libQtNetwork.so 
/usr/local/lib/qt4/libQtCore.so -pthread /usr/local/lib/libintl.so 
-Wl,-rpath,/usr/local/lib:/usr/local/lib/R/lib:/usr/local/lib/qt4:
...

> | > | > For what it is worth, I have been providing the Debian packages "as 
> is" for
> | > | > now 15+ years and nobody has complained. 
> | > | 
> | > | > What system are you on to get that complaint?
> | > | 
> | > | This is on FreeBSD.  Our apt-get, pkg, will not register shared library 
> dependencies if the shared library does not have a soname.  If the library
> | > | gets changed and is no longer compatible with the previous version, and 
> there is no soname to check, pkg will not know that all its dependencies
> | > | need to be reinstalled.
> | 
> | > Hmpf. No mechanism for fallback / default soname?  In that case you (or
> | > whoever acts as FreeBSD maintainer) may have to supply one.
> | 
> | Using a fallback or default soname would defeat the purpose, which is to 
> detect
> | when the library's interface has changed, so that the proper action can be
> | taken.  I could provide a local patch for R's autotools, but as a package
> | maintainer yourself, I expect you also prefer when upstream get's it right.
> | 
> | Are there any constructive reasons not to include a proper soname?


signature.asc
Description: PGP signature
__

Re: [Rd] shared libraries: missing soname

2016-11-21 Thread Dirk Eddelbuettel

On 21 November 2016 at 23:24, Joseph Mingrone wrote:
| Dirk Eddelbuettel  writes:
| > On 20 November 2016 at 21:49, Joseph Mingrone wrote:
| > | Hello Dirk,
| > | 
| > | Dirk Eddelbuettel  writes:
| > | 
| > | > On 20 November 2016 at 19:28, Joseph Mingrone wrote:
| > | > | Hello,
| > | > | 
| > | > | R's shared libraries are linked without setting the soname.  This is 
causing problems for some consumers.
| > | > | 
| > | > | Error: /usr/local/lib/R/library/tseries/libs/tseries.so is 
linked to
| > | > | /usr/local/lib/R/lib/libRblas.so which does not have a 
SONAME.  math/R needs
| > | > | to be fixed.
| > | > | 
| > | > | What's the correct way to add the necessary linker flags?  I believe 
it should be something like this.
| > | > | 
| > | > |cc -shared -Wl,-soname,...
| > | 
| > | > I think that may be true "in theory" (for libraries loaded by ldd(8) via
| > | > `/etc/ld.conf`) but not "in practice" for R which loads these shared
| > | > libraries itself (via dlopen(3) etc).
| > | 
| > | R may use dlopen() but other customers may not.
| 
| > Yes, well, but are there other customers?
| 
| Yes.  Here is one example. https://rkward.kde.org/

Really?  We had that eg in Debian too for a decade plus and it works just
fine _as is_ and finds its libraries. Without requiring a change.

It (AFAIK) just embeds R "as is" (as does my much smaller RInside).

  edd@bud:~$ ldd /usr/bin/rkward | grep R  # no R libs known to ldd
  edd@bud:~$ ldd /usr/bin/rkward | wc -l   # lots other shared libraries
  40
  edd@bud:~$ 
 
| > | > For what it is worth, I have been providing the Debian packages "as is" 
for
| > | > now 15+ years and nobody has complained. 
| > | 
| > | > What system are you on to get that complaint?
| > | 
| > | This is on FreeBSD.  Our apt-get, pkg, will not register shared library 
dependencies if the shared library does not have a soname.  If the library
| > | gets changed and is no longer compatible with the previous version, and 
there is no soname to check, pkg will not know that all its dependencies
| > | need to be reinstalled.
| 
| > Hmpf. No mechanism for fallback / default soname?  In that case you (or
| > whoever acts as FreeBSD maintainer) may have to supply one.
| 
| Using a fallback or default soname would defeat the purpose, which is to 
detect
| when the library's interface has changed, so that the proper action can be
| taken.  I could provide a local patch for R's autotools, but as a package
| maintainer yourself, I expect you also prefer when upstream get's it right.
| 
| Are there any constructive reasons not to include a proper soname?

I fear you are complaining to the wrong person. I am not a committer; just a
happy user, packager, and contributor. But as my first email tried to state:
nobody here seems to see a problem yet.

Best of luck,  Dirk

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

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] shared libraries: missing soname

2016-11-21 Thread Joseph Mingrone
Dirk,

Dirk Eddelbuettel  writes:
> On 20 November 2016 at 21:49, Joseph Mingrone wrote:
> | Hello Dirk,
> | 
> | Dirk Eddelbuettel  writes:
> | 
> | > On 20 November 2016 at 19:28, Joseph Mingrone wrote:
> | > | Hello,
> | > | 
> | > | R's shared libraries are linked without setting the soname.  This is 
> causing problems for some consumers.
> | > | 
> | > | Error: /usr/local/lib/R/library/tseries/libs/tseries.so is 
> linked to
> | > | /usr/local/lib/R/lib/libRblas.so which does not have a SONAME.  
> math/R needs
> | > | to be fixed.
> | > | 
> | > | What's the correct way to add the necessary linker flags?  I believe it 
> should be something like this.
> | > | 
> | > |cc -shared -Wl,-soname,...
> | 
> | > I think that may be true "in theory" (for libraries loaded by ldd(8) via
> | > `/etc/ld.conf`) but not "in practice" for R which loads these shared
> | > libraries itself (via dlopen(3) etc).
> | 
> | R may use dlopen() but other customers may not.

> Yes, well, but are there other customers?

Yes.  Here is one example. https://rkward.kde.org/

> | > For what it is worth, I have been providing the Debian packages "as is" 
> for
> | > now 15+ years and nobody has complained. 
> | 
> | > What system are you on to get that complaint?
> | 
> | This is on FreeBSD.  Our apt-get, pkg, will not register shared library 
> dependencies if the shared library does not have a soname.  If the library
> | gets changed and is no longer compatible with the previous version, and 
> there is no soname to check, pkg will not know that all its dependencies
> | need to be reinstalled.

> Hmpf. No mechanism for fallback / default soname?  In that case you (or
> whoever acts as FreeBSD maintainer) may have to supply one.

Using a fallback or default soname would defeat the purpose, which is to detect
when the library's interface has changed, so that the proper action can be
taken.  I could provide a local patch for R's autotools, but as a package
maintainer yourself, I expect you also prefer when upstream get's it right.

Are there any constructive reasons not to include a proper soname?

Regards,

Joseph


signature.asc
Description: PGP signature
__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel

Re: [Rd] shared libraries: missing soname

2016-11-20 Thread Dirk Eddelbuettel

On 20 November 2016 at 21:49, Joseph Mingrone wrote:
| Hello Dirk,
| 
| Dirk Eddelbuettel  writes:
| 
| > On 20 November 2016 at 19:28, Joseph Mingrone wrote:
| > | Hello,
| > | 
| > | R's shared libraries are linked without setting the soname.  This is 
causing problems for some consumers.
| > | 
| > | Error: /usr/local/lib/R/library/tseries/libs/tseries.so is linked 
to
| > | /usr/local/lib/R/lib/libRblas.so which does not have a SONAME.  
math/R needs
| > | to be fixed.
| > | 
| > | What's the correct way to add the necessary linker flags?  I believe it 
should be something like this.
| > | 
| > |cc -shared -Wl,-soname,...
| 
| > I think that may be true "in theory" (for libraries loaded by ldd(8) via
| > `/etc/ld.conf`) but not "in practice" for R which loads these shared
| > libraries itself (via dlopen(3) etc).
| 
| R may use dlopen() but other customers may not.

Yes, well, but are there other customers?
 
| > For what it is worth, I have been providing the Debian packages "as is" for
| > now 15+ years and nobody has complained. 
| 
| > What system are you on to get that complaint?
| 
| This is on FreeBSD.  Our apt-get, pkg, will not register shared library 
dependencies if the shared library does not have a soname.  If the library gets 
changed and is no longer compatible with the previous version, and there is no 
soname to check, pkg will not know that all its dependencies need to be 
reinstalled.

Hmpf. No mechanism for fallback / default soname?  In that case you (or
whoever acts as FreeBSD maintainer) may have to supply one.

Dirk

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

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] shared libraries: missing soname

2016-11-20 Thread Joseph Mingrone
Hello Dirk,

Dirk Eddelbuettel  writes:

> On 20 November 2016 at 19:28, Joseph Mingrone wrote:
> | Hello,
> | 
> | R's shared libraries are linked without setting the soname.  This is 
> causing problems for some consumers.
> | 
> | Error: /usr/local/lib/R/library/tseries/libs/tseries.so is linked to
> | /usr/local/lib/R/lib/libRblas.so which does not have a SONAME.  
> math/R needs
> | to be fixed.
> | 
> | What's the correct way to add the necessary linker flags?  I believe it 
> should be something like this.
> | 
> |cc -shared -Wl,-soname,...

> I think that may be true "in theory" (for libraries loaded by ldd(8) via
> `/etc/ld.conf`) but not "in practice" for R which loads these shared
> libraries itself (via dlopen(3) etc).

R may use dlopen() but other customers may not.

> For what it is worth, I have been providing the Debian packages "as is" for
> now 15+ years and nobody has complained. 

> What system are you on to get that complaint?

This is on FreeBSD.  Our apt-get, pkg, will not register shared library 
dependencies if the shared library does not have a soname.  If the library gets 
changed and is no longer compatible with the previous version, and there is no 
soname to check, pkg will not know that all its dependencies need to be 
reinstalled.

Regards,

Joseph


signature.asc
Description: PGP signature
__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel

Re: [Rd] shared libraries: missing soname

2016-11-20 Thread Dirk Eddelbuettel

On 20 November 2016 at 19:28, Joseph Mingrone wrote:
| Hello,
| 
| R's shared libraries are linked without setting the soname.  This is causing 
problems for some consumers.
| 
| Error: /usr/local/lib/R/library/tseries/libs/tseries.so is linked to
| /usr/local/lib/R/lib/libRblas.so which does not have a SONAME.  
math/R needs
| to be fixed.
| 
| What's the correct way to add the necessary linker flags?  I believe it 
should be something like this.
| 
|cc -shared -Wl,-soname,...

I think that may be true "in theory" (for libraries loaded by ldd(8) via
`/etc/ld.conf`) but not "in practice" for R which loads these shared
libraries itself (via dlopen(3) etc).

For what it is worth, I have been providing the Debian packages "as is" for
now 15+ years and nobody has complained. 

What system are you on to get that complaint?

Dirk

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

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


[Rd] shared libraries: missing soname

2016-11-20 Thread Joseph Mingrone
Hello,

R's shared libraries are linked without setting the soname.  This is causing 
problems for some consumers.

Error: /usr/local/lib/R/library/tseries/libs/tseries.so is linked to
/usr/local/lib/R/lib/libRblas.so which does not have a SONAME.  math/R 
needs
to be fixed.

What's the correct way to add the necessary linker flags?  I believe it should 
be something like this.

   cc -shared -Wl,-soname,...

Regards,

Joseph


signature.asc
Description: PGP signature
__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel