K
K
kristian3072019-08-27 18:03:45
Qt
kristian307, 2019-08-27 18:03:45

How to make ready executable application with Qt libraries?

Hello. In Qt Creator (I work on Linux Ubuntu) I assembled a release application from sources, modules: core, gui, xml, network. How to make it so that you can safely pack the application into an archive and drop it on another system? I read about dynamic / static linking, but did not quite understand how to implement it, especially in Linux'e. I'm sorry for the stupid question, it's just that Linux and QtCreator are new to me.
Or at least tell me where to dig, if not difficult.
Qt built itself from source, version 4.8.7

Answer the question

In order to leave comments, you need to log in

2 answer(s)
P
pfg21, 2019-08-27
@pfg21

to get the libraries needed by the binary for execution, there is a standard ldd utility. you get something like this

~$ ldd /usr/bin/qgis.bin
  linux-vdso.so.1 (0x00007ffdf00c5000)
*****************
  libQt5Widgets.so.5 => /usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5 (0x00007f9ad0967000)
  libQt5Gui.so.5 => /usr/lib/x86_64-linux-gnu/libQt5Gui.so.5 (0x00007f9ad03b8000)
  libQt5Core.so.5 => /usr/lib/x86_64-linux-gnu/libQt5Core.so.5 (0x00007f9acfe8e000)
*****************

if for a couple of times, bring a binary to show work at the university, then a clumsy collective farm with a binary archive + library will go.

V
vanyamba-electronics, 2019-08-27
@vanyamba-electronics

For Debian and Ubuntu, you can build a deb package.
How to build a binary deb package: a detailed HowTo

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question