File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -5,10 +5,16 @@ FROM ubuntu:22.04 AS base
55ENV DEBIAN_FRONTEND=noninteractive
66
77# Install necessary dependencies
8+ # Install GCC 13 from Ubuntu Toolchain PPA for full C++20 support
89RUN apt-get update
910RUN apt-get install -y software-properties-common
11+ RUN add-apt-repository -y ppa:ubuntu-toolchain-r/test
1012RUN apt-get update
11- RUN apt-get install -y build-essential python3 python3-distutils g++ make curl git pkg-config libssl-dev libffi-dev libgmp-dev libtool autoconf automake cmake wget xz-utils unzip vim
13+ RUN apt-get install -y build-essential python3 python3-distutils gcc-13 g++-13 make curl git pkg-config libssl-dev libffi-dev libgmp-dev libtool autoconf automake cmake wget xz-utils unzip vim
14+
15+ # Set GCC 13 as the default compiler
16+ RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-13 100
17+ RUN update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-13 100
1218
1319# Copy local Node.js source into the image
1420WORKDIR /usr/src/node
Original file line number Diff line number Diff line change @@ -6,11 +6,17 @@ ENV DEBIAN_FRONTEND=noninteractive
66
77# Install necessary dependencies
88# Ubuntu 22.04 has Python 3.10 which meets Node.js v24 requirement (3.9+)
9+ # Install GCC 13 from Ubuntu Toolchain PPA for full C++20 support
910RUN apt-get update
1011RUN apt-get install -y software-properties-common
11- RUN apt-get update && apt-get install -y build-essential python3 python3-distutils g++ make curl git pkg-config libssl-dev libffi-dev libgmp-dev libtool autoconf automake cmake wget xz-utils unzip vim
12+ RUN add-apt-repository -y ppa:ubuntu-toolchain-r/test
13+ RUN apt-get update && apt-get install -y build-essential python3 python3-distutils gcc-13 g++-13 make curl git pkg-config libssl-dev libffi-dev libgmp-dev libtool autoconf automake cmake wget xz-utils unzip vim
1214RUN rm -rf /var/lib/apt/lists/*
1315
16+ # Set GCC 13 as the default compiler
17+ RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-13 100
18+ RUN update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-13 100
19+
1420# Copy local Node.js source into the image
1521WORKDIR /usr/src/node
1622COPY . .
Original file line number Diff line number Diff line change @@ -5,10 +5,16 @@ FROM ubuntu:22.04 AS base
55ENV DEBIAN_FRONTEND=noninteractive
66
77# Install necessary dependencies
8+ # Install GCC 13 from Ubuntu Toolchain PPA for full C++20 support
89RUN apt-get update
910RUN apt-get install -y software-properties-common
11+ RUN add-apt-repository -y ppa:ubuntu-toolchain-r/test
1012RUN apt-get update
11- RUN apt-get install -y build-essential python3 python3-distutils g++ make curl git pkg-config libssl-dev libffi-dev libgmp-dev libtool autoconf automake cmake wget xz-utils unzip vim
13+ RUN apt-get install -y build-essential python3 python3-distutils gcc-13 g++-13 make curl git pkg-config libssl-dev libffi-dev libgmp-dev libtool autoconf automake cmake wget xz-utils unzip vim
14+
15+ # Set GCC 13 as the default compiler
16+ RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-13 100
17+ RUN update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-13 100
1218
1319# Copy local Node.js source into the image
1420WORKDIR /usr/src/node
You can’t perform that action at this time.
0 commit comments