diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 97487e4..9030c05 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,6 +1,9 @@ on: [pull_request] jobs: build: + env: + YOCTO_VERSION: 3.2.3 + YOCTO_BRANCH: gatesgarth runs-on: self-hosted steps: - uses: actions/checkout@v2 @@ -10,9 +13,9 @@ jobs: run: | mv poky/build/sstate-cache . || true rm -rf poky meta-openembedded - git clone -b gatesgarth --single-branch git://git.yoctoproject.org/poky - git clone -b gatesgarth --single-branch git://git.openembedded.org/meta-openembedded - - name: Run bitbake + git clone -b yocto-$YOCTO_VERSION --single-branch git://git.yoctoproject.org/poky + git clone -b $YOCTO_BRANCH --single-branch git://git.openembedded.org/meta-openembedded + - name: Configure build run: | cd poky . oe-init-build-env @@ -20,17 +23,19 @@ jobs: bitbake-layers add-layer ../../meta-openembedded/meta-oe bitbake-layers add-layer ../../meta-rust echo 'PARALLEL_MAKE_pn-rust-llvm-native = "-j2"' >> conf/local.conf + echo 'TOOLCHAIN_HOST_TASK_append = " packagegroup-rust-cross-canadian-${MACHINE}"' >> conf/local.conf + echo "SSTATE_MIRRORS = \"file://.* http://sstate.yoctoproject.org/$YOCTO_VERSION/PATH;downloadfilename=PATH \\n\"" >> conf/local.conf + echo 'PREFERRED_PROVIDER_virtual/kernel = "linux-dummy"' >> conf/local.conf + - name: Run bitbake + run: | + cd poky + . oe-init-build-env bitbake rust-hello-world - name: Test SDK run: | SDK_DIR=$PWD/sdk-test cd poky . oe-init-build-env - echo 'TOOLCHAIN_HOST_TASK_append = " packagegroup-rust-cross-canadian-${MACHINE}"' >> conf/local.conf - echo 'PREFERRED_PROVIDER_virtual/kernel = "linux-dummy"' >> conf/local.conf - echo 'DISTRO_FEATURES_remove = "acl alsa argp bluetooth ext2 ipv4 ipv6 largefile pcmcia usbgadget usbhost wifi xattr nfs zeroconf pci 3g nfc x11 vfat largefile opengl ptest multiarch wayland vulkan pulseaudio gobject-introspection-data ldconfig"' >> conf/local.conf - echo 'IMAGE_INSTALL_remove = "packagegroup-core-boot"' >> conf/local.conf - echo 'VIRTUAL-RUNTIME_dev_manager = ""' >> conf/local.conf bitbake core-image-minimal -c populate_sdk rm -rf $SDK_DIR ./$(find ./tmp/deploy/sdk/ -name '*.sh') -d $SDK_DIR -y