First, the preparatory work:
1. QT Application
2, tool chain---"Cross-tool chain installation, there will be a standard C library
3. Extended third-party library (ARM) () Touch screen Library (tslib.tar.gz)
4. QT Library
Second, compile TS Library and Qt Library using cross tool chain (default is compiled here)
Tslib-1.4.tar.gz
Qt-everywhere-opensource-src-5.5.0.tar.gz
Third, put the compiled library into the Development Board
1. Put the contents of Tslib into/tslib (you can throw the whole tslib directory in)
2. Place the Include,plugins directory in the qt-5.5.0-gec2015.11 directory in the/opt/qt-5.5.0-gec2015.11 directory
Iv. cross-compiling QT applications
1. Configure the QT integrated development environment
A, increase compiler tools-option-build&run
B. Increase QT version
C, add kits (bind compilation qmake and arm-linux-g++)
D. Add Kits
V. Setting environment variables in the Development Board (you can comment out similar environment variables that you have previously)
Export Tslib_tsdevice=/dev/event0 1
Export Tslib_fbdevice=/dev/fb0 1
Export tslib_conffile=/tslib/etc/ts.conf 1
Export Tslib_consoledevice=none 1
Export Tslib_calibfile=/etc/pointercal 1
Export Tslib_plugindir=/tslib/lib/ts 1
Export Path=/tslib/bin: $PATH 1
Export Ld_library_path=/tslib/lib:/lib:/usr/lib: $LD _library_path 1
--------------------------------------------
Export qthome=/opt/qt-5.5.0-gec2015.11
Export Qt_qpa_platform_plugin_path=qthome/plugins
Export qt_qpa_platform=linuxfb:tty=/dev/fb0
Export qt_qpa_fontdir= $QTHOME/lib/fonts
Export Qt_qpa_generic_plugins=tslib: $TSLIB _tsdevice
Export ld_preload=/tslib/lib/libts.so
Export ld_library_path= $QTHOME/lib: $LD _library_path
Export path= $QTHOME/lib: $PATH
Six, download the compiled QT application to the Development Board to run
./hello
QT porting to the Development Board