1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<TITLE> [Mageia-dev] linkingerror with gtk+ 2: missing X11 dep ?
</TITLE>
<LINK REL="Index" HREF="index.html" >
<LINK REL="made" HREF="mailto:mageia-dev%40mageia.org?Subject=Re%3A%20%5BMageia-dev%5D%20linkingerror%20with%20gtk%2B%202%3A%20missing%20X11%20dep%20%3F&In-Reply-To=%3CCA%2BCX%2BbjMKtrqoRwDGgyKjKOWYc5p6qj7wmvpxbQcxYYrQhQu3g%40mail.gmail.com%3E">
<META NAME="robots" CONTENT="index,nofollow">
<META http-equiv="Content-Type" content="text/html; charset=us-ascii">
<LINK REL="Previous" HREF="020903.html">
<LINK REL="Next" HREF="020904.html">
</HEAD>
<BODY BGCOLOR="#ffffff">
<H1>[Mageia-dev] linkingerror with gtk+ 2: missing X11 dep ?</H1>
<B>Pascal Terjan</B>
<A HREF="mailto:mageia-dev%40mageia.org?Subject=Re%3A%20%5BMageia-dev%5D%20linkingerror%20with%20gtk%2B%202%3A%20missing%20X11%20dep%20%3F&In-Reply-To=%3CCA%2BCX%2BbjMKtrqoRwDGgyKjKOWYc5p6qj7wmvpxbQcxYYrQhQu3g%40mail.gmail.com%3E"
TITLE="[Mageia-dev] linkingerror with gtk+ 2: missing X11 dep ?">pterjan at gmail.com
</A><BR>
<I>Mon Dec 24 13:42:45 CET 2012</I>
<P><UL>
<LI>Previous message: <A HREF="020903.html">[Mageia-dev] linkingerror with gtk+ 2: missing X11 dep ?
</A></li>
<LI>Next message: <A HREF="020904.html">[Mageia-dev] Rebuild failed on i586 for @334667:drakx-installer-stage2-15.15-1.mga3.src.rpm
</A></li>
<LI> <B>Messages sorted by:</B>
<a href="date.html#20905">[ date ]</a>
<a href="thread.html#20905">[ thread ]</a>
<a href="subject.html#20905">[ subject ]</a>
<a href="author.html#20905">[ author ]</a>
</LI>
</UL>
<HR>
<!--beginarticle-->
<PRE>On Mon, Dec 24, 2012 at 10:49 AM, Guillaume Rousse
<<A HREF="https://www.mageia.org/mailman/listinfo/mageia-dev">guillomovitch at gmail.com</A>> wrote:
><i> g++ -O2 -g -pipe -Wformat -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2
</I>><i> -fstack-protector --param=ssp-buffer-size=4 -fPIC -pthread -D_REENTRANT
</I>><i> -I/usr/include/gtk-2.0 -I/usr/lib64/gtk-2.0/include -I/usr/include/atk-1.0
</I>><i> -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0
</I>><i> -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include
</I>><i> -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/directfb
</I>><i> -I/usr/include/libpng15 -I/usr/include/libdrm -I/usr/include/harfbuzz
</I>><i> -I/usr/include/gconf/2 -I/usr/include/dbus-1.0 -I/usr/lib64/dbus-1.0/include
</I>><i> -Wl,--as-needed -Wl,--no-undefined -Wl,-z,relro -Wl,-O1 -Wl,--build-id
</I>><i> -Wl,--enable-new-dtags -o cryptkeeper encfs_wrapper.o ConfigDialog.o
</I>><i> ImportStashWizard.o CreateStashWizard.o PasswordChangeDialog.o main.o
</I>><i> gtkstatusicon.o gtktrayicon-x11.o PasswordEntryDialog.o lsof.o
</I>><i> -Wl,--export-dynamic -pthread -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0
</I>><i> -lgio-2.0 -lgmodule-2.0 -lrt -lpangoft2-1.0 -lpangocairo-1.0
</I>><i> -lgdk_pixbuf-2.0 -lcairo -lpango-1.0 -lfreetype -lfontconfig -lgobject-2.0
</I>><i> -lgconf-2 -lglib-2.0
</I>><i> /usr/bin/ld: gtktrayicon-x11.o: undefined reference to symbol
</I>><i> 'XUngrabServer'
</I>><i> /usr/bin/ld: note: 'XUngrabServer' is defined in DSO /lib64/libX11.so.6 so
</I>><i> try adding it to the linker command line
</I>><i> /lib64/libX11.so.6: could not read symbols: Invalid operation
</I>><i>
</I>><i> I fixed it in the package directly (cryptkeeper). However, shouldn't rather
</I>><i> gtk+-2.0 directly refers -lX11 instead ?
</I>
No it shouldn't, when using gtk you are not supposed to use anything X
specific directly, else your app will not work with another backend
than X.
In this case it seems the app is using X directly (outside of its use
of Gtk) so it should link to X11 itself.
><i> [<A HREF="https://www.mageia.org/mailman/listinfo/mageia-dev">guillaume at beria</A> cryptkeeper]$ pkg-config --libs gtk+-2.0
</I>><i> -Wl,--export-dynamic -pthread -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0
</I>><i> -lgio-2.0 -lgmodule-2.0 -lrt -lpangoft2-1.0 -lpangocairo-1.0
</I>><i> -lgdk_pixbuf-2.0 -lcairo -lpango-1.0 -lfreetype -lfontconfig -lgobject-2.0
</I>><i> -lglib-2.0
</I></PRE>
<!--endarticle-->
<HR>
<P><UL>
<!--threads-->
<LI>Previous message: <A HREF="020903.html">[Mageia-dev] linkingerror with gtk+ 2: missing X11 dep ?
</A></li>
<LI>Next message: <A HREF="020904.html">[Mageia-dev] Rebuild failed on i586 for @334667:drakx-installer-stage2-15.15-1.mga3.src.rpm
</A></li>
<LI> <B>Messages sorted by:</B>
<a href="date.html#20905">[ date ]</a>
<a href="thread.html#20905">[ thread ]</a>
<a href="subject.html#20905">[ subject ]</a>
<a href="author.html#20905">[ author ]</a>
</LI>
</UL>
<hr>
<a href="https://www.mageia.org/mailman/listinfo/mageia-dev">More information about the Mageia-dev
mailing list</a><br>
</body></html>
|