Caution
Building NDK needs a high-performance build system computer. See Build System Requirements.
Building NDK needs a high-performance build system computer. See Build System Requirements.
To build downloadable native apps or services for webOS Open Source Edition (OSE), you need to install Native Development Kit (NDK) on your computer.
The NDK is a set of tools that include toolchains, libraries, and header files. This guide describes how to build and install the NDK on your computer.
To build the NDK, enter the following commands:
# Download source codes
$ git clone https://github.com/webosose/build-webos
$ cd build-webos
# (Optional) If a patch version exists
# See http://webosose.org/docs/guides/setup/building-webos-ose/#
$ git checkout -t origin/<branch of the latest webos ose version>
# Install and configure the build
$ sudo scripts/prerequisites.sh
$ ./mcf -p <half the num of CPUs> -b <half the num of CPUs> <image type>
# Start to build
$ source oe-init-build-env
$ bitbake -c populate_sdk webos-image
Parameter | Description |
---|---|
<branch of the latest webos ose version> | This parameter varies depending on the current the webOS OSE version. Use the latest version. See also (Optional) How to Handle Patch Versions. |
<half the num of CPUs> | Number of CPU cores to allocate to the building process. For the specific value, refer to Appendix A. Setting Values for mcf. |
<image type> | A type of the webOS OSE image to build. See Configuring the Build. |
If the building process succeeds, a script file (.sh
) is generated in build-webos/BUILD/deploy/sdk/
.
$ ls BUILD/deploy/sdk
# Example results for webOS OSE v2.27.0
webos-sdk-x86_64-cortexa72-toolchain-2.27.0.g.host.manifest
webos-sdk-x86_64-cortexa72-toolchain-2.27.0.g.sh
webos-sdk-x86_64-cortexa72-toolchain-2.27.0.g.target.manifest
webos-sdk-x86_64-cortexa72-toolchain-2.27.0.g.testdata.json
To install the NDK, you need to:
.sh
) file.To run the generated script file, enter the following commands:
$ cd BUILD/deploy/sdk
$ ./webos-sdk-x86_64-cortexa72-toolchain-2.27.0.g.sh
webOS OSE SDK installer version 2.27.0.g
========================================
Enter target directory for SDK (default: /usr/local/webos-sdk-x86_64):
The directory "/usr/local/webos-sdk-x86_64" already contains a SDK for this architecture.
If you continue, existing files will be overwritten! Proceed [y/N]? y
If the process succeeds, an environment setup file (environment-setup-cortexa72-webos-linux
) is generated in the target directory (default: /usr/local/webos-sdk-x86_64
).
$ ls /usr/local/webos-sdk-x86_64/
environment-setup-cortexa72-webos-linux
site-config-cortexa72-webos-linux
sysroots
version-cortexa72-webos-linux
To set up the environment, run the environment setup file.
$ source /usr/local/webos-sdk-x86_64/environment-setup-cortexa72-webos-linux
Output messages might or might not be displayed depending on your computer’s setup. If you see the message below, it’s not an error so you can proceed to the next step.
Icecc not found. Disabling distributed compiling
Now you ready to build downloadable native apps or services. Check the following guides:
Contents