Skip to content

Commit

Permalink
Update kernel instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
ophub committed Feb 12, 2022
1 parent 1c303be commit 6d28e7c
Show file tree
Hide file tree
Showing 6 changed files with 95 additions and 2 deletions.
4 changes: 3 additions & 1 deletion README.cn.md
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,9 @@ sudo apt-get install -y $(curl -fsSL git.io/ubuntu-2004-server)

3. 在根目录下创建文件夹 `build/output/images` ,并上传 Armbian 镜像文件 ( 如:`Armbian_21.11.0-trunk_Lepotato_current_5.10.90.img` ) 到 `~/amlogic-s9xxx-armbian/build/output/images` 目录里。原版 Armbian 镜像文件名称中的发行版本号(如:`21.11.0`)和内核版本号(如:`5.10.90`)请保留,它将在重构后用作 Armbian 固件的名称。

4. 进入 `~/amlogic-s9xxx-armbian` 根目录,然后运行 `sudo ./rebuild -d -b s905x3 -k 5.4.170` 命令即可生成指定 soc 的 Armbian 镜像文件。生成的文件保存在 `build/output/images` 目录里。
4.`~/amlogic-s9xxx-armbian/build-armbian/amlogic-kernel` 目录下创建版本号对应的文件夹,如 `5.4.170` ,并将内核文件放入此目录。使用方法见 [build-armbian/amlogic-kernel/README.md](build-armbian/amlogic-kernel/README.md)

5. 进入 `~/amlogic-s9xxx-armbian` 根目录,然后运行 `sudo ./rebuild -d -b s905x3 -k 5.4.170` 命令即可生成指定 soc 的 Armbian 镜像文件。生成的文件保存在 `build/output/images` 目录里。

- ### 使用 GitHub Action 进行编译

Expand Down
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,9 @@ sudo apt-get install -y $(curl -fsSL git.io/ubuntu-2004-server)

3. Create the `build/output/images` folder, and upload the Armbian image ( Eg: `Armbian_21.11.0-trunk_Lepotato_current_5.10.90.img` ) to this `~/amlogic-s9xxx-armbian/build/output/images` directory. Please keep the release version number (e.g. `21.11.0`) and kernel version number (e.g. `5.10.90`) in the name of the original Armbian image file, It will be used as the name of the armbian firmware after rebuilding.

4. Enter the `~/amlogic-s9xxx-armbian` root directory. And run Eg: `sudo ./rebuild -d -b s905x3 -k 5.4.170` to build armbian for `amlogic s9xxx`. The generated Armbian image is in the `build/output/images` directory under the root directory.
4. Create a folder corresponding to the version number in the `~/amlogic-s9xxx-armbian/build-armbian/amlogic-kernel` directory, such as `5.4.170` , and put the kernel files in this directory. For usage, see [build-armbian/amlogic-kernel/README.md](build-armbian/amlogic-kernel/README.md)

5. Enter the `~/amlogic-s9xxx-armbian` root directory. And run Eg: `sudo ./rebuild -d -b s905x3 -k 5.4.170` to build armbian for `amlogic s9xxx`. The generated Armbian image is in the `build/output/images` directory under the root directory.

- ### Use GitHub Action to build

Expand Down
32 changes: 32 additions & 0 deletions build-armbian/README.cn.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# Amlogic s9xxx 系列内核相关文件说明

查看英文说明 | [View English description](README.md)

在相关目录中存储了一些与 Amlogic s9xxx 内核相关的编译 Armbian 所需的文件。

## amlogic-armbian

这里存放的文件是打包 Armbian 时需要使用的相关文件。

## amlogic-dtb

这里收录了各种型号机顶盒使用的 .dtb 文件,当你在使用安装脚本 `armbian-install` 将 Armbian 写入 EMMC 时,当你选择 `0` 进行自选 .dtb 文件安装时,需要填写具体的 .dtb 文件名称,你可以从这里查阅准确的文件名并填写。

## amlogic-kernel

`amlogic-kernel` 目录下存放的是编译 Armbian 需要的内核文件,使用方法见 [amlogic-kernel/README.md](amlogic-kernel/README.md)

## amlogic-u-boot

当你使用 5.10 内核的 Armbian 时,需要将 u-boot 文件复制为 `u-boot.ext` ,在 EMMC 中使用时,需要将 u-boot 文件复制为 `u-boot.emmc` 。这些复制工作在仓库的打包和安装/升级脚本中均已自动化完成,无需在人工复制。各型号对应的具体文件详见 [amlogic-u-boot](amlogic-u-boot)

## common-files

- files: 这里存放的是 Armbian 固件的个性化配置文件,将在打包脚本 `sudo ./rebuild` 执行时自动将相关文件集成到你的固件里。相关目录及文件命名均须与 Armbian 中 ROOTFS 分区 ( 即在 TTYD 终端里输入: `cd / && ls .` 你所看到的目录及各目录里面的文件名称 ) 保持完全一致。

```yaml
etc/config/network
lib/u-boot
```

- patches: 这是补丁文件存放目录,你可以将扩展文件,补丁等放置在该目录。
33 changes: 33 additions & 0 deletions build-armbian/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# amlogic-s9xxx kernel related files

View Chinese description | [查看中文说明](README.cn.md)

Some files needed for compilation related to amlogic-s9xxx kernel are stored in the directory.

## amlogic-armbian

The files stored here are related files that need to be used when packaging Armbian.

## amlogic-dtb

For more Armbian firmware .dtb files are in the amlogic-dtb directory. When writing into EMMC through `armbian-install`, select `0`: Enter the dtb file name of your box.

## amlogic-kernel

The kernel files needed to compile Armbian are stored in the `amlogic-kernel` directory. For usage, see [amlogic-kernel/README.md](amlogic-kernel/README.md)

## amlogic-u-boot

When using the 5.10 kernel version, you need to copy the corresponding [u-boot-*.bin](amlogic-u-boot) file to `u-boot.ext` (TF/SD card boot file) and `u-boot.emmc` (EMMC boot file).

## common-files

- files: The files in the `common-files/files` directory are custom files, which must be completely consistent with the structure and file naming and storage under the ***`ROOTFS`*** partiton in Armbian. If there are files in this directory, they will be automatically copied to the Armbian directory during `sudo ./rebuild`. E.g:

```yaml
etc/config/network
lib/u-boot
```

- patches: This is the directory where patch files are stored. You can place extension files, patches, etc. in this directory.

Empty file.
24 changes: 24 additions & 0 deletions build-armbian/amlogic-kernel/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Kernel Instructions / 内核使用说明

- Create a folder corresponding to the version number in the `amlogic-kernel` directory, such as `5.4.170` , and put the 4 needed kernel files into this directory (Other kernel files are not required, and putting them in does not affect use). Multiple kernels create directories in turn and put corresponding kernel files. Kernel files can be downloaded from the [kernel](https://github.com/ophub/kernel) repository or [custom compilation](https://github.com/ophub/amlogic-s9xxx-armbian/tree/main/compile-kernel). If the kernel file is not downloaded and stored manually, the script will also be automatically downloaded from the kernel repository at compile time.

-`amlogic-kernel` 目录下创建版本号对应的文件夹,如 `5.4.170` ,并将 4 个需要的内核文件放入此目录 (其他内核文件不需要,放入也不影响使用)。多个内核依次创建目录并放入对应的内核文件。内核文件可以从 [kernel](https://github.com/ophub/kernel) 仓库下载,也可以[自定义编译](https://github.com/ophub/amlogic-s9xxx-armbian/tree/main/compile-kernel)。如果没有手动下载存放内核文件,在编译时脚本也会自动从 kernel 仓库下载。

```yaml
~/amlogic-s9xxx-openwrt
└── amlogic-s9xxx
└── amlogic-kernel
├── 5.4.170
│ ├── header-5.4.170-xxx.tar.gz
│ ├── boot-5.4.170-xxx.tar.gz
│ ├── dtb-amlogic-5.4.170-xxx.tar.gz
│ └── modules-5.4.170-xxx.tar.gz
├── 5.10.90
│ ├── header-5.10.90-xxx.tar.gz
│ ├── boot-5.10.90-xxx.tar.gz
│ ├── dtb-amlogic-5.10.90-xxx.tar.gz
│ └── modules-5.10.90-xxx.tar.gz
├── more kernel...
```

0 comments on commit 6d28e7c

Please sign in to comment.