Hexagon Toolchain on Ubuntu
Here is a comprehensive guide to setting up the Hexagon Toolchain on Ubuntu (Linux), primarily in the context of the Qualcomm Neural Processing SDK (SNPE) and DSP development.
✅ Verified Host OS
SNPE is verified with Ubuntu 22.04 LTS as the Linux host operating system, as well as WSL2 environments. 10
📦 Step 1: Install Qualcomm Package Manager 3 (QPM3)
The Hexagon Toolchain is distributed via QPM3. 17
- Download the Linux version of QPM3. The file name will look like:
QualcommPackageManager3.3.0.121.7.Linux-x86.deb - Install it with:
sudo dpkg -i ./<path-to-your-downloaded-.deb> - Launch the QPM3 app and log in with your Qualcomm ID. 17
🔍 Step 2: Identify Your Hexagon Architecture & SDK Version
Look up which Hexagon Architecture your chip supports (e.g., V68, V73, V75), then determine the correct Hexagon SDK version: 17
| Hexagon Architecture | Hexagon SDK Version |
|---|---|
| V75 | 5.4.0 |
| V73 | 5.4.0 |
| V69 | 4.3.0 |
| v68 | 4.2.0 |
| v66 | 4.1.0 |
⬇️ Step 3: Download the Hexagon SDK & Toolchain
- In QPM3, go to "Tools" and search for "Hexagon SDK".
- Download the correct SDK version for your target device.
- Return to the search bar and search for "Hexagon Toolchain", then choose the version corresponding to your Hexagon Architecture. 17
⚠️ Important Note: Hexagon SDK tools versions
8.7.03 / 8.6.02 / 8.5.03 / 8.4.09 / 8.4.06are not pre-packaged into their respective Hexagon SDK versions (5.4.0 / 4.3.0 / 4.2.0 / 4.1.0). They must be downloaded separately and placed at: 17$HEXAGON_SDK_ROOT/tools/HEXAGON_Tools/
🔧 Step 4: Set Environment Variables
After installation, set the required environment variables. For Hexagon SDK 3.5.x: 21
export HEXAGON_SDK_ROOT=<path to hexagon sdk installation>
export HEXAGON_TOOLS_ROOT=$HEXAGON_SDK_ROOT/tools/HEXAGON_Tools/8.3.07
export ANDROID_NDK_ROOT=<path to Android NDK installation>
export SDK_SETUP_ENV=Done
For Hexagon SDK 4.x (DSP V68 or later): 19
export HEXAGON_SDK_ROOT=<path to hexagon sdk installation>
export HEXAGON_SDK4_ROOT=<path to hexagon sdk 4.x installation>
export HEXAGON_TOOLS_ROOT=$HEXAGON_SDK_ROOT/tools/HEXAGON_Tools/8.4.09
export QNN_SDK_ROOT=<path to QNN sdk installation>
export ANDROID_NDK_ROOT=<path to Android NDK installation>
export SDK_SETUP_ENV=Done
Note:
$ANDROID_NDK_ROOTmust be set for the Android NDK build toolchain. 19
🔨 Step 5: Complete SDK Setup
Follow the remaining setup instructions found at: 16
$HEXAGON_SDK_ROOT/docs/readme.html
Also ensure clang++ is installed so you can compile code for DSP hardware. 16
🗂️ DSP Libraries in the SDK
The Qualcomm Neural Processing SDK includes Hexagon DSP runtime libraries under lib/hexagon-<dsp_version> in the SDK layout, compiled for your target's DSP architecture. 1
📝 Summary
| Step | Action |
|---|---|
| 1 | Install QPM3 on Ubuntu via .deb |
| 2 | Identify your chip's Hexagon Architecture |
| 3 | Download Hexagon SDK + Toolchain via QPM3 |
| 4 | Set HEXAGON_SDK_ROOT, HEXAGON_TOOLS_ROOT, etc. |
| 5 | Follow $HEXAGON_SDK_ROOT/docs/readme.html for final setup |
&spm=1001.2101.3001.5002&articleId=163833939&d=1&t=3&u=451000fa8d1448d1a8a849f5a68393a2)
333

被折叠的 条评论
为什么被折叠?



