Error "Target xxx.obj does not exist" in pri
-
Hello,
Often I compile the current file, I am working on, with Menu: Build/Build xxx.cpp to check it. (Resp. I have a hotkey for it.)
This works no more for new files I added to a subproject (*.pri). The active parse context in the editor is shown correct. For new files in main project all works.
The common "tricks" to clean, delete makefiles, run qmake do not work.
This is strange, because when I build the whole project all works. The xxx.cpp will be compiled.
For older files "build current file" works without problems.What is the difference of the new files to the old files ?
-
@jsulm said in Error "Target xxx.obj does not exist" in pri:
@Andy314 Were the new files added in exactly same way as old ones?
I cannot really remember how I did it some month ago, but usually I
use Add New->C++ Class.
Nevertheless the only effect should be additional file entries in the pri-file.
That all looks OK.O I forgot: When I added the old files I used an older Qt/Creator version.
-
@jsulm said in Error "Target xxx.obj does not exist" in pri:
@Andy314 You can check the pro/pri files to see how the files were added
They all look total identical to the other files.
INCLUDEPATH += $$PWD
HEADERS +=
$$PWD/ActionLogging_Form.h \ // works not
$$PWD/qtdatabase.h \ // works
.................. -
@Andy314 said in Error "Target xxx.obj does not exist" in pri:
$$PWD/ActionLogging_Form.h \ // works not
This is a header file. Is it included anywhere?
-
@jsulm said in Error "Target xxx.obj does not exist" in pri:
@Andy314 said in Error "Target xxx.obj does not exist" in pri:
$$PWD/ActionLogging_Form.h \ // works not
This is a header file. Is it included anywhere?
I have shown only the Headers. I have similar entries for the SOURCES and FORMS.
I have included the header in ActionLogging_Form.cpp and an other cpp. -
I tested a lot over hours to find out whats the problem.
Creation of a new projekt or folder projekts gave the same error. Files with old filenames worked, new filenames worked no.
The after some changing of "set xxx als active projekt" the Creator tried to compile (or was it reversed) a Cpp file with Python. This gave the hint that with the Creator is something wrong, the active project (resp. the file project relation) was no accepted correctly.
Creating of a new workspace and integration my old project solved the problem. There must be a bug in the Creator.