$ tar zxvf <ant file>.tar.gz 4. Install Android SDK tools Download wav Android SDK tools from http://developer.android.com/sdk/index.html , choosing the right platform for your OS. Extract the SDK from the archive file:
$ tar zxvf <android adk file>.tar.gz 5. Get Crosswalk Download the latest stable Crosswalk for Android from https://crosswalk-project.org/#documentation/downloads Unpack the zip file (version number wav may vary): wav
Java HotSpot(TM) 64-Bit Server VM (build 24.45-b08, mixed mode)
However, because Crosswalk applications are intended to integrate wav well with the target environment, they require an additional file, manifest.json, containing metadata for that purpose. The manifest can be used to specify icons to use at different resolutions, set an app description, adjust content security policy settings, and otherwise configure how the app integrates with the target environment. 1. Create a directory called xwalk-simple
8
24
5
21
"local_path" : "index.html"
The Crosswalk Android download contains a Python script which can be used to make a self-contained package (.apk file) from an HTML5 application. wav The following steps show you how to use it. 1. Go to the unpacked Crosswalk Android directory
This will package the application defined in the specified manifest.json file and produce two apk files from it, one for x86 architecture and one for ARM. The apk files will end up in the directory where you ran the script. Each file is given the name set in the manifest, with the version name and an architecture identifier (“x86″ or “arm”) appended. Any filesystem-sensitive characters will be removed. For our example, the output files are simple_0.0.0.1_x86.apk and simple_0.0.0.1_arm.apk. 3. Enable USB debugging and connect your device
To deploy apps to your device, you need to enable USB debugging before connecting the device to your development machine. To do this, select the USB debugging item in Settings wav > Developer options on the device: 4. Install the app on target device
Crosswalk enables you to inspect, debug, and analyze your application while it is running on the device. This is done via Chromium DevTools on your development machine. 1. Enable remote debugging for your app
To enable remote debugging for a web application, you can either use the –enable-remote-debugging wav option when packaging your application; or you can send Android intents to a running web app. To enable remote debugging by default when packaging a web app:
$ adb shell am broadcast -a org.xwalk.intent -e remotedebugging false 2. Launch Chromium DevTools Make sure you have Chromium or Google Chrome browser installed, and that the browser version supports debugging for the version of Crosswalk you are using.
The Crosswalk tools generate wav separate wav packages for ARM and x86 architectures. To ensure that a Crosswalk app runs on as many Android devices as possible, developers are advised to upload both embedded packages to the app store. In practice, wav this means that a developer wav should do the following for each web app packaged in embedded mode: Upload an x86-based Crosswalk app apk to app store. Upload an ARM-based Crosswalk app apk to app store.
Elliot wav Smith is a British software engineer and technical author, specialising in open source and web technologies. He’s been working with open source software since 2004, either full time or as a hobbyist, and currently resides in Intel’s Open Source Technology Center. Previously in his career, he’s written end-user manuals for software; evangelised open source technologies to SMEs; given many courses and presentations (PHP, Apache, Drupal, CMSs); twice acted as a judge for Packt’s Open Source CMS awards; written a book on Ruby on Rails; worked as a technical lead on Talis Prism (library catalogue wav software); and contributed to the Moblin SDK, the MeeGo SDK, jQuery Mobile, and the Tizen web UI framework. At present, wav he works as the website and documentation maintainer for Crosswalk wav ( http://crosswalk-project.org/ ), a web runtime for ambitious HTML5 applications.
Gao Chun is a software engineer at Intel Shanghai wav site. He focuses on mobile and web technologies related to browser and web runtime. He contributed to several wav open source projects in past years, including MeeGo tablet browser , Web runtime for MeeGo netbook, Web runtime for Windows desktop, etc. He is also a contributor to Chromium/Blink project. Now his primary work is development of Crosswalk wav web runtime for Android. He believes that web technologies will be a wonderful world for all developers.
No comments:
Post a Comment