Preparing I.MX 8 Nano for development using Debian with QT UI / dotnet core for communication - qt

I am trying to get the above development system working, I am starting with a Varicsite NANO compute module. I am trying to get QT 5 setup to develop. I have been unable to find a good Debian guide on how to do that. I would eventually want the QT application to run in kiosk mode without the Weston desktop.
I have Debian built using their instructions of building Debian for the IMX8 board. It runs fine Weston comes up on boot.
I have installed the following packages on the target device.
sudo
apache2
php
jq
curl
qtwayland5
gdb
gdbserver
I have attempted to follow their guide on getting QT to work for YOCTO(not Debian) and have not gotten it to work. QT is installed but their Debian build does not come with a full sdk. Nor do they detail all of the packages that need to be installed.
I have also tried following this guide, but it was written for an RPI and X11 not wayland/Weston so some of the steps seem wrong especially in all of the packages it wants you to install.
https://mechatronicsblog.com/cross-compile-and-deploy-qt-5-12-for-raspberry-pi/
Is there a good guide on how to do this, I was thinking of trying to combine the two guides by using his lines to set up rsync and such but I still do not have a full SDK without the right qmake.
My host system is UBUNTU 16.04

Related

How to use QTermWidget with PyQt5?

I am trying to install https://github.com/lxqt/qtermwidget so that I can have a terminal widget to use with PyQt5. However, it does not seem to be possible to install without building myself, and when I try follow the instructions to build it myself, I get errors.
After doing cmake, I followed the instruction on qtermwidget's GitHub page to run sip-wheel inside the "pyqt" directory, but I get the error:
Querying qmake about your Qt installation...
sip-wheel: '12.11' is not a supported ABI version
What is the proper way to make "import QTermWidget" work inside python?
I got the same error when I used the sip-wheel to get qtermwidget Python binding. The problem is having different versions of PyQt and sip tools on the computer. I tested in a virtual machine with a clean version of Ubuntu, and I could build without problems. On my laptop, the solution was to create a virtual Python environment, install pyqt5, and sip tools again.

Run Binary With Specific QT Version - Cannot mix incompatible Qt library

I'm trying to replicate an application that we currently have running on a physical Ubuntu server using an Ubuntu machine in Virtual Box. It is a QT application but on the server we are running it using pm2 from NPM. After installing QT, and installing drivers needed for the application i've tried to run it but keep coming across this error:
Cannot mix incompatible Qt library (version 0x50701) with this library (version 0x50905)
I've inherited the code from someone else and don't want to change the project to QT5.9.5, so i'm trying to run with 5.7.1, I've followed instructions on other questions in order to change the QT version to 5.7.1 but still get the same error when running it.
I followed the instructions here:
https://unix.stackexchange.com/questions/116254/how-do-i-change-which-version-of-qt-is-used-for-qmake
When checking the QT version using "qmake -v" in the console I get the following output:
QMake version 3.0 Using Qt version 5.7.1 in /home/sam/Qt5.7.1/5.7/gcc_64/lib
So although it looks to me like i'm using the desired version of Qt (5.7.1), i'm still getting the incompatible library issue, i'm very new to all of this so apologies if this is a stupid question. If anyone could tell me what to do in order to use the compatible library that'd be great, thanks.
I will try to explain this in steps!
Each complete set of Qt libraries is called a Qt "distribution". You can get Qt distributions from a variety of sources:
Installed from the package manager of your OS (.deb/.rpm).
From a downloaded zip file on http://qt.io
As a cloned repo from git
etc..
Some of the available Qt distributions will come pre-built, and some will need to be built from sources. In either case they will all have a qmake program that is specific to that particular Qt distribution. This program is responsible for building programs so that they link to the particular Qt distribution that the qmake is part of. qmake is also used when building with QtCreator.
If you have a binary built with one qmake and you try to run it on another computer, it might find the wrong Qt libraries during dynamic linking and spit out errors of "incompatible version of Qt".
There are many solutions to this problem;
Collect all the Qt libraries (Mine are in /home/myusername/Qt/5.version/gcc_64/lib/*.so) in the same folder as your program executable. This will make sure they are prefered to any other version of Qt that may be in your dynamic linker's path.
Uninstall the OS supplied Qt version(s). This may not be advisable especially if other programs use them.
Rebuilt your program from source using the correct qmake.

Deployment of statically linked Qt application backward compatibility

This is my first attempt at making a Qt Application work on different systems.
I have opted for static linking method.I have already compiled the sources of Qt 5.5 and compiled my application with the static Qt. The executable is working fine on my computer.
My operating system is Ubuntu 15.04. But when I tried to run the same executable on Ubuntu 14.04 then I ran into trouble. The key details of the error message are given below.
libstdc++.so.6 cxxabi_1.3.8 not found
I did a standard Google search and realised it was because I had a newer version of it on my machine, the machine where I had created the executable. There were so many different approaches to handle this problem. One of the solutions I saw involved shipping your own copy of libstdc++.so with the executable. But when I tried to copy the .so file to a pen drive, there was a warning saying that the file system does not support such files.
My question is , what am I doing wrong ? Also if I wanted to make the executable target Ubuntu 10.04, what would be the correct procedure handling the backward compatibility issues. I know that one method would be to install the same OS on my machine and then create the executable , is there any other way?
libstd++ is backward compatible but not forward compatible, which means you can run a program with a newer version of libstdc++ than the one you compiled it with but not vice-versa. This is what you experienced.
One way to deal with this issue is using older OS versions as the build machine. When you for example use Ubuntu 14.04 LTS, you'll get this list of compatible target systems.
The build system you're using will probably limit available compilers. On Ubuntu 14.04 you get GCC 4.8, which is good for most C++11 and packages for clang 3.6 are available, which will give you full C++14 support.
Targeting Ubuntu 10.04 will be challenging if you do not want to use a stone age compiler.
The idea of shipping libstdc++ will not help you much because you'll run into the same problem with libc.

Arduino Installation Guide for Ubuntu 12.04 Precise Pangolin

I'm following an installation guide for Arduino. I have Arduino UNO rev3 and ubuntu 64bit
The guide refers to Synaptic Package manager to install software. But it doesn't seem to be available in Ubuntu 12.04 Precise Pangolin.
Should I install the list of software components via Ubuntu software center? Or should I install the Synaptic Package manager? (e.g. http://www.jonathanmoeller.com/screed/?p=3610)
Is there any difference between the two installation applications?
I had a lot of trouble syncing processing and arduino in 12.04.
I installed arduino in every possible way imaginable: from the website, from synaptic/software-centre, from apt-get... etc and it just wouldn't run.
If you are having trouble 'running' it , go to a terminal and run it there to see the problem. Post details.
In my case I got java headlessexceptions errors, which I concluded was because 12.04 didn't have any JAVA stuff installed? Can you believe it! It came to me as a shock, but oh well:
Go to synaptic and get the following packages:
java-common, openjdk-7/6, java-wrappers, libjaxme-java, default-jre, defaul-jdk, libbsf-java, default-jre-headless, openjdk-6-jre-headless
I am sorry if some of these are irrelevant to arduino, I just went on a 'click-on-jdk' stuff spree and got it to work :) Processing and Arduino run like a charm now!
Hope this helps!
Follow this tutorial for setting up Arduino in Ubuntu. I found this one to be the most helpful. Install Arduino IDE in Ubuntu.
Actually the easiest way to get the Arduino IDE on Linux is to download the software from this page http://arduino.cc/en/Main/Software (either the 32bit or 64bit linux version depending on your system)
After you download it all you have to do is extract the archive and run the executable called "arduino"
For installing Arduino 1.0 in Precise there is no difference between using Synaptic or Software Center, they will both install including dependancies. The biggest difference is the user interface and that Software Center allows for purchasing some additional software, they are both using your repos defined in /etc/apt/sources.
https://apps.ubuntu.com/cat/applications/precise/arduino/
https://apps.ubuntu.com/cat/applications/synaptic/
Installing Arduino on Linux is a little bit harder than the same installation on Windows or Mac. A wide list with tutorials for Arduino installation on Linux could be a good help for you. Also, you can check this guide for arduino installation http://playground.arduino.cc//Learning/Linux
The best way to install arduino for ubuntu is with terminal.
The first line command you have to write is:
sudo apt-get update && sudo apt-get install arduino
This will update your ubuntu packages and also install the arduino package. Then type:
tar -xvzf filename.tar.xz
Then you have to go to the directory Downloads (cd Downloads), and next to the arduino directory (cd filename).
Finally to run arduino, once you are inside the arduino directory you type:
./arduino
It will run the program.

Can you install Qt-4.6.0-wince successfully?

I'm trying to install Qt-4.6.0-wince on XP and Vista. I read the instructions and follow it to install.
However, I can't install it successfully due to some fatal errors on all of the two machines. I think the problem is that qconfig.[h cpp] files are not created automatically during the configuration.
I already report about this problem, so you can see the more information here. However, it is still remained as unresolved.
Anybody here who has been installed it successfully?
#KernelJ I believe the original poster is using the correct install distro - the final product will be cross compiled from Win32 to WinCE; as is pointed out in the Qt for Windows CE Requirements.
#Brian, Unfortunately, I can't answer your original question - I have had unrelated trouble with the WinCE distribution myself and am working the issues now. However, I can provide some help: I was able to get the Qt Everywhere 4.6 to cross compile on my Win32 (XP) host for WinCE. I used the commercial version, but here is a link to the Open Source Qt Everywhere 4.6 package. As is pointed out in the nokia instructions, make sure to use the Visual Studio command prompt, get your environment variables ironed out, create a custom mkspec (if you have to), and keep a close eye during the configuration for any warnings.
Good luck.
Qt-4.6.0-wince, as is implied in the name and said explictly on the page you linked, is for Windows CE, NOT for Windows XP and Vista!!!
Nokia have released a nice software development kit for Qt which you can download here. It is very impressive and powerful!
I got things running as compilable (and running on emulator) with VS 2008, so your milage may vary:
Make sure the PATH variable points to \bin
Open a command prompt (using the Visual Studio Command Prompt)
Run the vcvars32.bat file (in C:\Program Files\Microsoft Visual Studio 9\VC\bin) folder
Cd into the qt folder
Run this: configure -no-sql-sqlite -no-qt3support -platform win32-msvc2008 –xplatform wincewm50pocket-msvc2008 -no-phonon -no-phonon-backend -no-webkit (building for WINCE 5.0, and all the '-no-...' makes it build faster, removing stuff we don’t want)
The setccepaths script provided sometimes doesn’t work. I used checksdk.exe –script temp_script.bat (It creates a script, the default is for Pocket PC SDK 5)
Run that script you just created (the temp_script.bat thing. It sets up environment variables.
Run nmake
*whew*
and good luck.

Resources