Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 21 Jun 2006 13:49:31 -0400 (EDT)
From:      Daniel Eischen <deischen@freebsd.org>
To:        Norikatsu Shigemura <nork@freebsd.org>
Cc:        Alexander Leidinger <Alexander@Leidinger.net>, freebsd-current@freebsd.org
Subject:   Re: Linux-flashplugin7 & rtld - RFC
Message-ID:  <Pine.GSO.4.64.0606211322560.23942@sea.ntplx.net>
In-Reply-To: <Pine.GSO.4.64.0606211204300.23942@sea.ntplx.net>
References:  <44986777.6070601@FreeBSD.org> <20060621061437.GA53019@fit.vutbr.cz> <ygeodwn2fea.wl%ume@mahoroba.org> <2265.211.18.249.19.1150871779.squirrel@mail.ninth-nine.com> <20060621121114.h6udocel5wsgg8sg@netchild.homeip.net> <2692.219.127.74.121.1150885501.squirrel@mail.ninth-nine.com> <20060621155053.d6lseiz8z4ow8wo8@netchild.homeip.net> <Pine.GSO.4.64.0606211204300.23942@sea.ntplx.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, 21 Jun 2006, Daniel Eischen wrote:

> On Wed, 21 Jun 2006, Alexander Leidinger wrote:
>
>> Did you tried to put this into a liblinux2bsd? The idea I had was to try if 
>> such a lib can be "attached" to e.g. linux flashplugin. Either with some 
>> objcopy (or similar) stuff, by trying to link again (with liblinux2bsd), or 
>> with libmap.conf. Another nice try is to have a program/script which does 
>> some known obj* stuff with object files, libs and/or programs. The examples 
>> I wanted to look at with this stuff are your linuxpluginwrapper, the 
>> linuxthreads port, my icc port and maybe the ifc port (it's basically an 
>> adoption of my icc port, but AFAIR there are some enhancements). All of 
>> them contain already some kind of mappings between linux and bsd. And maybe 
>> a combination of both ways (liblinux2bsd and a script which does obj* 
>> stuff) could lead to a successfull assimilation of some linux-only stuff.
>
> When I was playing around with trying to get linuxpluginwrapper to
> work, I had scripts that parsed the undefined symbols from
> flashplayer.so and automatically created a library with those
> symbols (that called out to our own libc functions).  It wasn't
> that hard to do, but I got side-tracked and never was able to
> get rtld to load the mapped library.

My latest attempt is here:

   http://people.freebsd.org/~deischen/lpw.tgz

It's based on the linuxpluginwrapper port from a few months
ago, so it's probably a little out of date.  But using it,
I can produce a flash7.so and acrobat.so with:

$ readelf -sW flash7.so | grep GLIBC
     23: 0000434b     0 FUNC    GLOBAL DEFAULT   11 getenv@GLIBC_2.0
     24: 000045df     0 FUNC    GLOBAL DEFAULT   11 strcpy@GLIBC_2.0
     25: 0000467b     0 FUNC    GLOBAL DEFAULT   11 write@GLIBC_2.0
     26: 00004303     0 FUNC    GLOBAL DEFAULT   11 free@GLIBC_2.0
     27: 000045c7     0 FUNC    GLOBAL DEFAULT   11 strchr@GLIBC_2.0
   [ ... ]
    613: 0000454f     0 FUNC    GLOBAL DEFAULT   11 select@GLIBC_2.0
    615: 000043ab     0 FUNC    GLOBAL DEFAULT   11 log@GLIBC_2.0
    616: 00000000     0 OBJECT  GLOBAL DEFAULT  ABS GLIBC_2.1.3
    619: 0000445f     0 FUNC    GLOBAL DEFAULT   11 printf@GLIBC_2.0
    620: 00004213     0 FUNC    GLOBAL DEFAULT   11 abort@GLIBC_2.0
    622: 00002250   114 FUNC    GLOBAL DEFAULT   11 __xstat@GLIBC_2.0
    624: 0000440b     0 FUNC    GLOBAL DEFAULT   11 mmap@GLIBC_2.0

$ readelf -sW acrobat.so | grep GLIBC
     23: 00003057     0 FUNC    GLOBAL DEFAULT   11 getenv@GLIBC_2.0
     24: 00003207     0 FUNC    GLOBAL DEFAULT   11 strcpy@GLIBC_2.0
     25: 000032eb     0 FUNC    GLOBAL DEFAULT   11 write@GLIBC_2.0
     26: 0000301b     0 FUNC    GLOBAL DEFAULT   11 free@GLIBC_2.0
     27: 000031e3     0 FUNC    GLOBAL DEFAULT   11 strchr@GLIBC_2.0
   [ ... ]
    465: 00002feb     0 FUNC    GLOBAL DEFAULT   11 fopen@GLIBC_2.1
    469: 00002b44   178 FUNC    GLOBAL DEFAULT   11 connect@GLIBC_2.0
    470: 00000000     0 OBJECT  GLOBAL DEFAULT  ABS GLIBC_2.1.3
    473: 00002f37     0 FUNC    GLOBAL DEFAULT   11 abort@GLIBC_2.0
    474: 00002e04   114 FUNC    GLOBAL DEFAULT   11 __xstat@GLIBC_2.0
    475: 00003063     0 FUNC    GLOBAL DEFAULT   11 getpwnam@GLIBC_2.0

-- 
DE



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.GSO.4.64.0606211322560.23942>