2020-05-11 13:27:40 +10:00
|
|
|
FROM debian:stable-slim
|
|
|
|
|
2020-05-11 13:31:44 +10:00
|
|
|
RUN apt-get -y update && \
|
|
|
|
apt-get -y upgrade && \
|
|
|
|
apt-get install --no-install-recommends -y \
|
2020-05-11 13:38:45 +10:00
|
|
|
wget \
|
2020-05-11 13:27:40 +10:00
|
|
|
ca-certificates \
|
|
|
|
autoconf \
|
|
|
|
automake \
|
|
|
|
build-essential \
|
|
|
|
ccache \
|
|
|
|
device-tree-compiler \
|
|
|
|
dfu-util \
|
|
|
|
file \
|
|
|
|
g++ \
|
|
|
|
gcc \
|
|
|
|
gcc-multilib \
|
|
|
|
git \
|
|
|
|
iproute2 \
|
|
|
|
libpcap-dev \
|
|
|
|
libtool \
|
|
|
|
make \
|
|
|
|
ninja-build \
|
|
|
|
python3-dev \
|
|
|
|
python3-pip \
|
|
|
|
python3-setuptools \
|
|
|
|
xz-utils && \
|
|
|
|
rm -rf /var/lib/apt/lists/*
|
|
|
|
|
2020-05-11 13:38:45 +10:00
|
|
|
ARG ZSDK_VERSION=0.11.2
|
2020-05-11 13:45:08 +10:00
|
|
|
RUN wget -q "https://github.com/zephyrproject-rtos/sdk-ng/releases/download/v${ZSDK_VERSION}/zephyr-toolchain-arm-${ZSDK_VERSION}-setup.run" && \
|
|
|
|
sh "zephyr-toolchain-arm-${ZSDK_VERSION}-setup.run" --quiet -- -d /opt/toolchains/zephyr-sdk-${ZSDK_VERSION} && \
|
|
|
|
rm "zephyr-toolchain-arm-${ZSDK_VERSION}-setup.run"
|
2020-05-11 13:38:45 +10:00
|
|
|
|
|
|
|
ARG CMAKE_VERSION=3.16.2
|
|
|
|
RUN wget -q https://github.com/Kitware/CMake/releases/download/v${CMAKE_VERSION}/cmake-${CMAKE_VERSION}-Linux-x86_64.sh && \
|
|
|
|
chmod +x cmake-${CMAKE_VERSION}-Linux-x86_64.sh && \
|
|
|
|
./cmake-${CMAKE_VERSION}-Linux-x86_64.sh --skip-license --prefix=/usr/local && \
|
|
|
|
rm -f ./cmake-${CMAKE_VERSION}-Linux-x86_64.sh
|
|
|
|
|
|
|
|
ENV DEBIAN_FRONTEND noninteractive
|
|
|
|
|
2020-05-11 13:27:40 +10:00
|
|
|
RUN wget -q https://raw.githubusercontent.com/zephyrproject-rtos/zephyr/master/scripts/requirements.txt && \
|
|
|
|
wget -q https://raw.githubusercontent.com/zephyrproject-rtos/zephyr/master/scripts/requirements-base.txt && \
|
|
|
|
wget -q https://raw.githubusercontent.com/zephyrproject-rtos/zephyr/master/scripts/requirements-build-test.txt && \
|
|
|
|
wget -q https://raw.githubusercontent.com/zephyrproject-rtos/zephyr/master/scripts/requirements-doc.txt && \
|
|
|
|
wget -q https://raw.githubusercontent.com/zephyrproject-rtos/zephyr/master/scripts/requirements-run-test.txt && \
|
|
|
|
wget -q https://raw.githubusercontent.com/zephyrproject-rtos/zephyr/master/scripts/requirements-extras.txt && \
|
2020-05-12 01:09:10 +10:00
|
|
|
pip3 install wheel && \
|
2020-05-11 13:27:40 +10:00
|
|
|
pip3 install -r requirements.txt && \
|
2020-05-12 01:09:10 +10:00
|
|
|
pip3 install west && \
|
2020-05-11 13:27:40 +10:00
|
|
|
pip3 install sh
|
|
|
|
|
|
|
|
ENV ZEPHYR_TOOLCHAIN_VARIANT=zephyr
|
|
|
|
ENV ZEPHYR_SDK_INSTALL_DIR=/opt/toolchains/zephyr-sdk-${ZSDK_VERSION}
|
|
|
|
|
|
|
|
CMD ["/bin/bash"]
|