Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 55402 - net-wirless/libbtctl-0.4.1 works on amd64
Summary: net-wirless/libbtctl-0.4.1 works on amd64
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: AMD64 Linux
: High enhancement
Assignee: AMD64 Project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 55401
  Show dependency tree
 
Reported: 2004-06-28 03:02 UTC by Max Nickel
Modified: 2005-01-23 12:29 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Max Nickel 2004-06-28 03:02:37 UTC
Please add "~amd64" to the KEYWORDS for net-wireless/libbtctl-0.4.1

Reproducible: Always
Steps to Reproduce:
1.
2.
3.




Portage 2.0.50-r8 (default-amd64-2004.0, gcc-3.3.3, glibc-2.3.4.20040605-r0,
2.6.7-gentoo-r5)
=================================================================
System uname: 2.6.7-gentoo-r5 x86_64 4
Gentoo Base System version 1.4.16
Autoconf: sys-devel/autoconf-2.59-r4
Automake: sys-devel/automake-1.8.5-r1
ACCEPT_KEYWORDS="amd64 ~amd64"
AUTOCLEAN="yes"
CFLAGS="-O2 -pipe -ftracer"
CHOST="x86_64-pc-linux-gnu"
COMPILER="gcc3"
CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config
/usr/kde/3/share/config /usr/lib/mozilla/defaults/pref /usr/share/config
/var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2 -pipe -ftracer"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs ccache cvs sandbox"
GENTOO_MIRRORS="http://gentoo.oregonstate.edu
http://distro.ibiblio.org/pub/Linux/distributions/gentoo"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage/bmg-overlay
/usr/local/portage/bmg-gnome-current"
SYNC="rsync://tokyo/gentoo"
USE="X acpi alsa amd64 avi berkdb bluetooth cdr crypt cups dvd encode esd evo
foomaticdb gdbm gif gnome gpm gtk gtk2 imap imlib ipv6 irmc jpeg ldap libg++
libwww mikmod motif mozilla moznocompose moznoirc moznomail mpeg multilib
ncurses nls nntp nogcj nowin nptl oggvorbis opengl oss pam pdflib perl png ppds
python quicktime readline ruby scanner sdl slang spell ssl tcpd truetype usb
xine xml2 xmms xv xvid zlib"
Comment 1 Jelle Kalf 2004-07-03 07:46:44 UTC
building libbttcl-0.4.1 fails on ~amd64 gcc 3.3.3 and gcc 3.4.0

----------------------------------------------------
/bin/sh ../libtool --mode=link gcc  -O2   -o libbtctl.la -rpath /usr/lib -version-info 1:1:0 -lgobject-2.0 -lglib-2.0   -L/usr/lib -lbluetooth -lopenobex btctl.lo btctlimpl.lo btctl-marshal.lo bthelper.lo btctl-discovery-source.lo obex-server-source.lo btobex.lo obexsdp.lo obex-client-source.lo btobex-client.lo  
gcc -shared  .libs/btctl.o .libs/btctlimpl.o .libs/btctl-marshal.o .libs/bthelper.o .libs/btctl-discovery-source.o .libs/obex-server-source.o .libs/btobex.o .libs/obexsdp.o .libs/obex-client-source.o .libs/btobex-client.o -Wl,--whole-archive /usr/lib/libopenobex.a -Wl,--no-whole-archive  /usr/lib/libgobject-2.0.so /usr/lib/libglib-2.0.so -L/usr/lib /usr/lib/libbluetooth.so  -Wl,-soname -Wl,libbtctl.so.1 -o .libs/libbtctl.so.1.0.1
/usr/lib/gcc-lib/x86_64-pc-linux-gnu/3.3.3/../../../../x86_64-pc-linux-gnu/bin/ld: /usr/lib/libopenobex.a(obex_main.o): relocation R_X86_64_32S can not be used when making a shared object; recompile with -fPIC
/usr/lib/libopenobex.a(obex_main.o): could not read symbols: Bad value
collect2: ld returned 1 exit status
make[3]: *** [libbtctl.la] Error 1
make[3]: Leaving directory `/var/tmp/portage/libbtctl-0.4.1/work/libbtctl-0.4.1/src'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/var/tmp/portage/libbtctl-0.4.1/work/libbtctl-0.4.1/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/var/tmp/portage/libbtctl-0.4.1/work/libbtctl-0.4.1'
make: *** [all] Error 2

!!! ERROR: net-wireless/libbtctl-0.4.1 failed.
!!! Function gnome2_src_compile, Line 39, Exitcode 2
!!! compile failure
------------------------------------------------------
Comment 2 Jelle Kalf 2004-07-03 08:06:46 UTC
Solution (workarround) as following.

In order to get libbtctl to compile correctly when having the emulation libraries installed on your machines you need to have dev-libs/openobex compiled with -fPIC

little hint I got from another bug:

if [ "${ARCH}" = "x86_64" ]; then
  append-flags -fPIC
fi

the original just check for it != x86, but it's drastic to demand that on all platforms besides x86.

Do remember that -fPIC is NOT neccessary for libbtctl !
Comment 3 Danny van Dyk (RETIRED) gentoo-dev 2004-07-03 09:22:33 UTC
Reassigning to maintainer:

The packages libtool tries to build shared library from static library objects.
This is a bug in the libtool version that gets shipped. libtoolize doesnt solve
this problem !

Best solution is IMHO: sed -i -e "s/libext=\"a/& la/" libtool

This needs to be done directly after ./configure. Please reassign to amd64 when you're done so we can keyword. 
Comment 4 Danny van Dyk (RETIRED) gentoo-dev 2004-07-03 09:23:32 UTC
Dammit, forgot to reassign :-/ Please read above comment.
Comment 5 Alastair Tse (RETIRED) gentoo-dev 2004-07-03 11:05:59 UTC
so is this openobex that needs that hack or libbtctl?
Comment 6 Danny van Dyk (RETIRED) gentoo-dev 2004-07-05 11:07:16 UTC
This is a bug in net-wireless/libbtctl. You simply can't link objects to a static library and state the linker flag "-shared". Libtool doesn't recognize the ".la" extension properly. As i already stated, best solution IMHO:

sed -i -e "s/libext=\"a/& la/" libtool
Comment 7 Alastair Tse (RETIRED) gentoo-dev 2004-07-20 16:11:15 UTC
thanks .. i've committed the changes now, over to you guys.
Comment 8 Daniel Ahlberg (RETIRED) gentoo-dev 2004-09-05 07:23:09 UTC
Closing bug.
Comment 9 Daniel Ahlberg (RETIRED) gentoo-dev 2004-09-05 07:25:53 UTC
Ebuild hasn't ~amd64 (yet)
Comment 10 Malcolm Lashley (RETIRED) gentoo-dev 2004-10-05 15:45:47 UTC
I need to *remove* the patch for 55400 (openobex shared object patch...) in order to get libbtctl to compile... I think this is due to the subsequently added gnu_config_update in the openobex ebuild causing it to build correct shared libraries as libopenobex-1.0.so.1.0.0 with libopenobex.so as a symlink to it... the existing openobex ebuild in cvs installs a libopenobex.so - which is NOT a symlink, and contains unresolved symbols... need to doublecheck with Danny/Kugelfang that there are no other other adverse effects of removing the patch in 55400 - everything seems to build and work just fine.
Comment 11 Kfir Ozer 2005-01-10 10:32:10 UTC
hiya.. i get a different problem while trying to compile it:
x86_64-pc-linux-gnu-gcc -march=k8 -O3 -pipe -o .libs/btlist btlist.o  ./.libs/libbtctl.so -L//usr/lib /usr/lib/libgobject-2.0.so /usr/lib/libglib-2.0.so -L/usr/lib //usr/lib/libbluetooth.so //usr/lib/libopenobex.so -Wl,--rpath -Wl,//usr/lib
//usr/lib/libopenobex.so: undefined reference to `g_netbuf_realloc'
//usr/lib/libopenobex.so: undefined reference to `g_netbuf_tailroom'
//usr/lib/libopenobex.so: undefined reference to `g_netbuf_free'
//usr/lib/libopenobex.so: undefined reference to `g_netbuf_push'
//usr/lib/libopenobex.so: undefined reference to `g_netbuf_pull'
//usr/lib/libopenobex.so: undefined reference to `slist_append'
//usr/lib/libopenobex.so: undefined reference to `g_netbuf_put'
//usr/lib/libopenobex.so: undefined reference to `slist_remove'
//usr/lib/libopenobex.so: undefined reference to `g_netbuf_new'
//usr/lib/libopenobex.so: undefined reference to `g_netbuf_put_data'
//usr/lib/libopenobex.so: undefined reference to `g_netbuf_reserve'
//usr/lib/libopenobex.so: undefined reference to `g_netbuf_recycle'
collect2: ld returned 1 exit status
make[3]: *** [btlist] Error 1
--------------
Portage 2.0.51-r8 (default-linux/amd64/2004.3, gcc-3.4.3, glibc-2.3.4.20041102-r0, 2.6.9-gentoo-r12 x86_64)
=================================================================
System uname: 2.6.9-gentoo-r12 x86_64 AMD Athlon(tm) 64 Processor 3000+
Gentoo Base System version 1.6.8
Python:              dev-lang/python-2.3.4 [2.3.4 (#1, Jan  6 2005, 22:22:31)]
dev-lang/python:     2.3.4
sys-devel/autoconf:  2.59-r6, 2.13
sys-devel/automake:  1.8.5-r2, 1.5, 1.4_p6, 1.6.3, 1.7.9, 1.9.3
sys-devel/binutils:  2.15.92.0.2-r2
sys-devel/libtool:   1.5.10-r2
virtual/os-headers:  2.6.8.1-r2
ACCEPT_KEYWORDS="amd64 ~amd64"
AUTOCLEAN="yes"
CFLAGS="-march=k8 -O3 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/lib/X11/xkb /usr/lib/mozilla/defaults/pref /usr/share/config /usr/share/texmf/dvipdfm/config/ /usr/share/texmf/dvips/config/ /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/ /usr/share/texmf/xdvi/ /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-march=k8 -O3 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs autoconfig ccache distcc distlocks keeptemp keepwork sandbox"
GENTOO_MIRRORS="ftp://mirror.nutsmaas.nl/gentoo/ ftp://mir.zyrianes.net/gentoo/ http://mir.zyrianes.net/gentoo/"
LDFLAGS=""
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY=""
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="amd64 X Xaw3d aalib alsa apache2 apm audiofile avi bash-completion berkdb bidi bitmap-fonts bzlib cdr crypt cups directfb divx4linux emul-linux-x86 encode esd f77 fam fastcgi fbcon flac font-server foomaticdb fortran ftp gd gdbm gif gmp gnome gphoto2 gpm gstreamer gtk gtk2 icq imagemagick imap imlib ipv6 java jikes joystick jp2 jpeg ldap lesstif libwww lzw lzw-tiff mad mbox mime mozilla mpeg msn multilib mysql mysqli ncurses nls oggvorbis openal opengl oscar oss pam perl php png pnp python qt quicktime readline samba sasl scanner sdl slang sndfile snmp ssl tcltk tcpd tetex tiff truetype truetype-fonts type1-fonts unicode usb userlocales videos xine xinerama xml xml2 xpm xrandr xv xvid zlib"
--------------

thanks!
Comment 12 Simon Stelling (RETIRED) gentoo-dev 2005-01-23 12:29:42 UTC
-r1 also fails