Moc Error: Too many input files specified. Integration Problem?
Hi,
I have a really strange problem.
I add a new QObject class I have a moc Error:
Code:
#include <QObject>
{
Q_OBJECT
public:
Final();
};
I try to compile this code and this is the error:
>Moc'ing Final.h...
1>moc: Too many input files specified
1>Usage: moc [options] <header-file>
1> -o<file> write output to file rather than stdout
1> -I<dir> add dir to the include path for header files
1> -E preprocess only; do not generate meta object code
1> -D<macro>[=<def>] define macro, with optional definition
1> -U<macro> undefine macro
1> -i do not generate an #include statement
1> -p<path> path prefix for included file
1> -f[<file>] force #include, optional file name
1> -nw do not display warnings
1> @<file> read additional options from file
1> -v display version of moc
1>Project : error PRJ0019: A tool returned an error code from "Moc'ing Final.h..."
if I remove the macro Q_OBJECT compilation is successful (but I can't use SIGNAL and SLOT ;) )
Has anyone had the same problem?
I'm workin in Windows 7 64bit, Qt 4.6.2, Qt Addin 1.1.7, Visual Studio 2005.
Re: Moc Error: Too many input files specified. Integration Problem?
It's not nice to ask the same question at multiple forums.
http://developer.qt.nokia.com/forums/viewthread/1951/
Re: Moc Error: Too many input files specified. Integration Problem?
Sorry Tbscope, but I'm not sure that there are the same people.
Re: Moc Error: Too many input files specified. Integration Problem?
Try to rebuild your application (e.g. delete your old make file).
Re: Moc Error: Too many input files specified. Integration Problem?
Quote:
Originally Posted by
Lykurg
Try to rebuild your application (e.g. delete your old make file).
I have the same problem :(
I think that can be a wrong vcproj setting because I notided that only in this project (my solution is composed of multiple project) I don't have the visual studio autocomplete.
Re: Moc Error: Too many input files specified. Integration Problem?
I have solved my problem: the solution is use Qt Addin 1.1.5 instead Qt Addin 1.1.7.
I think that this is a Qt Addin 1.1.7 bug.
Re: Moc Error: Too many input files specified. Integration Problem?
Hi, I had the same problem and I solved it by making a random change in the Visual Studio project properties. In my case changing the order of the additional include directories did the magic, but I think that any change could work since it seems to me that this issue is caused by a malformed vcproj file.
Hope this helps.
Cheers
Re: Moc Error: Too many input files specified. Integration Problem?
Hello, in my installation(VS2008,Qt 4.7.1,Addin 1.1.7) " Files" is added at the end of Command Line In "Custom Build Step" for.h files. This gives the error message.
If i add a .h-file i always have to remove the added "Files".
Does anybody know how to modify the rules that were use to set the parameters in"Custom Build Steps"?
Bye
Re: Moc Error: Too many input files specified. Integration Problem?
Using the Visual Studio plugin, I found a workaround by going into Qt Project Settings and selecting a new module, compiling, and then going back and deselecting.