ALT Linux Team development discussions
 help / color / mirror / Atom feed
From: "Kirill A. Shutemov" <kirill@shutemov.name>
To: ALT Linux Team development discussions <devel@lists.altlinux.org>
Subject: Re: [devel] linkage_problems abiword unjoined
Date: Tue, 13 Jul 2010 13:37:31 +0300
Message-ID: <20100713103731.GB31562@shutemov.name> (raw)
In-Reply-To: <20100713080706.GP23050@altlinux.org>

On Tue, Jul 13, 2010 at 12:07:06PM +0400, Alexey Tourbin wrote:
> On Tue, Jul 13, 2010 at 12:19:14AM +0400, Alexey Tourbin wrote:
> > Ну вот например показывает что libabiword-2.8 недолинкован с libX11.
> >
> > [at@people at]$ fgrep libabiword-2.8 unjoined
> > abiword /usr/lib64/libabiword-2.8.so    U       XFreeModifiermap
> > abiword /usr/lib64/libabiword-2.8.so    U       XGetModifierMapping
> > abiword /usr/lib64/libabiword-2.8.so    U       XKeycodeToKeysym
> > abiword /usr/lib64/libabiword-2.8.so    U       XKeysymToKeycode
> > abiword /usr/lib64/libabiword-2.8.so    U       XParseGeometry
> > abiword-light   /usr/lib64/libabiword-2.8.so    U       XFreeModifiermap
> > abiword-light   /usr/lib64/libabiword-2.8.so    U	XGetModifierMapping
> > abiword-light   /usr/lib64/libabiword-2.8.so    U       XKeycodeToKeysym
> > abiword-light   /usr/lib64/libabiword-2.8.so    U       XKeysymToKeycode
> > abiword-light   /usr/lib64/libabiword-2.8.so    U       XParseGeometry
> > [at@people at]$ rpm -qpR /ALT/Sisyphus/files/x86_64/RPMS/abiword-2.8.4-alt1.x86_64.rpm |grep libX
> > [at@people at]$
> >
> > Как могло получиться, что abiword недолинкован с libX11?
> > У нас же и в binutils подержка есть "подцепить недостающие библиотеки",
> > и pkg-config для линковки рекурсивно раскрывает список Libs.
> 
> В ld/bfd что-то не так работает.

Хм... Похоже логика --as-needed работает до --copy-dt-needed-entries.
Это странно.

Пример:

$ cat 1.c
#include <stdlib.h>
#include <X11/Xlib.h>

int main(int argc, char **argv)
{
        XFreeModifiermap(NULL);
        return 0;
}
$ objdump -p /usr/lib/libgtk-x11-2.0.so | grep NEEDED
  NEEDED               libgdk_pixbuf-2.0.so.0
  NEEDED               libgdk-x11-2.0.so.0
  NEEDED               libpangocairo-1.0.so.0
  NEEDED               libX11.so.6
  NEEDED               libXfixes.so.3
  NEEDED               libatk-1.0.so.0
  NEEDED               libcairo.so.2
  NEEDED               libgio-2.0.so.0
  NEEDED               libpangoft2-1.0.so.0
  NEEDED               libpango-1.0.so.0
  NEEDED               libfontconfig.so.1
  NEEDED               libgobject-2.0.so.0
  NEEDED               libgmodule-2.0.so.0
  NEEDED               libglib-2.0.so.0
  NEEDED               libm.so.6
  NEEDED               libpthread.so.0
  NEEDED               libc.so.6
$ gcc 1.c -lgtk-x11-2.0
/usr/src/tmp/cc80cbEj.o: In function `main':
1.c:(.text+0x11): undefined reference to `XFreeModifiermap'
collect2: ld returned 1 exit status
$ gcc 1.c -Wl,--no-as-needed -lgtk-x11-2.0
$ objdump -p |grep NEEDED
  NEEDED               libgtk-x11-2.0.so.0
  NEEDED               libc.so.6
  NEEDED               libX11.so.6

-- 
 Kirill A. Shutemov


  parent reply	other threads:[~2010-07-13 10:37 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-10 23:43   ` [devel] Fwd: hylafax-5.2.7-alt5: Sisyphus/i586 test rebuild failed Led
2010-07-11  6:40     ` Денис Смирнов
2010-07-11  8:33       ` Dmitry V. Levin
2010-07-11  9:26         ` [devel] Q: second class packages in Sisyphus Dmitry V. Levin
2010-07-11 15:07           ` Michael Shigorin
2010-07-11 19:08             ` Yuri N. Sedunov
2010-07-12  5:14           ` Денис Смирнов
2010-07-12 16:47             ` Dmitry V. Levin
2010-07-12 16:54           ` Alexey Tourbin
2010-07-12 16:59             ` Dmitry V. Levin
2010-07-12 19:17               ` Alexey Tourbin
2010-07-12 20:19                 ` [devel] linkage_problems abiword unjoined Alexey Tourbin
2010-07-13  8:07                   ` Alexey Tourbin
2010-07-13  9:37                     ` Alexey Tourbin
2010-07-13 10:05                       ` Dmitry V. Levin
2010-07-13 10:37                     ` Kirill A. Shutemov [this message]
2010-07-12 22:10                 ` [devel] unjoined g_free Alexey Tourbin
2010-07-12 23:50                   ` Dmitry V. Levin
2010-07-15  8:01                   ` [devel] [cross] " Ildar Mulyukov
2010-07-12  5:17         ` [devel] Fwd: hylafax-5.2.7-alt5: Sisyphus/i586 test rebuild failed Денис Смирнов

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20100713103731.GB31562@shutemov.name \
    --to=kirill@shutemov.name \
    --cc=devel@lists.altlinux.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

ALT Linux Team development discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/devel/0 devel/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 devel devel/ http://lore.altlinux.org/devel \
		devel@altlinux.org devel@altlinux.ru devel@lists.altlinux.org devel@lists.altlinux.ru devel@linux.iplabs.ru mandrake-russian@linuxteam.iplabs.ru sisyphus@linuxteam.iplabs.ru
	public-inbox-index devel

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.devel


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git