From: Andrey Rahmatullin <wrar@altlinux.ru>
To: bluez-devel@lists.sourceforge.net
Subject: Re: [Bluez-devel] [PATCH] bluez-gnome link fix
Date: Fri, 22 Dec 2006 00:55:30 +0500 [thread overview]
Message-ID: <20061221195530.GD18112@wrars-comp.wrarsdomain> (raw)
In-Reply-To: <1166729874.372.3.camel@violet>
[-- Attachment #1.1: Type: text/plain, Size: 2208 bytes --]
On Thu, Dec 21, 2006 at 08:37:54PM +0100, Marcel Holtmann wrote:
> I need a more detailed explanation on why your fix is correct, because I
> simply don't see it.
gcc -I/usr/include/dbus-1.0 -I/usr/lib/dbus-1.0/include -I/usr/include/glib-2.0
-I/usr/lib/glib-2.0/include -DDBUS_API_SUBJECT_TO_CHANGE
-I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0
-I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/glib-2.0
-I/usr/lib/glib-2.0/include -pipe -Wall -O2 -march=athlon -mtune=athlon-xp
-D_FORTIFY_SOURCE=2 -o bluetooth-sendto main.o -lgtk-x11-2.0 -lgdk-x11-2.0
-latk-1.0 -lgdk_pixbuf-2.0 -lm -lpangocairo-1.0 -lpango-1.0 -lcairo
-lgobject-2.0 -lgmodule-2.0 -ldl -lglib-2.0 -ldbus-glib-1 -ldbus-1 -lglib-2.0
../common/libcommon.a
../common/libcommon.a(manager.o): In function `update_adapter_list':
manager.c:(.text+0x26a): undefined reference to `dbus_g_proxy_call'
../common/libcommon.a(manager.o): In function `bluetooth_manager_init':
manager.c:(.text+0x306): undefined reference to `dbus_g_proxy_new_for_name'
manager.c:(.text+0x332): undefined reference to `dbus_g_proxy_add_signal'
manager.c:(.text+0x356): undefined reference to `dbus_g_proxy_connect_signal'
manager.c:(.text+0x376): undefined reference to `dbus_g_proxy_add_signal'
manager.c:(.text+0x39a): undefined reference to `dbus_g_proxy_connect_signal'
../common/libcommon.a(private.o): In function `bluetooth_get_connection':
private.c:(.text+0x2c): undefined reference to `dbus_g_bus_get'
collect2: ld returned 1 exit status
make[2]: *** [bluetooth-sendto] Error 1
If you use ld --as-needed (which is by default in some distributions), you
should write all -l options after, not before .o files (and .a file is
just a collection of .o) which use symbols from that -l libs, or they will
be ignored.
Note also that if -lfoo resolves to static lib, this behavior will be
always the same even without --as-needed.
Normally if you use autotools, all that you need to do is writing your
-lfoo to LDADD/LIBADD, not LDFLAGS. But if you link internal static libs
to your binaries, you still need to check the order of -l and .a .
--
WBR, wRAR (ALT Linux Team)
[-- Attachment #1.2: Digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]
[-- Attachment #2: Type: text/plain, Size: 347 bytes --]
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
[-- Attachment #3: Type: text/plain, Size: 164 bytes --]
_______________________________________________
Bluez-devel mailing list
Bluez-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-devel
prev parent reply other threads:[~2006-12-21 19:55 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-12-21 19:15 [Bluez-devel] [PATCH] bluez-gnome link fix Andrey Rahmatullin
2006-12-21 19:37 ` Marcel Holtmann
2006-12-21 19:55 ` Andrey Rahmatullin [this message]
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=20061221195530.GD18112@wrars-comp.wrarsdomain \
--to=wrar@altlinux.ru \
--cc=bluez-devel@lists.sourceforge.net \
/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
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.