Making dylibs on OS X painless
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.


    - Frameworkify

    What is this and why should I care?

      Ever used cmake to create an OS X application and you're linking
      against some library that is not installed globally?  Chances are
      you have stumbled upon an error like this:

        dyld: Library not loaded: /usr/local/lib/libSDL-1.3.0.dylib
          Referenced from: ./
            Reason: image not found
        Trace/BPT trap

      In short: this script fixes it.  How does it do that and why does
      this happen?  It happens because apparently on OS X the .dylib
      file provides at compilation time the path where that library
      will be found later.  However very often you want to ship that
      library in the bundle (in the Frameworks) folder instead of putting
      it at the location the library wants to reside normally.

      This script rewrites your application after compilation to look
      for libraries elsewhere (namely in the Frameworks) folder.
      Furthermore it will copy your library into the Frameworks folder so
      you don't have to.

    How do I use it?


      This will then rewrite the path in YourApp and copy the library
      into the Frameworks folder.  For more options see --help.

    How do I use it with CMake?

      This is from my setup:

        add_custom_command(TARGET YourApp POST_BUILD
          COMMAND python scripts/

      Where SDL_LIBRARY was found this way:

          NAMES SDL-1.3.0
          PATHS ${SDL_PATH}/lib