|
45 | 45 |
|
46 | 46 | "${GITHUB_WORKSPACE}/${REPOSITORY}/install_requirements.sh" --example |
47 | 47 |
|
48 | | -# Install glibc-2.29 |
| 48 | +# Install glibc-2.34 |
49 | 49 |
|
50 | | -echo "GCC version: $(gcc -dumpfullversion)" |
| 50 | +# Install older GCC (works on GitHub Ubuntu runners) |
| 51 | +sudo apt-get update |
| 52 | +sudo apt-get install -y gcc-11 g++-11 |
| 53 | + |
| 54 | +# Force glibc build to use GCC 11 |
| 55 | +export CC=gcc-11 |
| 56 | +export CXX=g++-11 |
| 57 | + |
| 58 | +echo "GCC version (system default): $(gcc -dumpfullversion)" |
| 59 | +echo "GCC version (forced CC): $($CC -dumpfullversion)" |
51 | 60 |
|
52 | 61 | # 👇 only change this line to bump version |
53 | 62 | GLIBC_VERSION=2.34 |
@@ -77,22 +86,11 @@ cd "$BUILD_DIR" |
77 | 86 | # Unset LD_LIBRARY_PATH to satisfy glibc configure |
78 | 87 | unset LD_LIBRARY_PATH |
79 | 88 |
|
80 | | -# Suppress GCC 13+ warnings |
81 | | -COMMON_FLAGS="-O2 -fPIC -fcommon \ |
82 | | - -Wno-error \ |
83 | | - -Wno-error=array-parameter \ |
84 | | - -Wno-error=array-bounds \ |
85 | | - -Wno-error=maybe-uninitialized \ |
86 | | - -Wno-error=zero-length-bounds \ |
87 | | - -Wno-error=stringop-overflow \ |
88 | | - -Wno-error=deprecated-declarations \ |
89 | | - -Wno-error=use-after-free \ |
90 | | - -Wno-error=builtin-declaration-mismatch \ |
91 | | - -Wno-error=attributes \ |
92 | | - -Wno-error=implicit-function-declaration" |
93 | | - |
| 89 | +# Suppress GCC warnings (GCC 11 is more compatible, but keep flags) |
| 90 | +COMMON_FLAGS="-O2 -fPIC -fcommon -Wno-error" |
94 | 91 | export CFLAGS="$COMMON_FLAGS" |
95 | 92 | export CPPFLAGS="$COMMON_FLAGS" |
| 93 | +export CXXFLAGS="$COMMON_FLAGS" |
96 | 94 |
|
97 | 95 | # Configure |
98 | 96 | ../glibc-$GLIBC_VERSION/configure \ |
|
0 commit comments