From d2b1827a6457c48a8b4143395dd15002018e16b1 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 11:55:21 +0300 Subject: [PATCH 01/68] workflows/push.yml - add build action --- .github/workflows/push.yml | 50 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 .github/workflows/push.yml diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml new file mode 100644 index 00000000..e0abae58 --- /dev/null +++ b/.github/workflows/push.yml @@ -0,0 +1,50 @@ +name: CI + +on: + push: + branches: + - master + pull_request: + branches: + - master + +jobs: + build: + runs-on: ubuntu-22.04 + strategy: + matrix: + model: + [ + "hydrafw", + ] + fail-fast: true + + steps: + - name: Install dependencies + run: apt install --no-install-recommends --no-install-suggests python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib libc6:i386 + + - name: Install dependencies (python) + run: python3 -m pip install GitPython intelhex --upgrade + + - uses: actions/checkout@v4 + with: + submodules: true + + - name: Git ownership exception + run: ls -la / ; ls -la /__w/ ; git config --global --add safe.directory /__w/hydrabus/hydrafw && git config --global safe.directory "$GITHUB_WORKSPACE" + + - name: Git meta info + run: echo "GITHUB_CI_PR_SHA=${{github.event.pull_request.head.sha}}" >> "${GITHUB_ENV}" + + - name: Build ${{ matrix.model }} + run: cd src && make clean && make -j$(nproc) + + - name: Archive ${{ matrix.model }} artifacts + uses: actions/upload-artifact@v4 + with: + name: ${{ matrix.model }} + path: | + build/${{ matrix.model }}.dfu + if-no-files-found: error + + From 08f7e99dc5c408fc76fcdce5542b44b26f47255b Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 12:07:41 +0300 Subject: [PATCH 02/68] workflow/push.yml - add sudo for apt --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index e0abae58..bd64ae29 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -21,7 +21,7 @@ jobs: steps: - name: Install dependencies - run: apt install --no-install-recommends --no-install-suggests python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib libc6:i386 + run: sudo apt install --no-install-recommends --no-install-suggests python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib libc6:i386 - name: Install dependencies (python) run: python3 -m pip install GitPython intelhex --upgrade From bd085c8bf7c1cb9fdd2c877088301ea5714d037d Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 12:09:05 +0300 Subject: [PATCH 03/68] workflow/push.yml - remove libc:i386 from deps --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index bd64ae29..5bf7f308 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -21,7 +21,7 @@ jobs: steps: - name: Install dependencies - run: sudo apt install --no-install-recommends --no-install-suggests python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib libc6:i386 + run: sudo apt install --no-install-recommends --no-install-suggests python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib - name: Install dependencies (python) run: python3 -m pip install GitPython intelhex --upgrade From ae75fc04639f9defbd190ece01e7a8366e96b9b3 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 12:12:51 +0300 Subject: [PATCH 04/68] workflow/push.yml - fix git safe.directory paths --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 5bf7f308..95177e9e 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -31,7 +31,7 @@ jobs: submodules: true - name: Git ownership exception - run: ls -la / ; ls -la /__w/ ; git config --global --add safe.directory /__w/hydrabus/hydrafw && git config --global safe.directory "$GITHUB_WORKSPACE" + run: git config --global --add safe.directory /home/runner/work/hydrafw/hydrafw && git config --global safe.directory "$GITHUB_WORKSPACE" - name: Git meta info run: echo "GITHUB_CI_PR_SHA=${{github.event.pull_request.head.sha}}" >> "${GITHUB_ENV}" From a0a7a6d4d059c89907582a4f3bd0f0c629761183 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 12:30:09 +0300 Subject: [PATCH 05/68] workflow/push.yml - debugging --- .github/workflows/push.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 95177e9e..f5c9f971 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -36,6 +36,12 @@ jobs: - name: Git meta info run: echo "GITHUB_CI_PR_SHA=${{github.event.pull_request.head.sha}}" >> "${GITHUB_ENV}" + - name: DEBUGGING + run: echo "FW_REVISION" && python3 build-scripts/hydrafw-revision.py && echo "DONE" + + - name: DEBUGGING2 + run: git tag --points-at ${GITHUB_CI_PR_SHA} || true + - name: Build ${{ matrix.model }} run: cd src && make clean && make -j$(nproc) From f4c80638b9a34e18ad66a2275b69c4d7d56824ff Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 12:32:28 +0300 Subject: [PATCH 06/68] workflow/push.yml - remove git exception since applied anyway --- .github/workflows/push.yml | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index f5c9f971..a4d93e10 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -30,14 +30,11 @@ jobs: with: submodules: true - - name: Git ownership exception - run: git config --global --add safe.directory /home/runner/work/hydrafw/hydrafw && git config --global safe.directory "$GITHUB_WORKSPACE" - - name: Git meta info run: echo "GITHUB_CI_PR_SHA=${{github.event.pull_request.head.sha}}" >> "${GITHUB_ENV}" - name: DEBUGGING - run: echo "FW_REVISION" && python3 build-scripts/hydrafw-revision.py && echo "DONE" + run: echo "FW_REVISION" && cd src && python3 build-scripts/hydrafw-revision.py && echo "DONE" - name: DEBUGGING2 run: git tag --points-at ${GITHUB_CI_PR_SHA} || true From 0c85199e32a87ec0a96a12aef9960db058b75ef3 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 12:38:30 +0300 Subject: [PATCH 07/68] workflow/push.yml - debugging hfw-rev.py on GH build server --- src/build-scripts/hydrafw-revision.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/build-scripts/hydrafw-revision.py b/src/build-scripts/hydrafw-revision.py index b265fa85..7f195f89 100644 --- a/src/build-scripts/hydrafw-revision.py +++ b/src/build-scripts/hydrafw-revision.py @@ -7,4 +7,6 @@ git=Repo(search_parent_directories=True).git version = git.describe(tags=True,always=True,dirty=True,long=True) +print("VERSION:", version) +print("SEARCH:", r.search(version)) print(r.search(version).group(1)) From 264cea65be3578a5d4f66f58379e09bba2db19f8 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 12:42:19 +0300 Subject: [PATCH 08/68] hydrafw-revision.py: adopt script for GitHub actions CI build env --- src/build-scripts/hydrafw-revision.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/build-scripts/hydrafw-revision.py b/src/build-scripts/hydrafw-revision.py index 7f195f89..67d0d0a4 100644 --- a/src/build-scripts/hydrafw-revision.py +++ b/src/build-scripts/hydrafw-revision.py @@ -7,6 +7,7 @@ git=Repo(search_parent_directories=True).git version = git.describe(tags=True,always=True,dirty=True,long=True) -print("VERSION:", version) -print("SEARCH:", r.search(version)) -print(r.search(version).group(1)) +if r.search(version): + print(r.search(version).group(1)) +else: + print(version) From 071a6ce075a5b4eddb99645551ceb160c33b19d5 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 12:48:15 +0300 Subject: [PATCH 09/68] hydrafw-revision.py: print default revision/0.0 if revision tag is not extractable due to detached git repo state on GH build server --- src/build-scripts/hydrafw-revision.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/build-scripts/hydrafw-revision.py b/src/build-scripts/hydrafw-revision.py index 67d0d0a4..1c70982e 100644 --- a/src/build-scripts/hydrafw-revision.py +++ b/src/build-scripts/hydrafw-revision.py @@ -10,4 +10,4 @@ if r.search(version): print(r.search(version).group(1)) else: - print(version) + print("0.0") From 25f7953768d95a0e7cb16eebb0d8f5516b2227b1 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 12:51:50 +0300 Subject: [PATCH 10/68] workflow/push.yml - fix artifact path for hydrafw.dfu --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index a4d93e10..c92bacd2 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -47,7 +47,7 @@ jobs: with: name: ${{ matrix.model }} path: | - build/${{ matrix.model }}.dfu + src/build/${{ matrix.model }}.dfu if-no-files-found: error From aa9ef1f1f20f0f47910e1d914ed8099aa116da1f Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 12:58:41 +0300 Subject: [PATCH 11/68] workflow/push.yml - set ubuntu 18.04 as env since 22.04 includes toolchain which has strange issue with LTO stage (http://forum.chibios.org/viewtopic.php?t=5830) --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index c92bacd2..5ae45c47 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -10,7 +10,7 @@ on: jobs: build: - runs-on: ubuntu-22.04 + runs-on: ubuntu-18.04 strategy: matrix: model: From 6c09da23da5eaabb55d5726eb2df7f6498225493 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 13:05:42 +0300 Subject: [PATCH 12/68] workflow/push.yml - set ubuntu 18.04 as env since 22.04 includes toolchain which has strange issue with LTO stage (http://forum.chibios.org/viewtopic.php?t=5830) using container --- .github/workflows/push.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 5ae45c47..22c27119 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -10,7 +10,9 @@ on: jobs: build: - runs-on: ubuntu-18.04 + runs-on: ubuntu-22.04 + container: + image: ubuntu:18.04 strategy: matrix: model: From 55543db9ca95416b2c95b0876266039a2a476587 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 13:08:02 +0300 Subject: [PATCH 13/68] workflow/push.yml - remove sudo for apt --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 22c27119..f6d19e2e 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -23,7 +23,7 @@ jobs: steps: - name: Install dependencies - run: sudo apt install --no-install-recommends --no-install-suggests python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib + run: apt install --no-install-recommends --no-install-suggests python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib - name: Install dependencies (python) run: python3 -m pip install GitPython intelhex --upgrade From 2656fa4b3fe1d3484e2484c8a10f49435dbff6e6 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 13:11:03 +0300 Subject: [PATCH 14/68] workflow/push.yml - add apt repo configuration --- .github/workflows/push.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index f6d19e2e..9d64f18a 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -22,6 +22,9 @@ jobs: fail-fast: true steps: + - name: Configure apt + run: add-apt-repository universe && add-apt-repository multiverse && add-apt-repository restricted && apt update + - name: Install dependencies run: apt install --no-install-recommends --no-install-suggests python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib From 3e54f15f51e8348b62dc6b4c72cd6bfccbb09e61 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 13:12:19 +0300 Subject: [PATCH 15/68] workflow/push.yml - debugging apt --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 9d64f18a..f4dfc2a3 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -23,7 +23,7 @@ jobs: steps: - name: Configure apt - run: add-apt-repository universe && add-apt-repository multiverse && add-apt-repository restricted && apt update + run: cat /etc/apt/sources.list && apt update - name: Install dependencies run: apt install --no-install-recommends --no-install-suggests python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib From e58704f85f9c07b1f142e9c56806a4d9c996458d Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 13:13:32 +0300 Subject: [PATCH 16/68] workflow/push.yml - add yes to apt for non-interaction --- .github/workflows/push.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index f4dfc2a3..1dc07652 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -23,10 +23,10 @@ jobs: steps: - name: Configure apt - run: cat /etc/apt/sources.list && apt update + run: cat /etc/apt/sources.list && apt update -y - name: Install dependencies - run: apt install --no-install-recommends --no-install-suggests python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib + run: apt install -y --no-install-recommends --no-install-suggests python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib - name: Install dependencies (python) run: python3 -m pip install GitPython intelhex --upgrade From 4505071c84fbf207abe48a681f4e4bb1595cb32a Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 13:18:15 +0300 Subject: [PATCH 17/68] workflow/push.yml - downgrade to checkoutV3 since V4 is not compatible for this use case (https://github.com/actions/checkout/issues/1590) --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 1dc07652..b0e188a8 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -31,7 +31,7 @@ jobs: - name: Install dependencies (python) run: python3 -m pip install GitPython intelhex --upgrade - - uses: actions/checkout@v4 + - uses: actions/checkout@v3 with: submodules: true From 7f7b2c13ba6d2bda908a82a79b86f3b7704ff8f0 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 13:20:59 +0300 Subject: [PATCH 18/68] workflow/push.yml - add git --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index b0e188a8..8f2938d4 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -26,7 +26,7 @@ jobs: run: cat /etc/apt/sources.list && apt update -y - name: Install dependencies - run: apt install -y --no-install-recommends --no-install-suggests python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib + run: apt install -y --no-install-recommends --no-install-suggests git python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib - name: Install dependencies (python) run: python3 -m pip install GitPython intelhex --upgrade From 479098c400c9712b6635048cb69aec87afbae90d Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 13:22:44 +0300 Subject: [PATCH 19/68] workflow/push.yml - remove submodule keyword --- .github/workflows/push.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 8f2938d4..fdf821bc 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -32,8 +32,6 @@ jobs: run: python3 -m pip install GitPython intelhex --upgrade - uses: actions/checkout@v3 - with: - submodules: true - name: Git meta info run: echo "GITHUB_CI_PR_SHA=${{github.event.pull_request.head.sha}}" >> "${GITHUB_ENV}" From a8de2879b770fe24fab715ba2b426b34678f083e Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 13:28:31 +0300 Subject: [PATCH 20/68] hydrafw-revision.py: add exception --- src/build-scripts/hydrafw-revision.py | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/src/build-scripts/hydrafw-revision.py b/src/build-scripts/hydrafw-revision.py index 1c70982e..364f5a11 100644 --- a/src/build-scripts/hydrafw-revision.py +++ b/src/build-scripts/hydrafw-revision.py @@ -5,9 +5,12 @@ r = re.compile("v(\d+\.\d+).*") -git=Repo(search_parent_directories=True).git -version = git.describe(tags=True,always=True,dirty=True,long=True) -if r.search(version): - print(r.search(version).group(1)) -else: +try: + git=Repo(search_parent_directories=True).git + version = git.describe(tags=True,always=True,dirty=True,long=True) + if r.search(version): + print(r.search(version).group(1)) + else: + print("0.0") +except git.exc.InvalidGitRepositoryError: print("0.0") From 79c01cb7cf405849712900b18164cdbbf9385fa1 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 13:30:22 +0300 Subject: [PATCH 21/68] hydrafw-revision.py: fix exception --- src/build-scripts/hydrafw-revision.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/build-scripts/hydrafw-revision.py b/src/build-scripts/hydrafw-revision.py index 364f5a11..977a8b24 100644 --- a/src/build-scripts/hydrafw-revision.py +++ b/src/build-scripts/hydrafw-revision.py @@ -12,5 +12,5 @@ print(r.search(version).group(1)) else: print("0.0") -except git.exc.InvalidGitRepositoryError: +except InvalidGitRepositoryError: print("0.0") From 640262a655bd1d1ad5ed6794a7fcd06df03ec6b0 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 13:31:56 +0300 Subject: [PATCH 22/68] workflow/push.yml - add make --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index fdf821bc..f8b94efa 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -26,7 +26,7 @@ jobs: run: cat /etc/apt/sources.list && apt update -y - name: Install dependencies - run: apt install -y --no-install-recommends --no-install-suggests git python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib + run: apt install -y --no-install-recommends --no-install-suggests git make python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib - name: Install dependencies (python) run: python3 -m pip install GitPython intelhex --upgrade From 57085cf1aadd4471241274c81d4e5e7cc7b6792f Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 13:34:44 +0300 Subject: [PATCH 23/68] workflow/push.yml - add git submodules --- .github/workflows/push.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index f8b94efa..6e9da7ab 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -36,6 +36,9 @@ jobs: - name: Git meta info run: echo "GITHUB_CI_PR_SHA=${{github.event.pull_request.head.sha}}" >> "${GITHUB_ENV}" + - name: Git submodules + run: git submodule update --init --recursive + - name: DEBUGGING run: echo "FW_REVISION" && cd src && python3 build-scripts/hydrafw-revision.py && echo "DONE" From fcccefdc5590620722cd8c1b2b08e7908f9cfe66 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 13:43:10 +0300 Subject: [PATCH 24/68] workflow/push.yml - use debian --- .github/workflows/push.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 6e9da7ab..64f9dffb 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -12,7 +12,7 @@ jobs: build: runs-on: ubuntu-22.04 container: - image: ubuntu:18.04 + image: debian:oldstable strategy: matrix: model: @@ -31,7 +31,9 @@ jobs: - name: Install dependencies (python) run: python3 -m pip install GitPython intelhex --upgrade - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 + with: + submodules: true - name: Git meta info run: echo "GITHUB_CI_PR_SHA=${{github.event.pull_request.head.sha}}" >> "${GITHUB_ENV}" From d31b06bebfe4bcdb5439192eba5fa8356f08d081 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 13:46:14 +0300 Subject: [PATCH 25/68] workflow/push.yml - set ownership --- .github/workflows/push.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 64f9dffb..08af7901 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -35,12 +35,12 @@ jobs: with: submodules: true + - name: Git ownership + run: git config --global --add safe.directory /__w/hydrafw/hydrafw + - name: Git meta info run: echo "GITHUB_CI_PR_SHA=${{github.event.pull_request.head.sha}}" >> "${GITHUB_ENV}" - - name: Git submodules - run: git submodule update --init --recursive - - name: DEBUGGING run: echo "FW_REVISION" && cd src && python3 build-scripts/hydrafw-revision.py && echo "DONE" From ef1228f24f5a5481d6a2ff334838860d9ceccd6a Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 22 Mar 2024 13:53:34 +0300 Subject: [PATCH 26/68] workflow/push.yml - cleanup build steps --- .github/workflows/push.yml | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 08af7901..0d482171 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -22,31 +22,25 @@ jobs: fail-fast: true steps: - - name: Configure apt - run: cat /etc/apt/sources.list && apt update -y + - name: Update package cache + run: apt update -y - - name: Install dependencies + - name: Install packages run: apt install -y --no-install-recommends --no-install-suggests git make python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib - - name: Install dependencies (python) + - name: Install python modules run: python3 -m pip install GitPython intelhex --upgrade - uses: actions/checkout@v4 with: submodules: true - - name: Git ownership + - name: Set git ownership run: git config --global --add safe.directory /__w/hydrafw/hydrafw - - name: Git meta info + - name: Set git meta info run: echo "GITHUB_CI_PR_SHA=${{github.event.pull_request.head.sha}}" >> "${GITHUB_ENV}" - - name: DEBUGGING - run: echo "FW_REVISION" && cd src && python3 build-scripts/hydrafw-revision.py && echo "DONE" - - - name: DEBUGGING2 - run: git tag --points-at ${GITHUB_CI_PR_SHA} || true - - name: Build ${{ matrix.model }} run: cd src && make clean && make -j$(nproc) From 2316b65d3ec8fa490f9a92907e3fd2c9f28b2860 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Sat, 23 Mar 2024 03:25:59 +0300 Subject: [PATCH 27/68] workflow/push.yml - try build run without container --- .github/workflows/push.yml | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 0d482171..eeb3ee82 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -10,9 +10,7 @@ on: jobs: build: - runs-on: ubuntu-22.04 - container: - image: debian:oldstable + runs-on: debian-oldstable strategy: matrix: model: @@ -23,10 +21,10 @@ jobs: steps: - name: Update package cache - run: apt update -y + run: sudo apt update -y - name: Install packages - run: apt install -y --no-install-recommends --no-install-suggests git make python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib + run: sudo apt install -y --no-install-recommends --no-install-suggests git make python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib - name: Install python modules run: python3 -m pip install GitPython intelhex --upgrade @@ -35,9 +33,6 @@ jobs: with: submodules: true - - name: Set git ownership - run: git config --global --add safe.directory /__w/hydrafw/hydrafw - - name: Set git meta info run: echo "GITHUB_CI_PR_SHA=${{github.event.pull_request.head.sha}}" >> "${GITHUB_ENV}" From a2839cbff7abb0258d8841fb9f05825f5d63508d Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Sat, 23 Mar 2024 03:27:10 +0300 Subject: [PATCH 28/68] workflow/push.yml - revert run with container --- .github/workflows/push.yml | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index eeb3ee82..0d482171 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -10,7 +10,9 @@ on: jobs: build: - runs-on: debian-oldstable + runs-on: ubuntu-22.04 + container: + image: debian:oldstable strategy: matrix: model: @@ -21,10 +23,10 @@ jobs: steps: - name: Update package cache - run: sudo apt update -y + run: apt update -y - name: Install packages - run: sudo apt install -y --no-install-recommends --no-install-suggests git make python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib + run: apt install -y --no-install-recommends --no-install-suggests git make python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib - name: Install python modules run: python3 -m pip install GitPython intelhex --upgrade @@ -33,6 +35,9 @@ jobs: with: submodules: true + - name: Set git ownership + run: git config --global --add safe.directory /__w/hydrafw/hydrafw + - name: Set git meta info run: echo "GITHUB_CI_PR_SHA=${{github.event.pull_request.head.sha}}" >> "${GITHUB_ENV}" From 78deddcbc6a76d523748f8ede447d56156f54f95 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Sat, 23 Mar 2024 03:37:37 +0300 Subject: [PATCH 29/68] hydrafw-revision.py: testing build without exception --- src/build-scripts/hydrafw-revision.py | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/src/build-scripts/hydrafw-revision.py b/src/build-scripts/hydrafw-revision.py index 977a8b24..1c70982e 100644 --- a/src/build-scripts/hydrafw-revision.py +++ b/src/build-scripts/hydrafw-revision.py @@ -5,12 +5,9 @@ r = re.compile("v(\d+\.\d+).*") -try: - git=Repo(search_parent_directories=True).git - version = git.describe(tags=True,always=True,dirty=True,long=True) - if r.search(version): - print(r.search(version).group(1)) - else: - print("0.0") -except InvalidGitRepositoryError: +git=Repo(search_parent_directories=True).git +version = git.describe(tags=True,always=True,dirty=True,long=True) +if r.search(version): + print(r.search(version).group(1)) +else: print("0.0") From 6bd70443d30b77e049987dfb07058f689f958590 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Sat, 23 Mar 2024 03:43:56 +0300 Subject: [PATCH 30/68] workflow/push.yml - revert revision output to test --- .github/workflows/push.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 0d482171..b3ca439d 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -1,5 +1,6 @@ name: CI + on: push: branches: @@ -8,6 +9,7 @@ on: branches: - master + jobs: build: runs-on: ubuntu-22.04 @@ -42,7 +44,7 @@ jobs: run: echo "GITHUB_CI_PR_SHA=${{github.event.pull_request.head.sha}}" >> "${GITHUB_ENV}" - name: Build ${{ matrix.model }} - run: cd src && make clean && make -j$(nproc) + run: python3 src/build-scripts/hydrafw-revision.py && cd src && make clean && make -j$(nproc) - name: Archive ${{ matrix.model }} artifacts uses: actions/upload-artifact@v4 From 837b18cdacaac75f11f51d34846ef5e8f7fbe52c Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Sat, 23 Mar 2024 03:44:12 +0300 Subject: [PATCH 31/68] workflow/push.yml - remove git package from deps --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index b3ca439d..dff01518 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -28,7 +28,7 @@ jobs: run: apt update -y - name: Install packages - run: apt install -y --no-install-recommends --no-install-suggests git make python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib + run: apt install -y --no-install-recommends --no-install-suggests make python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib - name: Install python modules run: python3 -m pip install GitPython intelhex --upgrade From 37756d46bf75176687b18ae417b61acb3dabfcca Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Sat, 23 Mar 2024 03:49:14 +0300 Subject: [PATCH 32/68] workflow/push.yml - revert git package to deps --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index dff01518..b3ca439d 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -28,7 +28,7 @@ jobs: run: apt update -y - name: Install packages - run: apt install -y --no-install-recommends --no-install-suggests make python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib + run: apt install -y --no-install-recommends --no-install-suggests git make python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib - name: Install python modules run: python3 -m pip install GitPython intelhex --upgrade From 8397b419c90c6692854bdbfae17bd7c7324f8510 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Sat, 23 Mar 2024 13:46:12 +0300 Subject: [PATCH 33/68] workflow/push.yml - test without apt package db update --- .github/workflows/push.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index b3ca439d..2be978d3 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -24,9 +24,6 @@ jobs: fail-fast: true steps: - - name: Update package cache - run: apt update -y - - name: Install packages run: apt install -y --no-install-recommends --no-install-suggests git make python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib From e2244cceb42269d9de6b984f7cf1da6c9e3144a5 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Sat, 23 Mar 2024 13:47:01 +0300 Subject: [PATCH 34/68] workflow/push.yml - revert apt package db update --- .github/workflows/push.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 2be978d3..b3ca439d 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -24,6 +24,9 @@ jobs: fail-fast: true steps: + - name: Update package cache + run: apt update -y + - name: Install packages run: apt install -y --no-install-recommends --no-install-suggests git make python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib From bca2196cc0db53110061731e37c0259388af9bf6 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Sat, 23 Mar 2024 13:49:40 +0300 Subject: [PATCH 35/68] workflow/push.yml - test reformatting --- .github/workflows/push.yml | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index b3ca439d..cbbe41e2 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -17,10 +17,7 @@ jobs: image: debian:oldstable strategy: matrix: - model: - [ - "hydrafw", - ] + model: hydrafw fail-fast: true steps: @@ -38,13 +35,13 @@ jobs: submodules: true - name: Set git ownership - run: git config --global --add safe.directory /__w/hydrafw/hydrafw + run: git config --global --add safe.directory /__w/hydrafw/hydrafw - name: Set git meta info run: echo "GITHUB_CI_PR_SHA=${{github.event.pull_request.head.sha}}" >> "${GITHUB_ENV}" - name: Build ${{ matrix.model }} - run: python3 src/build-scripts/hydrafw-revision.py && cd src && make clean && make -j$(nproc) + run: make -j$(nproc) -C src/ - name: Archive ${{ matrix.model }} artifacts uses: actions/upload-artifact@v4 From 3dc8cc10d4816f0d6121a3a1ee0c918496b38d53 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Sat, 23 Mar 2024 13:50:29 +0300 Subject: [PATCH 36/68] workflow/push.yml - fix model name for matrix strategy --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index cbbe41e2..f4e524d5 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -17,7 +17,7 @@ jobs: image: debian:oldstable strategy: matrix: - model: hydrafw + model: "hydrafw" fail-fast: true steps: From 75ecfc6dc0655fdc15a6e0d9c4627399cbf96d04 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Sat, 23 Mar 2024 13:51:02 +0300 Subject: [PATCH 37/68] workflow/push.yml - try to set model in one line --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index f4e524d5..c28e4886 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -17,7 +17,7 @@ jobs: image: debian:oldstable strategy: matrix: - model: "hydrafw" + model: [ "hydrafw" ] fail-fast: true steps: From 72f33f093ad0fa436eafe1aeac4361dd55d2f78e Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Sat, 23 Mar 2024 13:54:19 +0300 Subject: [PATCH 38/68] workflow/push.yml - add python3 to deps --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index c28e4886..78bb2f7d 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -25,7 +25,7 @@ jobs: run: apt update -y - name: Install packages - run: apt install -y --no-install-recommends --no-install-suggests git make python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib + run: apt install -y --no-install-recommends --no-install-suggests git make python3 python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib - name: Install python modules run: python3 -m pip install GitPython intelhex --upgrade From 46cde8e7c4e2de86f6c166972c871243fe28a57e Mon Sep 17 00:00:00 2001 From: ia Date: Wed, 27 Mar 2024 12:10:52 +0300 Subject: [PATCH 39/68] scripts/env.sh - add script to enroll reference toolchain --- scripts/env.sh | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100755 scripts/env.sh diff --git a/scripts/env.sh b/scripts/env.sh new file mode 100755 index 00000000..4793725a --- /dev/null +++ b/scripts/env.sh @@ -0,0 +1,17 @@ +#!/usr/bin/env bash +set -e + +MD5SUM=8a4a74872830f80c788c944877d3ad8c +TARBALL=gcc-arm-none-eabi-4_9-2015q3-20150921-linux.tar.bz2 +TARDIR=gcc-arm-none-eabi-4_9-2015q3 +LINK=https://launchpad.net/gcc-arm-embedded/4.9/4.9-2015-q3-update/+download/"${TARBALL}" +CURDIR="$(pwd)" + +echo "${MD5SUM} ${TARBALL}" > md5.txt +wget "${LINK}" +md5sum -c md5.txt + +tar xvjf "${TARBALL}" + +echo "export PATH=\"${CURDIR}/${TARDIR}/bin\":\"\${PATH}\"" > build.env + From 9b752c87f80d06954f1a819a9b9558b2b6be178f Mon Sep 17 00:00:00 2001 From: ia Date: Wed, 27 Mar 2024 12:11:48 +0300 Subject: [PATCH 40/68] workflow/push.yml - remove host toolchain deps --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 78bb2f7d..77966f8b 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -25,7 +25,7 @@ jobs: run: apt update -y - name: Install packages - run: apt install -y --no-install-recommends --no-install-suggests git make python3 python3-pip gcc-arm-none-eabi libnewlib-arm-none-eabi libstdc++-arm-none-eabi-newlib + run: apt install -y --no-install-recommends --no-install-suggests git make python3 python3-pip - name: Install python modules run: python3 -m pip install GitPython intelhex --upgrade From c0932cad0ab40a18047d76fdc1ca72ed2a3f1c9d Mon Sep 17 00:00:00 2001 From: ia Date: Wed, 27 Mar 2024 12:14:21 +0300 Subject: [PATCH 41/68] workflow/push.yml - add reference toolchain install and configuration --- .github/workflows/push.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 77966f8b..dc700df3 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -30,6 +30,9 @@ jobs: - name: Install python modules run: python3 -m pip install GitPython intelhex --upgrade + - name: Install standalone reference GCC toolchain + run: bash scripts/env.sh + - uses: actions/checkout@v4 with: submodules: true @@ -41,7 +44,7 @@ jobs: run: echo "GITHUB_CI_PR_SHA=${{github.event.pull_request.head.sha}}" >> "${GITHUB_ENV}" - name: Build ${{ matrix.model }} - run: make -j$(nproc) -C src/ + run: source build.env && make -j$(nproc) -C src/ - name: Archive ${{ matrix.model }} artifacts uses: actions/upload-artifact@v4 From c242382b831b4bfe3267cf60727e4b692cf03088 Mon Sep 17 00:00:00 2001 From: ia Date: Wed, 27 Mar 2024 12:14:40 +0300 Subject: [PATCH 42/68] workflow/push.yml - remove debian container --- .github/workflows/push.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index dc700df3..0e6588f6 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -13,8 +13,6 @@ on: jobs: build: runs-on: ubuntu-22.04 - container: - image: debian:oldstable strategy: matrix: model: [ "hydrafw" ] From d527c731854ec00c63f8d85f38d3ae9455c1aff0 Mon Sep 17 00:00:00 2001 From: ia Date: Wed, 27 Mar 2024 12:16:00 +0300 Subject: [PATCH 43/68] workflow/push.yml - enable verbosity build by default --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 0e6588f6..e5c65395 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -42,7 +42,7 @@ jobs: run: echo "GITHUB_CI_PR_SHA=${{github.event.pull_request.head.sha}}" >> "${GITHUB_ENV}" - name: Build ${{ matrix.model }} - run: source build.env && make -j$(nproc) -C src/ + run: source build.env && make V=1 -j$(nproc) -C src/ - name: Archive ${{ matrix.model }} artifacts uses: actions/upload-artifact@v4 From a94c477d4edbe88783f49d9a4c713d54fa23df66 Mon Sep 17 00:00:00 2001 From: ia Date: Wed, 27 Mar 2024 12:16:51 +0300 Subject: [PATCH 44/68] workflow/push.yml - enable sudo mode for host packages operations --- .github/workflows/push.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index e5c65395..359e4f38 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -20,10 +20,10 @@ jobs: steps: - name: Update package cache - run: apt update -y + run: sudo apt update -y - name: Install packages - run: apt install -y --no-install-recommends --no-install-suggests git make python3 python3-pip + run: sudo apt install -y --no-install-recommends --no-install-suggests git make python3 python3-pip - name: Install python modules run: python3 -m pip install GitPython intelhex --upgrade From 30a7fe2d015c266d2986e8a66fbd983be0626398 Mon Sep 17 00:00:00 2001 From: ia Date: Wed, 27 Mar 2024 12:18:33 +0300 Subject: [PATCH 45/68] workflow/push.yml - fix steps order to download toolchain only after repo with script downloading it is checked out --- .github/workflows/push.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 359e4f38..c4be405c 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -28,9 +28,6 @@ jobs: - name: Install python modules run: python3 -m pip install GitPython intelhex --upgrade - - name: Install standalone reference GCC toolchain - run: bash scripts/env.sh - - uses: actions/checkout@v4 with: submodules: true @@ -41,6 +38,9 @@ jobs: - name: Set git meta info run: echo "GITHUB_CI_PR_SHA=${{github.event.pull_request.head.sha}}" >> "${GITHUB_ENV}" + - name: Install standalone reference GCC toolchain + run: bash scripts/env.sh + - name: Build ${{ matrix.model }} run: source build.env && make V=1 -j$(nproc) -C src/ From f4e4e845a5dc793bf9f4a55dc18bca3f947ab0dd Mon Sep 17 00:00:00 2001 From: ia Date: Wed, 27 Mar 2024 12:19:09 +0300 Subject: [PATCH 46/68] workflow/push.yml - remove ownership tweak (needed only for container) --- .github/workflows/push.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index c4be405c..49a56433 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -32,9 +32,6 @@ jobs: with: submodules: true - - name: Set git ownership - run: git config --global --add safe.directory /__w/hydrafw/hydrafw - - name: Set git meta info run: echo "GITHUB_CI_PR_SHA=${{github.event.pull_request.head.sha}}" >> "${GITHUB_ENV}" From d4ec89d07540eb690a9707e3129748674b0c663a Mon Sep 17 00:00:00 2001 From: ia Date: Wed, 27 Mar 2024 12:31:05 +0300 Subject: [PATCH 47/68] workflow/push.yml - add package deps explicitly --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 49a56433..6f21e47a 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -23,7 +23,7 @@ jobs: run: sudo apt update -y - name: Install packages - run: sudo apt install -y --no-install-recommends --no-install-suggests git make python3 python3-pip + run: sudo apt install -y --no-install-recommends --no-install-suggests bash coreutils tar bzip2 git make python3 python3-pip - name: Install python modules run: python3 -m pip install GitPython intelhex --upgrade From a0bf4d0a86dca17f1b6c309a4b2a809155eda062 Mon Sep 17 00:00:00 2001 From: ia Date: Wed, 27 Mar 2024 12:33:59 +0300 Subject: [PATCH 48/68] workflow/push.yml - output toolchain version and its dirs right before the build to make sure in logs that the proper GCC is used --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 6f21e47a..430756a7 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -39,7 +39,7 @@ jobs: run: bash scripts/env.sh - name: Build ${{ matrix.model }} - run: source build.env && make V=1 -j$(nproc) -C src/ + run: source build.env && arm-none-eabi-gcc --version && arm-none-eabi-gcc -print-search-dirs && make V=1 -j$(nproc) -C src/ - name: Archive ${{ matrix.model }} artifacts uses: actions/upload-artifact@v4 From 6159c5892b3aa1c0975774fd3cafe2d4ecb7c89f Mon Sep 17 00:00:00 2001 From: ia Date: Wed, 27 Mar 2024 13:00:47 +0300 Subject: [PATCH 49/68] scripts/env.sh - add a couple of comments with clarifications --- scripts/env.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/scripts/env.sh b/scripts/env.sh index 4793725a..e20c127b 100755 --- a/scripts/env.sh +++ b/scripts/env.sh @@ -1,6 +1,9 @@ #!/usr/bin/env bash set -e +# This script is used to enroll toolchain with GitHub Actions for CI/CD purposes +# But this script can be used as reference to install recommended toolchain for building hydrafw.dfu locally as well + MD5SUM=8a4a74872830f80c788c944877d3ad8c TARBALL=gcc-arm-none-eabi-4_9-2015q3-20150921-linux.tar.bz2 TARDIR=gcc-arm-none-eabi-4_9-2015q3 From 7118e55f0db4b28828c56ae23341c88a26d8a89a Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Wed, 27 Mar 2024 20:35:45 +0300 Subject: [PATCH 50/68] workflow/push.yml - testing suggestion from Baldanos to pass tags for GitHub build --- .github/workflows/push.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 430756a7..82dc304c 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -31,6 +31,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: true + fetch-tags: true - name: Set git meta info run: echo "GITHUB_CI_PR_SHA=${{github.event.pull_request.head.sha}}" >> "${GITHUB_ENV}" @@ -39,7 +40,7 @@ jobs: run: bash scripts/env.sh - name: Build ${{ matrix.model }} - run: source build.env && arm-none-eabi-gcc --version && arm-none-eabi-gcc -print-search-dirs && make V=1 -j$(nproc) -C src/ + run: source build.env && arm-none-eabi-gcc --version && arm-none-eabi-gcc -print-search-dirs && python3 src/build-scripts/hydrafw-revision.py && make V=1 -j$(nproc) -C src/ - name: Archive ${{ matrix.model }} artifacts uses: actions/upload-artifact@v4 From 595a6e1fc1d299392a8a0a51dd412572f5a8e5ef Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Wed, 27 Mar 2024 21:11:39 +0300 Subject: [PATCH 51/68] scripts/env.sh - debugging git meta on github builds --- scripts/env.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/scripts/env.sh b/scripts/env.sh index e20c127b..e1864382 100755 --- a/scripts/env.sh +++ b/scripts/env.sh @@ -18,3 +18,12 @@ tar xvjf "${TARBALL}" echo "export PATH=\"${CURDIR}/${TARDIR}/bin\":\"\${PATH}\"" > build.env +set +e +set -x + +echo "${GITHUB_CI_PR_SHA}" +sha="`git rev-parse --short=8 HEAD`" +tag="`git tag --points-at ${sha}`" +git rev-parse --symbolic-full-name --short HEAD +date +%Y-%m-%d + From 044e0bf607a14b07b7a94bc6164833636d713527 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Wed, 27 Mar 2024 21:59:52 +0300 Subject: [PATCH 52/68] scripts/env.sh - experiments with git meta on github builds --- scripts/env.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scripts/env.sh b/scripts/env.sh index e1864382..8ed4356f 100755 --- a/scripts/env.sh +++ b/scripts/env.sh @@ -26,4 +26,8 @@ sha="`git rev-parse --short=8 HEAD`" tag="`git tag --points-at ${sha}`" git rev-parse --symbolic-full-name --short HEAD date +%Y-%m-%d +git log --pretty=oneline v0.11..master +git log --pretty=oneline v0.11..master | wc -l +git describe --tags +echo `git describe --tags --abbrev=0`-`git log --pretty=oneline v0.11..master | wc -l` From 45cfe1f4cfeeaa8b8392c0755413adfd52f6727d Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Wed, 27 Mar 2024 22:18:48 +0300 Subject: [PATCH 53/68] workflow/push.yml - Changing Stuff and Seeing What Happens --- .github/workflows/push.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 82dc304c..2a442e93 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -32,6 +32,7 @@ jobs: with: submodules: true fetch-tags: true + fetch-depth: 0 - name: Set git meta info run: echo "GITHUB_CI_PR_SHA=${{github.event.pull_request.head.sha}}" >> "${GITHUB_ENV}" From 2744d288126818106b20c594a9a673ad8099d6d6 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Wed, 27 Mar 2024 22:22:36 +0300 Subject: [PATCH 54/68] workflow/push.yml - try to fetch meta about branches as well --- .github/workflows/push.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 2a442e93..a7b81b17 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -32,6 +32,7 @@ jobs: with: submodules: true fetch-tags: true + fetch-branches: true fetch-depth: 0 - name: Set git meta info From 9166842bb0e5e23261ef19dc2ca7fff5362eec77 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Wed, 27 Mar 2024 22:25:40 +0300 Subject: [PATCH 55/68] scripts/env.sh - add dot to git command --- scripts/env.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/env.sh b/scripts/env.sh index 8ed4356f..4a8e0fd4 100755 --- a/scripts/env.sh +++ b/scripts/env.sh @@ -28,6 +28,8 @@ git rev-parse --symbolic-full-name --short HEAD date +%Y-%m-%d git log --pretty=oneline v0.11..master git log --pretty=oneline v0.11..master | wc -l +git log --pretty=oneline v0.11...master +git log --pretty=oneline v0.11...master | wc -l git describe --tags echo `git describe --tags --abbrev=0`-`git log --pretty=oneline v0.11..master | wc -l` From c2fdf2b2da355a72bcecc48743b3efa631c4c065 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Wed, 27 Mar 2024 22:48:11 +0300 Subject: [PATCH 56/68] scripts/env.sh - google driven development --- scripts/env.sh | 36 +++++++++++++++++++++--------------- 1 file changed, 21 insertions(+), 15 deletions(-) diff --git a/scripts/env.sh b/scripts/env.sh index 4a8e0fd4..35cd01d8 100755 --- a/scripts/env.sh +++ b/scripts/env.sh @@ -1,6 +1,27 @@ #!/usr/bin/env bash set -e +set +e +set -x + +echo "${GITHUB_CI_PR_SHA}" +sha="`git rev-parse --short=8 HEAD`" +tag="`git tag --points-at ${sha}`" +git rev-parse --symbolic-full-name --short HEAD +date +%Y-%m-%d +git log --pretty=oneline v0.11..master +git log --pretty=oneline v0.11..master | wc -l +git log --pretty=oneline v0.11...master +git log --pretty=oneline v0.11...master | wc -l +git describe --tags + +git log --pretty=oneline origin/v0.11..origin/master +git log --pretty=oneline origin/v0.11..origin/master | wc -l + +echo `git describe --tags --abbrev=0`-`git log --pretty=oneline v0.11..master | wc -l` + +set -e + # This script is used to enroll toolchain with GitHub Actions for CI/CD purposes # But this script can be used as reference to install recommended toolchain for building hydrafw.dfu locally as well @@ -18,18 +39,3 @@ tar xvjf "${TARBALL}" echo "export PATH=\"${CURDIR}/${TARDIR}/bin\":\"\${PATH}\"" > build.env -set +e -set -x - -echo "${GITHUB_CI_PR_SHA}" -sha="`git rev-parse --short=8 HEAD`" -tag="`git tag --points-at ${sha}`" -git rev-parse --symbolic-full-name --short HEAD -date +%Y-%m-%d -git log --pretty=oneline v0.11..master -git log --pretty=oneline v0.11..master | wc -l -git log --pretty=oneline v0.11...master -git log --pretty=oneline v0.11...master | wc -l -git describe --tags - -echo `git describe --tags --abbrev=0`-`git log --pretty=oneline v0.11..master | wc -l` From 53e5b484d0daab3820fe6991ee6b04e154e5fac5 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Wed, 27 Mar 2024 22:52:24 +0300 Subject: [PATCH 57/68] scripts/env.sh - add more output of git meta --- scripts/env.sh | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/scripts/env.sh b/scripts/env.sh index 35cd01d8..e412caee 100755 --- a/scripts/env.sh +++ b/scripts/env.sh @@ -10,13 +10,15 @@ tag="`git tag --points-at ${sha}`" git rev-parse --symbolic-full-name --short HEAD date +%Y-%m-%d git log --pretty=oneline v0.11..master -git log --pretty=oneline v0.11..master | wc -l +git log --pretty=oneline v0.11..master +git log --pretty=oneline v0.11...master git log --pretty=oneline v0.11...master -git log --pretty=oneline v0.11...master | wc -l git describe --tags -git log --pretty=oneline origin/v0.11..origin/master -git log --pretty=oneline origin/v0.11..origin/master | wc -l +git log --pretty=oneline origin/master + +git branch -a + echo `git describe --tags --abbrev=0`-`git log --pretty=oneline v0.11..master | wc -l` From 3a256175aa645bebd6e03dfad22c9f83f417718d Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Wed, 27 Mar 2024 22:52:53 +0300 Subject: [PATCH 58/68] workflow/push.yml - remove wrong option --- .github/workflows/push.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index a7b81b17..2a442e93 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -32,7 +32,6 @@ jobs: with: submodules: true fetch-tags: true - fetch-branches: true fetch-depth: 0 - name: Set git meta info From 50c17626b7b69550711775647759e1ac82cf9ae8 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Wed, 27 Mar 2024 23:00:51 +0300 Subject: [PATCH 59/68] scripts/env.sh - trying extract git log to count 22 --- scripts/env.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/scripts/env.sh b/scripts/env.sh index e412caee..2beed4fb 100755 --- a/scripts/env.sh +++ b/scripts/env.sh @@ -15,10 +15,11 @@ git log --pretty=oneline v0.11...master git log --pretty=oneline v0.11...master git describe --tags -git log --pretty=oneline origin/master - git branch -a +git log --pretty=oneline d6d65865716adc1419cc89e59d05f99dc99f89a9..origin/master +git log --pretty=oneline d6d65865716adc1419cc89e59d05f99dc99f89a9..remotes/origin/master +git log --pretty=oneline d6d65865716adc1419cc89e59d05f99dc99f89a9..hydrabus/master echo `git describe --tags --abbrev=0`-`git log --pretty=oneline v0.11..master | wc -l` From 1e882a150de410e4049a4159ad6c955c168304e2 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Wed, 27 Mar 2024 23:06:56 +0300 Subject: [PATCH 60/68] scripts/env.sh - keep trying --- scripts/env.sh | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/scripts/env.sh b/scripts/env.sh index 2beed4fb..c349d9fd 100755 --- a/scripts/env.sh +++ b/scripts/env.sh @@ -17,7 +17,19 @@ git describe --tags git branch -a +fw_tag="`git describe --tags --abbrev=0`" +fw_id="`git rev-list -n 1 ${fw_tag}`" + +git log --pretty=oneline ${fw_id}..origin/master +git log --pretty=oneline ${fw_id}..origin/master | wc -l +NUMERB22=git log --pretty=oneline ${fw_id}..origin/master | wc -l + +echo "=====" +echo "${NUMBER22}" +echo "=====" + git log --pretty=oneline d6d65865716adc1419cc89e59d05f99dc99f89a9..origin/master +git log --pretty=oneline v0.11..origin/master git log --pretty=oneline d6d65865716adc1419cc89e59d05f99dc99f89a9..remotes/origin/master git log --pretty=oneline d6d65865716adc1419cc89e59d05f99dc99f89a9..hydrabus/master From 95fe10482edfd244e56651bf096a931bd0841522 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 29 Mar 2024 17:20:57 +0300 Subject: [PATCH 61/68] scripts/env.sh - testing git tags and commit IDs on github again --- scripts/env.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/scripts/env.sh b/scripts/env.sh index c349d9fd..b4091cd0 100755 --- a/scripts/env.sh +++ b/scripts/env.sh @@ -4,6 +4,11 @@ set -e set +e set -x +git describe --tags HEAD^1 +git describe --tags + +echo "-------------------------" + echo "${GITHUB_CI_PR_SHA}" sha="`git rev-parse --short=8 HEAD`" tag="`git tag --points-at ${sha}`" @@ -13,7 +18,6 @@ git log --pretty=oneline v0.11..master git log --pretty=oneline v0.11..master git log --pretty=oneline v0.11...master git log --pretty=oneline v0.11...master -git describe --tags git branch -a From 116ec7659ac5ab4c4774116f98f8ebed7c3f45c2 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 29 Mar 2024 18:18:50 +0300 Subject: [PATCH 62/68] hydrafw-version.py - taking into consideration original sha id before detaching on github --- src/build-scripts/hydrafw-version.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/build-scripts/hydrafw-version.py b/src/build-scripts/hydrafw-version.py index 85740bf9..c72bf9e9 100644 --- a/src/build-scripts/hydrafw-version.py +++ b/src/build-scripts/hydrafw-version.py @@ -1,6 +1,7 @@ #!/usr/bin/env python3 import sys +import os from optparse import OptionParser from datetime import * from git import * @@ -14,7 +15,12 @@ if len(args)==1: sys.stdout = open(args[0], 'w') git=Repo(search_parent_directories=True).git - print('#define HYDRAFW_GIT_TAG "' + git.describe(tags=True,always=True,dirty=True,long=True) + '"') + vermagic=git.describe(tags=True,always=True,dirty=True,long=True) + if os.environ.get("GITHUB_CI_PR_SHA", "") != "": + sha_id=os.environ["GITHUB_CI_PR_SHA"][:7] + print('#define HYDRAFW_GIT_TAG "' + re.sub('-g.*$', '-g' + sha_id, vermagic) + '"') + else: + print('#define HYDRAFW_GIT_TAG "' + vermagic + '"') print('#define HYDRAFW_CHECKIN_DATE "' + git.show(['-s', '--pretty=format:%ai']).partition(' ')[0] + '"') else: parser.print_help() From b0f78b2095ca3c549b63cc905e9961d271146444 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Fri, 29 Mar 2024 18:21:50 +0300 Subject: [PATCH 63/68] hydrafw-version.py - import missed re module --- src/build-scripts/hydrafw-version.py | 1 + 1 file changed, 1 insertion(+) diff --git a/src/build-scripts/hydrafw-version.py b/src/build-scripts/hydrafw-version.py index c72bf9e9..ceabc387 100644 --- a/src/build-scripts/hydrafw-version.py +++ b/src/build-scripts/hydrafw-version.py @@ -2,6 +2,7 @@ import sys import os +import re from optparse import OptionParser from datetime import * from git import * From 11c05b345e1eca21f92b796c986a039323e933c9 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Tue, 2 Apr 2024 14:11:18 +0300 Subject: [PATCH 64/68] hydrafw-version.py: add brief comments not to forget whats going on here --- src/build-scripts/hydrafw-version.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/build-scripts/hydrafw-version.py b/src/build-scripts/hydrafw-version.py index ceabc387..1f3bd6aa 100644 --- a/src/build-scripts/hydrafw-version.py +++ b/src/build-scripts/hydrafw-version.py @@ -18,9 +18,11 @@ git=Repo(search_parent_directories=True).git vermagic=git.describe(tags=True,always=True,dirty=True,long=True) if os.environ.get("GITHUB_CI_PR_SHA", "") != "": + # if GITHUB_CI_PR_SHA is set, then it's GitHub Actions build, so workaround to set a valid tag is required sha_id=os.environ["GITHUB_CI_PR_SHA"][:7] print('#define HYDRAFW_GIT_TAG "' + re.sub('-g.*$', '-g' + sha_id, vermagic) + '"') else: + # If it's local build, then set "normal" tag print('#define HYDRAFW_GIT_TAG "' + vermagic + '"') print('#define HYDRAFW_CHECKIN_DATE "' + git.show(['-s', '--pretty=format:%ai']).partition(' ')[0] + '"') else: From 4390579fc0b76c91cc8c5eee18c92504404a6b22 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Tue, 2 Apr 2024 14:14:04 +0300 Subject: [PATCH 65/68] scripts/env.sh: remove printf-like debugging for git meta info --- scripts/env.sh | 41 +---------------------------------------- 1 file changed, 1 insertion(+), 40 deletions(-) diff --git a/scripts/env.sh b/scripts/env.sh index b4091cd0..e662eaa3 100755 --- a/scripts/env.sh +++ b/scripts/env.sh @@ -1,44 +1,5 @@ #!/usr/bin/env bash -set -e - -set +e -set -x - -git describe --tags HEAD^1 -git describe --tags - -echo "-------------------------" - -echo "${GITHUB_CI_PR_SHA}" -sha="`git rev-parse --short=8 HEAD`" -tag="`git tag --points-at ${sha}`" -git rev-parse --symbolic-full-name --short HEAD -date +%Y-%m-%d -git log --pretty=oneline v0.11..master -git log --pretty=oneline v0.11..master -git log --pretty=oneline v0.11...master -git log --pretty=oneline v0.11...master - -git branch -a - -fw_tag="`git describe --tags --abbrev=0`" -fw_id="`git rev-list -n 1 ${fw_tag}`" - -git log --pretty=oneline ${fw_id}..origin/master -git log --pretty=oneline ${fw_id}..origin/master | wc -l -NUMERB22=git log --pretty=oneline ${fw_id}..origin/master | wc -l - -echo "=====" -echo "${NUMBER22}" -echo "=====" - -git log --pretty=oneline d6d65865716adc1419cc89e59d05f99dc99f89a9..origin/master -git log --pretty=oneline v0.11..origin/master -git log --pretty=oneline d6d65865716adc1419cc89e59d05f99dc99f89a9..remotes/origin/master -git log --pretty=oneline d6d65865716adc1419cc89e59d05f99dc99f89a9..hydrabus/master - -echo `git describe --tags --abbrev=0`-`git log --pretty=oneline v0.11..master | wc -l` - +#set -x set -e # This script is used to enroll toolchain with GitHub Actions for CI/CD purposes From e7a53f124d0add604b81c8bf204f4633f5e4d348 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Tue, 2 Apr 2024 14:14:57 +0300 Subject: [PATCH 66/68] scripts/env.sh: add deletion of temp files --- scripts/env.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/env.sh b/scripts/env.sh index e662eaa3..2dcec702 100755 --- a/scripts/env.sh +++ b/scripts/env.sh @@ -14,8 +14,10 @@ CURDIR="$(pwd)" echo "${MD5SUM} ${TARBALL}" > md5.txt wget "${LINK}" md5sum -c md5.txt +rm md5.txt tar xvjf "${TARBALL}" +rm "${TARBALL}" echo "export PATH=\"${CURDIR}/${TARDIR}/bin\":\"\${PATH}\"" > build.env From 9d77d8c0abb4536f7e22f9185c99146a82e99e00 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Tue, 2 Apr 2024 14:22:38 +0300 Subject: [PATCH 67/68] scripts/env.sh: add self-explanatory output help for user if its local run --- scripts/env.sh | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/scripts/env.sh b/scripts/env.sh index 2dcec702..7d65c924 100755 --- a/scripts/env.sh +++ b/scripts/env.sh @@ -19,5 +19,15 @@ rm md5.txt tar xvjf "${TARBALL}" rm "${TARBALL}" -echo "export PATH=\"${CURDIR}/${TARDIR}/bin\":\"\${PATH}\"" > build.env +if [ -n "${GITHUB_CI_PR_SHA}" ]; then + # This is for GitHub Actions CI/CD tooling only + echo "export PATH=\"${CURDIR}/${TARDIR}/bin\":\"\${PATH}\"" > build.env +else + # And this is for local install + echo "" + echo "Add a line like" + echo "export PATH=\"${CURDIR}/${TARDIR}/bin\":\"\${PATH}\"" + echo "to your ~/.profile and/or ~/.bashrc and run the line to enable toolchain as default one for arm-none-eabi-* target" + echo "" +fi; From df35e5b67bc80a2cec0f8ea158b8b7f1682b0299 Mon Sep 17 00:00:00 2001 From: Ivan Zorin Date: Tue, 2 Apr 2024 14:31:39 +0300 Subject: [PATCH 68/68] workflow/push.yml - remove printf-like step to show revision during debug --- .github/workflows/push.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 2a442e93..d760ee27 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -41,7 +41,7 @@ jobs: run: bash scripts/env.sh - name: Build ${{ matrix.model }} - run: source build.env && arm-none-eabi-gcc --version && arm-none-eabi-gcc -print-search-dirs && python3 src/build-scripts/hydrafw-revision.py && make V=1 -j$(nproc) -C src/ + run: source build.env && arm-none-eabi-gcc --version && arm-none-eabi-gcc -print-search-dirs && make V=1 -j$(nproc) -C src/ - name: Archive ${{ matrix.model }} artifacts uses: actions/upload-artifact@v4