Build the QT environment on the Ubuntu platform in Arm

Source: Internet
Author: User
The first time I came into contact with QT, I found that everyone had different environmental problems. I wrote down my problems and steps for reference! 1. Select the environment. QT needs to install the Xwindows operating system. At first, I started to use CentOS without a graphical interface. I found that the installation was not successful, beginner! Later, I chose Ubuntu. The reason why I chose Ubuntu was that a norm and I said that this system has a comprehensive drive, so there is no shortage of such drivers. 2. I installed Ubuntu on a virtual machine. After installation, I need to use the root user. Otherwise, many

The first time I came into contact with QT, I found that everyone had different environmental problems. I wrote down my problems and steps for reference!

1. Select the environment. QT needs to install the Xwindows operating system. At first, I started to use CentOS without a graphical interface. I found that the installation was not successful, beginner!

Later, I chose Ubuntu. The reason why I chose Ubuntu was that a norm and I said that this system has a comprehensive drive, so there is no shortage of such drivers.

2. I have installed Ubuntu on a virtual machine. After installation, I need to use the root user. Otherwise, many functions, such as ssh and nfs, will be restricted when interacting with the outside. Change User sudo passwd root.

3. Start the ssd Service. To communicate with windows, sudo apt-get install openssh-server.

4. Download the QT qt-x11-opensource-src-4.5.3.tar.gz to unzip and add settings under etc/profile

QTDIR =/usr/local/qt

PATH = $ QTDIR/bin: $ PATH

MANPATH = $ QTDIR/man: $ MANPATH

LD_LIBRARY_PATH = $ QTDIR/lib: $ LD_LIBRARY_PATH

Export qtdir path manpath LD_LIBRARY_PATH

To make the environment variables take effect, you can also directly export these variables.

5. In the compressed directory,./configure -- prefix =/usr/local/qt, The make: g ++: Command not found error occurs.

6. install g ++, first choice. Make sure you have installed the build-essential Package: sudo apt-get install build-essential (installation process, that is, install g ++ ).

Check the gcc version, ls/usr/bin/gcc *

7. Run configure under qt and find Basic XLib functionality test failed! This error

Install the sudo apt-get install libX11-dev libXext-dev libXtst-dev

8. Open the simple program Helloworld

9. qmake-project; qmake; make;./hello. Note that the environment variable 4 must be correctly configured. Otherwise, Qapplication. h cannot be found.

10. Connect to arm. Here we use a Super Terminal to connect to com. When configuring parameters, we should select none for Data Stream Control at www.linuxidc.com. If we select hardware, we cannot enter control.

11. Compile the arm file. I use the qmake provided by the Board Sub-manufacturer, that is, arm-none-linux-gnueabi-g ++ and arm-none-linux-gnueabi-gcc.

Pay attention to the configured QT environment variables.

12. Super Terminal transmission. Small files adopt zcom transmission protocol and large files adopt nfs

Use nfs, arm machine as client, Ubuntu as server, apt-get install nfs-kernel-server

Run the netstat-tl command to check whether the nfs port is enabled.

Nfs, vi/etc/exports, nfs mounting,/usr/www/src 192.168.1. * (rw, sync, no_subtree_check, no_root_squash) must be configured for Ubuntu)

Restart the service:/etc/init. d/nfs-kernel-server restart

13. On the arm terminal, mount-t nfs-o nolock 192.168.1.112:/usr/www/src/mnt

14. ls/mnt will see their Ubuntu shared directory, copy the program compiled with arm configuration, run on the Super Terminal, need to run in the background.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.