虚拟noexcept(真)错误:MinGW和gtkmm的 [英] virtual noexcept(true) errors: MinGW and gtkmm

查看:486
本文介绍了虚拟noexcept(真)错误:MinGW和gtkmm的的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经奋斗了一个月固体打造// //工作C ++ / gtkmm的-3.0在Windows上使用MinGW的应用程序。我终于设法得到库,MinGW的,而$ C $个cblocks相处的Windows XP(VirtualBox的)。但是,当我尝试建立,我收到以下错误。

I've been fighting for a month solid to build a //working// C++/gtkmm-3.0 application on Windows with MinGW. I finally managed to get the libraries, MinGW, and Codeblocks to get along on Windows XP (VirtualBox). However, when I try to build, I get the following errors.

这是最近期的gtkmm-3.0和依赖的版本。我通过MSYS2得到了他们,虽然我不能在原因尚未知晓的环境建设。因此,正如经常推荐的,我复制他们到MinGW的 / lib目录 /包括目录,并确保 pkg配置能找到他们。所有井有(可能)。

These are the most recent versions of gtkmm-3.0 and dependencies. I got them via MSYS2, though I cannot build in that environment for reasons yet unknown. So, as is oft recommended, I copied them over to the MinGW /lib and /include directories, and ensured pkg-config could find them. All's well there (allegedly).

这些问题不从我的code发起,效果显着。我没有写或修改gtkmm的。然而,我不能让这些离开。

These problems are not originating from my code, obviously. I didn't write or modify gtkmm. Yet, I can't get these to go away.

值得一提的是,我最后一次收到有关错误无法找到油腔滑调:: ustring :: ustring,它决定停止抱怨说,给我这些出蓝色来代替。如果前面的消息不断显示出来再说,我会在这里发帖。

It is worth mentioning that I was last getting errors relating to "cannot find glib::ustring::ustring", and it decided to stop whining about that and give me these out of the blue instead. If the earlier messages ever show up again, I'll post them here.

我开始认为这是不值得在所有发布在Windows上此软件。

I'm beginning to think it isn't worth releasing this software on Windows at all.

注意:我收到了其中50,所有的gtkmm-3.0及其依赖库,全部由1号线或2主,以及所有具有完全相同的细节始发。我会告诉只有少数在太空的兴趣。

NOTE: I am getting over 50 of these, all in gtkmm-3.0 and its dependency libraries, all originating from line 1 or 2 of main, and all with the exact same details. I'll show only a few in interest of space.

-------------- Build: Debug in infiltrator (compiler: GNU GCC Compiler)---------------

mingw32-g++.exe -std=c++11 -Wall -mms-bitfields -pthread -IC:/dev/MinGW/include/glibmm-2.4 -IC:/dev/MinGW/lib/glibmm-2.4/include -IC:/dev/MinGW/include/sigc++-2.0 -IC:/dev/MinGW/lib/sigc++-2.0/include -IC:/dev/MinGW/include/glib-2.0 -IC:/dev/MinGW/lib/glib-2.0/include -IC:/dev/MinGW/include/gtkmm-3.0 -IC:/dev/MinGW/lib/gtkmm-3.0/include -IC:/dev/MinGW/include/atkmm-1.6 -IC:/dev/MinGW/include/giomm-2.4 -IC:/dev/MinGW/lib/giomm-2.4/include -IC:/dev/MinGW/include/pangomm-1.4 -IC:/dev/MinGW/lib/pangomm-1.4/include -IC:/dev/MinGW/include/gtk-3.0 -IC:/dev/MinGW/include/cairomm-1.0 -IC:/dev/MinGW/lib/cairomm-1.0/include -IC:/dev/MinGW/include/gdk-pixbuf-2.0 -IC:/dev/MinGW/include/gdkmm-3.0 -IC:/dev/MinGW/lib/gdkmm-3.0/include -IC:/dev/MinGW/include/atk-1.0 -IC:/dev/MinGW/include/pango-1.0 -IC:/dev/MinGW/include/cairo -IC:/dev/MinGW/include/pixman-1 -IC:/dev/MinGW/include -I/mingw32/include/freetype2 -I/mingw32/include/libpng16 -I/mingw32/include/harfbuzz -I/mingw32/include/glib-2.0 -I/mingw32/lib/glib-2.0/include -I/mingw32/include -IC:/dev/MinGW/include/freetype2 -IC:/dev/MinGW/include/libpng16 -IC:/dev/MinGW/include/harfbuzz -Wl,-luuid -LC:/dev/MinGW/lib -lgtkmm-3.0 -latkmm-1.6 -lgdkmm-3.0 -lgiomm-2.4 -lpangomm-1.4 -lgtk-3 -lglibmm-2.4 -lcairomm-1.0 -lgdk-3 -lgdi32 -limm32 -lshell32 -lole32 -lwinmm -lz -latk-1.0 -lgio-2.0 -lpangowin32-1.0 -lpangocairo-1.0 -lgdk_pixbuf-2.0 -lcairo-gobject -lpango-1.0 -lcairo -lsigc-2.0 -lgobject-2.0 -lglib-2.0 -lintl -std=c++11 -Wall -g -mms-bitfields -pthread -IC:/dev/MinGW/include/glibmm-2.4 -IC:/dev/MinGW/lib/glibmm-2.4/include -IC:/dev/MinGW/include/sigc++-2.0 -IC:/dev/MinGW/lib/sigc++-2.0/include -IC:/dev/MinGW/include/glib-2.0 -IC:/dev/MinGW/lib/glib-2.0/include -IC:/dev/MinGW/include/gtkmm-3.0 -IC:/dev/MinGW/lib/gtkmm-3.0/include -IC:/dev/MinGW/include/atkmm-1.6 -IC:/dev/MinGW/include/giomm-2.4 -IC:/dev/MinGW/lib/giomm-2.4/include -IC:/dev/MinGW/include/pangomm-1.4 -IC:/dev/MinGW/lib/pangomm-1.4/include -IC:/dev/MinGW/include/gtk-3.0 -IC:/dev/MinGW/include/cairomm-1.0 -IC:/dev/MinGW/lib/cairomm-1.0/include -IC:/dev/MinGW/include/gdk-pixbuf-2.0 -IC:/dev/MinGW/include/gdkmm-3.0 -IC:/dev/MinGW/lib/gdkmm-3.0/include -IC:/dev/MinGW/include/atk-1.0 -IC:/dev/MinGW/include/pango-1.0 -IC:/dev/MinGW/include/cairo -IC:/dev/MinGW/include/pixman-1 -IC:/dev/MinGW/include -I/mingw32/include/freetype2 -I/mingw32/include/libpng16 -I/mingw32/include/harfbuzz -I/mingw32/include/glib-2.0 -I/mingw32/lib/glib-2.0/include -I/mingw32/include -IC:/dev/MinGW/include/freetype2 -IC:/dev/MinGW/include/libpng16 -IC:/dev/MinGW/include/harfbuzz -Wl,-luuid -LC:/dev/MinGW/lib -lgtkmm-3.0 -latkmm-1.6 -lgdkmm-3.0 -lgiomm-2.4 -lpangomm-1.4 -lgtk-3 -lglibmm-2.4 -lcairomm-1.0 -lgdk-3 -lgdi32 -limm32 -lshell32 -lole32 -lwinmm -lz -latk-1.0 -lgio-2.0 -lpangowin32-1.0 -lpangocairo-1.0 -lgdk_pixbuf-2.0 -lcairo-gobject -lpango-1.0 -lcairo -lsigc-2.0 -lgobject-2.0 -lglib-2.0 -lintl -std=c++11 -mms-bitfields -pthread -IC:/dev/MinGW/include/glibmm-2.4 -IC:/dev/MinGW/lib/glibmm-2.4/include -IC:/dev/MinGW/include/sigc++-2.0 -IC:/dev/MinGW/lib/sigc++-2.0/include -IC:/dev/MinGW/include/glib-2.0 -IC:/dev/MinGW/lib/glib-2.0/include -IC:/dev/MinGW/include/gtkmm-3.0 -IC:/dev/MinGW/lib/gtkmm-3.0/include -IC:/dev/MinGW/include/atkmm-1.6 -IC:/dev/MinGW/include/giomm-2.4 -IC:/dev/MinGW/lib/giomm-2.4/include -IC:/dev/MinGW/include/pangomm-1.4 -IC:/dev/MinGW/lib/pangomm-1.4/include -IC:/dev/MinGW/include/gtk-3.0 -IC:/dev/MinGW/include/cairomm-1.0 -IC:/dev/MinGW/lib/cairomm-1.0/include -IC:/dev/MinGW/include/gdk-pixbuf-2.0 -IC:/dev/MinGW/include/gdkmm-3.0 -IC:/dev/MinGW/lib/gdkmm-3.0/include -IC:/dev/MinGW/include/atk-1.0 -IC:/dev/MinGW/include/pango-1.0 -IC:/dev/MinGW/include/cairo -IC:/dev/MinGW/include/pixman-1 -IC:/dev/MinGW/include -I/mingw32/include/freetype2 -I/mingw32/include/libpng16 -I/mingw32/include/harfbuzz -I/mingw32/include/glib-2.0 -I/mingw32/lib/glib-2.0/include -I/mingw32/include -IC:/dev/MinGW/include/freetype2 -IC:/dev/MinGW/include/libpng16 -IC:/dev/MinGW/include/harfbuzz -Iinclude -IC:\dev\MinGW\include -c "C:\Documents and Settings\Jason\Desktop\infiltrator\main.cpp" -o obj\Debug\main.o
In file included from C:/dev/MinGW/include/pangomm-1.4/pangomm/fontset.h:33:0,
                 from C:/dev/MinGW/include/pangomm-1.4/pangomm/context.h:37,
                 from C:/dev/MinGW/include/gtkmm-3.0/gtkmm/widget.h:32,
                 from C:/dev/MinGW/include/gtkmm-3.0/gtkmm/actiongroup.h:29,
                 from C:/dev/MinGW/include/gtkmm-3.0/gtkmm/application.h:32,
                 from C:\Documents and Settings\Jason\Desktop\infiltrator\main.cpp:2:
C:/dev/MinGW/include/pangomm-1.4/pangomm/font.h:98:11: error: looser throw specifier for 'virtual Pango::Font::~Font()'
In file included from C:/dev/MinGW/include/glibmm-2.4/glibmm/binding.h:23:0,
                 from C:/dev/MinGW/include/glibmm-2.4/glibmm.h:96,
                 from C:\Documents and Settings\Jason\Desktop\infiltrator\main.cpp:1:
C:/dev/MinGW/include/glibmm-2.4/glibmm/object.h:117:11: error:   overriding 'virtual Glib::Object::~Object() noexcept (true)'
In file included from C:/dev/MinGW/include/pangomm-1.4/pangomm/context.h:37:0,
                 from C:/dev/MinGW/include/gtkmm-3.0/gtkmm/widget.h:32,
                 from C:/dev/MinGW/include/gtkmm-3.0/gtkmm/actiongroup.h:29,
                 from C:/dev/MinGW/include/gtkmm-3.0/gtkmm/application.h:32,
                 from C:\Documents and Settings\Jason\Desktop\infiltrator\main.cpp:2:
C:/dev/MinGW/include/pangomm-1.4/pangomm/fontset.h:81:11: error: looser throw specifier for 'virtual Pango::Fontset::~Fontset()'
In file included from C:/dev/MinGW/include/glibmm-2.4/glibmm/binding.h:23:0,
                 from C:/dev/MinGW/include/glibmm-2.4/glibmm.h:96,
                 from C:\Documents and Settings\Jason\Desktop\infiltrator\main.cpp:1:
C:/dev/MinGW/include/glibmm-2.4/glibmm/object.h:117:11: error:   overriding 'virtual Glib::Object::~Object() noexcept (true)'
In file included from C:/dev/MinGW/include/pangomm-1.4/pangomm/fontfamily.h:34:0,
                 from C:/dev/MinGW/include/pangomm-1.4/pangomm/fontmap.h:36,
                 from C:/dev/MinGW/include/pangomm-1.4/pangomm/context.h:38,
                 from C:/dev/MinGW/include/gtkmm-3.0/gtkmm/widget.h:32,
                 from C:/dev/MinGW/include/gtkmm-3.0/gtkmm/actiongroup.h:29,
                 from C:/dev/MinGW/include/gtkmm-3.0/gtkmm/application.h:32,
                 from C:\Documents and Settings\Jason\Desktop\infiltrator\main.cpp:2:
C:/dev/MinGW/include/pangomm-1.4/pangomm/fontface.h:81:11: error: looser throw specifier for 'virtual Pango::FontFace::~FontFace()'
In file included from C:/dev/MinGW/include/gtkmm-3.0/gtkmm/widget.h:41:0,
                 from C:/dev/MinGW/include/gtkmm-3.0/gtkmm/actiongroup.h:29,
                 from C:/dev/MinGW/include/gtkmm-3.0/gtkmm/application.h:32,
                 from C:\Documents and Settings\Jason\Desktop\infiltrator\main.cpp:2:
C:/dev/MinGW/include/gtkmm-3.0/gtkmm/buildable.h:107:11: error: looser throw specifier for 'virtual Gtk::Buildable::~Buildable()'
Process terminated with status 1 (0 minute(s), 6 second(s))
50 error(s), 0 warning(s) (0 minute(s), 6 second(s))

此类型的错误消息似乎与其他稳定弹出,工作项目和库正在兴建的Windows,除了gtkmm的。

This type of error message seems to pop up with other stable, working projects and library being built on Windows, aside from gtkmm.

我最好的猜测是我忘了一些编译器标志,设置,或在构建过程中的其他鲜艳的超炫明显的阶梯。我会赶紧提醒我在$ C $个cblocks(13.14)的读者,所以我没写构建命令自己。

My best guess is that I forgot some compiler flag, setting, or other bright-blazingly obvious step in the build process. I will hasten to remind the reader that I am on CodeBlocks (13.14), so I didn't write that build command myself.

请求信息
的mingw32-G ++。exe文件--version

的mingw32-G ++。exe文件(TDM-1)4.7.1

mingw32-g++.exe (tdm-1) 4.7.1

这是一个带着$ C $的cblock捆绑版本13.14。

This is the version that came bundled with CodeBlocks 13.14.

...

我赶紧提醒大家,我没有写的gtkmm或其依赖的任何一个方面,这是所有这些错误都起源。此外,这是一个完全稳定的版本,而不是一个测试版或开发快照。其次,此相同code正与我的Linux版本库完全相同的版本。

I will hasten to remind everyone that I didn't write any aspect of gtkmm or its dependencies, which is where all of these errors are originating. Also, this is a fully stable version, NOT a beta or development snapshot. Second, this exact same code is working with the exact same versions of the library on my Linux build.

这是说,这里是code的完整的生产线从所要求的位置。

That said, here are the complete lines of code from the requested locations.

C:/dev/MinGW/include/glibmm-2.4/glibmm/object.h,行117

C:/dev/MinGW/include/glibmm-2.4/glibmm/object.h, line 117

虚拟〜对象()noexcept; //它应该只由回调被删除。

C:/dev/MinGW/include/pangomm-1.4/pangomm/font.h,第98行

C:/dev/MinGW/include/pangomm-1.4/pangomm/font.h, line 98

虚拟〜字体();

推荐答案

您的g ++版本太旧这个code:4.7.x有一个不成熟的方式
与明确的和隐含的异常规范的和解
继承的成员函数,如在虚拟之间的这种情况下,间
析构函数的油嘴::对象的攀高::字体

Your g++ version is too old for this code: 4.7.x had a half-baked way with the reconciliation of explicit and implied exception specifications between inherited member functions, as in this case between the virtual destructor of Glib::Object and that of Pango::Font.

您需要至少升级到4.8.1 GCC - 这恰好是
最新的稳定版本的MinGW的。你可以得到涌上最新
TDM GCC的Windows移植。最新
有5.1

You need to upgrade to at least GCC 4.8.1 - which happens to be the latest stable version from MinGW. You can get well up-to-date Windows port of GCC from TDM. Latest there is 5.1

P.S。我有点怀疑,你是否有
建立的 glibmm-2.4 pangomm-1.4 这是真正同步。我有
这些包按我的Linux发行版(Ubuntu的15.04)两种官方和标本问题的声明,我询问的行号的来源是你的不同和他们都不具有 noexcept 规范,无疑避免了障碍。

P.S. I am a little suspicious as to whether you have builds of glibmm-2.4 and pangomm-1.4 that are really in sync. I have the sources of these packages both official per my linux distro (Ubuntu 15.04), and the line numbers of the specimen problem declarations that I enquired about are different from yours and neither of them has a noexcept specification which certainly avoids the snag.

这篇关于虚拟noexcept(真)错误:MinGW和gtkmm的的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆