From 16f8910456cc0416b617f3f5a4a2846d14357a63 Mon Sep 17 00:00:00 2001 From: Nbw Date: Sat, 30 Sep 2023 19:04:36 +0400 Subject: [PATCH 1/3] Fix Dockerfile --- Dockerfile | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/Dockerfile b/Dockerfile index fc633d6..38d8b28 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,10 +1,16 @@ +# hadolint ignore=DL3007 FROM archlinux:latest + WORKDIR /app + COPY . . -RUN pacman -Syyu base-devel --noconfirm -RUN pacman -Syyu arm-none-eabi-gcc --noconfirm -RUN pacman -Syyu arm-none-eabi-newlib --noconfirm -RUN pacman -Syyu git --noconfirm + +RUN set -eux; \ + pacman -Syy --noconfirm \ + arm-none-eabi-gcc \ + arm-none-eabi-newlib \ + base-devel \ + git RUN git submodule update --init --recursive #RUN make && cp firmware* compiled-firmware/ From 8905d352aeca99681a2e6a0d031c8c1188d5b9a5 Mon Sep 17 00:00:00 2001 From: Nbw Date: Sat, 30 Sep 2023 19:21:48 +0400 Subject: [PATCH 2/3] Fix missing python-crcmod package --- Dockerfile | 4 ++-- Makefile | 1 - compile-with-docker.sh | 2 +- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/Dockerfile b/Dockerfile index 38d8b28..dd07155 100644 --- a/Dockerfile +++ b/Dockerfile @@ -10,7 +10,7 @@ RUN set -eux; \ arm-none-eabi-gcc \ arm-none-eabi-newlib \ base-devel \ - git + git \ + python-crcmod RUN git submodule update --init --recursive -#RUN make && cp firmware* compiled-firmware/ diff --git a/Makefile b/Makefile index 97c565b..d22179e 100755 --- a/Makefile +++ b/Makefile @@ -173,7 +173,6 @@ DEPS = $(OBJS:.o=.d) all: $(TARGET) $(OBJCOPY) -O binary $< $<.bin -python fw-pack.py $<.bin $(GIT_HASH) $<.packed.bin - -python3 fw-pack.py $<.bin $(GIT_HASH) $<.packed.bin $(SIZE) $< debug: diff --git a/compile-with-docker.sh b/compile-with-docker.sh index fb5dd01..f9ee8aa 100755 --- a/compile-with-docker.sh +++ b/compile-with-docker.sh @@ -1,3 +1,3 @@ #!/bin/sh docker build -t uvk5 . -docker run -v $(PWD)/compiled-firmware:/app/compiled-firmware uvk5 /bin/bash -c "cd /app && make && cp firmware* compiled-firmware/" \ No newline at end of file +docker run -v "$(PWD)/compiled-firmware:/app/compiled-firmware" uvk5 /bin/bash -c "cd /app && make && cp firmware* compiled-firmware/" From be4f6ac46b7d50cf1d542e053727b4888407a26b Mon Sep 17 00:00:00 2001 From: Nbw Date: Sat, 30 Sep 2023 19:37:52 +0400 Subject: [PATCH 3/3] Fix syntax error in compile-with-docker.sh --- compile-with-docker.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/compile-with-docker.sh b/compile-with-docker.sh index f9ee8aa..8d4ccc0 100755 --- a/compile-with-docker.sh +++ b/compile-with-docker.sh @@ -1,3 +1,3 @@ #!/bin/sh docker build -t uvk5 . -docker run -v "$(PWD)/compiled-firmware:/app/compiled-firmware" uvk5 /bin/bash -c "cd /app && make && cp firmware* compiled-firmware/" +docker run -v "$(pwd)/compiled-firmware:/app/compiled-firmware" uvk5 /bin/bash -c "cd /app && make && cp firmware* compiled-firmware/"