Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Qt3D build in Qt6



  • I m using Linux 20.04 and trying to build 3D library of Qt6.0.3 version. I have installed Qt using online installer. I referred following links to build the library:
    https://www.kdab.com/getting-your-3d-ready-for-qt-6/#comment-153302
    https://wiki.qt.io/Qt6_Add-on_src_package_build_using_Conan_package_manager

    I have source files in /home/suraj/Qt/AdditionalLibraries/Qt/qt3d-6.0.3/Src directory.
    I have Conan in /home/suraj/Qt/Tools/Conan directory.
    I make a "build_dir" folder inside it.
    And I run the following command:

    conan install qt3d/6.0.3@qt/final --build=missing --profile=/home/suraj/Qt/Tools/Conan/profiles/'''qt-6.0.3-gcc-x86_64''' -s build_type=Release -g cmake_paths -g=cmake -g deploy
    

    I get following error:

    make -g deploy
    Configuration:
    [settings]
    arch=x86_64
    build_type=Release
    compiler=gcc
    compiler.libcxx=libstdc++11
    compiler.version=7.5
    os=Linux
    [options]
    qt6=6.0.3
    [build_requires]
    [env]
    QT_PATH=/home/suraj/Qt/6.0.3/gcc_64
    qt3d/6.0.3@qt/final: WARN: Package binary is corrupted, removing: d8a66a0900136a3d2ac348368a2db5ad95e3a64c
    Installing package: qt3d/6.0.3@qt/final
    Requirements
        qt3d/6.0.3@qt/final from local cache - Cache
    Packages
        qt3d/6.0.3@qt/final:d8a66a0900136a3d2ac348368a2db5ad95e3a64c - Build
    
    Installing (downloading, building) binaries...
    qt3d/6.0.3@qt/final: WARN: Build folder is dirty, removing it: /home/suraj/.conan/data/qt3d/6.0.3/qt/final/build/d8a66a0900136a3d2ac348368a2db5ad95e3a64c
    qt3d/6.0.3@qt/final: Copying sources to build folder
    qt3d/6.0.3@qt/final: Building your package in /home/suraj/.conan/data/qt3d/6.0.3/qt/final/build/d8a66a0900136a3d2ac348368a2db5ad95e3a64c
    qt3d/6.0.3@qt/final: Generator txt created conanbuildinfo.txt
    qt3d/6.0.3@qt/final: Calling build()
    CMAKE_PREFIX_PATH for 'qt3d/6.0.3' build is: /home/suraj/Qt/6.0.3/gcc_64
    CMAKE_PREFIX_PATH for 'qt3d/6.0.3' build is: /home/suraj/Qt/6.0.3/gcc_64
    -- The CXX compiler identification is GNU 9.3.0
    -- The C compiler identification is GNU 9.3.0
    -- Check for working CXX compiler: /usr/bin/g++
    -- Check for working CXX compiler: /usr/bin/g++ -- works
    -- Detecting CXX compiler ABI info
    -- Detecting CXX compiler ABI info - done
    -- Detecting CXX compile features
    -- Detecting CXX compile features - done
    -- Check for working C compiler: /usr/bin/gcc
    -- Check for working C compiler: /usr/bin/gcc -- works
    -- Detecting C compiler ABI info
    -- Detecting C compiler ABI info - done
    -- Detecting C compile features
    -- Detecting C compile features - done
    -- Looking for pthread.h
    -- Looking for pthread.h - found
    -- Performing Test CMAKE_HAVE_LIBC_PTHREAD
    -- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
    -- Check if compiler accepts -pthread
    -- Check if compiler accepts -pthread - yes
    -- Found Threads: TRUE  
    -- Performing Test HAVE_STDATOMIC
    -- Performing Test HAVE_STDATOMIC - Success
    -- Found WrapAtomic: TRUE  
    -- Found OpenGL: /usr/lib/x86_64-linux-gnu/libOpenGL.so   
    -- Found WrapOpenGL: TRUE  
    -- Found Vulkan: /usr/lib/x86_64-linux-gnu/libvulkan.so  
    -- Found XKB: /usr/lib/x86_64-linux-gnu/libxkbcommon.so (found suitable version "0.10.0", minimum required is "0.5.0") 
    -- Found OpenSSL: /usr/lib/x86_64-linux-gnu/libcrypto.so (found version "1.1.1f")  
    -- Found WrapOpenSSLHeaders: TRUE  
    -- Could NOT find Qt6Gamepad (missing: Qt6Gamepad_DIR)
    -- Check for feature set changes
    -- Using installed syncqt found at: /home/suraj/Qt/6.0.3/gcc_64/libexec/syncqt.pl
    -- Running syncqt for module: 'Qt3DCore' 
    -- Performing Test HAVE_DASH_UNDEFINED_SYMBOLS
    -- Performing Test HAVE_DASH_UNDEFINED_SYMBOLS - Success
    -- Performing Test HAVE_DASH_DASH_NO_UNDEFINED
    -- Performing Test HAVE_DASH_DASH_NO_UNDEFINED - Success
    -- Running syncqt for module: 'Qt3DLogic' 
    -- Running syncqt for module: 'Qt3DInput' 
    -- Running syncqt for module: 'Qt3DRender' 
    -- Running syncqt for module: 'Qt3DExtras' 
    -- Running syncqt for module: 'Qt3DAnimation' 
    -- Running syncqt for module: 'Qt3DQuick' 
    -- Running syncqt for module: 'Qt3DQuickRender' 
    -- Running syncqt for module: 'Qt3DQuickScene2D' 
    -- Running syncqt for module: 'Qt3DQuickExtras' 
    -- Running syncqt for module: 'Qt3DQuickInput' 
    -- Running syncqt for module: 'Qt3DQuickAnimation' 
    -- Found WrapAssimp: TRUE (Required is at least version "5") 
    -- Performing Test Assimp
    CMake Error in /home/suraj/.conan/data/qt3d/6.0.3/qt/final/build/d8a66a0900136a3d2ac348368a2db5ad95e3a64c/config.tests/assimp/CMakeLists.txt:
      Imported target "WrapAssimp::WrapAssimp" includes non-existent path
    
        "/usr/lib/include"
    
      in its INTERFACE_INCLUDE_DIRECTORIES.  Possible reasons include:
    
      * The path was deleted, renamed, or moved to another location.
    
      * An install or uninstall procedure did not complete successfully.
    
      * The installation package was faulty and references files it does not
      provide.
    
    
    
    CMake Error in /home/suraj/.conan/data/qt3d/6.0.3/qt/final/build/d8a66a0900136a3d2ac348368a2db5ad95e3a64c/config.tests/assimp/CMakeLists.txt:
      Imported target "WrapAssimp::WrapAssimp" includes non-existent path
    
        "/usr/lib/include"
    
      in its INTERFACE_INCLUDE_DIRECTORIES.  Possible reasons include:
    
      * The path was deleted, renamed, or moved to another location.
    
      * An install or uninstall procedure did not complete successfully.
    
      * The installation package was faulty and references files it does not
      provide.
    
    
    
    CMake Error at /home/suraj/Qt/6.0.3/gcc_64/lib/cmake/Qt6/QtFeature.cmake:802 (try_compile):
      Failed to generate test project build system.
    Call Stack (most recent call first):
      src/plugins/sceneparsers/configure.cmake:14 (qt_config_compile_test)
      src/plugins/sceneparsers/CMakeLists.txt:8 (include)
    
    
    -- Configuring incomplete, errors occurred!
    See also "/home/suraj/.conan/data/qt3d/6.0.3/qt/final/build/d8a66a0900136a3d2ac348368a2db5ad95e3a64c/CMakeFiles/CMakeOutput.log".
    See also "/home/suraj/.conan/data/qt3d/6.0.3/qt/final/build/d8a66a0900136a3d2ac348368a2db5ad95e3a64c/CMakeFiles/CMakeError.log".
    qt3d/6.0.3@qt/final: 
    qt3d/6.0.3@qt/final: ERROR: Package 'd8a66a0900136a3d2ac348368a2db5ad95e3a64c' build failed
    qt3d/6.0.3@qt/final: WARN: Build folder /home/suraj/.conan/data/qt3d/6.0.3/qt/final/build/d8a66a0900136a3d2ac348368a2db5ad95e3a64c
    ERROR: qt3d/6.0.3@qt/final: Error in build() method, line 120
    	self.run('%s "%s" %s' % (self._get_qtcmake(), self.source_folder, cmake.command_line))
    	ConanException: Error 1 while executing /home/suraj/Qt/6.0.3/gcc_64/bin/qt-cmake "/home/suraj/.conan/data/qt3d/6.0.3/qt/final/build/d8a66a0900136a3d2ac348368a2db5ad95e3a64c" -G "Unix Makefiles" -DCMAKE_BUILD_TYPE="Release" -DCONAN_IN_LOCAL_CACHE="ON" -DCONAN_COMPILER="gcc" -DCONAN_COMPILER_VERSION="7.5" -DCONAN_CXX_FLAGS="-m64" -DCONAN_SHARED_LINKER_FLAGS="-m64" -DCONAN_C_FLAGS="-m64" -DCONAN_LIBCXX="libstdc++11" -DBUILD_SHARED_LIBS="OFF" -DCMAKE_INSTALL_PREFIX="/home/suraj/.conan/data/qt3d/6.0.3/qt/final/build/d8a66a0900136a3d2ac348368a2db5ad95e3a64c/_install_tmp" -DCMAKE_INSTALL_BINDIR="bin" -DCMAKE_INSTALL_SBINDIR="bin" -DCMAKE_INSTALL_LIBEXECDIR="bin" -DCMAKE_INSTALL_LIBDIR="lib" -DCMAKE_INSTALL_INCLUDEDIR="include" -DCMAKE_INSTALL_OLDINCLUDEDIR="include" -DCMAKE_INSTALL_DATAROOTDIR="share" -DCMAKE_EXPORT_NO_PACKAGE_REGISTRY="ON" -DCONAN_EXPORTED="1" -DCMAKE_VERBOSE_MAKEFILE="ON" -Wno-dev
    
    

    What m I missing?



  • I got the solution to this error. include folder was missing in /usr/lib/.