From owner-freebsd-current@FreeBSD.ORG Mon Jul 3 04:16:57 2006 Return-Path: X-Original-To: current@freebsd.org Delivered-To: freebsd-current@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7269716A403; Mon, 3 Jul 2006 04:16:57 +0000 (UTC) (envelope-from deischen@freebsd.org) Received: from mail.ntplx.net (mail.ntplx.net [204.213.176.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id ECBDE43D46; Mon, 3 Jul 2006 04:16:56 +0000 (GMT) (envelope-from deischen@freebsd.org) Received: from sea.ntplx.net (sea.ntplx.net [204.213.176.11]) by mail.ntplx.net (8.13.6/8.13.6/NETPLEX) with ESMTP id k634GtJA028957; Mon, 3 Jul 2006 00:16:55 -0400 (EDT) Date: Mon, 3 Jul 2006 00:16:55 -0400 (EDT) From: Daniel Eischen X-X-Sender: eischen@sea.ntplx.net To: Norikatsu Shigemura In-Reply-To: <20060702225411.4bd0e2dd.nork@FreeBSD.org> Message-ID: References: <44986777.6070601@FreeBSD.org> <20060621061437.GA53019@fit.vutbr.cz> <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> <20060623013106.d4397e26.nork@FreeBSD.org> <20060622230416.3907a848@kan.dnsalias.net> <20060625191405.d0e78240.nork@FreeBSD.org> <20060702225411.4bd0e2dd.nork@FreeBSD.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Virus-Scanned: by AMaViS and Clam AntiVirus (mail.ntplx.net) Cc: Alexander@Leidinger.net, kabaev@gmail.com, current@freebsd.org Subject: Re: Linux-flashplugin7 & rtld - RFC X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Daniel Eischen List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Jul 2006 04:16:57 -0000 On Sun, 2 Jul 2006, Norikatsu Shigemura wrote: > On Mon, 26 Jun 2006 15:06:33 -0400 (EDT) > Daniel Eischen wrote: >> The check for the object providing the correct version should >> still be done, but it needs to be checking the correct (libmap'd) >> object. > > Eureka!!! > > I understand why my approch should be integrated to libc/libm/ > libpthread, and deischen's approch failuer. So I can sperate > library from libc/libm/libpthread. > > deischen's LPW: > $ readelf -Ws flash7.so | fgrep open > 71: 00001760 54 FUNC LOCAL DEFAULT 11 popen > 110: 000025e0 54 FUNC LOCAL DEFAULT 11 iconv_open > 185: 00001520 54 FUNC LOCAL DEFAULT 11 fopen > 198: 000016e0 54 FUNC LOCAL DEFAULT 11 opendir > These are bad. > > $ readelf -Ws flash7.so | fgrep pthread_ > : > 27: 00000000 117 FUNC GLOBAL DEFAULT UND _pthread_mutex_init@LIBTHREAD_1_0 (13) > : > 70: 00000f80 94 FUNC LOCAL DEFAULT 11 pthread_mutex_init@GLIBC_2.0 > : > These are good. > > So it should be fixed like following: > flash7.so: flash7.map ${FLASH7OBJ} > ${CC} -shared -o $@ ${CFLAGS} ${FLASH7OBJ} \ > -Wl,--version-script=flash7.map -lc -lm -lpthread -lstdc++ > ~~~~ Yes, I tried that also, but I couldn't get it to work. -- DE