Unable to install on systems using GCC 15, e.g. Fedora 42

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Fixed
    • Priority: Blocker - P1
    • bson-5.0.2
    • Affects Version/s: None
    • Component/s: BSON
    • None
    • Fully Compatible
    • Ruby Drivers
    • Not Needed
    • None
    • None
    • None
    • None
    • None
    • None

      Installation of bson on systems using GCC v15 is not possible.  See attached file:

      {{ gem_make.out}}

      A telltale signal of this issue is seeing this repeated, with small variations, many times in the output:

      error: unknown type name ‘bool’
        578 | static inline bool
      
      note: ‘bool’ is defined in header ‘<stdbool.h>’; this is probably fixable by adding ‘#include <stdbool.h>’ 

      This is likely related to an issue Nobu (Ruby's "patch monster") found:

      Anyway, -std=c99 flag is nonsense for other than gcc family.
      Use append_cflags instead of adding them blindly.

      This issue affected other gems as well, and solutions are known:

      1. io-event gem:
        1. Fixed one week ago. 
        2. bug report: https://github.com/socketry/io-event/issues/136
        3. bugfix patch (+6 / -6): https://github.com/socketry/io-event/pull/137/commits/d08576119ccd48900850b833fe853f39f3d604b7
      2.  ed25519 gem:
        1. Fixed two months ago.
        2. bug report: https://github.com/RubyCrypto/ed25519/issues/44
        3. bugfix patch (+1 / -1): https://github.com/RubyCrypto/ed25519/pull/45/files#diff-805cf1ea9824de19b94dce429b3a3544fd9cb0b3cc278e571776c7d672cc1dfa 
      3. jaro_winkler gem:
        1. Fixed 3 weeks ago.
        2. bug report: https://github.com/tonytonyjan/jaro_winkler/issues/61
        3. bugfix patch (+1 / -1):[ https://github.com/tonytonyjan/jaro_winkler/pull/62/files#diff-594397402316a8262174f2dc8159b5a35560516bd3cd355b1bf657a6e0a973ce|https://github.com/tonytonyjan/jaro_winkler/pull/62/files#diff-594397402316a8262174f2dc8159b5a35560516bd3cd355b1bf657a6e0a973ce]
      4. Further discussion on the Ruby Lang bug trackcer:
        1. https://bugs.ruby-lang.org/issues/21290
          #61

        1. gem_make.out
          34 kB
          Peter Boling

            Assignee:
            Unassigned
            Reporter:
            Peter Boling
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: