Skip to content

Commit

Permalink
Repair version-related patch-logic in shell
Browse files Browse the repository at this point in the history
  • Loading branch information
ckormanyos committed Jan 29, 2024
1 parent dd20a2c commit bf3da20
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 16 deletions.
31 changes: 17 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,22 @@ Design goals:
- Provide a non-trivial test of the newly-built toolchain(s) based on a real-world project.
- Support cyclic monthly build of modern, evolving GCC releases.
- Publish the build artifacts directly from the GHA Workflow-Run(s).
- TBD: Publish named releases instead of cyclic build and publishing directly from the GHA Workflow-Run(s), see also [issue 26](https://github.com/ckormanyos/avr-gcc-build/issues/26).
- Occasionally create and publish versioned releases. See also [issue 26](https://github.com/ckormanyos/avr-gcc-build/issues/26).

## Distribution: Releases and Build Artifacts

Using released or CI-built artifacts can be convenient when you
do not actually want to nor need to manually build
`avr-gcc` toolchain.

Releases and build artifacts consisting of the
fully-built `avr-gcc` toolchain are occasionally created
and published for `x86_64-linux-gnu` (Linux) and
`x86_64-w64-mingw32` (Windows). These can be readily found
on the repo front page and in CI workflow-run download-areas
for immediate client use. The releases are permanent, whereby
the built artifacts are limited to three days after the
Workflow-Run(s).

## Workflow-Run

Expand All @@ -34,21 +49,9 @@ Workflow:
- GCC prerequisites including [GMP](https://gmplib.org), [MPFR](https://www.mpfr.org), [MPC](https://www.multiprecision.org), etc. are built on-the-fly in the Workflow-Run.
- Build [`binutils`](https://www.gnu.org/software/binutils) and partially verify the build artifacts.
- Then build `avr-gcc` and partially verify the build artifacts.
- Get a modern release of [`avr-libc`](https://github.com/avrdudes/avr-libc/tags) from [`avrdudes/avr-libc`](https://github.com/avrdudes/avr-libc) and build it with its `--prefix` matching that of the above-mentioned `avr-gcc`-build.
- Get the main branch of [`avr-libc`](https://github.com/avrdudes/avr-libc/tags) from [`avrdudes/avr-libc`](https://github.com/avrdudes/avr-libc) and build it with its `--prefix` matching that of the above-mentioned `avr-gcc`-build.
- Test the complete, newly built `avr-gcc` toolchain with a non-trivial compiler test. In the compiler test, we build `ref_app` (the reference application) from [`ckormanyos/real-time-cpp`](https://github.com/ckormanyos). Verify the creation of key build results from `ref_app` including ELF-file, HEX-file, map files, etc.

## Distribution: Releases and Build Artifacts

Occasional releases and build artifacts consisting of the
`avr-gcc` toolchain are created for `x86_64-linux-gnu` (Linux) and
`x86_64-w64-mingw32` (Windows). These can be readily found
on the repo front page and in CI workflow-run download-areas
for immediate client use.

Using released or CI-built artifacts can be convenient when you
do not actually want to nor need to manually build
`avr-gcc` toolchain.

## Additional Notes

Notes:
Expand Down
4 changes: 2 additions & 2 deletions avr-gcc-100.sh
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ mkdir -p $SCRIPT_DIR/gcc_build
echo


if [[ "$1" != "12.3.0" ]]; then
if [[ "$MY_VERSION" == "12.3.0" ]]; then
echo 'copy gcc patch file'
cd $SCRIPT_DIR/gcc_build
cp ../avr-gcc-100-"$MY_VERSION"_"$BUILD_NAME".patch .
Expand Down Expand Up @@ -190,7 +190,7 @@ echo
cd $SCRIPT_DIR/gcc_build
echo 'build gcc'
tar -xf gcc-"$MY_VERSION".tar.xz
if [[ "$1" != "12.3.0" ]]; then
if [[ "$MY_VERSION" == "12.3.0" ]]; then
patch -p0 < avr-gcc-100-"$MY_VERSION"_"$BUILD_NAME".patch
fi
mkdir objdir-gcc-"$MY_VERSION"-avr
Expand Down

0 comments on commit bf3da20

Please sign in to comment.