A few questions about the Qt file

I want to find the generated Makefile in another directory and use it from there.

Here is part of my profile:

OBJECTS_DIR = build/Objects-files
MOC_DIR = build/Moc-files
RCC_DIR = build/Rcc-files

# Location of the binary file
DESTDIR = bin

MAKEFILE = build/Makefile

And with the last line, I got:

make: *** No targets specified and no makefile found. Stop.
Exited with code 2.

And the second question, which variable sets the location of the ui include files (e.g. ui_mainwindow.h

thank

+3
source share
1 answer

As far as I know, you need to run qmake in the directory in which you want the Makefile to be generated, so you had to do this.

cd build
qmake ../your_project_file.pro

Regarding the location of the files created by uic, you need to set variables UI_DIR(or UI_HEADERS_DIR/ UI_SOURCES_DIRif you want to place the header and implementation files in separate headers).

+2
source

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


All Articles