{"id":15020631,"url":"https://github.com/umrninside/rpi-arm64","last_synced_at":"2025-10-14T14:45:59.597Z","repository":{"id":207188070,"uuid":"117321068","full_name":"UMRnInside/RPi-arm64","owner":"UMRnInside","description":"Build a Debian-based ARM64 system for Raspberry Pi 3 (and 3 B+ ?)","archived":false,"fork":false,"pushed_at":"2019-08-08T11:06:40.000Z","size":179,"stargazers_count":94,"open_issues_count":1,"forks_count":29,"subscribers_count":10,"default_branch":"master","last_synced_at":"2024-10-11T02:02:35.172Z","etag":null,"topics":["aarch64","linux","raspberry-pi","raspberry-pi-3"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"lgpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/UMRnInside.png","metadata":{"files":{"readme":"README-CN.md.old","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2018-01-13T06:45:25.000Z","updated_at":"2024-08-25T15:12:39.000Z","dependencies_parsed_at":"2023-11-14T14:57:22.363Z","dependency_job_id":null,"html_url":"https://github.com/UMRnInside/RPi-arm64","commit_stats":null,"previous_names":["umrninside/rpi-arm64"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UMRnInside%2FRPi-arm64","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UMRnInside%2FRPi-arm64/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UMRnInside%2FRPi-arm64/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UMRnInside%2FRPi-arm64/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/UMRnInside","download_url":"https://codeload.github.com/UMRnInside/RPi-arm64/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":219864035,"owners_count":16555943,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["aarch64","linux","raspberry-pi","raspberry-pi-3"],"created_at":"2024-09-24T19:55:21.864Z","updated_at":"2025-10-14T14:45:54.566Z","avatar_url":"https://github.com/UMRnInside.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# RPi-arm64\n为树莓派3构建基于Debian ARM64 的操作系统。\n\n目前支持:\n\n* **Stage 1:** 下载、准备、编译内核\n* **Stage 2:** 使用 _debootstrap_ 构建根文件系统\n* **Stage 3:** 安装bootcode和VideoCore libs\n* **Stage 4:** 离线操作 (例如添加用户)\n\n## Stage 1\n```\n./stage1/prepare_kernel.sh\n./stage1/build_kernel.sh\n```\n\n### 运行条件\n* 一些工具，比如：\n    * git\n    * patch\n    * 等等...\n* 交叉编译工具链，例如：\n    * Debian上的 _aarch64-linux-gnu-_， 可以通过安装`gcc-aarch64-linux-gnu`获得\n\n### 参数\n#### `FETCH_METHOD`\n指定获取内核源代码的方式 [默认值 wget]\n\n备选项 (**大小写敏感**):\n\n* git\n* wget\n\n    FETCH_METHOD=wget ./stage1/prepare_kernel.sh\n\n#### `ARCH`\n指定内核的目标架构 [默认值 arm64]\n\n    ARCH=arm64 ./stage1/build_kernel.sh\n#### `CROSS_COMPILE`\n指定交叉编译工具链 [默认值 aarch64-linux-gnu- ]\n\n    CROSS_COMPILE=aarcch64-linux-gnu- ./stage1/build_kernel.sh\n#### `JOBCOUNT`\n将向`make -j `传递 [默认值 $(nproc)]\n\n    JOBCOUNT=4 ./stage1/build_kernel.sh\n\n#### `BUILD_PATH`\n指定暂时放置内核的位置 [默认值 build ]\n\n    BUILD_PATH=./build ./stage1/build_kernel.sh\n#### `SKIP_KERNELFETCH`\n跳过内核下载.\n\n    SKIP_KERNELFETCH=1 ./stage1/build_kernel.sh\n\n### 其他信息:\n`prepare_kernel.sh` 会修改内核配置，详见：\n\n * [Issue 2117](https://github.com/raspberrypi/linux/issues/2117)\n * [Issue 2124](https://github.com/raspberrypi/linux/issues/2124)\n * [Issue 2136](https://github.com/raspberrypi/linux/issues/2136)\n\n## Stage 2\n```\n# 假装您使用root\n# 最先运行\n./stage2/root_debootstrap.sh\n\n# 安装内核模块\n./stage2/install_kernel.sh\n\n# firmware-brcm80211 是非自由软件包\n./stage2/enable_nonfree.sh\n./stage2/install_firmware_brcm.sh\n\n# 可选\n# 执行它们可以使您获得armhf/armel支持\n# 取消注释以启用它们\n#./stage2/enable_armhf.sh\n#./stage2/enable_armel.sh\n\n```\n\n### 运行条件\n* 以root运行\n* `debootstrap`\n* `chroot`\n* 在 ARM64 平台上运行，或者有可用的 `qemu-aarch64-static`\n\n### 参数\n#### `ROOT_PATH`\n指定根文件系统安置点\n它可以被手动移动至其它地方 [默认值 ./dist/rootfs/]\n\n**注意：** 如果您没有使用默认值，请处处指定它\n\n    sudo ROOT_PATH=./dist/rootfs ./stage2/root_debootstrap.sh\n\n#### `MIRROR`\n指定所使用的镜像源 [默认值 http://httpredir.debian.org/debian/]\n\n**注意：** `enable_nonfree.sh` 将在`$ROOT_PATH`内**覆盖 sources.list文件**\n\n    sudo MIRROR=\"https://mirrors.ustc.edu.cn/debian/\" ./stage2/root_debootstrap.sh\n    sudo MIRROR=\"https://mirrors.ustc.edu.cn/debian/\" ./stage2/enable_nonfree.sh\n\n#### `SUITE`\n指定发行代号, 这取决于`debootstrap` [默认值 stable]\n\n    sudo SUITE=stable ./stage2/root_debootstrap.sh\n    sudo SUITE=stable ./stage2/enable_nonfree.sh\n\n#### `DEB_INCLUDE`\n指定预先安装的软件包. [默认值 \"\"]\n\n    sudo DEB_INCLUDE=vim,wpasupplicant,hostapd,udhcpd ./stage2/root_debootstrap.sh\n\n## Stage 3\n```\n./stage3/bootcode_install.sh\n./stage3/kernel_install.sh\n```\n### 运行条件:\n* 在执行每个脚本时指定恰当且相同的 `BOOT_PATH` 和 `ROOT_PATH`，可以留空以使用默认值\n\n### 参数:\n#### `FETCH_METHOD`\n含义与`./stage1/prepare_kernel.sh`相同\n\nBootcode 来自 [Hexxeh/rpi-firmware](https://github.com/Hexxeh/rpi-firmware)\n\n#### `ROOT_PATH` and `BOOT_PATH`\n指定根目录和启动目录\n\n    sudo BOOT_PATH=/media/boot ./stage3/kernel_install.sh\n    sudo BOOT_PATH=/media/boot ROOT_PATH=/media/root ./stage3/bootcode_install.sh\n\n#### `INSTALL_VC`\n如果您不需要`/opt/vc`内的VideoCore库，请设置为0 \n\n    sudo BOOT_PATH=/media/boot ROOT_PATH=/media/root INSTALL_VC=1 ./stage3/bootcode_install.sh\n\n#### `FPTYPE`\n可选项:\n\n* `hardfp` (**默认值**)\n    需要 **armhf** 支持\n* `softfp`\n    需要 **armel** 支持\n\n\n    sudo FPTYPE=hardfp ./stage3/bootcode_install.sh\n\n## Stage 4\n```\n./stage4/passwd_root.sh\n./stage4/adduser.sh pi\n./stage4/setup_hostapd.sh\n```\n### 运行条件:\n* 在执行每个脚本时指定恰当且相同的 `BOOT_PATH` 和 `ROOT_PATH`，可以留空以使用默认值\n* 以root运行\n\n### 参数:\n#### `IFACE`\n指定 WLAN 接口名\n大多数情况下，使用默认的`wlan0`就可以正常工作了.\n\n    sudo IFACE=wlan0 ./stage4/setup_hostapd.sh\n\n#### `SSID` 和 `PSK`\n指定热点的名字(SSID)和口令(PSK)\n否则，脚本将自行生成随机值。\n\n    sudo SSID=Test PSK=changeme ./stage4/setup_hostapd.sh\n\n#### `IPADDR`\n指定 IP 地址 [默认值 172.16.233.1]\n\n    sudo IPADDR=172.16.233.1 ./stage4/setup_hostapd.sh\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fumrninside%2Frpi-arm64","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fumrninside%2Frpi-arm64","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fumrninside%2Frpi-arm64/lists"}