Fix typo #209
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: R2S-OpenWrt | |
on: | |
push: | |
branches: | |
- main | |
paths: | |
- '.github/workflows/R2S-OpenWrt.yml' | |
- 'SEED/R2S/config.seed' | |
- 'SEED/extra.cfg' | |
- 'SCRIPTS/switch' | |
# watch: | |
# types: [started] | |
jobs: | |
build: | |
runs-on: ubuntu-24.04 | |
if: github.event.repository.owner.id == github.event.sender.id | |
steps: | |
- name: Maximize build space | |
uses: easimon/maximize-build-space@master | |
with: | |
swap-size-mb: 1024 | |
temp-reserve-mb: 512 | |
root-reserve-mb: 4096 | |
remove-dotnet: 'true' | |
remove-android: 'true' | |
remove-haskell: 'true' | |
remove-codeql: 'true' | |
- name: Checkout | |
uses: actions/checkout@main | |
- name: Show CPU Model | |
run: | | |
echo -e "Total CPU cores\t: $(nproc)" | |
cat /proc/cpuinfo | grep 'model name' | |
ulimit -a | |
- name: Init build dependencies | |
env: | |
DEBIAN_FRONTEND: noninteractive | |
run: | | |
sudo -E apt-get -qq update | |
sudo /bin/bash -c "$(curl -sL https://git.io/vokNn)" | |
sudo -E apt-fast -y -qq install asciidoc bash bcc bin86 binutils bison bzip2 clang-15 llvm-15 file flex g++ g++-multilib gawk gcc gcc-multilib gettext git gzip help2man intltool libboost-dev libelf-dev libncurses-dev libncurses5-dev libssl-dev libthread-queue-any-perl libusb-dev libxml-parser-perl make patch perl-modules python3-dev python3-pip python3-pyelftools python3-setuptools rsync sharutils swig time unzip util-linux wget xsltproc zlib1g-dev zip | |
sudo -E apt-fast -y -qq install dos2unix dwarves quilt | |
pip3 install --user -U pylibfdt --break-system-packages | |
sudo -E apt-get -qq autoremove --purge | |
sudo -E apt-get -qq clean | |
sudo -E git config --global user.name 'GitHub Actions' && git config --global user.email 'noreply@github.com' | |
sudo -E git config --global core.abbrev auto | |
df -h | |
- name: Prepare Mixedwrt | |
run: | | |
sudo chown -R runner:runner /home/runner/work/OpenWrt-Autobuild | |
cp -r ./SCRIPTS/R2S/. ./SCRIPTS/ | |
cp -r ./SCRIPTS/. ./ | |
/bin/bash 01_get_ready.sh | |
- name: Prepare Package | |
working-directory: ${{ github.workspace }}/openwrt | |
run: | | |
cp -r ../SCRIPTS/. ./ | |
/bin/bash 02_prepare_package.sh | |
/bin/bash 02_R2S.sh | |
- name: Convert Translation | |
working-directory: ${{ github.workspace }}/openwrt | |
run: | | |
/bin/bash 03_convert_translation.sh | |
- name: Remove Upx | |
working-directory: ${{ github.workspace }}/openwrt | |
run: | | |
/bin/bash 04_remove_upx.sh | |
- name: Add ACL | |
working-directory: ${{ github.workspace }}/openwrt | |
run: | | |
/bin/bash 05_create_acl_for_luci.sh -a | |
- name: Fix Permissions | |
working-directory: ${{ github.workspace }}/openwrt | |
run: | | |
sudo -E chmod -R 755 ./08_fix_permissions.sh | |
/bin/bash 08_fix_permissions.sh | |
- name: Make Config | |
working-directory: ${{ github.workspace }}/openwrt | |
run: | | |
mv ../SEED/R2S/config.seed .config | |
make defconfig | |
- name: Smart chmod | |
run: | | |
MY_Filter=$(mktemp) | |
echo '/\.git' > ${MY_Filter} | |
echo '/\.svn' >> ${MY_Filter} | |
find ./ -maxdepth 1 | grep -v '\./$' | grep -v '/\.git' | xargs -s1024 chmod -R u=rwX,og=rX | |
find ./ -type f | grep -v -f ${MY_Filter} | xargs -s1024 file | grep 'executable\|ELF' | cut -d ':' -f1 | xargs -s1024 chmod 755 | |
rm -f ${MY_Filter} | |
unset MY_Filter | |
- name: Make Download | |
working-directory: ${{ github.workspace }}/openwrt | |
run: | | |
make download -j48 | |
- name: Make Toolchain | |
working-directory: ${{ github.workspace }}/openwrt | |
run: | | |
IGNORE_ERRORS=1 make toolchain/install -j$(($(nproc) + 1)) V=s | |
- name: Compile Openwrt | |
working-directory: ${{ github.workspace }}/openwrt | |
run: | | |
IGNORE_ERRORS=1 make -j$(($(nproc) + 1)) V=s | |
- name: Cleaning | |
working-directory: ${{ github.workspace }}/openwrt | |
run: | | |
cd bin/targets/rockchip/armv8 | |
/bin/bash ../../../../../SCRIPTS/06_cleaning.sh | |
- name: Print Disk Space After | |
run: df -h | |
- name: Upload Firmwares | |
uses: actions/upload-artifact@main | |
with: | |
name: R2S-OpenWrt | |
path: openwrt/bin/targets/rockchip/armv8/ |