develooper Front page | perl.perl5.porters | Postings from December 2013

Re: Option to use and create "unique" library names

Thread Previous | Thread Next
From:
Brian Fraser
Date:
December 3, 2013 00:05
Subject:
Re: Option to use and create "unique" library names
Message ID:
CA+nL+nZB7HSh+-m6VXrqHpyHWC=OmzF_DJdC7N3cZAovJAdTRw@mail.gmail.com
On Mon, Dec 2, 2013 at 8:46 AM, Irek Szczesniak <iszczesniak@gmail.com>wrote:

> On Wed, Nov 20, 2013 at 6:41 AM, Brian Fraser <fraserbn@gmail.com> wrote:
> > Background:
> > Android's linker has some bugg^Wunusual behavior, in that it caches
> loaded
> > libraries, but only uses the basename in the cache.  That means that,
> > as far as its dlopen() is concerned, the libraries for Hash::Util and
> > List::Util,
> > both of which are named Util.so, are the same.
> >
> > What we did in the android branch was introduce an option,
> d_libname_unique,
> > that when defined, has Makemaker create an "unique" libname for each
> module,
> > and teaches XSLoader and Dynaloader to look for those; So for example,
> > Hash/Util/Util.so becomes Hash/Util/Perl_Hash_Util.so.
> >
> > The changes for this are in
> >
> http://perl5.git.perl.org/perl.git/shortlog/refs/heads/hugmeir/d_libname_unique
> > and can be tested by compiling perl with -Dd_libname_unique.
> >
> > Any objections to this going in?
>
> Yes, I do have one. I think this should be fixed in Android and not be
> the burden of every damn platform or language to fix. There are more
> than perl which will stumble over this, and IMHO the Google staff who
> invented this should get the whips where it hurts.
>

*shrug*
Idealism won't get perl working. We already do the libname fixup for other
two platforms. We jump through a monstrous amount of hoops for most
platforms that we support. Why you think that drawing the line on this one
would be meaningful is beyond me.
Moreso, I'd rather have perl working on every version of Android out there
*now*, rather than sitting around, twiddling my thumbs until -- if ever --
google fixes bionic's linker.
But even that's useless. I can write an Android app using perl with this
workaround (...and some others). By your approach, I'd have to wait for one
hypothetical version that won't get any significant market share in at
least a couple of years.

Google already knows about the bug. You're free to nag them about it. In
fact, Android is open source, so you're free to file a patch.


>
> If we work around this issue for perl than Google is likely never
> fixing their broken linker.
>

What do you think this would accomplish? You'd be "telling" Google that a
language that they don't support and doesn't quite work on their system...
Still doesn't work?

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About