[flac-dev] How to change the dynamic library project name ogg to libogg?
LRN
lrn1986 at gmail.com
Tue Jun 6 19:39:31 UTC 2023
On 06.06.2023 22:33, Martijn van Beurden wrote:
> Hi,
>
> This rabbit hole went quite a bit deeper than I expected. Apparently,
> CMake prepends 'lib' to library names for unix like environments
> (including MinGW) but not for Visual Studio. So, when building on
> Windows, you get either libFLAC.dll and libogg.dll or FLAC.dll and
> ogg.dll depending on what toolchain you're using. I'm not quite sure
> whether this makes sense. I've tried quite a few ways to override this
> behaviour, but the most obvious solutions didn't work.
>
> Sorry, I've been trying various things for two hours today, I give up.
> Perhaps someone else on this list knows the answer.
>
set_target_properties(foobar PROPERTIES
SOVERSION ${SO_MAJOR_VERSION} VERSION ${SO_VERSION}
OUTPUT_NAME foobar
RUNTIME_OUTPUT_NAME foobar-${SO_MAJOR_VERSION}
ARCHIVE_OUTPUT_NAME foobar)
Something like that. This should produce libfoobar-X, where X is the
SO_MAJOR_VERSION value.
--
O< ascii ribbon - stop html email! - www.asciiribbon.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature
Type: application/pgp-signature
Size: 236 bytes
Desc: OpenPGP digital signature
URL: <http://lists.xiph.org/pipermail/flac-dev/attachments/20230606/78e96b08/attachment.sig>
More information about the flac-dev
mailing list