1. #1
    Sencha User
    Join Date
    Oct 2011
    Posts
    26
    Vote Rating
    0
    gopikumar is on a distinguished road

      0  

    Default Native Packaging Issue -Platform :iOS not working

    Native Packaging Issue -Platform :iOS not working


    Hi all,

    I am trying Native iOs packaging referring API Docs.

    But I am getting issus with it.
    Code:
    {
          "versionString":"1.0",
          "applicationName":"App",
          "applicationId":"com.aaa.App",
          "inputPath":"sample/myFolder",
          "outputPath":"sample",
          "iconName": "icon.png",
          "configuration":"Debug",
          "platform":"iOS", 
          "deviceType":"iPhone",
          "orientations": [
                    "portrait",
                   "landscapeLeft",
                  "landscapeRight",
                  "portraitUpsideDown"
         ]
    }

    when i use platform : iOSSimulator it working fine with simulator.

    when i change platform to iOS it is showing packaging successfully with the error below and not signing the package.

    The application was successfully packagedAssertion failed: (type_ == stringValue), function asCString, file src/json_value.cpp, line 679.

    Am I missing anything. help needed

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    37,330
    Vote Rating
    847
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      -1  

    Default


    You don't have a certificatePath or certificateAlias config.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  3. #3
    Sencha User
    Join Date
    Apr 2012
    Posts
    5
    Vote Rating
    0
    billwyuan is on a distinguished road

      0  

    Default Help needed with Sencha touch 2.1: iOS native packaging not working on sencha cmd

    Help needed with Sencha touch 2.1: iOS native packaging not working on sencha cmd


    I use the same process to build a default app.
    To reproduce: sencha -sdk /path/to/sdk generate app MyApp/path/to/MyApp

    Under MyApp, run: sencha app build native, getting error and generating a packaged My App, failed to install on iPhone.
    The trace

    [INF] Packaging your application as a native app to /Applications/MAMP/htdocs/MyApp/build/MyApp/native ...
    [ERR] failed running native packager
    [ERR] Assertion failed: (type_ == stringValue), function asCString, file src/json_value.cpp, line 679.
    The application was successfully packaged


    [ERR]
    [ERR] BUILD FAILED
    [ERR] com.sencha.exceptions.BasicException: The following error occurred while executing this line:
    {


    "applicationName":"My Application",
    "applicationId":"com.erprules.myAppID",
    "bundleSeedId":"73F33ZW49D",
    "versionString":"1.0",
    "versionCode":"1",
    "icon": {
    "57":"resources/icons/Icon.png",
    "72":"resources/icons/Icon~ipad.png",
    "114":"resources/icons/Icon@2x.png",
    "144":"resources/icons/Icon~ipad@2x.png"
    },
    "inputPath":"./",
    "outputPath":"../build/",
    "configuration":"Debug",
    "platform":"iOS",
    "deviceType":"iPhone",
    "certificatePath":"ios_development.cer",
    "certificatePassword":"",
    "provisionProfile":"Yuan_dev-3.mobileprovision",
    "permissions":[
    "INTERNET",
    "ACCESS_NETWORK_STATE",
    //"CAMERA",
    //"VIBRATE",
    "ACCESS_FINE_LOCATION",
    "ACCESS_COARSE_LOCATION",
    "CALL_PHONE"],


    "orientations": [
    "portrait",
    "landscapeLeft",
    "landscapeRight",
    "portraitUpsideDown"
    ]
    }

  4. #4
    Sencha User
    Join Date
    Apr 2012
    Location
    Brisbane
    Posts
    12
    Vote Rating
    0
    vanr6572 is on a distinguished road

      0  

    Default


    Have to be a p12 certificate not cer at least if it on windows. On mac can use certicicateAlias with an alias in your key ring.

    The native packing documentation explains how to convert cer to dem to a p12. http://docs.sencha.com/touch/2-1/#!/...tive_packaging

  5. #5
    Sencha User
    Join Date
    Apr 2012
    Posts
    5
    Vote Rating
    0
    billwyuan is on a distinguished road

      0  

    Default Native packing issues on 2.1.1

    Native packing issues on 2.1.1


    I converted the cert to p12 and used the setting, and tried build again, but I got the same error at the same line: 679. Although it had a MyApp.app, but when I tried to drag it and synch to device, device pops up a message: failed to launch MyApp.

    On Mac, I also tried certicicateAlias ="iPhone developer FirstName Last Name", It says can't find the certicicateAlias.

    Thanks for your analysis. This is my first natvie package I struggled , I can't resolve it after many hours search. Can you or anyone show a workable setting file by removing your name?
    I installed compass, I used a empty generated sample project without any customization on lion, 2.1.1 sencha touch, 3.0.2 cmd. It is really frustrating I have not seen it working on device.



    Quote Originally Posted by vanr6572 View Post
    Have to be a p12 certificate not cer at least if it on windows. On mac can use certicicateAlias with an alias in your key ring.

    The native packing documentation explains how to convert cer to dem to a p12. http://docs.sencha.com/touch/2-1/#!/...tive_packaging
    thanks,

    Bill Yuan

  6. #6
    Sencha User
    Join Date
    Feb 2013
    Posts
    1
    Vote Rating
    0
    vadimg88 is on a distinguished road

      0  

    Default


    Having the exact same issue, after getting the p12 file trying again same thing happens.

    There is a need for better documentation on deploying apps. The current documentation just referrers you to the iOS docs for anything related to that. But in most cases there are no answers there.

    Help is appreciated.

  7. #7
    Sencha User
    Join Date
    Apr 2012
    Location
    Brisbane
    Posts
    12
    Vote Rating
    0
    vanr6572 is on a distinguished road

      0  

    Default


    I also had issues, but have it working on windows environment, another thing you could try is give you p12 certificate a password.

    packager.json
    Code:
    {
    
    
      /**
       * @cfg {String} applicationName
       * 
       * This is the name of your application, which is displayed on the device when the app is installed. On IOS, this should match
       * the name of your application in the Apple Provisioning Portal.
       */
      "applicationName": "ExchangeStats",
    
    
      /**
       * @cfg {String} applicationId
       * 
       * This is the name namespace for your application. On IOS, this should match the name of your application in the Apple Provisioning Portal.
       */
      "applicationId": "com.hatch.ExchangeStats",
    
    
      /**
       * @cfg {String} bundleSeedId
       * 
       * A ten character string which stands before aplication ID in Apple Provisioning Portal
       */
      "bundleSeedId": "BTLTDH9B69",
    
    
      /**
       * @cfg {String} versionString
       * 
       * This is the version of your application.
       */
      "versionString": "1.0.3",
    
    
      /**
       * @cfg {String} versionCode
       * 
       * This is the integer version code of your application, or you can refer to it as a build number. Used only for Android builds.
       */
      "versionCode": "3",
    
    
      /**
       * @cfg {Object} icon
       * 
       * For iOS, please refer to their documentation about icon sizes:
       * https://developer.apple.com/library/ios/#documentation/userexperience/conceptual/mobilehig/IconsImages/IconsImages.html
       * 
       * For Android, please refer to the Google Launcher icons guide:
       * http://developer.android.com/guide/practices/ui_guidelines/icon_design_launcher.html
       */
      "icon": {
        "57": "resources/icons/Icon.png",
        "72": "resources/icons/Icon~ipad.png",
        "114": "resources/icons/Icon@2x.png",
        "144": "resources/icons/Icon~ipad@2x.png"
      },
    
    
      /**
       * @cfg {String} inputPath
       * 
       * This is location of your Sencha Touch 2 application, relative to this configuration file.
       */
      "inputPath": "./build/ExchangeStats/testing",
    
    
      /**
       * @cfg {String} outputPath
       * 
       * This is where the built application file with be saved. Make sure that output path is not in your input path, you may get into endless recursive copying
       */
      "outputPath": "../build/native",
    
    
      /**
       * @cfg {String} configuration
       * 
       * This is configuration for your application. `Debug` should always be used unless you are submitting your app to an online
       * store - in which case `Release` should be specified.
       */
      "configuration": "Debug",
    
    
      "notificationConfiguration": "Debug",
      
      /**
       * @cfg {String} platform
       * 
       * This is the platform where you will be running your application.
       * Available options are:
       *  - iOSSimulator
       *  - iOS
       *  - Android
       *  - AndroidEmulator
       */
      "platform": "iOS",
    
    
      /**
       * @cfg {String} deviceType
       * 
       * This is device type that your application will be running on.
       * If you are developing for Android, this is not necessary.
       * Available options are:
       *  - iPhone
       *  - iPad
       *  - Universal
       */
      "deviceType": "Universal",
    
    
      /**
       * @cfg {String} certificatePath
       * 
       * This is the location of your certificate.
       * This is required when you are developing for Android or you are developing on Windows.
       */
      "certificatePath": "../keys/ios_development.p12",
    
    
      /**
       * @cfg {String} certificatePassword
       * 
       * The password which was specified during certificate export.
       */
      "certificatePassword": "*** hidden ***",
    
    
      /**
       * @cfg {String} provisionProfile
       * 
       * The path to the provision profile (APP_NAME.mobileprovision) which you can create and then download from Apple's provisioning portal
       */
      "provisionProfile": "../keys/Getting_Started_Development.mobileprovision",
    
    
      /**
       * @cfg {String} sdkPath
       * 
       * This is the path to the Android SDK, if you are developing an Android application.
       */
      "sdkPath": "../libs/adt-bundle-windows-x86_64/sdk",
    
    
      /**
       * @cfg {String} androidAPILevel
       * 
       * This is android API level, the version of Android SDK to use, you can read more about it here: http://developer.android.com/guide/appendix/api-levels.html.
       * Be sure to install corresponding platform API in android SDK manager (android_sdk/tools/android)
       */
      "androidAPILevel": "17",
    
    
      /**
       * @cfg {Array[String]} permissions
       * 
       * Array of permissions that is used by an application (Android only)
       * Full list of permissions for Android application can be found here: http://developer.android.com/reference/android/Manifest.permission.html#ACCESS_CHECKIN_PROPERTIES
       */
      "permissions": [
        "INTERNET",
        "ACCESS_NETWORK_STATE",
        "CAMERA",
        "VIBRATE",
        "ACCESS_FINE_LOCATION",
        "ACCESS_COARSE_LOCATION",
        "CALL_PHONE"
      ],
    
    
      /**
       * @cfg {Array[String]} orientations
       * 
       * This is orientations that this application can run.
       */
      "orientations": [
        "portrait",
        "landscapeLeft",
        "landscapeRight",
        "portraitUpsideDown"
      ]
    }