net-im/qTox is a Qt5 project. It doesn't use qmake, but it uses CMAKE_AUTOMOC. For some reason, build fails without USE_QT5+=qmake_build: > CMake Error at /usr/local/lib/cmake/Qt5Core/Qt5CoreConfig.cmake:15 (message): > The imported target "Qt5::Core" references the file > "/usr/local/lib/qt5/bin/qmake" > but this file does not exist. Possible reasons include: > * The file was deleted, renamed, or moved to another location. > * An install or uninstall procedure did not complete successfully. > * The installation package was faulty and contained > "/usr/local/lib/cmake/Qt5Core/Qt5CoreConfigExtras.cmake" > but not all the files it references. Qt5 should not require qmake_build when qmake isn't used. It should have moc_build or automoc_build or something like this.
qTox update suffering from the problem: bug#220814
Hi Yuri Even if a Qt5 project uses cmake to be built, it [almost] always also requires USE_QT5=qmake_build, as the cmake files shipped by Qt are just built this way (remember, QtBase is not supposed to be split, as it is in the ports tree). I'm not sure if the price "having to add USE_QT5=qmake_build" is worth the effort to mess with Qt's cmake files. mfg Tobias
As tcberner@ says, the Qt-provided CMake modules (for Qt5) require qmake to be installed. If you really, really, want to avoid qmake in an otherwise Qt5-using port (remember, we're fighting against upstream to even allow qmake to be absent), you can use some CMake trickery in your own port: add_executable(Qt5::qmake IMPORTED) set_target_properties(Qt5::qmake PROPERTIES IMPORTED_LOCATION "/usr/bin/false") That will prevent the Qt5 module from looking for qmake on its own. We don't think it's worth it to wrestle away qmake.