title: Prevent duplicate symbols when building static library with Cocoapods
body: <p>While I've seen many questions dealing with Cocoapods and static libraries, most of them seem to assume you'll eventually have a single workspace with your static library and end target app.</p>
  
  <p>In my scenario, I am building a static library. More specifically, I'm hacking a MyLib.framework for users to consume. I'd <strong>really</strong> like to manage MyLib.framework's dependencies with Cocoapods, but it creates many pain points when consumers of my library <em>also</em> use Cocoapods.</p>
  
  <p>For example, my library has an AFNetworking dependency which I manage with Cocoapods. When I build my library, it links in libPods.a which includes AFNetworking, as well as some "dummy" files/objects. If users of my framework also use Cocoapods to build <em>their</em> app, they'll see something like this:</p>
  
  <pre><code>duplicate symbol _OBJC_METACLASS_$_PodsDummy_Pods in:
      /Users/erikkerber/Dropbox/Projects/MillMain/MyLib.framework/BuddySDK(Pods-dummy.o)
      /Users/erikkerber/Library/Developer/Xcode/DerivedData/MillMain-fngfqhlslygksgcfuciznkpqfrbr/Build/Products/Debug-iphonesimulator/libPods.a(Pods-dummy.o)
  duplicate symbol _OBJC_CLASS_$_PodsDummy_Pods in:
      /Users/erikkerber/Dropbox/Projects/MillMain/MyLib.framework/BuddySDK(Pods-dummy.o)
      /Users/erikkerber/Library/Developer/Xcode/DerivedData/MillMain-fngfqhlslygksgcfuciznkpqfrbr/Build/Products/Debug-iphonesimulator/libPods.a(Pods-dummy.o)
  ld: 2 duplicate symbols for architecture i386
  </code></pre>
  
  <p>I imagine if they were to add an AFNetworking dependency, that they would also get duplicate symbols relating to AFNetworking.</p>
  
  <p>I plan to eventually distribute MyLib with Cocoapods as well, but I also want to be able to distribute a MyLib.framework itself.</p>
  
  <p>Is there any way to use Cocoapods with my library while making Cocoapods safe to any potential user?</p>