Bug 146353 - can't link programs with libopenobex.so
can't link programs with libopenobex.so
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: openobex (Show other bugs)
4
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Harald Hoyer
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2005-01-27 07:42 EST by Sergey Khvatov
Modified: 2007-11-30 17:10 EST (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2005-09-27 08:34:44 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Test program (731 bytes, text/plain)
2005-01-27 07:44 EST, Sergey Khvatov
no flags Details
patch which fixes broken `obex.sym' file... (385 bytes, patch)
2005-02-09 12:23 EST, Dmitry Butskoy
no flags Details | Diff

  None (edit)
Description Sergey Khvatov 2005-01-27 07:42:31 EST
Description of problem: 
 
No program can be linked with libopenobex.so. Some symbols from this 
library appeared undefined. Linking with static library is still 
possible.  
 
Version-Release number of selected component (if applicable): 
 
openobex-1.0.1-1 
 
How reproducible: 
 
Allways 
 
Steps to Reproduce: 
1. Compile and link the attached test  
   
Actual results: 
 
[xbatob@sagittarius oob]$ cc obexserver.c -lopenobex 
/tmp/ccN0zkLf.o(.text+0x6f): In function `main': 
: undefined reference to `btobex_accept' 
collect2: ld returned 1 exit status 
[xbatob@sagittarius oob]$ cc obexserver.c -static -lopenobex 
[xbatob@sagittarius oob]$  
 
Expected results: 
 
no errors both case 
 
Additional info: 
 
I had downloaded source archive from openobex.sourceforge.net, 
make rpm from it (the tarball contains valid spec file) and had it 
installed. Everything works OK
Comment 1 Sergey Khvatov 2005-01-27 07:44:42 EST
Created attachment 110289 [details]
Test program

This program useless but valid.
Comment 2 Harald Hoyer 2005-01-27 08:22:31 EST
only symbols from openobex-1.0.1/src/obex.sym should be exported as
the rule in openobex-1.0.1/src/Makefile.am states:
libopenobex_la_LDFLAGS = \
        -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \
        -release $(LT_RELEASE) \
        -export-symbols $(top_srcdir)/src/obex.sym

This means, that the libtool in the tar.gz and the libtool we use to
build the package differ in this case.

This may be a bug in our libtool or the libtool openobex packages.
I don't know, but obex.sym does not seem to include bt_accept and this
was never needed by other packages which used openobex.
Comment 3 Sergey Khvatov 2005-01-27 08:58:14 EST
Yes this symbol seems to be unneeded, but my program calls 
OBEX_ServerAccept which also doesn't exported. 
Comment 4 Dmitry Butskoy 2005-02-09 12:22:02 EST
  The program `obexftp' (tool to access mobile phone "disks" by
ftp-like way) need `OBEX_ServerAccept' symbol for successful linkage.
IMHO, may be this symbol only is missing in `obex.sym'...
Comment 5 Dmitry Butskoy 2005-02-09 12:23:42 EST
Created attachment 110882 [details]
patch which fixes broken `obex.sym' file...

  `obexftp' build is OK after it.
Comment 6 Harald Hoyer 2005-05-02 11:53:09 EDT
added OBEX_ServerAccept
Comment 7 Dmitry Butskoy 2005-05-11 09:26:30 EDT
 Cannot find updated package in rawhide.
 The old package (1.0.1-3, without changes) still exist in rawhide and FC3test3 ...
Comment 8 Bastien Nocera 2005-09-13 19:48:55 EDT
Reopening, the problem is still current with FC4.
Comment 9 Bastien Nocera 2005-09-13 19:51:29 EDT
$ strings /usr/lib/libopenobex.so | grep OBEX_ServerAccept
$ rpm -q openobex
openobex-1.0.1-3

And trying to compile obexftp:
/home/hadess/src/obexftp-0.10.7/apps/obexftpd.c:119: undefined reference to
`OBEX_ServerAccept'
collect2: ld returned 1 exit status
make: *** [obexftpd] Error 1
Comment 10 Bastien Nocera 2005-09-13 19:58:28 EDT
This was committed, but looks like it wasn't built for FC3 or FC4:
https://www.redhat.com/archives/fedora-cvs-commits/2005-May/msg00025.html

an rpmbuild --rebuild of the following package can fix it for the impatient:
http://download.fedora.redhat.com/pub/fedora/linux/core/development/SRPMS/openobex-1.0.1-4.src.rpm
Comment 11 Harald Hoyer 2005-09-14 04:33:21 EDT
openobex-1.0.1-3.0.FC4.1 will soon appear in the testing channel...

Note You need to log in before you can comment on or make changes to this bug.