• 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
Re: linking to a static lib and *not* a dynamic lib when both are present
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: linking to a static lib and *not* a dynamic lib when both are present


  • Subject: Re: linking to a static lib and *not* a dynamic lib when both are present
  • From: "Mark Wagner" <email@hidden>
  • Date: Wed, 19 Mar 2008 13:02:24 -0700

On 3/19/08, Tyler Daniel <email@hidden> wrote:
> Hi all,
>
>  So I'm hoping someone can tell me that my problems linking to static
>  libs late last night really were, as I hope, only nightmares.
>
>  As silly as it sounds, I can't find any way to tell Xcode (2.5 or 3.0)
>  to link to the *static* version of a library.  I even suspect that all
>  library references are passed to gcc indiscriminately with "-l" options.
>  This behavior surprised me after I very carefully dragged the .a
>  version of the library and *not* the .so into Xcode.  The reference is
>  even named libsomething.a.  Hmm.
>
>  Of course, Google offered this piece of advice:
>
>  http://developer.apple.com/qa/qa2006/qa1393.html
>
>  What's this?  apple.com was hacked by a script kiddie with a *very*
>  subtle sense of humor?  A forgotten April Fool's joke, perhaps?
>
>  In short, somebody say it ain't so!

As far as I'm aware, there are three ways to link to a static library
rather than a dynamic one:
1) Specify the library to the linker by full name and path.  Since
Xcode is a sort-of-GUI application, this isn't easy.
2) Rename the static library to something unique.
3) Delete the dynamic library.

--
Mark Wagner
 _______________________________________________
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: linking to a static lib and *not* a dynamic lib when both are present
      • From: Tyler Daniel <email@hidden>
References: 
 >linking to a static lib and *not* a dynamic lib when both are present (From: Tyler Daniel <email@hidden>)

  • Prev by Date: Xcode 3.0 - Uncaught Exception: error during SQL execution
  • Next by Date: IB 3.0 and tab order
  • Previous by thread: linking to a static lib and *not* a dynamic lib when both are present
  • Next by thread: Re: linking to a static lib and *not* a dynamic lib when both are present
  • Index(es):
    • Date
    • Thread