Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Arc speed #5

Closed
wants to merge 9 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 21 additions & 7 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,26 +3,32 @@ name: Compile and publish kernels
on:
push:
branches:
- fd4.10
- ARC-Migration
- arc-speed

env:
- BUILD_ARCHES: ["armel", "mipseb", "mipsel", "mips64eb", "mips64el"]

jobs:
build:
runs-on: ubuntu-latest

runs-on: panda-arc
strategy:
matrix:
arch: ${{ env.BUILD_ARCHES }}
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Build
run: |
bash docker_build.sh
tar -czvf kernels-latest.tar.gz binaries
bash docker_build.sh ${{ matrix.arch }}
tar -c -I 'xz -6 -T0' -f kernels-latest-${{ matrix.arch }}.tar.xz binaries

- name: Save package
uses: actions/upload-artifact@v3
with:
name: kernels-latest.tar.gz
path: kernels-latest.tar.gz
name: kernels-latest-${{ matrix.arch }}.tar.gx
path: kernels-latest-${{ matrix.arch }}.tar.gx

- name: Create release
id: create_release
Expand All @@ -36,6 +42,14 @@ jobs:
Release @${{ github.ref }}
draft: true
prerelease: false
- name: Download all workflow run artifacts
uses: actions/download-artifact@v3

- name: Combine all artifacts
run: |
mkdir -p binaries
for f in ${{ env.BUILD_ARCHES }}; do mv "kernels-latest-$f.tar.gz" binaries; done
tar -cvf kernels-latest.tar binaries
- name: Upload release asset
uses: actions/upload-release-asset@v1
env:
Expand Down
9 changes: 7 additions & 2 deletions docker_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,13 @@
#Commented out target list is what we'd like to have, but haven't tested
#TARGETLIST="armel armeb mipseb mipsel mips64 mips64el aarch64"
#These targets are ones we've tested
TARGETLIST="armel mipseb mipsel mips64eb mips64el"

ALL_TARGETS="armel mipseb mipsel mips64eb mips64el"
if [ ! -z $1 ]
then
TARGETLIST=$1
else
TARGETLIST=$ALL_TARGETS
fi
docker build -t igloo_kernel_builder . || exit
docker run --rm -v `realpath .`:/linux -w /linux -e IGLOO_TARGETLIST="$TARGETLIST" -e DOCKER_USER="$USER" \
igloo_kernel_builder xonsh docker_inner_build_targets.xsh
4 changes: 2 additions & 2 deletions docker_inner_build_targets.xsh
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ $NPROC=$(nproc).strip()
cd $BUILD_ROOT

for arch in TARGETLIST:
make mrproper
make mrproper -j$NPROC
TARGETS=["vmlinux"]
if "arm" in arch:
TARGETS.append("zImage")
Expand All @@ -59,7 +59,7 @@ for arch in TARGETLIST:
$CROSS_CC=get_cc(arch)
mkdir -p f"build/{arch}"
cp f"config.{arch}" f"build/{arch}/.config"
make ARCH=@(short_arch) CROSS_COMPILE=$CROSS_CC O=build/@(arch) olddefconfig
make ARCH=@(short_arch) CROSS_COMPILE=$CROSS_CC O=build/@(arch) olddefconfig -j$NPROC

echo "Building kernel"
make ARCH=@(short_arch) CROSS_COMPILE=$CROSS_CC O=build/@(arch) @(TARGETS) -j$NPROC
Expand Down