barry-ran / QtScrcpy

Android real-time display control software

Home Page:https://blog.csdn.net/rankun1/article/details/87970523

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

作者提供的版本真的能编译嘛

itimetime opened this issue · comments

成功了

In file included from /home/user/Qt/5.15.2/gcc_64/include/QtCore/QPointer:1, from /home/user/software/QtScrcpy-2.1.2/QtScrcpy/QtScrcpyCore/src/devicemanage/../../include/QtScrcpyCore.h:2, from /home/user/software/QtScrcpy-2.1.2/QtScrcpy/QtScrcpyCore/src/devicemanage/devicemanage.h:6, from /home/user/software/QtScrcpy-2.1.2/QtScrcpy/QtScrcpyCore/src/devicemanage/devicemanage.cpp:6: /home/user/Qt/5.15.2/gcc_64/include/QtCore/qpointer.h: In instantiation of ‘QPointer<T>::QPointer(T*) [with T = VideoSocket]’: /home/user/software/QtScrcpy-2.1.2/QtScrcpy/QtScrcpyCore/src/device/demuxer/demuxer.h:44:43: required from here /home/user/Qt/5.15.2/gcc_64/include/QtCore/qpointer.h:62:29: error: no matching function for call to ‘QWeakPointer<QObject>::QWeakPointer(VideoSocket*&, bool)’ 62 | inline QPointer(T *p) : wp(p, true) { } | ^~~~~~~~~~~ In file included from /home/user/Qt/5.15.2/gcc_64/include/QtCore/qsharedpointer.h:48, from /home/user/Qt/5.15.2/gcc_64/include/QtCore/qdebug.h:54, from /home/user/Qt/5.15.2/gcc_64/include/QtCore/QDebug:1, from /home/user/software/QtScrcpy-2.1.2/QtScrcpy/QtScrcpyCore/src/devicemanage/devicemanage.cpp:1: /home/user/Qt/5.15.2/gcc_64/include/QtCore/qsharedpointer_impl.h:679:12: note: candidate: ‘template<class X, typename std::enable_if<std::is_convertible<_Up*, QObject*>::value, bool>::type <anonymous> > QWeakPointer<T>::QWeakPointer(X*, bool) [with X = X; typename std::enable_if<std::is_convertible<_Up*, _Tp*>::value, bool>::type <anonymous> = <anonymous>; T = QObject]’ 679 | inline QWeakPointer(X *ptr, bool) : d(ptr ? Data::getAndRef(ptr) : nullptr), value(ptr) | ^~~~~~~~~~~~ /home/user/Qt/5.15.2/gcc_64/include/QtCore/qsharedpointer_impl.h:679:12: note: template argument deduction/substitution failed: /home/user/Qt/5.15.2/gcc_64/include/QtCore/qsharedpointer_impl.h:678:42: error: no type named ‘type’ in ‘struct std::enable_if<false, bool>’ 678 | template <class X, IfCompatible<X> = true> | ^~~~ /home/user/Qt/5.15.2/gcc_64/include/QtCore/qsharedpointer_impl.h:636:12: note: candidate: ‘template<class X, typename std::enable_if<std::is_convertible<_Up*, QObject*>::value, bool>::type <anonymous> > QWeakPointer<T>::QWeakPointer(const QSharedPointer<X>&) [with X = X; typename std::enable_if<std::is_convertible<_Up*, _Tp*>::value, bool>::type <anonymous> = <anonymous>; T = QObject]’ 636 | inline QWeakPointer(const QSharedPointer<X> &o) : d(nullptr), value(nullptr) | ^~~~~~~~~~~~ /home/user/Qt/5.15.2/gcc_64/include/QtCore/qsharedpointer_impl.h:636:12: note: template argument deduction/substitution failed: In file included from /home/user/Qt/5.15.2/gcc_64/include/QtCore/QPointer:1, from /home/user/software/QtScrcpy-2.1.2/QtScrcpy/QtScrcpyCore/src/devicemanage/../../include/QtScrcpyCore.h:2, from /home/user/software/QtScrcpy-2.1.2/QtScrcpy/QtScrcpyCore/src/devicemanage/devicemanage.h:6, from /home/user/software/QtScrcpy-2.1.2/QtScrcpy/QtScrcpyCore/src/devicemanage/devicemanage.cpp:6: /home/user/Qt/5.15.2/gcc_64/include/QtCore/qpointer.h:62:29: note: mismatched types ‘const QSharedPointer<T>’ and ‘VideoSocket*’ 62 | inline QPointer(T *p) : wp(p, true) { } | ^~~~~~~~~~~ In file included from /home/user/Qt/5.15.2/gcc_64/include/QtCore/qsharedpointer.h:48, from /home/user/Qt/5.15.2/gcc_64/include/QtCore/qdebug.h:54, from /home/user/Qt/5.15.2/gcc_64/include/QtCore/QDebug:1, from /home/user/software/QtScrcpy-2.1.2/QtScrcpy/QtScrcpyCore/src/devicemanage/devicemanage.cpp:1: /home/user/Qt/5.15.2/gcc_64/include/QtCore/qsharedpointer_impl.h:615:12: note: candidate: ‘template<class X, typename std::enable_if<std::is_convertible<_Up*, QObject*>::value, bool>::type <anonymous> > QWeakPointer<T>::QWeakPointer(const QWeakPointer<X>&) [with X = X; typename std::enable_if<std::is_convertible<_Up*, _Tp*>::value, bool>::type <anonymous> = <anonymous>; T = QObject]’ 615 | inline QWeakPointer(const QWeakPointer<X> &o) : d(nullptr), value(nullptr) | ^~~~~~~~~~~~ /home/user/Qt/5.15.2/gcc_64/include/QtCore/qsharedpointer_impl.h:615:12: note: template argument deduction/substitution failed: In file included from /home/user/Qt/5.15.2/gcc_64/include/QtCore/QPointer:1, from /home/user/software/QtScrcpy-2.1.2/QtScrcpy/QtScrcpyCore/src/devicemanage/../../include/QtScrcpyCore.h:2, from /home/user/software/QtScrcpy-2.1.2/QtScrcpy/QtScrcpyCore/src/devicemanage/devicemanage.h:6, from /home/user/software/QtScrcpy-2.1.2/QtScrcpy/QtScrcpyCore/src/devicemanage/devicemanage.cpp:6: /home/user/Qt/5.15.2/gcc_64/include/QtCore/qpointer.h:62:29: note: mismatched types ‘const QWeakPointer<T>’ and ‘VideoSocket*’ 62 | inline QPointer(T *p) : wp(p, true) { } | ^~~~~~~~~~~ In file included from /home/user/Qt/5.15.2/gcc_64/include/QtCore/qsharedpointer.h:48, from /home/user/Qt/5.15.2/gcc_64/include/QtCore/qdebug.h:54, from /home/user/Qt/5.15.2/gcc_64/include/QtCore/QDebug:1, from /home/user/software/QtScrcpy-2.1.2/QtScrcpy/QtScrcpyCore/src/devicemanage/devicemanage.cpp:1: /home/user/Qt/5.15.2/gcc_64/include/QtCore/qsharedpointer_impl.h:606:12: note: candidate: ‘QWeakPointer<T>::QWeakPointer(const QSharedPointer<T>&) [with T = QObject]’ 606 | inline QWeakPointer(const QSharedPointer<T> &o) : d(o.d), value(o.data()) | ^~~~~~~~~~~~ /home/user/Qt/5.15.2/gcc_64/include/QtCore/qsharedpointer_impl.h:606:12: note: candidate expects 1 argument, 2 provided /home/user/Qt/5.15.2/gcc_64/include/QtCore/qsharedpointer_impl.h:585:5: note: candidate: ‘QWeakPointer<T>::QWeakPointer(QWeakPointer<T>&&) [with T = QObject]’ 585 | QWeakPointer(QWeakPointer &&other) noexcept | ^~~~~~~~~~~~ /home/user/Qt/5.15.2/gcc_64/include/QtCore/qsharedpointer_impl.h:585:5: note: candidate expects 1 argument, 2 provided /home/user/Qt/5.15.2/gcc_64/include/QtCore/qsharedpointer_impl.h:583:5: note: candidate: ‘QWeakPointer<T>::QWeakPointer(const QWeakPointer<T>&) [with T = QObject]’ 583 | QWeakPointer(const QWeakPointer &other) noexcept : d(other.d), value(other.value) | ^~~~~~~~~~~~ /home/user/Qt/5.15.2/gcc_64/include/QtCore/qsharedpointer_impl.h:583:5: note: candidate expects 1 argument, 2 provided /home/user/Qt/5.15.2/gcc_64/include/QtCore/qsharedpointer_impl.h:565:12: note: candidate: ‘QWeakPointer<T>::QWeakPointer() [with T = QObject]’ 565 | inline QWeakPointer() noexcept : d(nullptr), value(nullptr) { } | ^~~~~~~~~~~~ /home/user/Qt/5.15.2/gcc_64/include/QtCore/qsharedpointer_impl.h:565:12: note: candidate expects 0 arguments, 2 provided cc1plus: note: unrecognized command-line option ‘-Wno-c++17-extensions’ may have been intended to silence earlier diagnostics cc1plus: note: unrecognized command-line option ‘-Wno-nested-anon-types’ may have been intended to silence earlier diagnostics gmake[2]: *** [QtScrcpy/QtScrcpyCore/CMakeFiles/QtScrcpyCore.dir/build.make:398:QtScrcpy/QtScrcpyCore/CMakeFiles/QtScrcpyCore.dir/src/devicemanage/devicemanage.cpp.o] 错误 1 gmake[1]: *** [CMakeFiles/Makefile2:170:QtScrcpy/QtScrcpyCore/CMakeFiles/QtScrcpyCore.dir/all] 错误 2 gmake: *** [Makefile:91:all] 错误 2 error: CMake build failed, exiting......

成功了

最后是怎么解决的啊?我编译也遇到了好几种报错

成功了

最后是怎么解决的啊?我编译也遇到了好几种报错

更新下:我也构建成功了,最后用的QT5.15+MSVC2019