From owner-freebsd-current@FreeBSD.ORG Sun Jul 2 13:54:16 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 7356F16A40F; Sun, 2 Jul 2006 13:54:16 +0000 (UTC) (envelope-from nork@FreeBSD.org) Received: from sakura.ninth-nine.com (sakura.ninth-nine.com [219.127.74.120]) by mx1.FreeBSD.org (Postfix) with ESMTP id A74F243D48; Sun, 2 Jul 2006 13:54:15 +0000 (GMT) (envelope-from nork@FreeBSD.org) Received: from nadesico.ninth-nine.com (nadesico.ninth-nine.com [219.127.74.122]) by sakura.ninth-nine.com (8.13.6/8.13.6/NinthNine) with ESMTP id k62DsBWu095155; Sun, 2 Jul 2006 22:54:12 +0900 (JST) (envelope-from nork@FreeBSD.org) Date: Sun, 2 Jul 2006 22:54:11 +0900 From: Norikatsu Shigemura To: Daniel Eischen Message-Id: <20060702225411.4bd0e2dd.nork@FreeBSD.org> In-Reply-To: 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> X-Mailer: Sylpheed version 2.2.6 (GTK+ 2.8.19; i386-portbld-freebsd7.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-2.0.2 (sakura.ninth-nine.com [219.127.74.121]); Sun, 02 Jul 2006 22:54:14 +0900 (JST) Cc: Alexander@Leidinger.net, current@FreeBSD.org, nork@FreeBSD.org, kabaev@gmail.com Subject: Re: Linux-flashplugin7 & rtld - RFC X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Jul 2006 13:54:16 -0000 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++ ~~~~