How to configure qmake to install my application using make install?

I have a small qt application that I use qmake to build, but I miss the make install target. How to configure qmake so that my binary is copied to / usr / local / bin / when I run "make install"?

  • QMAKE
  • make
  • make install

What do I need to add to my .pro file in order to get the β€œinstall” goal and how can I control which file and path will be used?


Btw installation will be on Linux pc: s like Debian and Ubuntu.

+6
source share
1 answer

Add something similar to you .pro file

target.path = /usr/local/bin/ INSTALLS += target 
+11
source

Source: https://habr.com/ru/post/925512/


All Articles