v2024dev2 is based on bookworm and bookworm dropped gcc-10. We know use gcc-12 and must give gcc more flags to avoid errors.
This reverts fce0ce56 and 9d0655c8