• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
How to properly add libraries
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

How to properly add libraries


  • Subject: How to properly add libraries
  • From: Kelvin Chung <email@hidden>
  • Date: Fri, 09 Dec 2011 21:30:51 -0500

I'm having trouble getting my program to run in XCode.  My project relies on a few boost libraries that use automatic linking (boost::thread, etc).  Suppose that the path to the boost libs is "~/Downloads/boost/lib".  If I add that to the library search path, then the build fails.  If I go into "Link Binary With Libraries" in "Build Phases" and add the specific libs required (libboost_system.a and libboost_thread.a) from the lib directory, the code compiles, but crashes on running.  GDB gives these warnings:

warning: Unable to read symbols for libboost_system.dylib (file not found).
warning: Unable to read symbols from "libboost_system.dylib" (not yet mapped into memory).
warning: Unable to read symbols for libboost_thread.dylib (file not found).
warning: Unable to read symbols from "libboost_thread.dylib" (not yet mapped into memory).

Then it crashes with this:

dyld: Library not loaded: libboost_system.dylib
 Referenced from: (path redacted)
 Reason: image not found

The .dylibs are found in the same place as the .a files, so they definitely exist.  What am I doing wrong? _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: How to properly add libraries
      • From: Andreas Grosam <email@hidden>
    • Re: How to properly add libraries
      • From: Jonny Yu <email@hidden>
  • Prev by Date: Re: Clean command fail
  • Next by Date: Re: Clean command fail
  • Previous by thread: Re: Generating CoreData accessors Xc4?
  • Next by thread: Re: How to properly add libraries
  • Index(es):
    • Date
    • Thread