[jira] [Commented] (AVRO-2063) C: VERSION, SOVERSION not set correctly for shared library

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (AVRO-2063) C: VERSION, SOVERSION not set correctly for shared library

JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/AVRO-2063?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16115015#comment-16115015 ]

Robert Edmonds commented on AVRO-2063:
--------------------------------------

Here's the patch I've applied downstream for the Debian package: https://anonscm.debian.org/cgit/collab-maint/avro-c.git/commit/?id=f29dae6e2b93be52d72d19b0061935bf8ba9c7b4.

When the unpatched 1.8.2 release is built and installed, it results in this symlink and SONAME:

{code}
edmonds@chase{0}:/usr/local/stow/avro-c-1.8.2/lib$ ls -l libavro.so*
lrwxrwxrwx 1 root staff   17 Jul 28 15:41 libavro.so -> libavro.so.23.0.0
-rw-r--r-- 1 root staff 1.1M Jul 28 15:41 libavro.so.23.0.0
edmonds@chase{0}:/usr/local/stow/avro-c-1.8.2/lib$ objdump -p libavro.so | grep SONAME
  SONAME               libavro.so.23.0.0
edmonds@chase{0}:/usr/local/stow/avro-c-1.8.2/lib$
{code}

When 1.8.2 with the patch linked above is built and installed, it results in this symlink chain and SONAME:

{code}
edmonds@chase{0}:/usr/lib/x86_64-linux-gnu$ ls -l libavro.so*
lrwxrwxrwx 1 root root   13 Aug  4 17:15 libavro.so -> libavro.so.23
lrwxrwxrwx 1 root root   17 Aug  4 17:15 libavro.so.23 -> libavro.so.23.0.0
-rw-r--r-- 1 root root 234K Aug  4 17:15 libavro.so.23.0.0
edmonds@chase{0}:/usr/lib/x86_64-linux-gnu$ objdump -p libavro.so | grep SONAME
  SONAME               libavro.so.23
edmonds@chase{0}:/usr/lib/x86_64-linux-gnu$
{code}

> C: VERSION, SOVERSION not set correctly for shared library
> ----------------------------------------------------------
>
>                 Key: AVRO-2063
>                 URL: https://issues.apache.org/jira/browse/AVRO-2063
>             Project: Avro
>          Issue Type: Bug
>          Components: c
>    Affects Versions: 1.8.2
>            Reporter: Robert Edmonds
>            Priority: Minor
>
> Hi,
> I'm attempting to package avro-c for Debian. While doing so, I noticed that the libavro.so symlink that gets installed points directly to the libavro.so.23.0.0 library file, without an intermediate "libavro.so.23" symlink, and that the SONAME embedded in the library file is set to "libavro.so.23.0.0", rather than "libavro.so.23", which is what I would expect for a library trying to follow the libtool-style current/revision/age scheme on Linux systems.
> It looks like the recommended way to get CMake to produce the typical symlink chain and SONAME is to set the VERSION property to "23.0.0" and the SOVERSION to 23 on the shared library target. See this article for details: http://pusling.com/blog/?p=352.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)
Loading...