gdraheim / zziplib

The ZZIPlib provides read access on ZIP-archives and unpacked data. It features an additional simplified API following the standard Posix API for file access
Other
62 stars 50 forks source link

zzip/CMakeLists.txt: fix for macOS #96

Closed veprbl closed 3 years ago

veprbl commented 4 years ago

We've noticed that on macOS the library symlinks were not creating. Turns out, the condition https://github.com/gdraheim/zziplib/blob/c3de4fe291ab6756593a0ef6bad007ddd3953e00/zzip/CMakeLists.txt#L302 was silently failing for us. This happens because the names of the libraries are generated differently for apple, we get libzzip-0.13.0.71.dylib when the code in zziplib expects libzzip-0.dylib.13.0.71.

https://gitlab.kitware.com/cmake/cmake/-/blob/742ff97f809410055b22405a6b5728e72c458683/Source/cmGeneratorTarget.cxx#L5890-5903

Also a related thread: https://cmake.org/pipermail/cmake/2013-February/053605.html

cc @jtojnar

jtojnar commented 4 years ago

Weird, I would expect the symlinks to be created automatically by setting VERSION

https://cmake.org/cmake/help/latest/command/install.html?highlight=symlink#installing-targets