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,16 +5,32 @@ 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
9- RUN apt-get update
10- RUN apt-get install -y software-properties-common
11- RUN add-apt-repository -y ppa:ubuntu-toolchain-r/test
12- RUN apt-get update
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
8+ # Use GCC 11 (default in Ubuntu 22.04) for C++20 support with compatible GLIBCXX symbols
9+ RUN apt-get update && apt-get install -y \
10+ build-essential \
11+ python3 \
12+ python3-distutils \
13+ g++-11 \
14+ make \
15+ curl \
16+ git \
17+ pkg-config \
18+ libssl-dev \
19+ libffi-dev \
20+ libgmp-dev \
21+ libtool \
22+ autoconf \
23+ automake \
24+ cmake \
25+ wget \
26+ xz-utils \
27+ unzip \
28+ vim \
29+ && rm -rf /var/lib/apt/lists/*
30+
31+ # Set GCC 11 as the default compiler
32+ RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-11 100
33+ RUN update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-11 100
1834
1935# Copy local Node.js source into the image
2036WORKDIR /usr/src/node
Original file line number Diff line number Diff line change @@ -6,16 +6,33 @@ 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
10- RUN apt-get update
11- RUN apt-get install -y software-properties-common
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
14- RUN rm -rf /var/lib/apt/lists/*
9+ # Use GCC 11 (default in Ubuntu 22.04) for C++20 support with compatible GLIBCXX symbols
10+ # GCC 13 requires GLIBCXX_3.4.31/32 which older systems don't have
11+ RUN apt-get update && apt-get install -y \
12+ build-essential \
13+ python3 \
14+ python3-distutils \
15+ g++-11 \
16+ make \
17+ curl \
18+ git \
19+ pkg-config \
20+ libssl-dev \
21+ libffi-dev \
22+ libgmp-dev \
23+ libtool \
24+ autoconf \
25+ automake \
26+ cmake \
27+ wget \
28+ xz-utils \
29+ unzip \
30+ vim \
31+ && rm -rf /var/lib/apt/lists/*
1532
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
33+ # Set GCC 11 as the default compiler
34+ RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-11 100
35+ RUN update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-11 100
1936
2037# Copy local Node.js source into the image
2138WORKDIR /usr/src/node
Original file line number Diff line number Diff line change @@ -5,16 +5,32 @@ 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
9- RUN apt-get update
10- RUN apt-get install -y software-properties-common
11- RUN add-apt-repository -y ppa:ubuntu-toolchain-r/test
12- RUN apt-get update
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
8+ # Use GCC 11 (default in Ubuntu 22.04) for C++20 support with compatible GLIBCXX symbols
9+ RUN apt-get update && apt-get install -y \
10+ build-essential \
11+ python3 \
12+ python3-distutils \
13+ g++-11 \
14+ make \
15+ curl \
16+ git \
17+ pkg-config \
18+ libssl-dev \
19+ libffi-dev \
20+ libgmp-dev \
21+ libtool \
22+ autoconf \
23+ automake \
24+ cmake \
25+ wget \
26+ xz-utils \
27+ unzip \
28+ vim \
29+ && rm -rf /var/lib/apt/lists/*
30+
31+ # Set GCC 11 as the default compiler
32+ RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-11 100
33+ RUN update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-11 100
1834
1935# Copy local Node.js source into the image
2036WORKDIR /usr/src/node
You can’t perform that action at this time.
0 commit comments