title: Add Pod dependency to a cordova plugin
body: <p>I'm currently building an Ionic 3 project and I need to develop a custom Cordova plugin which needs a Pod for iOS platform (<a href="https://github.com/NordicSemiconductor/IOS-Pods-DFU-Library" rel="nofollow noreferrer">https://github.com/NordicSemiconductor/IOS-Pods-DFU-Library</a>). </p>
  
  <p>I added the line </p>
  
  <pre><code>&lt;framework src="iOSDFULibrary" type="podspec" spec="4.1.0"/&gt;
  </code></pre>
  
  <p>to the plugin.xml file, child element of </p>
  
  <pre><code>&lt;platform name="ios"&gt;
  </code></pre>
  
  <p>It doesn't seem to install the Pod depency. Then created the podfile, added the desired pod to the podfile</p>
  
  <pre><code>target 'MyApp' do
      use_frameworks!
      pod 'iOSDFULibrary'
  end
  </code></pre>
  
  <p>and finally fin run pod install. I fixed some dependencies issues whith Xcode (using $(inherited) for embedded libraries and runpath) </p>
  
  <p>Then I run </p>
  
  <pre><code>ionic cordova build ios
  </code></pre>
  
  <p>from the root directoy and I get the following error : </p>
  
  <pre><code> ProcessProductPackaging "" /Users/XXX/Library/Developer/Xcode/DerivedData/MyApp-cnmgcjqxsbizwzgzyunkhpaidafn/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/Zip.build/Zip.framework.xcent
  cd /Users/XXX/Documents/dev/app/test/ble/ble/last/platforms/ios/Pods
  export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/Users/XXX/Documents/dev/app/test/ble/ble/last/node_modules/.bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/Applications/Wireshark.app/Contents/MacOS:/usr/local/Cellar/android-sdk/24.1.2/tools:/usr/local/Cellar/android-sdk/24.1.2/platform-tools≈"
  builtin-productPackagingUtility -entitlements -format xml -o /Users/XXX/Library/Developer/Xcode/DerivedData/MyApp-cnmgcjqxsbizwzgzyunkhpaidafn/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/Zip.build/Zip.framework.xcent
   warning: Falling back to contents of entitlements file "Entitlements-Debug.plist" because it was modified during the build process. Modifying the entitlements file during the build is unsupported.error: The file “Entitlements-Debug.plist” couldn’t be opened because there is no such file.
  
   === BUILD TARGET CordovaLib OF PROJECT CordovaLib WITH CONFIGURATION Debug ===
   Check dependencies
  
   Write auxiliary files
  
   /bin/mkdir -p /Users/XXX/Documents/dev/app/test/ble/ble/last/platforms/ios/build/sharedpch/CordovaLib_Prefix-asuvblhsjpogpaeowyccynwoocft
   write-file /Users/XXX/Documents/dev/app/test/ble/ble/last/platforms/ios/build/sharedpch/CordovaLib_Prefix-asuvblhsjpogpaeowyccynwoocft/CordovaLib_Prefix.pch.pch.hash-criteria
   write-file /Users/XXX/Library/Developer/Xcode/DerivedData/MyApp-cnmgcjqxsbizwzgzyunkhpaidafn/Build/Intermediates.noindex/CordovaLib.build/all-product-headers.yaml
  
   ** BUILD FAILED **
  
  
   The following build commands failed:
   ProcessProductPackaging ""      /Users/XXX/Library/Developer/Xcode/DerivedData/MyApp-cnmgcjqxsbizwzgzyunkhpaidafn/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/Zip.build/Zip.framework.xcent
   (1 failure)
   Error: Error code 65 for command: xcodebuild with args: -xcconfig,/Users/XXX/Documents/dev/app/test/ble/ble/last/platforms/ios/cordova/build-debug.xcconfig,-workspace,MyApp.xcworkspace,-scheme,MyApp,-configuration,Debug,-sdk,iphonesimulator,-destination,platform=iOS Simulator,name=iPhone SE,build,CONFIGURATION_BUILD_DIR=/Users/XXX/Documents/dev/app/test/ble/ble/last/platforms/ios/build/emulator,SHARED_PRECOMPS_DIR=/Users/XXX/Documents/dev/app/test/ble/ble/last/platforms/ios/build/sharedpch
  </code></pre>
  
  <p><strong>1st question</strong> : How to bundle a Cocoapod written in swift to a custom plugin written in swift ?</p>
  
  <p><strong>2nd question</strong> : What is the meaning of ProcessProductPackaging ?</p>
  
  <blockquote>
    <p>Documentations</p>
  </blockquote>
  
  <p><a href="https://cordova.apache.org/docs/en/latest/plugin_ref/spec.html" rel="nofollow noreferrer">https://cordova.apache.org/docs/en/latest/plugin_ref/spec.html</a></p>
  
  <p><a href="https://stackoverflow.com/questions/25414404/how-to-bundle-cocoapod-dependencies-with-cordova-plugin">How to bundle Cocoapod dependencies with Cordova Plugin?</a> </p>
  
  <p><a href="https://github.com/blakgeek/cordova-plugin-cocoapods-support" rel="nofollow noreferrer">https://github.com/blakgeek/cordova-plugin-cocoapods-support</a></p>
  
  <p>Any advices appreciated</p>