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
60 stars 50 forks source link

Can build tests on macOS without installed libzzip #121

Closed catap closed 2 years ago

catap commented 2 years ago

Test building is fails with error like:

dyld: Library not loaded: /opt/local/lib/libzzip.13.dylib
  Referenced from: /opt/local/var/macports/build/_Users_catap_src_macports-ports_archivers_libzzip/libzzip/work/build/test/./zzipsetstub
  Reason: image not found
/bin/sh: line 1: 16514 Abort trap: 6           ./zzipsetstub test/zzipshowme zzipself

As soon as I install it, tests are build and can be run.

gdraheim commented 2 years ago

I can not help with that as there seem to be specific features of the dynamic-load mechanism involved. I know that some older platforms had the rpath fixed needing to relink binaries upon installation.

catap commented 2 years ago

@gdraheim ok, I'll make patch for it.

catap commented 2 years ago

Long story short: it isn't a bug.

I've used macports to build and macports added for all cmake's build CMAKE_BUILD_WITH_INSTALL_RPATH and CMAKE_INSTALL_RPATH which creates this issue.