From d95d7a73da8acef3aeea1c8f570975bb303200d1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonatan=20M=C3=A4nnchen?= Date: Thu, 4 Jun 2026 11:46:36 +0200 Subject: [PATCH 01/13] erts: avoid array-bounds warning in eq() GCC 14 (cross toolchain on Debian Trixie) flags the over-read of the trailing data.ui[1] member when comparing external pids/ports, since EXTERNAL_PID/PORT_DATA_WORDS is 2 on 32-bit. Replace the element-wise comparison loops with sys_memcmp, matching erl_monitor_link.c. --- erts/emulator/beam/utils.c | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/erts/emulator/beam/utils.c b/erts/emulator/beam/utils.c index 709870fe8456..5579948a5074 100644 --- a/erts/emulator/beam/utils.c +++ b/erts/emulator/beam/utils.c @@ -1279,7 +1279,6 @@ int eq(Eterm a, Eterm b) case EXTERNAL_PID_SUBTAG: { ExternalThing *ap; ExternalThing *bp; - int i; if(!is_external(b)) goto not_equal; @@ -1293,16 +1292,14 @@ int eq(Eterm a, Eterm b) ASSERT(external_data_words(a) == EXTERNAL_PID_DATA_WORDS); ASSERT(external_data_words(b) == EXTERNAL_PID_DATA_WORDS); - for (i = 0; i < EXTERNAL_PID_DATA_WORDS; i++) { - if (ap->data.ui[i] != bp->data.ui[i]) - goto not_equal; - } + if (sys_memcmp(ap->data.ui, bp->data.ui, + EXTERNAL_PID_DATA_WORDS * sizeof(Uint)) != 0) + goto not_equal; goto pop_next; } case EXTERNAL_PORT_SUBTAG: { ExternalThing *ap; ExternalThing *bp; - int i; if(!is_external(b)) goto not_equal; @@ -1316,10 +1313,9 @@ int eq(Eterm a, Eterm b) ASSERT(EXTERNAL_PORT_DATA_WORDS == external_data_words(a)); ASSERT(EXTERNAL_PORT_DATA_WORDS == external_data_words(b)); - for (i = 0; i < EXTERNAL_PORT_DATA_WORDS; i++) { - if (ap->data.ui[i] != bp->data.ui[i]) - goto not_equal; - } + if (sys_memcmp(ap->data.ui, bp->data.ui, + EXTERNAL_PORT_DATA_WORDS * sizeof(Uint)) != 0) + goto not_equal; goto pop_next; } case EXTERNAL_REF_SUBTAG: { From c58c097bc8e748b4d21dd2129219ccd1451a05ba Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonatan=20M=C3=A4nnchen?= Date: Thu, 4 Jun 2026 11:47:17 +0200 Subject: [PATCH 02/13] erts: fix -Wstrict-prototypes errors clang 18 on Noble errors on -Wstrict-prototypes for functions defined with an empty parameter list. Declare them as (void). --- erts/emulator/beam/beam_bp.c | 2 +- erts/emulator/beam/erl_crash_dump.c | 4 ++-- erts/emulator/beam/erl_lock_count.c | 10 +++++----- erts/lib_src/yielding_c_fun/ycf_utils.c | 2 +- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/erts/emulator/beam/beam_bp.c b/erts/emulator/beam/beam_bp.c index 9c18ec5148dc..9cab23a8f146 100644 --- a/erts/emulator/beam/beam_bp.c +++ b/erts/emulator/beam/beam_bp.c @@ -1618,7 +1618,7 @@ static void collect_timem_info(BpTimemTrace* bdt, } } -void erts_timem_info_consolidate() +void erts_timem_info_consolidate(void) { FinishTimemInfo *fin = &finish_timem_info; GenericBpData *staging = &fin->g->data[erts_staging_bp_ix()]; diff --git a/erts/emulator/beam/erl_crash_dump.c b/erts/emulator/beam/erl_crash_dump.c index 8b45bbd88430..f6b12f68b279 100644 --- a/erts/emulator/beam/erl_crash_dump.c +++ b/erts/emulator/beam/erl_crash_dump.c @@ -238,7 +238,7 @@ erl_crash_dump_init_envelope(EVP_PKEY *public_key, free(key); } -void erl_crash_dump_init() { +void erl_crash_dump_init(void) { unsigned char iv[AES_256_CBC_IV_SIZE]; unsigned char *secret; size_t secret_size; @@ -339,7 +339,7 @@ crash_dump_encrypted_close(void *to_arg) { } #else /* !defined(ENCRYPTED_CRASH_DUMPS) */ -void erl_crash_dump_init() { +void erl_crash_dump_init(void) { /* Nothing to do. */ } #endif diff --git a/erts/emulator/beam/erl_lock_count.c b/erts/emulator/beam/erl_lock_count.c index 6399c16f2d2b..18d7b8c228ea 100644 --- a/erts/emulator/beam/erl_lock_count.c +++ b/erts/emulator/beam/erl_lock_count.c @@ -463,7 +463,7 @@ void lcnt_register_static_lock__(erts_lcnt_ref_t *reference, const char *name, E /* - Initialization - */ -void erts_lcnt_pre_thr_init() { +void erts_lcnt_pre_thr_init(void) { /* Ensure that the dependency hack mentioned in the header doesn't * explode at runtime. */ ERTS_CT_ASSERT(sizeof(LcntThrPrgrLaterOp) >= sizeof(ErtsThrPrgrLaterOp)); @@ -476,7 +476,7 @@ void erts_lcnt_pre_thr_init() { lcnt_init_static_lock_registry(); } -void erts_lcnt_post_thr_init() { +void erts_lcnt_post_thr_init(void) { /* ASSUMPTION: this is safe since it runs prior to the creation of other * threads (Directly after ethread init). */ @@ -485,7 +485,7 @@ void erts_lcnt_post_thr_init() { erts_lcnt_thread_setup(); } -void erts_lcnt_late_init() { +void erts_lcnt_late_init(void) { /* Set start timer and zero all statistics */ erts_lcnt_clear_counters(); erts_thr_install_exit_handler(erts_lcnt_thread_exit_handler); @@ -502,7 +502,7 @@ void erts_lcnt_post_startup(void) { erts_lcnt_set_category_mask(ERTS_LOCK_FLAGS_MASK_CATEGORY); } -void erts_lcnt_thread_setup() { +void erts_lcnt_thread_setup(void) { lcnt_thread_data_t__ *eltd = lcnt_thread_data_alloc(); ASSERT(eltd); @@ -510,7 +510,7 @@ void erts_lcnt_thread_setup() { ethr_tsd_set(lcnt_thr_data_key__, eltd); } -void erts_lcnt_thread_exit_handler() { +void erts_lcnt_thread_exit_handler(void) { lcnt_thread_data_t__ *eltd = lcnt_get_thread_data__(); if (eltd) { diff --git a/erts/lib_src/yielding_c_fun/ycf_utils.c b/erts/lib_src/yielding_c_fun/ycf_utils.c index 10f3a60acc36..aa1e88d192d1 100644 --- a/erts/lib_src/yielding_c_fun/ycf_utils.c +++ b/erts/lib_src/yielding_c_fun/ycf_utils.c @@ -38,7 +38,7 @@ bool ycf_track_memory = false; size_t ycf_memory_usage = 0; size_t ycf_max_memory_usage = 0; -void ycf_enable_memory_tracking(){ +void ycf_enable_memory_tracking(void){ ycf_track_memory = true; } From 910f51ecf2ea4bb9b7ff682f58b2a43dbfc77db6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonatan=20M=C3=A4nnchen?= Date: Thu, 4 Jun 2026 12:10:37 +0200 Subject: [PATCH 03/13] erts: guard software f16 conversion helpers f32_to_f16/f16_to_f32 are only used when the platform lacks native float16 conversion. On Noble, GCC 13 errors with -Werror=unused-function when native conversion is available. Guard the helpers with the same condition that selects the software path. --- erts/emulator/beam/erl_bits.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/erts/emulator/beam/erl_bits.c b/erts/emulator/beam/erl_bits.c index f23648af2c73..02bc512f6c49 100644 --- a/erts/emulator/beam/erl_bits.c +++ b/erts/emulator/beam/erl_bits.c @@ -423,6 +423,7 @@ erts_bs_get_binary_2(Process *p, Uint num_bits, ErlSubBits *sb) return result; } +#if !((SIZEOF__FLOAT16 == 2) && defined(FLOAT16_IS_CONVERTIBLE)) static ERTS_INLINE Uint16 f32_to_f16(float fp) { union { @@ -531,6 +532,7 @@ static ERTS_INLINE float f16_to_f32(Uint16 fp) u.u32 = res; return u.f32; } +#endif Eterm erts_bs_get_float_2(Process *p, Uint num_bits, unsigned flags, ErlSubBits *sb) From df669ab5fa331bab1acbe639df980f674a8003c1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonatan=20M=C3=A4nnchen?= Date: Thu, 4 Jun 2026 12:12:46 +0200 Subject: [PATCH 04/13] erts: free temporary GC heap after its last use In garbage_collect_hibernate, heap_area points into collection_heap and is passed to the offset_* calls as an address range. Move the erts_free of collection_heap after those calls so it is freed after its last use. GCC 13 on Noble flags the previous ordering with -Werror=use-after-free. --- erts/emulator/beam/erl_gc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/erts/emulator/beam/erl_gc.c b/erts/emulator/beam/erl_gc.c index 04a771233ead..b766d89c0116 100644 --- a/erts/emulator/beam/erl_gc.c +++ b/erts/emulator/beam/erl_gc.c @@ -1057,7 +1057,6 @@ garbage_collect_hibernate(Process* p, int check_long_gc) stack_area_sz = stack_size * sizeof(Eterm); erts_deallocate_young_generation(p); - erts_free(ERTS_ALC_T_TMP_HEAP, collection_heap); p->heap = final_heap; p->heap_sz = final_size; @@ -1075,6 +1074,8 @@ garbage_collect_hibernate(Process* p, int check_long_gc) stack_offset, stack_area, stack_area_sz, p->arg_reg, p->arity); + erts_free(ERTS_ALC_T_TMP_HEAP, collection_heap); + if (erts_frame_layout == ERTS_FRAME_LAYOUT_FP_RA) { FRAME_POINTER(p) += stack_offset; } From 1496a220f301e447feda5fb55b11bfcd9e07fd11 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonatan=20M=C3=A4nnchen?= Date: Thu, 4 Jun 2026 11:47:56 +0200 Subject: [PATCH 05/13] wx: accept wxWidgets 3.2 in compat version check The configure check rejected wx 3.x unless WXWIN_COMPATIBILITY_3_0 was set. Accept 3.2 (the version shipped in Noble and Trixie) directly so configure succeeds without the 3.0 compat shim. --- lib/wx/configure | 2 +- lib/wx/configure.ac | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/wx/configure b/lib/wx/configure index 3a9fb665527c..09890bdbf283 100755 --- a/lib/wx/configure +++ b/lib/wx/configure @@ -8043,7 +8043,7 @@ int main (void) { - #if wxMAJOR_VERSION > 2 && (wxMINOR_VERSION == 0 || WXWIN_COMPATIBILITY_3_0 == 1) + #if wxMAJOR_VERSION > 2 && (wxMINOR_VERSION == 0 || wxMINOR_VERSION >= 2 || WXWIN_COMPATIBILITY_3_0 == 1) ; #else #error barf diff --git a/lib/wx/configure.ac b/lib/wx/configure.ac index c3825e2a54d6..e53768706a3c 100644 --- a/lib/wx/configure.ac +++ b/lib/wx/configure.ac @@ -603,7 +603,7 @@ AC_COMPILE_IFELSE( [AC_LANG_PROGRAM([[ #include "wx/wx.h" ]], [[ - #if wxMAJOR_VERSION > 2 && (wxMINOR_VERSION == 0 || WXWIN_COMPATIBILITY_3_0 == 1) + #if wxMAJOR_VERSION > 2 && (wxMINOR_VERSION == 0 || wxMINOR_VERSION >= 2 || WXWIN_COMPATIBILITY_3_0 == 1) ; #else #error barf From 7f9463d2160fec42f883ba59daba7ac1c0fd57a0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonatan=20M=C3=A4nnchen?= Date: Wed, 3 Jun 2026 15:43:25 +0200 Subject: [PATCH 06/13] ci: update ubuntu base image from Jammy to Noble (24.04) - Update wxWidgets packages from 3.0 to 3.2 (3.0 removed in Noble) - Remove manual wx-config alternative (no longer needed with 3.2) - Use dpkg --print-architecture for java-alternatives to support non-amd64 - Update build-base-image.sh to reference ubuntu:24.04 --- .github/dockerfiles/Dockerfile.ubuntu-base | 5 ++--- .github/scripts/build-base-image.sh | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/dockerfiles/Dockerfile.ubuntu-base b/.github/dockerfiles/Dockerfile.ubuntu-base index 528deced2e90..0f2920aaeab3 100644 --- a/.github/dockerfiles/Dockerfile.ubuntu-base +++ b/.github/dockerfiles/Dockerfile.ubuntu-base @@ -24,7 +24,7 @@ ARG BASE=gitpod/workspace-full FROM $BASE -ENV INSTALL_LIBS="zlib1g-dev libncurses5-dev libssl-dev unixodbc-dev libsctp-dev lksctp-tools libgmp3-dev libwxbase3.0-dev libwxgtk3.0-gtk3-dev libwxgtk-webview3.0-gtk3-dev" +ENV INSTALL_LIBS="zlib1g-dev libncurses5-dev libssl-dev unixodbc-dev libsctp-dev lksctp-tools libgmp3-dev libwxgtk3.2-dev libwxgtk-webview3.2-dev" USER root @@ -36,9 +36,8 @@ RUN apt-get update && apt-get -y upgrade && \ apt-get install -y build-essential m4 autoconf clang-format \ flex pkg-config locales tzdata sudo ${INSTALL_LIBS} && \ sed -i 's@# en_US.UTF-8@en_US.UTF-8@g' /etc/locale.gen && locale-gen && \ - update-alternatives --set wx-config /usr/lib/x86_64-linux-gnu/wx/config/gtk3-unicode-3.0 && \ apt-get install -y openjdk-8-jdk-headless && apt-get install -y openjdk-11-jdk-headless && \ - (update-java-alternatives -s java-1.8.0-openjdk-amd64 || true) && \ + update-java-alternatives -s java-1.8.0-openjdk-$(dpkg --print-architecture) && \ java -version 2>&1 | grep 'version "1[.]8' > /dev/null || exit 1 ARG MAKEFLAGS=-j4 diff --git a/.github/scripts/build-base-image.sh b/.github/scripts/build-base-image.sh index 9328639d6f15..592433351741 100755 --- a/.github/scripts/build-base-image.sh +++ b/.github/scripts/build-base-image.sh @@ -63,7 +63,7 @@ case "${BASE_TAG}" in BASE_TYPE=debian-base ;; *ubuntu-base) - BASE="ubuntu:22.04" + BASE="ubuntu:24.04" BASE_TYPE=ubuntu-base ;; esac From f0dc77c6cfb8496221e3a3e5a61e8176582895e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonatan=20M=C3=A4nnchen?= Date: Wed, 3 Jun 2026 15:48:41 +0200 Subject: [PATCH 07/13] ci: build cross-compile images on Debian Trixie The cross-compile job links lib_src objects pre-built by the 64-bit job, which on Noble (glibc 2.39) emits __isoc23_* symbols whenever _GNU_SOURCE is set. The Bookworm cross sysroot (glibc 2.36) lacks those symbols, so the link failed. No -std= flag suppresses the redirect; it is keyed on _GNU_SOURCE, not the C standard. - Bump Debian cross/base images from Bookworm to Trixie (glibc 2.41) - Switch libncurses5-dev to libncurses-dev (renamed in Trixie) --- .github/dockerfiles/Dockerfile.debian-base | 6 +++--- .github/scripts/build-base-image.sh | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/dockerfiles/Dockerfile.debian-base b/.github/dockerfiles/Dockerfile.debian-base index 5ab91d6a057e..8aff841f1147 100644 --- a/.github/dockerfiles/Dockerfile.debian-base +++ b/.github/dockerfiles/Dockerfile.debian-base @@ -21,17 +21,17 @@ ## ## This docker file will build a base image for building Erlang/OTP ## -ARG BASE=debian:bookworm +ARG BASE=debian:trixie FROM $BASE ## Need to have a second arg here as the first does not expose the $BASE in the script below -ARG BASE=debian:bookworm +ARG BASE=debian:trixie ARG HOST_TRIP=x86_64-linux-gnu ENV HOST_TRIP=$HOST_TRIP ENV LANG=C.UTF-8 ENV LC_ALL=C.UTF-8 -ENV INSTALL_LIBS="zlib1g-dev libncurses5-dev libssl-dev unixodbc-dev libwxgtk3.2-dev libwxgtk-webview3.2-dev libsctp-dev lksctp-tools" +ENV INSTALL_LIBS="zlib1g-dev libncurses-dev libssl-dev unixodbc-dev libwxgtk3.2-dev libwxgtk-webview3.2-dev libsctp-dev lksctp-tools" ENV CROSS_LIBS="$INSTALL_LIBS" ## See https://wiki.debian.org/Multiarch/HOWTO for details on how to install things diff --git a/.github/scripts/build-base-image.sh b/.github/scripts/build-base-image.sh index 592433351741..4ea5af65467d 100755 --- a/.github/scripts/build-base-image.sh +++ b/.github/scripts/build-base-image.sh @@ -55,11 +55,11 @@ fi case "${BASE_TAG}" in *i386-debian-base) - BASE="i386/debian:bookworm" + BASE="i386/debian:trixie" BASE_TYPE=debian-base ;; *debian-base) - BASE="debian:bookworm" + BASE="debian:trixie" BASE_TYPE=debian-base ;; *ubuntu-base) From cc657b4715428b7062cd1460e2c18dc502577750 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonatan=20M=C3=A4nnchen?= Date: Wed, 3 Jun 2026 15:44:28 +0200 Subject: [PATCH 08/13] ci: fix UBSan linker error on Ubuntu Noble with GCC 13 GCC 13 on Noble no longer automatically links libubsan when -fsanitize=signed-integer-overflow is in CFLAGS. Add the flag to LDFLAGS as well so the runtime is linked in. --- .github/dockerfiles/Dockerfile.64-bit | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/dockerfiles/Dockerfile.64-bit b/.github/dockerfiles/Dockerfile.64-bit index f026fe20ed1f..58ff3070c57d 100644 --- a/.github/dockerfiles/Dockerfile.64-bit +++ b/.github/dockerfiles/Dockerfile.64-bit @@ -44,7 +44,7 @@ ENV CXXFLAGS="-Wno-maybe-uninitialized" ENV SKIPPED_OSSF_CFLAGS="-Wconversion -mbranch-protection=standard \ -Wextra -Werror=implicit -Werror=incompatible-pointer-types -Werror=int-conversion \ -Wsign-conversion" -ENV LDFLAGS="" +ENV LDFLAGS="-fsanitize=signed-integer-overflow" ## OpenSSF recommended LDFLAGS, skipped are: ## -Wl,-z,nodlopen - as opening drivers/nifs needs this ## -fPIE - not needed with gcc 11 From 464212059ee7eb5b21c75b0f740804e3012c0641 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonatan=20M=C3=A4nnchen?= Date: Wed, 3 Jun 2026 15:49:23 +0200 Subject: [PATCH 09/13] ci: install libstdc++-14-dev for clang on Noble clang 18 on Noble selects the GCC 14 toolchain but only the GCC 13 libstdc++ headers are present, so the C++ standard headers are not found. Install libstdc++-14-dev. --- .github/dockerfiles/Dockerfile.clang | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/dockerfiles/Dockerfile.clang b/.github/dockerfiles/Dockerfile.clang index 05ebe8efa317..fee5eb4476b7 100644 --- a/.github/dockerfiles/Dockerfile.clang +++ b/.github/dockerfiles/Dockerfile.clang @@ -29,7 +29,7 @@ ENV MAKEFLAGS=$MAKEFLAGS \ ERL_TOP=/buildroot/otp \ PATH=/otp/bin:/buildroot/otp/bin:$PATH -RUN sudo apt-get update && sudo apt-get install -y clang +RUN sudo apt-get update && sudo apt-get install -y clang libstdc++-14-dev ARG ARCHIVE=./otp.tar.gz COPY $ARCHIVE /buildroot/otp.tar.gz From 4537394df89198455b45d293dfcbfa472c5d1231 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonatan=20M=C3=A4nnchen?= Date: Wed, 3 Jun 2026 15:49:53 +0200 Subject: [PATCH 10/13] ci: fix pip install in SBOM workflow on Python 3.12 Python 3.12 (shipped with Ubuntu Noble) enforces PEP 668, blocking system-wide pip installs. Add --break-system-packages to allow it in the Docker build context. --- .github/workflows/reusable-sbom.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/reusable-sbom.yaml b/.github/workflows/reusable-sbom.yaml index 8885a2c6a7fd..2ff78ad5f52a 100644 --- a/.github/workflows/reusable-sbom.yaml +++ b/.github/workflows/reusable-sbom.yaml @@ -126,8 +126,8 @@ jobs: FROM otp RUN echo 'export PATH="\$HOME/.local/bin:\$PATH"' >> /home/otptest/.profile RUN sudo apt-get install -y libicu-dev pip && \ - pip install click==8.3.1 scancode-toolkit==${SCANCODE_VERSION} reuse && \ - pip install -U ntia-conformance-checker + pip install --break-system-packages click==8.3.1 scancode-toolkit==${SCANCODE_VERSION} reuse && \ + pip install --break-system-packages -U ntia-conformance-checker EOF - name: Restore from cache From 081796b889a344bd7d2154f093b762391439a42c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonatan=20M=C3=A4nnchen?= Date: Wed, 3 Jun 2026 15:43:55 +0200 Subject: [PATCH 11/13] devcontainer: update base image from focal to noble --- .devcontainer/devcontainer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index 291644fdeb6e..fce8ecf9fb85 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -26,7 +26,7 @@ "dockerfile": "../.github/dockerfiles/Dockerfile.ubuntu-base", "context": "../.github", "args": { - "BASE": "mcr.microsoft.com/vscode/devcontainers/base:focal", + "BASE": "mcr.microsoft.com/devcontainers/base:noble", "USER": "vscode", "GROUP": "vscode" } From 259c573ee3365a1b75d332b0d503f9d73445be7e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonatan=20M=C3=A4nnchen?= Date: Fri, 5 Jun 2026 13:44:19 +0200 Subject: [PATCH 12/13] ci: drop Gitpod support Gitpod was sunset on 2025-10-15. Base the Ubuntu image on ubuntu:24.04 directly instead of gitpod/workspace-full, rename the leftover gitpod ARG defaults, and remove the now-unused .gitpod.yml and its documentation. --- .github/dockerfiles/Dockerfile.ubuntu-base | 6 ++--- .github/scripts/build-base-image.sh | 1 - .gitpod.yml | 27 ---------------------- HOWTO/DEVELOPMENT.md | 22 ++++++++---------- 4 files changed, 12 insertions(+), 44 deletions(-) delete mode 100644 .gitpod.yml diff --git a/.github/dockerfiles/Dockerfile.ubuntu-base b/.github/dockerfiles/Dockerfile.ubuntu-base index 0f2920aaeab3..295a412fd4ab 100644 --- a/.github/dockerfiles/Dockerfile.ubuntu-base +++ b/.github/dockerfiles/Dockerfile.ubuntu-base @@ -21,7 +21,7 @@ ## ## This docker file will build a base image for building Erlang/OTP ## -ARG BASE=gitpod/workspace-full +ARG BASE=ubuntu:24.04 FROM $BASE ENV INSTALL_LIBS="zlib1g-dev libncurses5-dev libssl-dev unixodbc-dev libsctp-dev lksctp-tools libgmp3-dev libwxgtk3.2-dev libwxgtk-webview3.2-dev" @@ -46,8 +46,8 @@ ENV MAKEFLAGS=$MAKEFLAGS \ ENV LANG=en_US.UTF-8 LC_ALL=en_US.UTF-8 -ARG USER=gitpod -ARG GROUP=gitpod +ARG USER=otptest +ARG GROUP=uucp ARG gid=10 ARG uid=421 diff --git a/.github/scripts/build-base-image.sh b/.github/scripts/build-base-image.sh index 4ea5af65467d..6f41814d23fe 100755 --- a/.github/scripts/build-base-image.sh +++ b/.github/scripts/build-base-image.sh @@ -92,7 +92,6 @@ else ${BASE_CACHE} \ --file ".github/dockerfiles/Dockerfile.${BASE_TYPE}" \ --build-arg MAKEFLAGS=-j6 \ - --build-arg USER=otptest --build-arg GROUP=uucp \ --build-arg uid="$(id -u)" \ --build-arg LATEST_ERLANG_VERSION="${LATEST_ERLANG_VERSION}" \ --build-arg BASE="${BASE}" \ diff --git a/.gitpod.yml b/.gitpod.yml deleted file mode 100644 index 8c78aae86c5e..000000000000 --- a/.gitpod.yml +++ /dev/null @@ -1,27 +0,0 @@ -## %CopyrightBegin% -## -## SPDX-License-Identifier: Apache-2.0 -## -## Copyright Ericsson AB 2021-2025. All Rights Reserved. -## -## Licensed under the Apache License, Version 2.0 (the "License"); -## you may not use this file except in compliance with the License. -## You may obtain a copy of the License at -## -## http://www.apache.org/licenses/LICENSE-2.0 -## -## Unless required by applicable law or agreed to in writing, software -## distributed under the License is distributed on an "AS IS" BASIS, -## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -## See the License for the specific language governing permissions and -## limitations under the License. -## -## %CopyrightEnd% - -image: - file: .github/dockerfiles/Dockerfile.ubuntu-base - context: .github -vscode: - extensions: - - ms-vscode.cpptools - - erlang-ls.erlang-ls diff --git a/HOWTO/DEVELOPMENT.md b/HOWTO/DEVELOPMENT.md index d17d8b7c08e8..11ce01be2f41 100644 --- a/HOWTO/DEVELOPMENT.md +++ b/HOWTO/DEVELOPMENT.md @@ -65,7 +65,7 @@ with. 7. [Github Actions](#github-actions) 1. [Debugging github actions failures](#debugging-github-actions-failures) 8. [Using Docker](#using-docker) - 1. [Gidpod.io or VSCode dev container](#gitpod-io-or-vscode-dev-container) + 1. [VSCode dev container](#vscode-dev-container) ## Short version @@ -554,8 +554,7 @@ you can do that like this: ```bash docker build -t ghcr.io/erlang/otp/ubuntu-base \ - --build-arg BASE=ubuntu:20.04 --build-arg USER=otptest --build-arg uid=$(id -u) \ - --build-arg GROUP=uucp --build-arg gid=$(id -g) \ + --build-arg uid=$(id -u) --build-arg gid=$(id -g) \ -f .github/dockerfiles/Dockerfile.ubuntu-base .github/ ``` @@ -577,24 +576,21 @@ docker run --init -v $PWD/make_test_dir:/buildroot/otp/lib/stdlib/make_test_dir The Common Test logs will be placed in `make_test_dir/ct_logs`. -### Gidpod.io or VSCode dev container +### VSCode dev container -This git repository is also prepared to run using [Gitpod](https://gitpod.io/) or +This git repository is also prepared to run using a [VSCode Devcontainer](https://code.visualstudio.com/docs/remote/containers). -The support for these environments is very early so it will be a bit unstable. - -To access the gitpod for Erlang/OTP you just navigate to -[https://gitpod.io/#https://github.com/erlang/otp](https://gitpod.io/#https://github.com/erlang/otp). +The support for this environment is very early so it will be a bit unstable. When using a VSCode dev container, you only need to open [VSCode](https://code.visualstudio.com/) in the Erlang/OTP repository and you should get a popup that asks if you want to run in a dev container. -The gitpod and dev container both use the base ubuntu image built in [Using Docker](#using-docker). -So it should be possible to run all tests inside the containers with all test +The dev container uses the base ubuntu image built in [Using Docker](#using-docker). +So it should be possible to run all tests inside the container with all test dependencies available. -*WARNING*: Using VSCode dev container on macOS can be very slow because of limitations -in the filesystem. So I would recommend either using gitpod or just work locally without +*WARNING*: Using a VSCode dev container on macOS can be very slow because of limitations +in the filesystem. So I would recommend just working locally without the dev container on macOS. From 9b984a9ec08ba770981c6d9432e9a55e3fc76aa7 Mon Sep 17 00:00:00 2001 From: Sverker Eriksson Date: Mon, 8 Jun 2026 17:26:21 +0200 Subject: [PATCH 13/13] fixup! erts: avoid array-bounds warning in eq() --- erts/emulator/beam/erl_term.h | 2 +- erts/emulator/beam/utils.c | 16 ++++++++++------ 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/erts/emulator/beam/erl_term.h b/erts/emulator/beam/erl_term.h index 8263706dc394..f731d740f30a 100644 --- a/erts/emulator/beam/erl_term.h +++ b/erts/emulator/beam/erl_term.h @@ -1154,7 +1154,7 @@ typedef struct external_thing_ { #endif } port; Uint32 ui32[2]; - Uint ui[1]; + Uint ui[sizeof(Uint64) / sizeof(Uint)]; } data; } ExternalThing; diff --git a/erts/emulator/beam/utils.c b/erts/emulator/beam/utils.c index 5579948a5074..709870fe8456 100644 --- a/erts/emulator/beam/utils.c +++ b/erts/emulator/beam/utils.c @@ -1279,6 +1279,7 @@ int eq(Eterm a, Eterm b) case EXTERNAL_PID_SUBTAG: { ExternalThing *ap; ExternalThing *bp; + int i; if(!is_external(b)) goto not_equal; @@ -1292,14 +1293,16 @@ int eq(Eterm a, Eterm b) ASSERT(external_data_words(a) == EXTERNAL_PID_DATA_WORDS); ASSERT(external_data_words(b) == EXTERNAL_PID_DATA_WORDS); - if (sys_memcmp(ap->data.ui, bp->data.ui, - EXTERNAL_PID_DATA_WORDS * sizeof(Uint)) != 0) - goto not_equal; + for (i = 0; i < EXTERNAL_PID_DATA_WORDS; i++) { + if (ap->data.ui[i] != bp->data.ui[i]) + goto not_equal; + } goto pop_next; } case EXTERNAL_PORT_SUBTAG: { ExternalThing *ap; ExternalThing *bp; + int i; if(!is_external(b)) goto not_equal; @@ -1313,9 +1316,10 @@ int eq(Eterm a, Eterm b) ASSERT(EXTERNAL_PORT_DATA_WORDS == external_data_words(a)); ASSERT(EXTERNAL_PORT_DATA_WORDS == external_data_words(b)); - if (sys_memcmp(ap->data.ui, bp->data.ui, - EXTERNAL_PORT_DATA_WORDS * sizeof(Uint)) != 0) - goto not_equal; + for (i = 0; i < EXTERNAL_PORT_DATA_WORDS; i++) { + if (ap->data.ui[i] != bp->data.ui[i]) + goto not_equal; + } goto pop_next; } case EXTERNAL_REF_SUBTAG: {