Skip to content

Commit 6d532cf

Browse files
committed
Add toolchain reference documentation
0 parents  commit 6d532cf

1 file changed

Lines changed: 73 additions & 0 deletions

File tree

README.md

Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
# HiSilicon Cross-Compilation Toolchains
2+
3+
Cross-compiler toolchains extracted from HiSilicon SDKs, hosted as release assets for use in CI pipelines.
4+
5+
## Toolchain Reference
6+
7+
| Toolchain | GCC | Libc | Float | Default arch | Multilib targets | `CROSS_COMPILE` | Source SDKs |
8+
|-----------|-----|------|-------|-------------|-----------------|-----------------|-------------|
9+
| arm-hisiv300-linux | 4.8.3 (Linaro) | uClibc 0.9.33.2 | softfp | armv5te | ARM926, A9, A7 | `arm-hisiv300-linux-uclibcgnueabi-` | Hi3518E_SDK_V1.0.4.0, Hi3516A_SDK_V1.0.5.0 |
10+
| arm-hisiv500-linux | 4.9.4 (Linaro) | uClibc 0.9.33.2 | softfp | armv5te | ARM926, A9, A7 | `arm-hisiv500-linux-uclibcgnueabi-` | Hi3516CV300_SDK, Hi3516C V300R001C01SPC040 |
11+
| arm-hisiv510-linux | 6.2.1 (Linaro) | uClibc 0.9.33.2 | softfp | armv5te | ARM926, A9, A7, A17, A53, A73, M7 | `arm-hisiv510-linux-uclibcgnueabi-` | Hi3518E V200R001C01SPC050, Hi3516A V100R001C01SPC080 |
12+
| arm-hisiv600-linux | 4.9.4 (Linaro) | glibc 2.20 | softfp | armv5te | ARM926, A9, A7 | `arm-hisiv600-linux-gnueabi-` | Hi3516C V300R001C02SPC040 |
13+
| arm-himix100-linux | 6.3.0 | uClibc 0.9.33.2 | softfp | armv5te | ARM926, A9, A7, A17, A53, A73 | `arm-himix100-linux-` | Hi3516EV200 series |
14+
| arm-himix200-linux | 6.3.0 | glibc 2.24 | softfp | armv5te | ARM926, A9, A7, A17, A53, A73 | `arm-himix200-linux-` | Hi3516CV500, Hi3519V101 |
15+
16+
All toolchains default to soft-float ABI (gnueabi). Hard-float variants are available via multilib flags, e.g.:
17+
18+
```sh
19+
-mcpu=cortex-a7 -mfloat-abi=hard -mfpu=neon-vfpv4
20+
```
21+
22+
## Archive Format
23+
24+
Most archives are `.tgz` files with a nested structure:
25+
26+
```
27+
<name>.tgz
28+
+-- <name>/
29+
+-- <name>.tar.bz2 # actual toolchain
30+
+-- <name>.install # vendor install script (not needed for CI)
31+
+-- runtime_*.tgz # runtime libraries
32+
```
33+
34+
**Exceptions:**
35+
36+
- `arm-hisiv300-linux.tar.bz2` is the inner archive directly (no `.tgz` wrapper).
37+
- `arm-himix200-linux.tgz` is split into two parts due to the 2 GB GitHub release asset limit.
38+
39+
## Usage in CI
40+
41+
### Extracting
42+
43+
```sh
44+
# Standard .tgz archives (two-step extraction)
45+
tar xzf arm-hisiv510-linux.tgz
46+
tar xjf arm-hisiv510-linux/arm-hisiv510-linux.tar.bz2
47+
48+
# arm-hisiv300 (single-step, bare tar.bz2)
49+
tar xjf arm-hisiv300-linux.tar.bz2
50+
51+
# arm-himix200 (reassemble split parts first)
52+
cat arm-himix200-linux.tgz.part* > arm-himix200-linux.tgz
53+
tar xzf arm-himix200-linux.tgz
54+
tar xjf arm-himix200-linux/arm-himix200-linux.tar.bz2
55+
```
56+
57+
### Building
58+
59+
The vendor install script creates `target/bin/` with absolute symlinks to `/opt/hisi-linux/...` which only work on the original install path. For CI, use the full `CROSS_COMPILE` prefix (from the table above) with the `bin/` directory on `PATH`:
60+
61+
```sh
62+
export PATH="$PWD/arm-hisiv510-linux/bin:$PATH"
63+
make CROSS_COMPILE=arm-hisiv510-linux-uclibcgnueabi-
64+
```
65+
66+
### Downloading in GitHub Actions
67+
68+
```yaml
69+
- name: Download toolchain
70+
env:
71+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
72+
run: gh release download v1 -R OpenIPC/toolchains -p 'arm-hisiv510-linux.tgz'
73+
```

0 commit comments

Comments
 (0)