@@ -7,22 +7,25 @@ LABEL description="This is a Docker Image for XRobot build."
77
88RUN apt update
99
10- RUN apt upgrade -y --no-install-recommends && apt install -y --no-install-recommends xz-utils git curl sudo wget zip make && apt install -y net-tools usbutils nano gdb cmake ninja-build file clang-tidy gcc g++ python3-tk && apt clean
11-
12- RUN wget https://github.com/ARM-software/LLVM-embedded-toolchain-for-Arm/releases/download/release-19.1.5/LLVM-ET-Arm-19.1.5-Linux-x86_64.tar.xz && tar -xvf LLVM-ET-Arm-19.1.5-Linux-x86_64.tar.xz && rm LLVM-ET-Arm-19.1.5-Linux-x86_64.tar.xz && mv LLVM-ET-Arm-19.1.5-Linux-x86_64 /opt && sudo ln -s /opt/LLVM-ET-Arm-19.1.5-Linux-x86_64/bin/* /usr/bin
13-
14- RUN for pair in \
15- "clang:clang" \
16- "clang++:clang++" \
17- "llvm-objcopy:objcopy" \
18- "llvm-size:size" \
19- "llvm-ar:ar" \
20- "llvm-nm:nm" \
21- "llvm-strip:strip" ; do \
22- src=$(echo $pair | cut -d: -f1); \
23- tgt=$(echo $pair | cut -d: -f2); \
24- ln -sf /opt/LLVM-ET-Arm-19.1.5-Linux-x86_64/bin/$src /usr/bin/starm-$tgt; \
25- done
10+ RUN apt upgrade -y --no-install-recommends && apt install -y --no-install-recommends xz-utils git curl sudo wget zip unzip make && apt install -y net-tools usbutils util-linux expect nano gdb cmake ninja-build file clang-tidy gcc g++ python3-tk && apt clean
11+
12+ RUN curl -L -o stm32cube-ide-core.vsix \
13+ -H "Accept: application/octet-stream" \
14+ -A "Mozilla/5.0" \
15+ "https://marketplace.visualstudio.com/_apis/public/gallery/publishers/stmicroelectronics/vsextensions/stm32cube-ide-core/latest/vspackage" && \
16+ mv stm32cube-ide-core.vsix stm32cube-ide-core.vsix.gz && \
17+ gunzip stm32cube-ide-core.vsix.gz && \
18+ unzip stm32cube-ide-core.vsix && \
19+ expect -c 'spawn extension/resources/binaries/linux/x86_64/cube bundle download st-arm-clang; set timeout -1; expect { -re "Proceed with download (yes, no)?" { send "yes\r "; exp_continue }; eof }' && \
20+ BUNDLE_FILE=$(ls -t *.bundle | head -n1) && \
21+ mkdir -p /opt/st-arm-clang && \
22+ unzip "$BUNDLE_FILE" -d /opt/st-arm-clang && \
23+ rm -rf extension *.bundle *.vsix stm32cube-ide-core.vsix.gz
24+
25+ RUN for exe in /opt/st-arm-clang/bin/*; do \
26+ ln -sf "$exe" /usr/bin/$(basename "$exe" ); \
27+ done
28+
2629
2730RUN sudo mv /usr/lib/python3.12/EXTERNALLY-MANAGED /usr/lib/python3.12/EXTERNALLY-MANAGED.bk
2831
0 commit comments