Add QFTP module in qt5 - c++

i want to install QFTP module in my qt5
I downloaded it from github and i want to know what is the next step, if possible try to be the most explicit because my english is not very good, thanks

Did you try to open qtftp.pro file with QTCreator and then build it?
If this step is completed without errors, you can install the library to the main QT direcotry. Use the QT console window for this, which has all the paths embedded in it.
Go to the directory where you built the library and enter the command mingw32-make.exe install.
After that probably you can use your library in QT Creator by command:
QT += name_of_library

Related

How to build a project under the src directory of Qt?

I found a .pro file 5.12.1\Src\qtbase\src\plugins\platforms\windows\windows.pro and opened it in Qt Creator. After configuring a MingW kit, I tried to build the project. But I got this error;
error: vulkan/vulkan.h: No such file or directory
#include <vulkan/vulkan.h>
Do I need to configure something before building the project? I do not want the vulkan support, just want to compile it successfully. I remember if I build the whole Qt src, I need to run a command like "configure xxxxx" in the src directory. Now I do not want to build whole Qt, just this project. There is a line in windows.pro that seems related to this problem.
qtConfig(vulkan): QT += vulkan_support-private
How should I do to remove the need for the vulkan stuff in order to build it successfully?
Yes, you will need to configure things. I suggest you read up on Building Qt 5 from source to understand what is involved.

How to add a Scintilla component to a Qt Creator C++ project?

I would like to use scintilla on a Qt project, but I don't know how to start, do I have to include the source files? or is there some library that I can reference?
The only installation examples I have found are for PyQt but I'm using c++ on Linux.
QScintilla is a library derived from Scintilla to use with Qt. This library can be downloaded from https://riverbankcomputing.com/software/qscintilla/download.
To use this library you need to build and install first. As you use Linux, the building process is
cd Qt4Qt5
qmake
make
make install
Note:
The directory Qt4Qt5 is inside the uncompressed QScintilla directory.
Make sure Qt binary path is in your Linux PATH variable.
To use QScintilla in your project, in your .pro file just add the following line.
CONFIG += qscintilla2
The library comes with an example. To build the example use the following commands in your bash.
cd example-Qt4Qt5
qmake
make

Qt Creator adding mqtt library

Working on Win 10 with QT Creator 4.3.1
Trying to add a library to my qt project via the GUI. In specific the qtmqtt library.
right click on project -> "Add library..." and simply nothing happens.
Anybody else having this problem?
Seems like I am to stupid to add a library directory via the .pro file. Googled for hours but cant get my head around it. So I really need the GUI solution to be working.
According to this, there's no need to add libraries, since MQTT is a Qt module just add this line in your pro file:
QT += mqtt
To use a Qt module, it must be installed in the Qt lib directory.
First, retrieve the lib directory path executing this command from a terminal:
qmake -query QT_INSTALL_LIBS
Cd into that directory and check if a file called Qt5Mqtt.dll is there: if not, you must build/install the module.
To get the module source code, you can execute this git command:
git clone git://code.qt.io/qt/qtmqtt.git
Once you have the source files, cd into the source files directory containing the file qtmqtt.pro and run these commands:
qmake
make
make install
(you may need administrator privileges for the last one).
After the commands completed successfully, you should be able to see the library in the QT_INSTALL_LIBS directory, and use the module in a Qt project.
In case of compilation issues, open the qtmqtt.pro file with creator, and try to build the library from there, then manually install (copy) it into the QT_INSTALL_LIBS.
try this step by step :
//emqttd boker
git clone https://github.com/emqtt/qmqtt.git
//Qt mqtt
git clone https://code.qt.io/qt/qtmqtt.git
cd qmqtt
mkdir build
cd build
//Untubu
~/Qt/5.10.0/gcc_64/bin/qmake qmake -r ..
//mac Os
~/Qt/5.10.0/clang_64/bin/qmake qmake -r ..
make
sudo make install
Done

How to run qmake from the static Qt

For making a very simple Qt app "installable" on other systems, I'm using Qt Installer Framework following this link.
In bottom, in Setting up Qt Installer Framework, number 1 orders to have Qt Installer Framework source code. I downloaded it from here. (qt-installer-framework-opensource-2.0.1-src.zip)
Now I don't understand the next instruction there :(
It says:
2- Build the tools by running the "qmake" from the static Qt, followed by "make" or "nmake".
My question is, first what does it mean?
And from what path?
I don't know how to do it:(
qmake comes with the qt-framework and is a make file generator. (an alternative to cmake).
You call qmake on a .pro file from your project. This .pro file have to contain your source code files project dependencies and more.
Consider that you have a project folder with your source code and the .pro file. Then you call the qmake command in this folder. qmake is an program itself, which you can find in the bin folder of your qt-installation. If qmake is in your path variable, you go to the terminal, navigate to the specific folder and just write:
qmake
After that qmake will create a makefile. Then you could call makeand your program will be build.
I hope my answer helps you. You can learn more about qmake on the website of Qt. Here is also a very good qmake tutorial: klick
edit:
how to call make on windows:
download and install cygwin from
http://www.cygwin.com/setup-x86.exe - 32 bit installer or
http://www.cygwin.com/setup-x86_64.exe - 64 bit installer.
then start the Cygwin terminal (Cygwin.bat) and navigate to your folder and call
make
and that will build your qt-installer!

Qt unit-test: why "qmake" is not recognized

I managed to follow this tutorial in order to write my first unit-test.
However, when opening a "cmd-console" from inside my project folder and try to rum qmake, i get the following error:
'qmake' is not recognized as an internal or external command, operable program or batch file.
so, why qmake is not recognized? (note that I am working on windows Vita)
On Windows qt and its tools are installed by default in C:\Qt\blablah. You should add the path to the qmake binary, and that will do the trick. See the instructions here. Note that Qt creator set some variables for its terminal so you use qmake in creator without touching the system.
set path the Qt compiler.
sth like this:
set PATH=C:\Qt\4.8.5\bin
where the 4.8.5 is the version of Qt you installed.
If you don't want to add the QT bin path to PATH you can write the full path to qmake:
>"$(QTDIR)\bin\qmake.exe" -o Makefile odbc.pro
where $(QTDIR) is the full path of the qtbase directory.