To run the media player example in QT we require cross-compile Gstreamer as back-end
cross compiling gstreamer was made comparatively easy for me,thanks to Mr. Felipe Contreras blog.This is the link to his blog.
For my board mini2440 I cross compiled the following source and installed in "/opt/gst" in my root filesystem.
- glib
- gstreamer
- liboil
- gst-plugin-base
- gst-plugin-good
- gst-plugin-ugly
Now you cross compile QT4.6 with phonon enabled,and linking the gstreamer library.
export PKG_CONFIG_PATH=/opt/gst/lib/pkgconfig
./configure -prefix /opt/qt-4.6/build -debug -shared -fast -pch -no-qt3support -qt-sql-sqlite -no-libtiff -no-libmng -qt-libjpeg -qt-zlib -qt-libpng -qt-freetype -no-openssl -nomake examples -nomake demos -nomake tools -optimized-qmake -no-nis -no-opengl -no-cups -no-xcursor -no-xfixes -no-xrandr -no-xrender -no-xkb -no-feature-CURSOR -no-sm -no-xinerama -no-xshape -webkit -no-separate-debug-info -xplatform qws/linux-arm-g++ -embedded arm -depths 16 -no-qvfb -qt-gfx-linuxfb -no-gfx-qvfb -no-kbd-qvfb -no-mouse-qvfb -qt-kbd-tty -confirm-license -qt-mouse-tslib -phonon -I /opt/gst/lib/glib-2.0/include -I /opt/gst/include/glib-2.0 -I /opt/gst/include/gstreamer-0.10/gst -L /opt/gst/lib -L /opt/gst/lib/gstreamer-0.10 -force-pkg-config -v
After doing 'make install' the libraries are installed on '/opt/qt-4.6/build'
create '/opt/qt-4.6/build' in mini2440 filesystem copy QT related libraries.
create '/opt/gst/lib' in mini2440 copy the contents of the '/opt/gst/lib' on PC to mini2440 filesystem's '/opt/gst/lib'
once this is done cross compile the QT MediaPlayer example in QT Source tree, and copy it on the board and run it.
please don't forget to update the 'LD_LIBRARY_PATH' in the environment variable.
export LD_LIBRARY_PATH=$QTDIR/lib:/opt/gst/lib
Please see my previous blog on crosscompiling QT for mini2440 board for details.
Hello,
ReplyDeletePlease tell me the full procedure to install qt-media player lib.
I have done Qt 4.6.3 cross compilation and its works properly