On Tue Feb 15, 2022 at 09:58:00PM +0100, Caspar Schutijser wrote: > Hi, > > Qt5's cmake files are installed in /usr/local/lib/qt5/cmake/. Many other > software packages install their cmake in /usr/local/lib/cmake/. Is > there a reason Qt5's cmake files are not installed in > /usr/local/lib/cmake/?
No, I don't know the reason. I think it certainly has something to do with Q3 vs Qt4 vs Q5 in the early days. The Qt5 module handles all the mgaic for the ports. > > The reason I'm asking is that if I'm building a Qt5/cmake project > outside the ports tree, I have to manually add something like > set(CMAKE_PREFIX_PATH /usr/local/lib/qt5/cmake) > to the project's CMakeLists.txt file because otherwise cmake won't find > Qt5's cmake files. Sometimes that's a bit annoying. > > If you're OK with changing this, I can have a look at creating a diff. > > Caspar > You can it do it easily with Qt5_DIR, checkout: https://www.sizeofvoid.org/posts/2020-03-29-how-to-build-qt5-applications-with-cake-on-openbsd/ Rafael
