Skip to content

Commit

Permalink
Merge pull request #188 from microsoft/fixdocs
Browse files Browse the repository at this point in the history
Button up Dockerfile and related Linux dev environment documentation
  • Loading branch information
abeltrano authored Feb 29, 2024
2 parents 8dcf1bb + 2194d10 commit c961c33
Show file tree
Hide file tree
Showing 2 changed files with 47 additions and 43 deletions.
86 changes: 45 additions & 41 deletions .docker/netremote-dev/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@
FROM ubuntu:mantic as netremote-build

# Set arguments used only in this Dockerfile.
ARG build_date="2023-11-09T19:51:18Z"
ARG BUILD_DATE="2024-02-28T21:09:49+00:00"
ARG DEBIAN_FRONTEND=noninteractive
ARG LLVM_VERSION=17
ARG APT_ARGS_COMMON="-yqq --no-install-recommends"

LABEL maintainer="Andrew Beltrano ([email protected])"
LABEL org.label-schema.build-date = "${build_date}"
LABEL org.label-schema.build-date = "${BUILD_DATE}"
LABEL org.label-schema.name = "Microsoft NetRemote build environment"
LABEL org.label-schema.description = "Build environment for development of the NetRemote project"
LABEL org.label-schema.description = "Build environment for the NetRemote project"
LABEL org.label-schema.vendor = "Microsoft"
LABEL org.label-schema.version = "1.0.0"
LABEL org.label-schema.schema-version = "1.0"
Expand All @@ -22,7 +22,7 @@ LABEL org.label-schema.schema-version = "1.0"
# sudo apt -y update && sudo apt -y upgrade
#
# 2. Install core build tools and dependencies:
# sudo apt install -y --no-install-recommends build-essential ca-certificates cmake curl dotnet7 git gnupg linux-libc-dev ninja-build pkg-config tar unzip zip libnl-3-200-dbg libnl-3-dev libssl-dev libnl-genl-3-dev libdbus-c++-dev libnl-route-3-dev
# sudo apt install -y --no-install-recommends build-essential ca-certificates cmake curl dotnet7 git gnupg linux-libc-dev ninja-build pkg-config tar unzip zip
#
# 3. Install complete LLVM 17 + clang 17 toolchain:
# sudo apt install -y --no-install-recommends libllvm-17-ocaml-dev libllvm17 llvm-17 llvm-17-dev llvm-17-doc llvm-17-examples llvm-17-runtime clang-17 clang-tools-17 clang-17-doc libclang-common-17-dev libclang-17-dev libclang1-17 clang-format-17 python3-clang-17 clangd-17 clang-tidy-17 libclang-rt-17-dev libpolly-17-dev libfuzzer-17-dev lldb-17 lld-17 libc++-17-dev libc++abi-17-dev libomp-17-dev libclc-17-dev libunwind-17-dev libmlir-17-dev mlir-17-tools libbolt-17-dev bolt-17 flang-17 libclang-rt-17-dev-wasm32 libclang-rt-17-dev-wasm64 libc++-17-dev-wasm32 libc++abi-17-dev-wasm32 libclang-rt-17-dev-wasm32 libclang-rt-17-dev-wasm64
Expand All @@ -35,9 +35,9 @@ LABEL org.label-schema.schema-version = "1.0"
#

# Install packages.
RUN apt -y update && \
apt -y upgrade && \
apt install -qq -y --no-install-recommends \
RUN apt-get $APT_ARGS_COMMON update && \
apt-get $APT_ARGS_COMMON upgrade && \
apt-get $APT_ARGS_COMMON install \
# Core project build dependencies.
# build-essential ca-certificates cmake curl dotnet7 git gnupg linux-libc-dev ninja-build pkg-config tar unzip zip
build-essential \
Expand All @@ -54,44 +54,45 @@ RUN apt -y update && \
unzip \
zip \
# LLVM + Clang toolchain.
libllvm-17-ocaml-dev \
libllvm17 \
llvm-17 \
llvm-17-dev \
llvm-17-doc \
llvm-17-examples \
llvm-17-runtime \
# libllvm-17-ocaml-dev libllvm17 llvm-17 llvm-17-dev llvm-17-doc llvm-17-examples llvm-17-runtime clang-17 clang-tools-17 clang-17-doc libclang-common-17-dev libclang-17-dev libclang1-17 clang-format-17 python3-clang-17 clangd-17 clang-tidy-17 libclang-rt-17-dev libpolly-17-dev libfuzzer-17-dev lldb-17 lld-17 libc++-17-dev libc++abi-17-dev libomp-17-dev libclc-17-dev libunwind-17-dev libmlir-17-dev mlir-17-tools libbolt-17-dev bolt-17 flang-17 libclang-rt-17-dev-wasm32 libclang-rt-17-dev-wasm64 libc++-17-dev-wasm32 libc++abi-17-dev-wasm32 libclang-rt-17-dev-wasm32 libclang-rt-17-dev-wasm64
bolt-17 \
clang-17 \
clang-tools-17 \
clang-17-doc \
libclang-common-17-dev \
libclang-17-dev \
libclang1-17 \
clang-format-17 \
python3-clang-17 \
clangd-17 \
clang-tidy-17 \
libclang-rt-17-dev \
libpolly-17-dev \
libfuzzer-17-dev \
lldb-17 \
lld-17 \
libc++-17-dev \
libc++abi-17-dev \
libomp-17-dev \
libclc-17-dev \
libunwind-17-dev \
libmlir-17-dev \
mlir-17-tools \
libbolt-17-dev \
bolt-17 \
clang-tools-17 \
clangd-17 \
flang-17 \
libclang-rt-17-dev-wasm32 \
libclang-rt-17-dev-wasm64 \
libbolt-17-dev \
libc++-17-dev \
libc++-17-dev-wasm32 \
libc++abi-17-dev \
libc++abi-17-dev-wasm32 \
libclang-17-dev \
libclang-common-17-dev \
libclang-rt-17-dev \
libclang-rt-17-dev-wasm32 \
libclang-rt-17-dev-wasm32 \
libclang-rt-17-dev-wasm64 \
libclang-rt-17-dev-wasm64 \
libclang1-17 \
libclc-17-dev \
libfuzzer-17-dev \
libllvm-17-ocaml-dev \
libllvm17 \
libmlir-17-dev \
libomp-17-dev \
libpolly-17-dev \
libunwind-17-dev \
lld-17 \
lldb-17 \
llvm-17 \
llvm-17-dev \
llvm-17-doc \
llvm-17-examples \
llvm-17-runtime \
mlir-17-tools \
python3-clang-17 \
# hostapd build dependencies.
# libnl-3-200-dbg libnl-3-dev libssl-dev libnl-genl-3-dev
libnl-3-200-dbg \
Expand All @@ -104,7 +105,7 @@ RUN apt -y update && \
libnl-route-3-dev

# Reduce image size by removing package cache
RUN apt clean && \
RUN apt-get -yqq clean && \
rm -rf /var/lib/apt/lists/*

# Set environment variables for external vcpkg to support binary caching
Expand Down Expand Up @@ -132,9 +133,12 @@ ENTRYPOINT [ "/bin/entrypoint-build.sh" ]

FROM netremote-build as netremote-dev

LABEL org.label-schema.name = "Microsoft NetRemote development environment"
LABEL org.label-schema.description = "Development environment for the NetRemote project"

# Install packages.
RUN apt update && \
apt install -y --no-install-recommends \
RUN apt-get $APT_ARGS_COMMON update && \
apt-get $APT_ARGS_COMMON install \
# WSL2 kernel development dependencies.
# build-essential flex bison dwarves libssl-dev libelf-dev bc
bc \
Expand Down Expand Up @@ -164,7 +168,7 @@ RUN apt update && \
vim \
&& \
# Reduce image size by removing package cache.
apt clean && \
apt-get -yqq clean && \
rm -rf /var/lib/apt/lists/*

# Copy outside content into container.
Expand Down
4 changes: 2 additions & 2 deletions src/linux/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ Execute the following commands in a shell to install all the tools required to c
2. Install core build tools and dependencies:

```bash
sudo apt install -y --no-install-recommends build-essential ca-certificates cmake curl dotnet7 git gnupg linux-libc-dev ninja-build pkg-config tar unzip zip libnl-3-200-dbg libnl-3-dev libssl-dev libnl-genl-3-dev libdbus-c++-dev libnl-route-3-dev clang-17 clang-tools-17 clang-format-17 clangd-17 clang-tidy-17 lldb-17 lld-17 libbolt-17-dev bolt-17 libunwind-17-dev
sudo apt install -y --no-install-recommends build-essential ca-certificates cmake curl dotnet7 git gnupg linux-libc-dev ninja-build pkg-config tar unzip zip
```

3. Install LLVM compiler dependencies:
Expand All @@ -84,7 +84,7 @@ Execute the following commands in a shell to install all the tools required to c
5. Install [hostapd](git://w1.fi/hostap.git) development dependencies:

```bash
sudo apt install -y libnl-3-dev libssl-dev libnl-genl-3-dev libnl-3-dev libdbus-c++-dev libnl-route-3-dev flex bison dwarves libelf-dev bc
sudo apt install -y --no-install-recommends libnl-3-dev libssl-dev libnl-genl-3-dev libnl-3-dev libdbus-c++-dev libnl-route-3-dev flex bison dwarves libelf-dev bc
```

> [!NOTE]
Expand Down

0 comments on commit c961c33

Please sign in to comment.