shared library versioning on OS X

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

shared library versioning on OS X

Bruce Stephens
By the looks of it setting the SOVERSION when generating a SHARED library creates the symbolic link, but it doesn't seem to use the -current_version or -compatibility_version flags when linking.

Those flags are set as variables CMAKE_C_OSX_CURRENT_VERSION_FLAG and CMAKE_C_OSX_COMPATIBILITY_VERSION_FLAG (and similar for other languages) but those don't seem to be used.

Is that deliberate?


--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake
Reply | Threaded
Open this post in threaded view
|

Re: shared library versioning on OS X

Clinton Stimpson
Perhaps this bug report fits what you are seeing.  Are you seeing this limitation in the ninja generator?

https://cmake.org/Bug/view.php?id=14140

Clint

On Feb 20, 2016 11:49 AM, Bruce Stephens <[hidden email]> wrote:
>
> By the looks of it setting the SOVERSION when generating a SHARED library creates the symbolic link, but it doesn't seem to use the -current_version or -compatibility_version flags when linking.
>
> Those flags are set as variables CMAKE_C_OSX_CURRENT_VERSION_FLAG and CMAKE_C_OSX_COMPATIBILITY_VERSION_FLAG (and similar for other languages) but those don't seem to be used.
>
> Is that deliberate?
>
--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake
Reply | Threaded
Open this post in threaded view
|

Re: shared library versioning on OS X

Bruce Stephens
Ah, yes. That looks like exactly the bug, thanks.

So it's a straight bug in the ninja generator, not something deliberate that I was just failing to understand. And with the Unix Makefile generator the compatibility version is set (presumably the current version would be set if I used VERSION).

On Sat, Feb 20, 2016 at 6:59 PM, <[hidden email]> wrote:
Perhaps this bug report fits what you are seeing.  Are you seeing this limitation in the ninja generator?

https://cmake.org/Bug/view.php?id=14140

Clint

On Feb 20, 2016 11:49 AM, Bruce Stephens <[hidden email]> wrote:
>
> By the looks of it setting the SOVERSION when generating a SHARED library creates the symbolic link, but it doesn't seem to use the -current_version or -compatibility_version flags when linking.
>
> Those flags are set as variables CMAKE_C_OSX_CURRENT_VERSION_FLAG and CMAKE_C_OSX_COMPATIBILITY_VERSION_FLAG (and similar for other languages) but those don't seem to be used.
>
> Is that deliberate?
>


--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake
Reply | Threaded
Open this post in threaded view
|

Re: shared library versioning on OS X

Bruce Stephens
In case anyone cares, I think https://github.com/brucestephens/CMake contains a quick fix.

On Sat, Feb 20, 2016 at 7:17 PM, Bruce Stephens <[hidden email]> wrote:
Ah, yes. That looks like exactly the bug, thanks.

So it's a straight bug in the ninja generator, not something deliberate that I was just failing to understand. And with the Unix Makefile generator the compatibility version is set (presumably the current version would be set if I used VERSION).

On Sat, Feb 20, 2016 at 6:59 PM, <[hidden email]> wrote:
Perhaps this bug report fits what you are seeing.  Are you seeing this limitation in the ninja generator?

https://cmake.org/Bug/view.php?id=14140

Clint

On Feb 20, 2016 11:49 AM, Bruce Stephens <[hidden email]> wrote:
>
> By the looks of it setting the SOVERSION when generating a SHARED library creates the symbolic link, but it doesn't seem to use the -current_version or -compatibility_version flags when linking.
>
> Those flags are set as variables CMAKE_C_OSX_CURRENT_VERSION_FLAG and CMAKE_C_OSX_COMPATIBILITY_VERSION_FLAG (and similar for other languages) but those don't seem to be used.
>
> Is that deliberate?
>



--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake