• 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: Should I be building a static or dynamic library?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Should I be building a static or dynamic library?


  • Subject: Re: Should I be building a static or dynamic library?
  • From: Nick Blievers <email@hidden>
  • Date: Sun, 12 Aug 2012 18:07:02 -0500
  • Acceptlanguage: en-US
  • Thread-topic: Should I be building a static or dynamic library?


On 13/08/2012, at 7:58 AM, Quincey Morris wrote:

On Aug 12, 2012, at 14:33 , Stephen Kay <email@hidden> wrote:

If this proprietary library is only to be used by the instance of my
application, and not shared with any other apps, then it should be a static
library?

I think the short answer is, "Yes".

If the library is not going to be shared with other apps, then I can't think of any generic reason for making it dynamic. There are probably a few specific use-cases for private dynamic libraries, but I think you would know if any of them applied here:

1. You had a reason for keeping the library code out of memory until/unless it was actually used.

2. You wanted to choose between alternate dynamic libraries at run-time.

3. You wanted to mess with symbol resolution before the library was loaded.

4. You wanted to share the library between the app and any plugin bundles.

(That sort of thing, etc. I can't say I've ever had to do any of these things.)

5. There is a conflicting license which doesn't allow static linking.



(ie LGPL).



 _______________________________________________
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

References: 
 >Re: Should I be building a static or dynamic library? (From: Stephen Kay <email@hidden>)
 >Re: Should I be building a static or dynamic library? (From: Quincey Morris <email@hidden>)

  • Prev by Date: Re: Should I be building a static or dynamic library?
  • Next by Date: Re: man pages
  • Previous by thread: Re: Should I be building a static or dynamic library?
  • Next by thread: Code Signing and custom installer
  • Index(es):
    • Date
    • Thread