大家好,我不知道我应该在哪里问这个问题。我从过去 1 周开始尝试这个。我正在尝试在基于 imx6 arm 的设备上使用 gstreamer 交叉编译 Qt 5.1.1 qtmultimedia。这是我的配置文件:
#!/bin/sh
./configure —prefix=/tools/rootfs/usr/local/qt-5.1.1 -examplesdir /tools/rootfs/usr/local/qt-5.1.1/examples -verbose -opensource -confirm-license -make libs -make examples -device imx6 \
-device-option CROSS_COMPILE=\
/opt/freescale/usr/local/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/fsl-linaro- toolchain/bin/arm-fsl-linux-gnueabi- \
-no-pch -no-opengl -no-icu -no-xcb -no-c++11 \
-opengl es2 \
-eglfs \
-compile-examples \
-glib -gstreamer \
这是我的 qmake.conf:
include(../common/linux_device_pre.conf) ROOTFS=/tools/rootfs EGLFS_PLATFORM_HOOKS_SOURCES = $$PWD/qeglfshooks_imx6.cpp
QMAKE_INCDIR += $$ROOTFS/usr/include \ $$ROOTFS/usr/include/glib-2.0 \
$$ROOTFS/usr/include/glib-2.0/gio \ $$ROOTFS/usr/include/glib-2.0/glib \
$$ROOTFS/usr/include/glib-2.0/gobject \ $$ROOTFS/usr/include/glib-2.0/include
$$ROOTFS/usr/include/gstreamer-0.10 \ $$ROOTFS/usr/include/libxml2
QMAKE_LIBDIR += $$ROOTFS/usr/lib
QMAKE_LIBS += -L/tools/rootfs/usr/lib -lgthread-2.0 -lgio-2.0 -lglib-2.0 - lgmodule-2.0 -lgobject-2.0 -lgstbase-0.10 -lgstcontroller-0.10 -lgstreamer-0.10
QMAKE_INCDIR_OPENGL_ES2+= $$ROOTFS/usr/include/GLES2
QMAKE_LIBDIR_OPENGL_ES2+= $$ROOTFS/usr/lib QMAKE_LIBS_EGL += -lEGL
QMAKE_LIBS_OPENGL_ES2 += -lGLESv2 -lEGL -lGAL
QMAKE_LIBS_OPENVG += -lOpenVG -lEGL -lGAL
QMAKE_LFLAGS += -Wl,-rpath-link,$$ROOTFS/usr/lib
IMX6_CFLAGS = -march=armv7-a -mfpu=neon -DLINUX=1 -DEGL_API_FB=1
IMX6_CFLAGS_RELEASE = -O2 $$IMX6_CFLAGS
QMAKE_CFLAGS_RELEASE += $$IMX6_CFLAGS_RELEASE
QMAKE_CXXFLAGS_RELEASE += $$IMX6_CFLAGS_RELEASE
QMAKE_CFLAGS_DEBUG += $$IMX6_CFLAG
QMAKE_CXXFLAGS_DEBUG += $$IMX6_CFLAGS include(../common/linux_device_post.conf) load(qt_config)
当我配置 gstreamer 时启用。但它不是在构建多媒体。我去了 qt-everywhere-opensource-src-5.1.1 并制作了模块 qtmultimedia。在 make install 之后,我尝试在设备上运行我的应用程序。它说: QtMultimedia : defaultServiceProvider::requestService(): no service found for – “org.qt-project.qt.mediaplayer”</p>
根据 qtmultimedia config.log 包 gstreamer-0.10 未找到。之后尝试构建它导出 PKG_CONFIG_PATH 仍然结果是相同的。谁能帮我解决这个错误!