diff options
author | Khem Raj <raj.khem@gmail.com> | 2020-09-15 00:36:24 -0700 |
---|---|---|
committer | Khem Raj <raj.khem@gmail.com> | 2020-09-16 11:09:57 -0700 |
commit | 7a9b817cc144d4daf31af281825f25889b2d549d (patch) | |
tree | 285aa1c9831bf45acbae728cf610374cbd3b3a24 | |
parent | e47ed0398fdaeee872cea9990117db31baede1a4 (diff) | |
download | meta-clang-7a9b817cc144d4daf31af281825f25889b2d549d.tar.gz |
Add support for github actions
Signed-off-by: Khem Raj <raj.khem@gmail.com>
-rw-r--r-- | .drone.yml | 83 | ||||
-rw-r--r-- | .github/workflows/yoe.yml | 79 | ||||
-rw-r--r-- | README.md | 2 |
3 files changed, 80 insertions, 84 deletions
diff --git a/.drone.yml b/.drone.yml deleted file mode 100644 index a96ba46..0000000 --- a/.drone.yml +++ /dev/null | |||
@@ -1,83 +0,0 @@ | |||
1 | kind: pipeline | ||
2 | type: exec | ||
3 | name: arm64 | ||
4 | |||
5 | platform: | ||
6 | os: linux | ||
7 | arch: arm64 | ||
8 | |||
9 | clone: | ||
10 | disable: false | ||
11 | |||
12 | trigger: | ||
13 | branch: | ||
14 | - master | ||
15 | event: | ||
16 | - push | ||
17 | - pull_request | ||
18 | |||
19 | steps: | ||
20 | - name: build | ||
21 | commands: | ||
22 | - git clone --recurse-submodules -j8 git://github.com/YoeDistro/yoe-distro.git yoe | ||
23 | - cd yoe | ||
24 | - git checkout -b test origin/master | ||
25 | - git pull | ||
26 | - git submodule update --recursive --init | ||
27 | - rm -rf sources/meta-clang | ||
28 | - ln -sf `pwd`/../ sources/meta-clang | ||
29 | - export DOCKER_REPO=none | ||
30 | - export LANG=en_US.UTF-8 | ||
31 | - export SSTATE_CACHE_DIR=/scratch/sstate-cache | ||
32 | - echo "Started build# $DRONE_BUILD_NUMBER" | ||
33 | - echo "sstate cache dir = $SSTATE_CACHE_DIR" | ||
34 | - echo "building $DRONE_GIT_HTTP_URL, branch $DRONE_SOURCE_BRANCH" | ||
35 | - echo export DOCKER_REPO=none > local.sh | ||
36 | - echo export LANG=en_US.UTF-8 >> local.sh | ||
37 | - echo export SSTATE_CACHE_DIR=/scratch/sstate-cache >> local.sh | ||
38 | - cp conf/local.conf.sample conf/local.conf | ||
39 | - echo SSTATE_DIR = \"$SSTATE_CACHE_DIR\" >> conf/local.conf | ||
40 | - echo IMAGE_CLASSES += \"testimage testsdk\" >> conf/local.conf | ||
41 | - echo INHERIT += \"report-error rm_work blacklist\" >> conf/local.conf | ||
42 | - echo ERR_REPORT_SERVER = \"errors.yoctoproject.org\" >> conf/local.conf | ||
43 | - echo ERR_REPORT_PORT = \"80\" >> conf/local.conf | ||
44 | - echo ERR_REPORT_USERNAME = \"Drone Autobuilder\" >> conf/local.conf | ||
45 | - echo ERR_REPORT_EMAIL = \"info@yoedistro.org\" >> conf/local.conf | ||
46 | - echo TOOLCHAIN = \"clang\" >> conf/local.conf | ||
47 | - echo CLANGSDK = \"1\" >> conf/local.conf | ||
48 | - echo IMAGE_INSTALL_append = \" clang \" >> conf/local.conf | ||
49 | - echo XZ_DEFAULTS = \"--threads=8\" >> conf/local.conf | ||
50 | - echo LICENSE_FLAGS_WHITELIST_append = \" commercial non-commercial\" >> conf/local.conf | ||
51 | #- echo TESTIMAGE_AUTO_qemuall = \"1\" >> conf/local.conf | ||
52 | - /bin/bash -c ". ./qemux86-64-envsetup.sh && bitbake yoe-debug-image -cpopulate_sdk" | ||
53 | - /bin/bash -c ". ./qemux86-64-envsetup.sh && ./sources/openembedded-core/scripts/sstate-cache-management.sh -d -y" | ||
54 | --- | ||
55 | kind: pipeline | ||
56 | type: exec | ||
57 | name: cleanup | ||
58 | |||
59 | platform: | ||
60 | os: linux | ||
61 | arch: arm64 | ||
62 | |||
63 | clone: | ||
64 | disable: true | ||
65 | |||
66 | trigger: | ||
67 | branch: | ||
68 | - master | ||
69 | event: | ||
70 | - push | ||
71 | - pull_request | ||
72 | status: | ||
73 | - success | ||
74 | - failure | ||
75 | |||
76 | steps: | ||
77 | - name: clean | ||
78 | commands: | ||
79 | - echo "Deleting tmpdir for build# $DRONE_BUILD_NUMBER" | ||
80 | - rm -rf /scratch/tmp-clang-$DRONE_BUILD_NUMBER | ||
81 | |||
82 | depends_on: | ||
83 | - arm64 | ||
diff --git a/.github/workflows/yoe.yml b/.github/workflows/yoe.yml new file mode 100644 index 0000000..bdb4c30 --- /dev/null +++ b/.github/workflows/yoe.yml | |||
@@ -0,0 +1,79 @@ | |||
1 | name: Yoe Distro CI | ||
2 | |||
3 | on: | ||
4 | # Trigger the workflow on push or pull request, | ||
5 | # but only for the master branch | ||
6 | push: | ||
7 | branches: | ||
8 | - master | ||
9 | - dunfell | ||
10 | pull_request: | ||
11 | branches: | ||
12 | - master | ||
13 | - dunfell | ||
14 | jobs: | ||
15 | build: | ||
16 | name: Yoe Build | ||
17 | runs-on: [self-hosted, Linux] | ||
18 | timeout-minutes: 720 | ||
19 | steps: | ||
20 | - name: Checkout | ||
21 | uses: actions/checkout@v2.3.2 | ||
22 | with: | ||
23 | fetch-depth: 0 | ||
24 | submodules: recursive | ||
25 | - name: checkout yoe | ||
26 | run: | | ||
27 | git clone --recurse-submodules -j8 -b master git://github.com/YoeDistro/yoe-distro.git yoe | ||
28 | cd yoe | ||
29 | git checkout master | ||
30 | git pull | ||
31 | git submodule update --recursive --init | ||
32 | rm -rf sources/meta-clang | ||
33 | rsync -av --progress --exclude="yoe" `pwd`/../ sources/meta-clang/ | ||
34 | - name: Setup | ||
35 | run: | | ||
36 | cd yoe | ||
37 | export DOCKER_REPO=none | ||
38 | export LANG=en_US.UTF-8 | ||
39 | export SSTATE_CACHE_DIR=/scratch/sstate-cache | ||
40 | echo export DOCKER_REPO=none > local.sh | ||
41 | echo export LANG=en_US.UTF-8 >> local.sh | ||
42 | echo export SSTATE_CACHE_DIR=/scratch/sstate-cache >> local.sh | ||
43 | cp conf/local.conf.sample conf/local.conf | ||
44 | echo SSTATE_DIR = \"$SSTATE_CACHE_DIR\" >> conf/local.conf | ||
45 | echo IMAGE_CLASSES += \"testimage testsdk\" >> conf/local.conf | ||
46 | echo INHERIT += \"report-error rm_work\" >> conf/local.conf | ||
47 | echo ERR_REPORT_SERVER = \"errors.yoctoproject.org\" >> conf/local.conf | ||
48 | echo ERR_REPORT_PORT = \"80\" >> conf/local.conf | ||
49 | echo ERR_REPORT_USERNAME = \"Drone Autobuilder\" >> conf/local.conf | ||
50 | echo ERR_REPORT_EMAIL = \"info@yoedistro.org\" >> conf/local.conf | ||
51 | echo TOOLCHAIN = \"clang\" >> conf/local.conf | ||
52 | echo CLANGSDK = \"1\" >> conf/local.conf | ||
53 | echo IMAGE_INSTALL_append = \" clang \" >> conf/local.conf | ||
54 | echo XZ_DEFAULTS = \"--threads=8\" >> conf/local.conf | ||
55 | echo SDKMACHINE = \"aarch64\" >> conf/local.conf | ||
56 | /bin/bash -c "sed -i -e 's/PACKAGE_FEED_URI.*$//' conf/site.conf" | ||
57 | /bin/bash -c "sed -i -e 's/SDK_UPDATE_URL.*$//' conf/site.conf" | ||
58 | /bin/bash -c "sed -i -e 's/backend=fbdev-backend.so.*$//' sources/openembedded-core/meta/recipes-graphics/wayland/weston-init/qemuall/weston.ini" | ||
59 | - name: Build Image | ||
60 | run: | | ||
61 | cd yoe | ||
62 | /bin/bash -c ". ./qemuarm64-envsetup.sh && bitbake yoe-qt5-image yoe-sdk-image yoe-debug-image" | ||
63 | - name: Build SDK | ||
64 | run: | | ||
65 | cd yoe | ||
66 | /bin/bash -c ". ./qemuarm64-envsetup.sh && bitbake yoe-debug-image -cpopulate_sdk_ext" | ||
67 | - name: Test Image | ||
68 | run: | | ||
69 | cd yoe | ||
70 | echo TESTIMAGE_AUTO_qemuall = \"1\" >> conf/local.conf | ||
71 | /bin/bash -c ". ./qemuarm64-envsetup.sh && bitbake yoe-sdk-image" | ||
72 | - name: Prepare results | ||
73 | run: | | ||
74 | cd yoe | ||
75 | /bin/bash -c ". ./qemuarm64-envsetup.sh && resulttool report build/tmp/log/oeqa" | ||
76 | - name: Clean shared state | ||
77 | run: | | ||
78 | cd yoe | ||
79 | /bin/bash -c ". ./qemuarm64-envsetup.sh && ./sources/openembedded-core/scripts/sstate-cache-management.sh -d -y" | ||
@@ -1,4 +1,4 @@ | |||
1 | [![Build Status](https://drone.yoedistro.org/api/badges/kraj/meta-clang/status.svg)](https://drone.yoedistro.org/kraj/meta-clang) | 1 | ![Yoe Distro CI](https://github.com/kraj/meta-clang/workflows/Yoe%20Distro%20CI/badge.svg?branch=master) |
2 | 2 | ||
3 | # meta-clang (a C language family frontend and LLVM compiler backend) | 3 | # meta-clang (a C language family frontend and LLVM compiler backend) |
4 | 4 | ||