Cannot find Qt6 installation? - c++

Trying to follow the install instructions from a GitHub page: https://github.com/TASEmulators/fceux
I went through with installing Qt6 and when I do the following this happens:
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX=/usr -DQT6=1 -DCMAKE_BUILD_TYPE=Debug ..
-- Selecting Windows SDK version 10.0.19041.0 to target Windows 10.0.19042.
-- GUI Frontend: Qt6
CMake Error at src/CMakeLists.txt:22 (find_package):
By not providing "FindQt6.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "Qt6", but
CMake did not find one.
Could not find a package configuration file provided by "Qt6" with any of
the following names:
Qt6Config.cmake
qt6-config.cmake
Add the installation prefix of "Qt6" to CMAKE_PREFIX_PATH or set "Qt6_DIR"
to a directory containing one of the above files. If "Qt6" provides a
separate development package or SDK, be sure it has been installed.
-- Configuring incomplete, errors occurred!

As the error message says, you need up set the environment value Qt6_DIR to the location you installed qt6 to. This should be a part of the instructions in installing qt6.
You should link the instructions you used for installing qt6. They may contain instructions to set the environment variable QT_DIR instead of the Qt6_DIR which is required by what you're building. If this is the case just follow the instructions for setting QT_DIR to also set Qt6_DIR.

Related

DicomToMesh OSX Building Issue

I want to compile DicomToMesh according to the instructions in this link.
> git clone https://github.com/AOT-AG/DicomToMesh.git
> cd DicomToMesh
> mkdir build
> cd build
> ccmake .. #opens ccmake window
By executing above instruction I supposed to get something similar to the following within the ccmake window,
BUILD_GUI OFF
CMAKE_BUILD_TYPE DEBUG
CMAKE_INSTALL_PREFIX /usr/local
USE_VTK_DICOM OFF
VTK_DIR /home/eidelen/Development/libs/vtk/build
But in my case I'm getting this result:
After pressing c, it generates following error:
CMake Error at /usr/local/lib/cmake/vtk-9.0/VTK-vtk-module-find-packages.cmake:115
(find_package):
By not providing "FindQt5.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "Qt5", but
CMake did not find one.
Could not find a package configuration file provided by "Qt5" (requested
version 5.15) with any of the following names:
Qt5Config.cmake
qt5-config.cmake
Add the installation prefix of "Qt5" to CMAKE_PREFIX_PATH or set "Qt5_DIR"
to a directory containing one of the above files. If "Qt5" provides a
separate development package or SDK, be sure it has been installed.
Call Stack (most recent call first):
/usr/local/lib/cmake/vtk-9.0/vtk-config.cmake:131 (include)
CMakeLists.txt:5 (find_package)
Configuring incomplete, errors occurred!
See also "/Users/mrhs/DicomToMesh/build/CMakeFiles/CMakeOutput.log".
See also "/Users/mrhs/DicomToMesh/build/CMakeFiles/CMakeError.log".
I have installed QT5 5.15.2 using
brew install qt5
I tried to follow this solution using command
brew install qtbase5-dev
brew install qtdeclarative5-dev
But getting Warning: No available formula or cask with the name "qtbase5-dev". and Error: No similarly named formulae found'
I have tried this solution by using the command
export CMAKE_PREFIX_PATH=/usr/local/Cellar/qt#5/
cd build
but it is showing No such file or directory
I'm using this for the first time and my be i'm missing something which I could not figure out yet. I will be really very thankful and will appreciate it if anyone can help me. I badly need to solve this issue and has spend a lot of time but in vain.
N.B. This is my CMakeError.log and CMakeOutput.log
Installing brew install qt5, at the end the process is going to display something like :
echo 'export PATH="/usr/local/opt/qt#5/bin:$PATH"' >> ~/.zshrc
export LDFLAGS="-L/usr/local/opt/qt#5/lib"
export CPPFLAGS="-I/usr/local/opt/qt#5/include"
Just type them in your terminal

Could NOT find Qt5WebKitWidgets

I am trying to build nextcloud open source project. I am using built tools Qt 5.6 version. following errors has occurred-
-- Could NOT find Qt5WebKitWidgets (missing: Qt5WebKitWidgets_DIR)
CMake Warning at src/gui/CMakeLists.txt:313 (find_package):
Found package configuration file:
C:/Qt/Qt5.6.0/5.6/mingw49_32/lib/cmake/Qt5/Qt5Config.cmake
but it sets Qt5_FOUND to FALSE so package "Qt5" is considered to be NOT
FOUND. Reason given by package:
Failed to find Qt5 component "WebKitWidgets" config file at
C:/Qt/Qt5.6.0/5.6/mingw49_32/lib/cmake/Qt5WebKitWidgets/
Qt5WebKitWidgetsConfig.cmake
Thanks everyone.finally I have got solution.I have just used Qt 5.5 version which solves my problem.

Cross-Compiling QT5 for windows on ubuntu host

I'm trying to compile this wallet on Ubuntu 14.04 machine. I already compiled it for Linux using the docs:
mkdir build && cd build && cmake .. && make
But, unfortunately, I don't have a windows machine to compile it.
I tried installing mingw32 and compile using those toolchains, and then by using this answer but it didn't work and thrown an error:
CMake Error at CMakeLists.txt:19 (find_package):
By not providing "FindQt5Gui.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "Qt5Gui", but
CMake did not find one.
Could not find a package configuration file provided by "Qt5Gui" with any
of the following names:
Qt5GuiConfig.cmake
qt5gui-config.cmake
Add the installation prefix of "Qt5Gui" to CMAKE_PREFIX_PATH or set
"Qt5Gui_DIR" to a directory containing one of the above files. If "Qt5Gui"
provides a separate development package or SDK, be sure it has been
installed.
PS: I already installed QT5 using apt-get install qt5-default.

Installing the SFGUI with Cmake

I've been trying to install SFGUI library with Cmake tool with instructions given here: SFGUI Install Tutorial . Still got many problems in major with Cmake, which couldn't find few files from SFGUI directory, for example
CMake Error: The source "D:/SFGUI-master/CMakeLists.txt" does not match the source "D:/SFGUI-0.3.0/CMakeLists.txt" used to generate cache. Re-run cmake with a different source directory.
Restarting didn't help. Could anyone write how to install this in simple steps? Regards.
cmake is telling you that the files it has generated in it's cache from a previous run don't match the source files you are currently using. I would imagine that you ran cmake, then switched git branches or tags and tried to run cmake again. You can just rm -r CMakeFiles in your build directory to remove the cache. Then you should be able to run cmake again without errors.
Thanks! It moved a little bit, but stopped actually at error:
CMake Error at cmake/Modules/FindSFML.cmake:306 (message):
Could NOT find SFML (missing: SFML_GRAPHICS_LIBRARY SFML_WINDOW_LIBRARY
SFML_SYSTEM_LIBRARY)
Call Stack (most recent call first):
CMakeLists.txt:21 (find_package)
Configuring incomplete, errors occurred!
See also "C:/Users/admin/Documents/Visual Studio 2015/Projects/sfml1/sfml1/CMakeFiles/CMakeOutput.log".
To be honest, I will write down steps I did: 1.Configured SFML in VS15 in Windows 8.1 2. I installed the newswet version of CMake 3. Installed also newest SFGUI from Github. 4.In Cmake GUI as a build I choose my project in VS and as a source - SFGUI directory. 5.In CMake Configure and there are the errors. Did I missed something?

CMake cannot find libcurl-config.cmake

I'm trying to compile code with cmake. The code was imported from Windows onto a Raspberry Pi with Debian OS. The code works fine when compiling on Windows. Here is the error when I try to compile:
CMake Error at CMakeLists.txt:6 (FIND_PACKAGE):
By not providing "Findlibcurl.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "libcurl", but
CMake did not find one.
Could not find a package configuration file provided by "libcurl" with any
of the following names:
libcurlConfig.cmake
libcurl-config.cmake
Add the installation prefix of "libcurl" to CMAKE_PREFIX_PATH or set
"libcurl_DIR" to a directory containing one of the above files. If
"libcurl" provides a separate development package or SDK, be sure it has
been installed.
Here is a list of the installed packages regarding libcurl:
ii libcurl3:armhf 7.26.0-1+whe armhf easy-to-use client-side URL trans
ii libcurl3-gnutl 7.26.0-1+whe armhf easy-to-use client-side URL trans
ii libcurl4-opens 7.26.0-1+whe armhf development files and documentati
Could this mean the packages are installed incorrectly or I have the wrong one?
I did not touched arduino yet, but if you can access arduino's debian - try to do something like:
sudo apt-get install libcurl-dev --reinstall
and then:
make clean
make
P.S. You may have libcurl but CMake requires dev-information of it too.