How to distribute ImageMagick libraries in a Mac App bundle

Questions and postings pertaining to the development of ImageMagick, feature enhancements, and ImageMagick internals. ImageMagick source code and algorithms are discussed here. Usage questions which are too arcane for the normal user list should also be posted here.
Post Reply
sztepen
Posts: 1
Joined: 2017-10-04T05:01:34-07:00
Authentication code: 1151

How to distribute ImageMagick libraries in a Mac App bundle

Post by sztepen » 2017-10-04T05:08:11-07:00

I am trying to distribute ImageMagick (C++) with my Mac app.

I tried building the binaries using MacPorts as well as directly from source with CMake.

The resultant .dylib pathnames (as seen with otools -L) are absolute and relate to specific local folders, such as "opt/local" or "usr/local".

This makes the app crash on end-user's computer.

I would like to set the dylib pathnames to @rpath or @executable_path so that I can ship the dylibs within the bundle, and the app itslef can find them using default search paths.

Currently I am lost, tried to change the CMake config parameters, to no avail.

Post Reply