首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >gst-plugins-good构建失败并出现错误:‘GLsync’尚未声明

gst-plugins-good构建失败并出现错误:‘GLsync’尚未声明
EN

Stack Overflow用户
提问于 2019-12-15 17:16:57
回答 1查看 141关注 0票数 0

当我在另一台ARM机器上为Raspberry Pi构建gst-plugins-good==1.16.2时,Qt插件构建失败。

我成功地构建了gstreamer==1.16.2gst-plugins-base==1.16.2qtbase==5.13.2,但它们似乎与gst-plugins-good==1.16.2不兼容

代码语言:javascript
复制
In file included from gstqtgl.h:32:0,
                 from qtwindow.h:27,
                 from moc_qtwindow.cc:10:
/build/snaps/full/stage/include/gstreamer-1.0/gst/gl/gstglfuncs.h:93:17: error: expected identifier before ‘*’ token
   ret (GSTGLAPI *name) args;
                 ^
/build/snaps/full/stage/include/gstreamer-1.0/gst/gl/glprototypes/sync.h:27:1: note: in expansion of macro ‘GST_GL_EXT_FUNCTION’
 GST_GL_EXT_FUNCTION (GLsync, FenceSync,
 ^
/build/snaps/full/stage/include/gstreamer-1.0/gst/gl/glprototypes/sync.h:29:39: error: ISO C++ forbids declaration of ‘GLsync’ with no type [-fpermissive]
                       GLbitfield flags))
                                       ^
/build/snaps/full/stage/include/gstreamer-1.0/gst/gl/gstglfuncs.h:93:24: note: in definition of macro ‘GST_GL_EXT_FUNCTION’
   ret (GSTGLAPI *name) args;
                        ^
/build/snaps/full/stage/include/gstreamer-1.0/gst/gl/glprototypes/sync.h:29:39: error: ‘GLsync’ declared as function returning a function
                       GLbitfield flags))
                                       ^
/build/snaps/full/stage/include/gstreamer-1.0/gst/gl/gstglfuncs.h:93:24: note: in definition of macro ‘GST_GL_EXT_FUNCTION’
   ret (GSTGLAPI *name) args;
                        ^
/build/snaps/full/stage/include/gstreamer-1.0/gst/gl/glprototypes/sync.h:31:23: error: ‘GLsync’ has not been declared
                      (GLsync sync))
                       ^
/build/snaps/full/stage/include/gstreamer-1.0/gst/gl/gstglfuncs.h:93:24: note: in definition of macro ‘GST_GL_EXT_FUNCTION’
   ret (GSTGLAPI *name) args;
                        ^
/build/snaps/full/stage/include/gstreamer-1.0/gst/gl/glprototypes/sync.h:33:23: error: ‘GLsync’ has not been declared
                      (GLsync sync))
                       ^
/build/snaps/full/stage/include/gstreamer-1.0/gst/gl/gstglfuncs.h:93:24: note: in definition of macro ‘GST_GL_EXT_FUNCTION’
   ret (GSTGLAPI *name) args;
                        ^
/build/snaps/full/stage/include/gstreamer-1.0/gst/gl/glprototypes/sync.h:35:23: error: ‘GLsync’ has not been declared
                      (GLsync sync,
                       ^
/build/snaps/full/stage/include/gstreamer-1.0/gst/gl/gstglfuncs.h:93:24: note: in definition of macro ‘GST_GL_EXT_FUNCTION’
   ret (GSTGLAPI *name) args;
                        ^
/build/snaps/full/stage/include/gstreamer-1.0/gst/gl/glprototypes/sync.h:39:23: error: ‘GLsync’ has not been declared
                      (GLsync sync,
                       ^
/build/snaps/full/stage/include/gstreamer-1.0/gst/gl/gstglfuncs.h:93:24: note: in definition of macro ‘GST_GL_EXT_FUNCTION’
   ret (GSTGLAPI *name) args;
                        ^
/build/snaps/full/stage/include/gstreamer-1.0/gst/gl/glprototypes/sync.h:43:23: error: ‘GLsync’ has not been declared
                      (GLsync sync,
                       ^
/build/snaps/full/stage/include/gstreamer-1.0/gst/gl/gstglfuncs.h:93:24: note: in definition of macro ‘GST_GL_EXT_FUNCTION’
   ret (GSTGLAPI *name) args;
                        ^
Makefile:881: recipe for target 'libgstqmlgl_la-moc_gstqsgtexture.lo' failed

我在https://bugzilla.gnome.org/show_bug.cgi?id=796879中看到了一个非常类似的问题,但在我的代码中,他们想要删除的行已经丢失了。

相反,我从ext/qt/gstqtgl.h中删除了#define GST_GL_HAVE_GLSYNC 1,编译成功。

但是该行上面的注释说它应该使用Qt的GLsync定义,这样我的“修复”看起来就不正确了。

我仍然在努力为这个问题找到一个合适的解决方案。

EN

回答 1

Stack Overflow用户

发布于 2019-12-16 18:56:41

我发现,当你在Raspberry Pi设备上使用补丁时,它不会破坏任何东西。

代码语言:javascript
复制
diff -Naur ./src/ext/qt/gstqtgl.h ./src2/ext/qt/gstqtgl.h
--- ./ext/qt/gstqtgl.h      2019-04-19 09:16:25.000000000 +0000
+++ ./ext/qt/gstqtgl.h      2019-12-15 09:22:22.503065057 +0000
@@ -28,7 +28,6 @@
  * that we don't typedef GLsync in gstglfuncs.h */
 #include <gst/gl/gstglconfig.h>
 #undef GST_GL_HAVE_GLSYNC
-#define GST_GL_HAVE_GLSYNC 1
 #include <gst/gl/gstglfuncs.h>

 /* The glext.h guard was renamed in 2018, but some software which

我希望这对有麻烦的人有帮助。

如果有什么问题,我会更新这篇文章。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/59342567

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档