# GitHub workflow (firmware and extras) Source: [https://docs.qualcomm.com/doc/80-70014-254/topic/build_addn_info.html](https://docs.qualcomm.com/doc/80-70014-254/topic/build_addn_info.html) Note: These steps are applicable only for authorized users. To upgrade your access, go to [http://www.qualcomm.com/support/working-with-qualcomm](http://www.qualcomm.com/support/working-with-qualcomm). To build various Qualcomm Linux Yocto layers including `meta-qcom-hwe`, `meta-qcom-extras`, `meta-qcom-qim-product-sdk`, and `meta-qcom-robotics-sdk` using selective proprietary sources and binaries/libraries, follow these step-by-step reference instructions. ## Host machine requirements Source: [https://docs.qualcomm.com/doc/80-70014-254/topic/build_addn_info.html](https://docs.qualcomm.com/doc/80-70014-254/topic/build_addn_info.html) | Configuration | Tools | Permissions | | --- | --- | --- | | x86 machine | Git 1.8.3.1 or later versions | A `sudo` permission is
required to execute a few commands. | | Quad-core CPU, for example, Intel i7-2600 at 3.4 GHz
(equivalent or better) | Tar 1.28 or later versions | A `sudo` permission is
required to execute a few commands. | | 300 GB free disk space (swap partition >
32 GB) | Python 3.10.2 or later versions | A `sudo` permission is
required to execute a few commands. | | 16 GB RAM | GCC 7.5 or later versions | A `sudo` permission is
required to execute a few commands. | | Ubuntu 22.04 | GNU Make 4.0 or later versions | A `sudo` permission is
required to execute a few commands. | | | | | | | | | | | | | | | | | ## Install QSC CLI Source: [https://docs.qualcomm.com/doc/80-70014-254/topic/build_addn_info.html](https://docs.qualcomm.com/doc/80-70014-254/topic/build_addn_info.html) Set up `qsc-cli`: 1. Install curl (if not already installed): sudo apt install curlCopy to clipboard 2. Download the Debian package for `qsc-cli`: cd curl -L https://softwarecenter.qualcomm.com/api/download/software/qsc/linux/latest.deb -o qsc_installer.debCopy to clipboard 3. Install the `qsc-cli` Debian package: sudo dpkg -i qsc_installer.debCopy to clipboard 4. Log in to `qsc-cli`: qsc-cli login -u Copy to clipboard Note: A one-time login into [chipcode.qti.qualcomm.com](http://chipcode.qti.qualcomm.com/) is required to download Qualcomm proprietary git repositories. Use your Qualcomm login credentials to complete this step. For more details, see `qsc-cli` related topics in [How to](https://docs.qualcomm.com/doc/80-70014-254/topic/how_to.html). ## Ubuntu host setup Source: [https://docs.qualcomm.com/doc/80-70014-254/topic/build_addn_info.html](https://docs.qualcomm.com/doc/80-70014-254/topic/build_addn_info.html) The Ubuntu host machine needs a few setup operations to ensure that the required software tools are ready. 1. Install the following packages: sudo apt update sudo apt install repo gawk wget git diffstat unzip texinfo gcc build-essential chrpath socat cpio python3 python3-pip python3-pexpect xz-utils debianutils iputils-ping python3-git python3-jinja2 libegl1-mesa libsdl1.2-dev pylint xterm python3-subunit mesa-common-dev zstd liblz4-tool locales tar python-is-python3 file libxml-opml-simplegen-perl vim whiptail sudo apt-get install lib32stdc++6 libncurses5 checkinstall libreadline-dev libncursesw5-dev libssl-dev libsqlite3-dev tk-dev libgdbm-dev libc6-dev libbz2-dev libffi-dev curlCopy to clipboard 2. Add your Qualcomm login ID with PAT to the `.netrc` file in your home directory: # Log in to qsc-cli to generate PAT qsc-cli login -u # Run the following command to generate PAT qsc-cli pat --get # This command gives output as shown in the following note # The last line in this output is the token, which can be used to access # Qualcomm Proprietary repositories. This token expires in two weeks.Copy to clipboard Note: user@hostname:/local/mnt/workspace$ qsc-cli pat --get [Info]: Starting qsc-cli version 0.0.0.9 **5LThNlklb55mMVLB5C2KqUGU2jCF** vim ~/.netrc # add the following entries machine chipmaster2.qti.qualcomm.com login password machine qpm-git.qualcomm.com login password Copy to clipboard 3. Set up the locales (if not set up already): sudo locale-gen en_US.UTF-8 sudo update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 export LC_ALL=en_US.UTF-8 export LANG=en_US.UTF-8Copy to clipboard 4. Update git configurations: # Check if your identity is configured in .gitconfig git config --get user.email git config --get user.name # Run the following commands if you do not have your account identity set in .gitconfig git config --global user.email git config --global user.name <"Your Name"> # Add the following UI color option for output of console (optional) git config --global color.ui auto # Add the following git configurations to fetch large size repositories and to avoid unreliable connections git config --global http.postBuffer 1048576000 git config --global http.maxRequestBuffer 1048576000 git config --global http.lowSpeedLimit 0 git config --global http.lowSpeedTime 999999 # Add the following git configurations to follow remote redirects from http-alternates files or alternates git config --global http.https://chipmaster2.qti.qualcomm.com.followRedirects true git config --global http.https://qpm-git.qualcomm.com.followRedirects trueCopy to clipboard 5. Set up Python 3.10.2: Note: Skip the following instructions if you already have python 3.10.2 or later versions. python --version # Download it in a directory of your choice wget https://www.python.org/ftp/python/3.10.2/Python-3.10.2.tgz tar -xvf Python-3.10.2.tgz cd Python-3.10.2 # Use sudo if you need to access /opt ./configure --prefix=/opt/python3 --enable-optimizations make make install ln -s /opt/python3/bin/python3 /opt/python3/bin/python export PATH=/opt/python3/bin:$PATH export PYTHONPATH=/opt/python3/lib:$PYTHONPATHCopy to clipboard ## Build with firmware sources Source: [https://docs.qualcomm.com/doc/80-70014-254/topic/build_addn_info.html](https://docs.qualcomm.com/doc/80-70014-254/topic/build_addn_info.html) ### Sync firmware The following table describes the Qualcomm Yocto layers and release tags: | Access level | Yocto layer | Release tag | Example | | --- | --- | --- | --- | | Registered developer with any email
address | `meta-qcom-hwe` | manifest release tag | qcom-6.6.28-QLI.1.1-Ver.1.1.xml | | Registered developer with any email
address | `meta-qcom-qim-product-sdk` | manifest release tag | qcom-6.6.28-QLI.1.1-Ver.1.1\_qim-product-sdk-1.1.3.xml | | Registered developer with any email
address | `meta-qcom-robotics-sdk` | manifest release tag | qcom-6.6.28-QLI.1.1-Ver.1.1\_robotics-product-sdk-1.1.xml | | Registered developer from a verified organization | `meta-qcom-extras` | meta-qcom-extras release tag | r1.0\_00041.0 | | See [Table : Mapping access levels](https://docs.qualcomm.com/doc/80-70014-254/topic/build_addn_info.html#build_private_distribution_with_extras__mapping_access_levels). | NA | firmware release tag | r1.0\_00039.2 | | | | | | | | | | | The following tables describe the available distributions for firmware that can be downloaded according to the need and entitlements: | **Access level** | **Distribution** | Yocto layers | | --- | --- | --- | | Registered developer from a verified
organization | Base build: High-level OS and firmware source (GPS
only)
`Qualcomm_Linux.SPF.1.0|AP|Standard|OEM|NoModem` | `meta-qcom`



`meta-qcom-hwe`



`meta-qcom-extras` | | Registered developer from a verified
organization | Base build + QIMP
SDK
`Qualcomm_Linux.SPF.1.0|AP|Standard|OEM|NM_QIMPSDK` | `meta-qcom`



`meta-qcom-hwe`



`meta-qcom-extras`



`meta-qcom-qim-product-sdk` | | Registered developer from a verified
organization | Base build + QIMP SDK + QIRP
SDK
`Qualcomm_Linux.SPF.1.0|AP|Standard|OEM|NM_QIRPSDK` | `meta-qcom`



`meta-qcom-hwe`



`meta-qcom-extras`



`meta-qcom-robotics-extras`



`meta-ros`



`meta-qcom-robotics`



`meta-qcom-robotics-distro`



`meta-qcom-robotics-sdk`



`meta-qcom-qim-product-sdk` | | Licensed developer with additional
access | Base build: High-level OS and firmware (GPS only)
source
`Qualcomm_Linux.SPF.1.0|AP|Standard|OEM|` | `meta-qcom`



`meta-qcom-hwe`



`meta-qcom-extras` | | Licensed developer with additional
access | Base build + QIMP SDK (GPS
only)
`Qualcomm_Linux.SPF.1.0|AP|Standard|OEM|QIMPSDK` | `meta-qcom`



`meta-qcom-hwe`



`meta-qcom-extras`



`meta-qcom-qim-product-sdk` | | Licensed developer with additional
access | Base build: High-level OS and firmware (GPS and modem)
source
`Qualcomm_Linux.SPF.1.0|AMSS|Standard|OEM|` | `meta-qcom`



`meta-qcom-hwe`



`meta-qcom-extras` | | Licensed developer with additional
access | Base build + QIMP SDK (GPS and
modem)
`Qualcomm_Linux.SPF.1.0|AMSS|Standard|OEM|QIMPSDK` | `meta-qcom`



`meta-qcom-hwe`



`meta-qcom-extras`



`meta-qcom-qim-product-sdk` | | | | | | | | | | | | | For Yocto layer descriptions, see [Table : 1. Qualcomm Linux Yocto layers](https://docs.qualcomm.com/doc/80-70014-254/topic/build_from_source_qsc_gui_intro.html#concept_n2t_tjn_w1c__Yocto_layer_descriptions). Table : Mapping of firmware distributions and git repositories | Firmware distribution | Git command | Directory into which firmware gets synced on git
clone | | --- | --- | --- | | Qualcomm\_Linux.SPF.1.0|AP|Standard|OEM|NoModem | `git clone -b --depth 1
https://qpm-git.qualcomm.com/home2/git/qualcomm/qualcomm-linux-spf-1-0_ap_standard_oem_nomodem.git` | `qualcomm-linux-spf-1-0_ap_standard_oem_nomodem` | | Qualcomm\_Linux.SPF.1.0|AP|Standard|OEM|NM\_QIMPSDK | `git clone -b --depth 1
https://qpm-git.qualcomm.com/home2/git/qualcomm/qualcomm-linux-spf-1-0_ap_standard_oem_nm-qimpsdk.git` | `qualcomm-linux-spf-1-0_ap_standard_oem_nm-qimpsdk` | | Qualcomm\_Linux.SPF.1.0|AP|Standard|OEM|NM\_QIRPSDK | `git clone -b --depth 1
https://qpm-git.qualcomm.com/home2/git/qualcomm/qualcomm-linux-spf-1-0_ap_standard_oem_nm-qirpsdk.git` | `qualcomm-linux-spf-1-0_ap_standard_oem_nm-qirpsdk` | | Qualcomm\_Linux.SPF.1.0|AP|Standard|OEM| | `git clone -b --depth 1
https://qpm-git.qualcomm.com/home2/git/qualcomm/qualcomm-linux-spf-1-0_ap_standard_oem.git` | `qualcomm-linux-spf-1-0_ap_standard_oem` | | Qualcomm\_Linux.SPF.1.0|AP|Standard|OEM|QIMPSDK | `git clone -b --depth 1
https://qpm-git.qualcomm.com/home2/git/qualcomm/qualcomm-linux-spf-1-0_ap_standard_oem_qimpsdk.git` | `qualcomm-linux-spf-1-0_ap_standard_oem_qimpsdk` | | Qualcomm\_Linux.SPF.1.0|AMSS|Standard|OEM| | `git clone -b --depth 1
https://qpm-git.qualcomm.com/home2/git/qualcomm/qualcomm-linux-spf-1-0_amss_standard_oem.git` | `qualcomm-linux-spf-1-0_amss_standard_oem` | | Qualcomm\_Linux.SPF.1.0|AMSS|Standard|OEM|QIMPSDK | `git clone -b --depth 1
https://qpm-git.qualcomm.com/home2/git/qualcomm/qualcomm-linux-spf-1-0_amss_standard_oem_qimpsdk.git` | `qualcomm-linux-spf-1-0_amss_standard_oem_qimpsdk` | Note: Commands in the following sections are based on binary and source for firmware images without modem and GPS (see the command in [Table : Mapping of firmware distributions and git repositories](https://docs.qualcomm.com/doc/80-70014-254/topic/build_addn_info.html#build_private_distribution_with_extras__distributions_firmware)). Hence, `qualcomm-linux-spf-1-0_ap_standard_oem_nm-qimpsdk` is used. If you use any other distribution, then update the directory accordingly. The **Git command** column (see [Table : Mapping of firmware distributions and git repositories](https://docs.qualcomm.com/doc/80-70014-254/topic/build_addn_info.html#build_private_distribution_with_extras__distributions_firmware)) provides the git repository, which contains the firmware sources. These repositories are hosted on Qualcomm servers. Clone the appropriate repositories based on your access profile and use case. The following git clone command downloads the selected firmware components in source, except the modem: mkdir -p cd git clone -b --depth 1 https://qpm-git.qualcomm.com/home2/git/qualcomm/qualcomm-linux-spf-1-0_ap_standard_oem_nm-qimpsdk.git # Example, is r1.0_00039.2Copy to clipboard Note: The `git clone` command clones the content into the `/qualcomm-linux-spf-1-0_ap_standard_oem_nm-qimpsdk` directory. For the latest ``, see the Build-critical release tags section in the [Release Notes](https://docs.qualcomm.com/bundle/publicresource/topics/RNO-240626095531/). ### Build firmware - **Prerequisites** - Ensure that the working shell is `bash`. Check the output: echo $0Copy to clipboard The expected output of the command should be `bash`. If not, enter the bash shell: bashCopy to clipboard - Install libffi6 using the following commands. This is required for the QAIC compiler, which generates header and source files from IDL files: curl -LO http://archive.ubuntu.com/ubuntu/pool/main/libf/libffi/libffi6_3.2.1-8_amd64.deb sudo dpkg -i libffi6_3.2.1-8_amd64.debCopy to clipboard - Install LLVM for AOP, TZ, and BOOT compilation: cd mkdir llvm # Log in to qpm-cli and activate the license qpm-cli --login qpm-cli --license-activate sdllvm_arm # LLVM requirement for BOOT compilation is 10.0.3 qpm-cli --install sdllvm_arm --version 10.0.3 --path /llvm/10.0.3 chmod -R 777 /llvm/10.0.3 # LLVM requirement for AOP is 14.0.4 qpm-cli --install sdllvm_arm --version 14.0.4 --path /llvm/14.0.4 chmod -R 777 /llvm/14.0.4 # LLVM requirement for TZ compilation is 16.0.7 qpm-cli --install sdllvm_arm --version 16.0.7 --path /llvm/16.0.7 chmod -R 777 /llvm/16.0.7Copy to clipboard - Export the `SECTOOLS` variable and compile the firmware builds (`/qualcomm-linux-spf-1-0_ap_standard_oem_nm-qimpsdk` is the top-level directory): export SECTOOLS=/qualcomm-linux-spf-1-0_ap_standard_oem_nm-qimpsdk//common/sectoolsv2/ext/Linux/sectools export SECTOOLS_DIR=/qualcomm-linux-spf-1-0_ap_standard_oem_nm-qimpsdk//common/sectoolsv2/ext/Linux # An example is QCM6490.LE.1.0, see the latest Release Notes.Copy to clipboard - Install and set up Qualcomm^®^ Hexagon^™^: qpm-cli --extract hexagon8.4 --version 8.4.07 export HEXAGON_ROOT=$HOME/Qualcomm/HEXAGON_Tools echo $HEXAGON_ROOTCopy to clipboard Note: Set the environment variable HEXAGON\_ROOT to the path where the Hexagon SDK is installed. To change the install path when using `qpm-cli`, see [How can I change the Hexagon tool install path?](https://docs.qualcomm.com/doc/80-70014-254/topic/how_to.html#howto_build__section_nqg_cj3_v1c_vinayjk_03-23-24-006-3-877). - **Build cDSP** **Tools required** - Compiler version – Hexagon 8.4.07 - Python version – Python 3.10.2 - Install libffi6 **Build steps** 1. Navigate to the following directory: cd /qualcomm-linux-spf-1-0_ap_standard_oem_nm-qimpsdk/CDSP.HT.2.5.c3/cdsp_proc/build/msCopy to clipboard 2. Clean the build: python ./build_variant.py kodiak.cdsp.prod --cleanCopy to clipboard 3. Build the image: python ./build_variant.py kodiak.cdsp.prodCopy to clipboard - **Build aDSP** **Tools required** - Compiler version – Hexagon 8.4.07 - Python version – Python 3.10.2 - Install libffi6 **Nanopb integration (only one-time setup)** cd /qualcomm-linux-spf-1-0_ap_standard_oem_nm-qimpsdk/ADSP.HT.5.5.c8/adsp_proc/qsh_api curl https://jpa.kapsi.fi/nanopb/download/nanopb-0.3.9.5-linux-x86.tar.gz -o nanopb-0.3.9.5-linux-x86.tar.gz cd /qualcomm-linux-spf-1-0_ap_standard_oem_nm-qimpsdk/ADSP.HT.5.5.c8/adsp_proc/ python qsh_api/build/config_nanopb_dependency.py -f nanopb-0.3.9.5-linux-x86Copy to clipboard **Build steps** 1. Navigate to the following directory: cd /qualcomm-linux-spf-1-0_ap_standard_oem_nm-qimpsdk/ADSP.HT.5.5.c8/adsp_proc/build/msCopy to clipboard 2. Clean the build: python ./build_variant.py kodiak.adsp.prod --cleanCopy to clipboard 3. Build the image: python ./build_variant.py kodiak.adsp.prodCopy to clipboard - **Build Boot** **Tools required** - Compiler version – LLVM version must be updated to 10.0.3 Note: To avoid build errors, ensure that there is a `/` at the end of the command. export LLVM=/llvm/10.0.3/Copy to clipboard - Python version – Python 3.10 - Install libffi6 **Build steps** 1. For compiling Boot, you need the device tree compiler in the /pkg/qct/software/boottools directory. Install the package: sudo apt-get install device-tree-compilerCopy to clipboard 2. Copy the /usr/bin/dtc file to the /pkg/qct/software/boottools directory: sudo mkdir -p /pkg/qct/software/boottools sudo cp -r /usr/bin/dtc /pkg/qct/software/boottoolsCopy to clipboard 3. Navigate to the following directory: cd /qualcomm-linux-spf-1-0_ap_standard_oem_nm-qimpsdk/BOOT.MXF.1.0.c1/Copy to clipboard 4. Install the dependencies: python -m pip install -r boot_images/boot_tools/dtschema_tools/oss/requirements.txtCopy to clipboard 5. Clean the build: python -u boot_images/boot_tools/buildex.py -t kodiak,QcomToolsPkg -v LAA -r RELEASE --build_flags=cleanallCopy to clipboard 6. Build the image: python -u boot_images/boot_tools/buildex.py -t kodiak,QcomToolsPkg -v LAA -r RELEASECopy to clipboard Note: For debug variant builds, replace `RELEASE` with `DEBUG`. - **TZ firmware** **Tools required** - Compiler version – LLVM 16.0.7 - Python version – Python 3.10 **Build steps** 1. Install LLVM: cd /TZ.XF.5.0/trustzone_images/build/ms/ vi build_config_deploy_kodiak.xml # Edit all the occurrences of /pkg/qct/software/llvm/release/arm/16.0.7/ to /llvm/16.0.7/Copy to clipboard 2. Build the image: cd /TZ.XF.5.0/trustzone_images/build/ms/ python build_all.py -b TZ.XF.5.0 CHIPSET=kodiak --cfg=build_config_deploy_kodiak.xmlCopy to clipboard - **AOP firmware** **Tools required** - Compiler version – LLVM 14.0.4 - Python version – Python 3.10 **Build steps** 1. Navigate to the following directory: cd /AOP.HO.3.6/aop_proc/build/Copy to clipboard 2. Build the image: ./build_kodiak.sh -l /llvm/14.0.4/Copy to clipboard - **CPUCP firmware** The CPUCP firmware is released as a binary and build compilation is not required. - **CPUSYS.VM firmware** The CPUSYS.VM firmware is released as a binary and build compilation is not required. - **BTFM firmware** The BTFM firmware is released as a binary and build compilation is not required. - **WLAN firmware** The WLAN firmware is released as a binary and build compilation is not required. - **Generate firmware prebuilds (boot-critical and split-firmware binaries)** Create an integrated firmware binary from the individual components that you compiled: # cd /qualcomm-linux-spf-1-0_ap_standard_oem_nm-qimpsdk//common/build # An example is QCM6490.LE.1.0, see the latest Release Notes cd /qualcomm-linux-spf-1-0_ap_standard_oem_nm-qimpsdk/QCM6490.LE.1.0/common/build python build.py --imfCopy to clipboard Note: Firmware prebuild is successful if the following zip files are generated in the <FIRMWARE\_ROOT>/qualcomm-linux-spf-1-0\_ap\_standard\_oem\_nm-qimpsdk/QCM6490.LE.1.0/common/build/ufs/bindirectory: - QCM6490\_bootbinaries.zip - QCM6490\_dspso.zip - QCM6490\_fw.zip ### Build base image with extras 1. Download Qualcomm Yocto and supporting layers with extras: # cd to directory where you have 300 GB of free storage space to create your workspaces mkdir cd repo init -u https://github.com/quic-yocto/qcom-manifest -b qcom-linux-kirkstone -m # Example, is qcom-6.6.28-QLI.1.1-Ver.1.1.xml repo sync git clone https://qpm-git.qualcomm.com/home2/git/qualcomm/qualcomm-linux-spf-1-0_hlos_oem_metadata.git -b --depth 1 # Example, is r1.0_00041.0 mkdir -p layers/meta-qcom-extras cp -rf qualcomm-linux-spf-1-0_hlos_oem_metadata/QCM6490.LE.1.0/common/config/meta-qcom-extras/* layers/meta-qcom-extras/Copy to clipboard Note: For the `` and `` information, see the Build-critical release tags section in the [Release Notes](https://docs.qualcomm.com/bundle/publicresource/topics/RNO-240626095531/). 2. Set up the Yocto build: # Export additional meta layers to EXTRALAYERS. Location is assumed under /layers. export EXTRALAYERS="meta-qcom-extras" # CUST_ID is used to clone the proprietary source repositories downloaded by meta-qcom-extras. # It enables source compilation for the corresponding binaries present in meta-qcom-hwe. # This ID is constant for the firmware repository qualcomm-linux-spf-1-0_ap_standard_oem_nm-qirpsdk.git. # CUST_ID must be initialized to for "Licensed customers with additional access". # For example, for distros like "Qualcomm_Linux.SPF.1.0|AP|Standard|OEM|" and "Qualcomm_Linux.SPF.1.0|AMSS|Standard|OEM|", # is provided while signing up for distros mapping to "Licensed customers with additional access". # To find , sign in to your account at qualcomm.com. # Click the profile icon, select Account Settings, and then scroll to Company Information section. # Use the number specified for Export ID as . export CUST_ID="213195" # The firmware recipe is compiled when the Yocto build is initiated. Firmware recipe expects the # path of firmware. You have generated firmware prebuilts (boot-critical and split-firmware binaries) # using the steps described in the previous section. The directory path must contain QCM6490_bootbinaries.zip, # QCM6490_dspso.zip, and QCM6490_fw.zip. # Set the environment variable to pick up the prebuilts: export FWZIP_PATH="/qualcomm-linux-spf-1-0_ap_standard_oem_nm-qimpsdk//common/build/ufs/bin" # An example is QCM6490.LE.1.0. For more information on , see the latest Release Notes. MACHINE=qcm6490 DISTRO=qcom-wayland source setup-environment # source setup-environment: Sets the environment settings, creates the build directory build-qcom-wayland, # and enters into build-qcom-wayland directory.Copy to clipboard 3. Compile the Yocto build: bitbake qcom-multimedia-imageCopy to clipboard Note: Clean the Yocto build: bitbake -fc cleansstate qcom-multimedia-image bitbake -fc cleanall qcom-multimedia-imageCopy to clipboard On successful build, you can check if `system.img` is present in the `/build-qcom-wayland/tmp-glibc/deploy/images/qcm6490/qcom-multimedia-image` directory: cd /build-qcom-wayland/tmp-glibc/deploy/images/qcm6490/qcom-multimedia-image ls -al system.imgCopy to clipboard 4. Flash the generated build using [Flash images for registered users](https://docs.qualcomm.com/doc/80-70014-254/topic/flash_images.html). ### Build QIMP SDK image with extras 1. Download QIMP SDK layers, Qualcomm Yocto, and supporting layers with extras: # cd to directory where you have 300 GB of free storage space to create your workspaces mkdir cd repo init -u https://github.com/quic-yocto/qcom-manifest -b qcom-linux-kirkstone -m # Example, is qcom-6.6.28-QLI.1.1-Ver.1.1.xml repo sync git clone https://qpm-git.qualcomm.com/home2/git/qualcomm/qualcomm-linux-spf-1-0_hlos_oem_metadata.git -b --depth 1 # Example, is r1.0_00041.0 mkdir -p layers/meta-qcom-extras cp -rf qualcomm-linux-spf-1-0_hlos_oem_metadata/QCM6490.LE.1.0/common/config/meta-qcom-extras/* layers/meta-qcom-extras/ git clone https://github.com/quic-yocto/meta-qcom-qim-product-sdk -b qcom-6.6.28-QLI.1.1-Ver.1.1_qim-product-sdk-1.1.3 layers/meta-qcom-qim-product-sdkCopy to clipboard Note: For the `` and `` information, see the Build-critical release tags section in the [Release Notes](https://docs.qualcomm.com/bundle/publicresource/topics/RNO-240626095531/). 2. Set up the Yocto build: # Export additional meta layers to EXTRALAYERS. Location is assumed under /layers. export EXTRALAYERS="meta-qcom-extras meta-qcom-qim-product-sdk" # CUST_ID is used to clone the proprietary source repositories downloaded by meta-qcom-extras. # It enables source compilation for the corresponding binaries present in meta-qcom-hwe. # This ID is constant for the firmware repository qualcomm-linux-spf-1-0_ap_standard_oem_nm-qirpsdk.git. # CUST_ID must be initialized to for "Licensed customers with additional access". # For example, for distros like "Qualcomm_Linux.SPF.1.0|AP|Standard|OEM|" and "Qualcomm_Linux.SPF.1.0|AMSS|Standard|OEM|", # is provided while signing up for distros mapping to "Licensed customers with additional access". # To find , sign in to your account at qualcomm.com. # Click the profile icon, select Account Settings, and then scroll to Company Information section. # Use the number specified for Export ID as . export CUST_ID="213195" # The firmware recipe is compiled when the Yocto build is initiated. Firmware recipe expects the # path of firmware. You have generated firmware prebuilts (boot-critical and split-firmware binaries) # using the steps described in the previous section. The directory path must contain QCM6490_bootbinaries.zip, # QCM6490_dspso.zip, and QCM6490_fw.zip. # Set the environment variable to pick up the prebuilts: export FWZIP_PATH="/qualcomm-linux-spf-1-0_ap_standard_oem_nm-qimpsdk//common/build/ufs/bin" # An example is QCM6490.LE.1.0. For more information on , see the latest Release Notes. MACHINE=qcm6490 DISTRO=qcom-wayland source setup-environment # source setup-environment: Sets the environment settings, creates the build directory build-qcom-wayland, # and enters into build-qcom-wayland directory.Copy to clipboard 3. Compile the QIMP SDK build: bitbake qcom-multimedia-image bitbake qim-product-sdkCopy to clipboard Note: Clean the QIMP SDK build: bitbake -fc cleansstate qcom-multimedia-image bitbake -fc cleanall qcom-multimedia-image bitbake -fc cleansstate qim-product-sdk bitbake -fc cleanall qim-product-sdkCopy to clipboard On successful build, you can check if `system.img` is present in the `/build-qcom-wayland/tmp-glibc/deploy/images/qcm6490/qcom-multimedia-image` directory: cd /build-qcom-wayland/tmp-glibc/deploy/images/qcm6490/qcom-multimedia-image ls -al system.imgCopy to clipboard 4. Flash the generated build using [Flash images for registered users](https://docs.qualcomm.com/doc/80-70014-254/topic/flash_images.html). ### Build QIRP SDK image with extras Note: Ensure that you have cloned the respective firmware for QIRP SDK. For example, `qualcomm-linux-spf-1-0_ap_standard_oem_nm-qirpsdk`. 1. Download QIRP SDK layers, Qualcomm Yocto, and supporting layers with extras: # cd to directory where you have 300 GB of free storage space to create your workspaces mkdir cd repo init -u https://github.com/quic-yocto/qcom-manifest -b qcom-linux-kirkstone -m # Example, is qcom-6.6.28-QLI.1.1-Ver.1.1.xml repo sync git clone https://qpm-git.qualcomm.com/home2/git/qualcomm/qualcomm-linux-spf-1-0_hlos_oem_metadata.git -b --depth 1 # Example, is r1.0_00041.0 mkdir -p layers/meta-qcom-extras mkdir -p layers/meta-qcom-robotics-extras cp -rf qualcomm-linux-spf-1-0_hlos_oem_metadata/QCM6490.LE.1.0/common/config/meta-qcom-extras/* layers/meta-qcom-extras/ cp -rf qualcomm-linux-spf-1-0_hlos_oem_metadata/QCM6490.LE.1.0/common/config/meta-qcom-robotics-extras/* layers/meta-qcom-robotics-extras/ git clone https://git.codelinaro.org/clo/le/meta-ros.git -b ros.qclinux.1.0.r1-rel layers/meta-ros git clone https://github.com/quic-yocto/meta-qcom-robotics.git layers/meta-qcom-robotics git clone https://github.com/quic-yocto/meta-qcom-robotics-distro.git layers/meta-qcom-robotics-distro git clone https://github.com/quic-yocto/meta-qcom-robotics-sdk.git layers/meta-qcom-robotics-sdk git clone https://github.com/quic-yocto/meta-qcom-qim-product-sdk -b layers/meta-qcom-qim-product-sdk # Example, is qcom-6.6.28-QLI.1.1-Ver.1.1_qim-product-sdk-1.1.3Copy to clipboard Note: For the ``, ``, and `` information, see the Build-critical release tags section in the [Release Notes](https://docs.qualcomm.com/bundle/publicresource/topics/RNO-240626095531/). 2. Set up the Yocto build: # Export additional meta layers to EXTRALAYERS. Location is assumed under /layers. export EXTRALAYERS="meta-qcom-extras meta-qcom-robotics-extras" # CUST_ID is used to clone the proprietary source repositories downloaded by meta-qcom-extras. # It enables source compilation for the corresponding binaries present in meta-qcom-hwe. # This ID is constant for the firmware repository qualcomm-linux-spf-1-0_ap_standard_oem_nm-qirpsdk.git. # CUST_ID must be initialized to for "Licensed customers with additional access". # For example, for distros like "Qualcomm_Linux.SPF.1.0|AP|Standard|OEM|" and "Qualcomm_Linux.SPF.1.0|AMSS|Standard|OEM|", # is provided while signing up for distros mapping to "Licensed customers with additional access". # To find , sign in to your account at qualcomm.com. # Click the profile icon, select Account Settings, and then scroll to Company Information section. # Use the number specified for Export ID as . export CUST_ID="213195" # The firmware recipe is compiled when the Yocto build is initiated. Firmware recipe expects the # path of firmware. You have generated firmware prebuilts (boot-critical and split-firmware binaries) # using the steps described in the previous section. The directory path must contain QCM6490_bootbinaries.zip, # QCM6490_dspso.zip, and QCM6490_fw.zip. # Set the environment variable to pick up the prebuilts: export FWZIP_PATH="/qualcomm-linux-spf-1-0_ap_standard_oem_nm-qirpsdk//common/build/ufs/bin" # An example is QCM6490.LE.1.0. For more information on , see the latest Release Notes.Copy to clipboard 3. Compile the QIRP SDK build: ln -s layers/meta-qcom-robotics-distro/set_bb_env.sh ./setup-robotics-environment ln -s layers/meta-qcom-robotics-sdk/scripts/qirp-build ./qirp-build MACHINE=qcm6490 DISTRO=qcom-robotics-ros2-humble source setup-robotics-environment # source setup-robotics-environment: Sets the environment settings, creates the build directory build-qcom-robotics-ros2-humble, # and enters into build-qcom-robotics-ros2-humble directory. ../qirp-build qcom-robotics-full-imageCopy to clipboard On a successful build, you can see the QIRP SDK build artifacts at the following paths: QIRP SDK artifacts: /build-qcom-robotics-ros2-humble/tmp-glibc/deploy/qirpsdk_artifacts/qirp-sdk_.tar.gz # system.img is present in the following path Robotics image: /build-qcom-robotics-ros2-humble/tmp-glibc/deploy/images/qcm6490/qcom-robotics-full-imageCopy to clipboard 4. Flash the generated build using [Flash images for registered users](https://docs.qualcomm.com/doc/80-70014-254/topic/flash_images.html). Last Published: Aug 07, 2024 [Previous Topic GitHub workflow for registered users](https://docs.qualcomm.com/bundle/publicresource/80-70014-254/topics/build_from_source_github_intro.md) [Next Topic Flash images for unregistered users](https://docs.qualcomm.com/bundle/publicresource/80-70014-254/topics/flash_images_unregistered.md)