title: Xcode build command equivalent in python
body: <p>I tried the equivalent of :</p>
  
  <pre><code>/usr/bin/xcrun -sdk iphoneos PackageApplication -v  "$APP_OUTPUT_DIR"/"$PRODUCT_NAME".app -o "$APP_OUTPUT_DIR"/"$PLIST_IPA_NAME".ipa -embed "$PROVISONING_PROFILE_PATH" "OTHER_CODE_SIGN_FLAGS=--keychain $TEAMCITY_RUN_SCRIPT_LOCATION/$TEAMCITY_KEYCHAIN"
  </code></pre>
  
  <p>in python3.4 using subprocess as :</p>
  
  <pre><code>value = '/usr/bin/xcrun'
  cmd = [value1]
  cmd += [" -sdk iphoneos PackageApplication -v " + app_output_directory + '/' + product_name + '.app']
  cmd += [" -o " + app_output_directory + '/' + product_name + '.ipa']
  cmd += [" -embed " + provisioning_profile_path]
  cmd += [' --keychain ' + value]
  print(cmd)
  subprocess.call(cmd)
  </code></pre>
  
  <p>Am I doing it correct. If not, please give a solution.</p>
  
  <p>EDIT: The error is like</p>
  
  <pre><code>xcrun: error: unable to find utility "\ -sdk\ iphoneos\ PackageApplication\ -v\ /Users/NAME/Desktop/iOS/build/Sun\ Risers.app", not a developer tool or in PATH
  </code></pre>