Skip to content

Commit

Permalink
#0: add gcc-12 and python 3.11 and make them the default when invokin…
Browse files Browse the repository at this point in the history
…g g++ and python3 respectively
  • Loading branch information
TT-billteng committed Aug 7, 2024
1 parent 2b7ea8d commit e531b98
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 4 deletions.
15 changes: 15 additions & 0 deletions dockerfile/ubuntu-22.04-amd64.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@ FROM ubuntu:22.04
ARG DEBIAN_FRONTEND=noninteractive
ENV DOXYGEN_VERSION=1.9.6

RUN apt update -y && apt install software-properties-common gpg-agent -y

# add custom repo
RUN add-apt-repository ppa:deadsnakes/ppa

# Install build and runtime deps
COPY /scripts/docker/requirements-22.04.txt /opt/tt_metal_infra/scripts/docker/requirements.txt
RUN apt-get -y update \
Expand Down Expand Up @@ -63,4 +68,14 @@ RUN python3 -m pip config set global.extra-index-url https://download.pytorch.or
RUN python3 -m pip install -r ${TT_METAL_INFRA_DIR}/tt-metal/tt_metal/python_env/requirements-dev.txt
RUN python3 -m pip install -r ${TT_METAL_INFRA_DIR}/tt-metal/docs/requirements-docs.txt

# Set python 3.11 and gcc-12 to be default
RUN update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.10 10
RUN update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.11 11

RUN update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-11 11
RUN update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-12 12

RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-11 11
RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-12 12

# CMD ["tail", "-f", "/dev/null"]
7 changes: 3 additions & 4 deletions scripts/docker/requirements-22.04.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
apt-utils
dialog
build-essential
software-properties-common
gcc-12
g++-12
git
Expand All @@ -15,7 +14,7 @@ curl
wget
python3-pip
libhwloc-dev
python3-dev
python3-venv
python3.11-dev
python3.11-venv
cargo
ninja-build
ninja-build

0 comments on commit e531b98

Please sign in to comment.