Embedded 4412 development board QT5.7 compiled and installed to arm

Publisher:小星星龙猫Latest update time:2022-02-03 Source: eefocusKeywords:Embedded Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

Platform: iTOP-4412 Elite Edition + 4.3-inch screen

I have the habit of writing articles when I learn something. After all, they are all for beginners. Here I record the installation process. Although it may not be used in the short term, it can be used as a reference when it is used in the future.
******************************** Gorgeous dividing line *****************************
1. Download all the latest source codes from the Internet
Ubuntu16.0 amd64 version The first one, no need for the source code, just install it directly
QT5.7.0, the omnipotent Baidu can find it (official website download), pay attention to download the source code, the source code of the linux version. ARM-NONE-LINUX-GNUEABI-GCC4.8, arm-*** will be written like this in the future. The name is too long. You can choose the source code or the compiled one. There is a blog (http://blog.csdn.net/ee230/article/details/41513957) that collects all the compiler versions from 08 to 14. If you download from the official website, it is more difficult and you have to register something. (If anyone is interested in downloading 15 and 16, please send me a copy). Big companies are just pretending to be cool. Registration is so difficult.
2. There is nothing to say about the installation of Ubuntu 16. The virtual machine is the next step
. 3. The system is installed, install the auxiliary software. Wine 1.9, this installation process seems to have some special issues that need to be paid attention to. For the installation of ssh, just apt-get directly. In fact, foreign servers are not very slow. I did not change the server. The download speed of 500~600kbps is still acceptable. ATTENTION: The latest version of ssh does not support the old version of encryption protocol, resulting in client connection problems. This is when Baidu comes in handy. The problem is easy to solve, so I won't write about it. Just search and follow the steps. After installing Wine, install source insight, notepad++, and you can install QQ if you want. Change the font library, otherwise it won't work. Basically, all operations will be performed under Linux.
4. Installation of the compiler. Two compilers need to be installed here (if you don't want to cause trouble in the future), arm-***q09 and arm-***q14 (hereinafter referred to as q09 and q14). The reason for installing the first compiler is to compile the kernel (of course you can also use q14. During this period, you need to be extremely careful and patient in debugging. It took me two days to compile it. The new version of the compiler has a big change in the compilation method of inline functions, so you have to debug it bit by bit. Of course, if you have any questions, you can communicate more~~). The compiler does not need to be reinstalled. The installation process is also relatively simple. Just unzip it to the opt directory and configure the environment (since qt is about to be compiled, comment the q09 environment here and add the q14 environment). After the installation is complete, open the console, enter arm and double-click tab to see if anything magical happens (if a lot of commands starting with arm appear, it means you have succeeded).

5. Compilation of tslib
The process of compiling tslib was extremely tortuous. This should have been the easiest plug-in to compile, but because the version was too old, it stopped updating in 2009. Its open function did not add the third parameter when using O_CREAT. The arm-none compiler after 2009 required that the file opened by O_CREAT must have the third parameter. I was exhausted from changing it over and over again. Then I was surprised to find that the Taoist priest had already compiled it in the 4412 CD. (4412 CD iTOP-4412 Elite Edition CD Material 8_Source Code_QtE and qtopia2.2.0 file system patch), I copied it directly and used it. However, it was a version problem again. It was not well compatible with qt5.7.0. Moreover, there was no source code, so I couldn’t debug it at all, and it failed. What to do? I continued to search on Baidu. Finally, I found a great guy who compiled ts under qt5.5. He provided a perfect source code, which was not changed at all. The q2014 compiler compiled it directly. The source code is not difficult for everyone. I directly put it in a compressed package and sent it to everyone. Take a look at my compilation process (it took me a whole afternoon to work on it)

 


I love tslib so much that I have to save it.
I still use the script that everyone loves to write the compilation process, which is very comfortable:
Create a new file vim configTslib14.sh in the Tslib folder
Content:
#!/bin/sh

make clean && make distclean
echo "ac_cv_func_malloc_0_nonnull=yes" >arm-linux.cache
CC=/usr/local/arm-2014.05/bin/arm-none-linux-gnueabi-gcc ./configure --host=arm-linux --prefix=/opt/tslib1.4 --cache-file=arm-linux.cache
make && make install

Run ./configTslib14.sh
to compile and install. Actually, I compiled qt first, copied tslib to the qt directory, and compiled the module, but it failed (I haven't found the reason yet. You can try to compile qt5.7 first, and then compile tslib). In this case, repackage and compile it directly into qt. So this place can save everyone's time. I actually compiled qt5.7 successfully for two hours, but found that the tslib module compilation failed and returned to repackage and compile. So the order of this tutorial is to compile tslib first. I also hope that everyone is interested in studying module compilation, so that you can add or remove modules in qt5.7 at will, because the biggest feature of qt5.7 is modularization, which is very convenient, but I didn't use it. Continue the tutorial~

6. Qt compilation.
I will recompile Qt here and save some screenshots for you. Because the useless modules were not deleted in the first compilation, a 140MB library was compiled. It has everything, including mouse, keyboard, NFC, etc. Qt5.7 also comes with a purchasing module, yes, a purchasing module, a bit like Apple Pay, we don't want all of these, so I recompile it. The process can be screenshotted. Note that Qt5.7 must have the q2014 compiler, because the qt5.7 source code is written in stdc++11 version (the new c++ rules released in 2011, how can you compile it with q2009, I made the same mistake for a long time), and start the operation.
1. Unzip the source code. I don't have a good habit of leaving the source code on the desktop. I'm used to operating with the graphical interface and the console. If you tar the folder under the console as the root user, the folder belongs to the root, and the user of the graphical interface cannot modify the files in it (of course you can chmod 777, but it's still very troublesome). So, simply leave the console aside, right-click the source code compression package, directly extract here to unzip it
and leave the compression package for later use. Here you can see that there is a small lock next to the console tar folder, and ordinary users can only read it but not change it.

 

 

 

 

 

 


Ctrl+alt+t to open the console, vim modify the qt-everywhere-opensource-src-5.7.0/qtbase/mkspecs/linux-arm-gnueabi-g++/qmake.conf file, start adding these three sentences to tell Qmake our platform. The explanations of these scripts are all on the official website. If you are interested, go and have a look

 

 

 


/************************************NEW addition***************************/
QT_QPA_DEFAULT_PLATFORM = linux #eglfs
QMAKE_CFLAGS_RELEASE += -O2 -march=armv7-a
QMAKE_CXXFLAGS_RELEASE += -O2 -march=armv7-a

 

Add none to the compiler name. Of course, you can use a friendly compiler or an elf compiler. Modify it according to the name and save.

In the qt-everywhere-opensource-src-5.3.0/directory, create an autoconfig.sh file for easy configuration (right-click the folder to create a new one, then double-click to open it). The content is:
#!/bin/sh
./configure
-v
-prefix /opt/qt5.7.0
-release
-opensource
-make libs
-xplatform linux-arm-gnueabi-g++
-optimized-qmake
-pch
-qt-sql-sqlite
-qt-libjpeg
-qt-zlib
-no-opengl
-skip qt3d
-skip qtcanvas3d
-skip qtpurchasing
-no-sse2
-no-openssl
-no-nis
-no-cups
-no-glib
-no-iconv
-nomake examples
-nomake tools
-skip qtvirtualkeyboard
-I/opt/tslib1.4/include
-L/opt/tslib1.4/lib

The last two lines of exit
are the installation location of tslib. Change
them as needed. I have never understood the meaning of nomake and skip. I feel that they are the same. The above content tells qt which modules are needed, which modules are not needed, and their installation paths, etc. You can enter ./configure --help for details. If some modules do not have opengl, they need to be modified, otherwise the compilation will not pass. I don't use these modules, so skip them all. There are also examples. I suggest you compile them in. The small examples in them can be used directly for testing. I have compiled them, so I will just nomake. Pay special attention to adding a space before all hyphens/, and press Enter before exit. The sh file format is very important. One more space will cause an error. You can explore it yourself. Don't type spaces randomly, even at the end of each line. -no-iconv This must be added, otherwise the font library will have problems. We will not use this module for the time being.

After the setup is complete, run:
./autoconfig.sh
Wait for qmake to configure for a while, check the module list that pops up to see if there are any missing or more modules,
and then the routine
make
blah blah #¥……%&……*&()*#%¥%……&(), wait for about an hour

 



During the compilation, go to the Qt official website to download the Ubuntu version of qt5.7 for Linux. You don't need the source code. Download the .run file, download it to your computer, and double-click to install it. (Note: The Linux version of qt5.7 can only be installed on Ubuntu 16. It cannot be opened on Ubuntu 12. Do not use the console to install it. Just double-click to open the installation. It is installed in the /home path by default, which is convenient for future use.)

[1] [2]
Keywords:Embedded Reference address:Embedded 4412 development board QT5.7 compiled and installed to arm

Previous article:Differences between the 4412 and 4418 development boards
Next article:Android development process based on Xunwei 4412 development board

Recommended posts

Follow me Season 2, Issue 1, Basic Task 2 (Must Do) Monitor ambient temperature and light, and display comfort through onboard LEDs...
Therearetwodatathatneedtobeobtained:ambienttemperatureandlight.MMBT2222ALSPT1931HereIdefinethatthestrongerthelight,themorelightswillbeon,becausethelocalambienttemperatureismoredifficulttochangethantheambien
pildio DigiKey Technology Zone
How to Place an Inductor on a Switch Mode Power Supply PCB
Question:Whereshouldthecoilbeplaced? answer: Switchingregulatorsforvoltageconversionuseinductorstotemporarilystoreenergy.Theseinductorsareusuallyverylargeandmustbelocatedintheprintedcircuitboard(PCB)layou
eric_wang Power technology
Do you know about incomplete types in C language?
Whatisanincompletetype? Clanguagetypesaredividedintothreecategories:functions,objects(suchaschar,int,arrays,structures,pointers)andincompletetypes. Incompletetypesaretypeswhosesizecannotbedetermined,
MamoYU Integrated technical exchanges
[ ST NUCLEO-U575ZI-Q Review] 12-Create a task using the AZure ThreadX operating system
FortheSTM32U5chip,thegenerationofFreeRTOScodeisnolongersupportedinSTM32CUBEMX.Instead,theAzureThreadXoperatingsystemisused. ThreadXisanembeddedoperatingsystemunderMicrosoft.Inadditiontotheoperatingsystem,italso
manhuami2007 RF/Wirelessly
CircuitPython 6.0.0 Beta 1 released
https://blog.adafruit.com/2020/10/01/ci...-released/ ThisisthesecondbetareleaseofCircuitPython6.0.0,andit'sgenerallystable.Seetheportingstatusbelowformorestabilitydetails.ThisreleaseincludesthenewcanioAPI,sup
dcexpert MicroPython Open Source section
Where can I get the aduc7026 board?
CananyonetellmewhereIcangettheaduc7026board?Thanks! https://www.digikey.cn/zh/products/detail/analog-devices-inc/EVAL-ADUC7026QSPZ/1551771 Thanks Morethan1400yuan,nomore
chenbingjy ARM Technology
Latest Microcontroller Articles
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号