[CMake] CMake does not find an header file, and ignores the classes found in several other header files.

Rolf Eike Beer eike at sf-mail.de
Sun Aug 5 05:24:41 EDT 2012


Toronto Andrew wrote:
> Hello, thank you for looking at my CMake issues! I really appreciate it :)
> 
> I fixed the major issue you mentioned (Moving INCLUDE_DIRECTORIES above
> ADD_EXECUTABLE), however this did not seem to fix anything. I still got the
> errors I was receiving prior to that change, and I used absolute paths when
> linking to the include directory within my source.
> 
> I fixed this *qextserialport\src\moc_qextserialport.cpp(10): fatal error
> C1083: Cannot open include file: '../../../src/qextserialport.h': No such
> file or directory. * by linking to the absolute path in
> moc_qextserialport.cpp, which seemed to get rid of it, however it draws up
> these now:
> 
> *2>build\x\QExtSerialPort\src\moc_qextserialport.cxx(97): error C2027: use
> of undefined type 'QextSerialPortPrivate'
> 2>  QExtSerialPort/src/qextserialport.h(167) : see declaration of
> 'QextSerialPortPrivate'
> 2>build\x\QExtSerialPort\src\moc_qextserialport.cxx(97): error C2227: left
> of '->_q_canRead' must point to class/struct/union/generic type*



More information about the CMake mailing list