Skip to content
Commit d6d7cb2b authored by Mike Fleetwood's avatar Mike Fleetwood Committed by Curtis Gedak
Browse files

Enable C++11 compilation when using glibmm 2.45.40 and later (#756035)

Glibmm 2.45.40 and later uses features in the ISO C++ 2011 standard.
The NEWS file [1] says:

    Changes in 2.46 compared to 2.44:

    General:
    * Use, and require C++11, using features such as move operations,
      noexcept auto, = delete, nulltpr, override.
      (Murray Cumming, Kjell Ahlstedt)

Also found this by Murray Cumming [2]:

    glibmm 2.45.40 requires C++11, both for its own build and by any
    apps that use it.  gtkmm also now requires C++11.

    I think you are seeing a symptom of building the application without
    C++11 support.  For instance, using CXXFLAGS="--std=c++11", though
    you'd be better of using an m4 macro such as
    AX_CXX_COMPILE_STDCXX_11().

Without enabling C++11 compiler features, compilation of GParted with
the latest glibmm library fails with errors such as these:

    /usr/include/glibmm-2.4/glibmm/ustring.h:267:14: error: expected ';' at end of member declaration
       ~ustring() noexcept;
                ^
    /usr/include/glibmm-2.4/glibmm/ustring.h:267:14: error: 'noexcept' does not name a type
       ~ustring() noexcept;
                  ^
    /usr/include/glibmm-2.4/glibmm/ustring.h:267:14: note: C++11 'noexcept' only available with -std=c++11 or -std=gnu++11

[1] glibmm NEWS file
    https://git.gnome.org/browse/glibmm/tree/NEWS?id=934e8290ce913b12e251ea617d0fc8ac53c385c6

[2] https://bugs.launchpad.net/ubuntu/+source/glibmm2.4/+bug/1478367

Bug 756035 - GParted does not compile with newer gtkmm libraries in
             Fedora 23
parent f97cac9a
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment