升级系统后Qt无法使用qDebug()输出
Tofloor
poster avatar
GavinLiu
deepin
2020-11-19 03:33
Author

这两天有更新系统后,突然发现Qt无法使用qDebug()输出,只能使用qWarning

已经重装qt,未能解决,现在还在用qWarning调试,求大佬支招。

几种解决方式都试过了

https://blog.csdn.net/qq_30441219/article/details/79050376

Reply Favorite View the author
All Replies
Hello
deepin
2020-11-19 03:57
#1

我用的官方的5.15,不是仓库的5.11,发生了什么我不知道,我到没怎么用qdebug,从来是用std::cout的2333,因为qdebug太多问题了

Reply View the author
Hello
deepin
2020-11-19 03:59
#2

先帮你mark一下,不过我很不了解qdebug到底有什么用,std::cout性能还比qdebug好

Reply View the author
GavinLiu
deepin
2020-11-19 04:47
#3
Hello

我用的官方的5.15,不是仓库的5.11,发生了什么我不知道,我到没怎么用qdebug,从来是用std::cout的2333,因为qdebug太多问题了

我是用到官方5.15的版本,主要是qml的consle.log()也不能用了

Reply View the author
jzc
deepin
2020-11-19 05:02
#4

难道新版的qDebug只能在调试模式下使用? 试试 qInfo() <<  

Reply View the author
GavinLiu
deepin
2020-11-19 05:10
#5
jzc

难道新版的qDebug只能在调试模式下使用? 试试 qInfo() <<  

调试模式也没反应,qInfo/ qWarning/qCritical/qFatal还能用[衰]

Reply View the author
GavinLiu
deepin
2020-11-19 05:15
#6

建议遇到相同问题的兄弟,qml文件中使用 console.info,c++中用其他几个代替,还能接着用,不用重装系统,谢谢前面几位大佬指点

Reply View the author
Maicss
deepin
2020-11-19 06:28
#7

我也这种情况,还以为是个例呢

Reply View the author
海天鹰
deepin
2020-11-19 07:09
#8

已经验证是真的,前几天就觉得怪怪的。

Reply View the author
Hello
deepin
2020-11-19 07:29
#9

可以先用标准库顶一下,或者自己写一个宏,已经确认是bug

Reply View the author
houyawei
deepin
2020-12-18 23:09
#10

我也有这个问题,看来只能等修复的,各种方法都试了

Reply View the author
h1007886499
deepin
2021-01-16 21:32
#11

请问大家有没有解决方法呢 

 

Reply View the author
走钢丝
deepin
2021-01-16 21:40
#12
h1007886499

请问大家有没有解决方法呢 

 

木有解决。可能 deepin 编译的包有问题。

 

Reply View the author
deepinnist
deepin
2021-01-19 18:27
#13

用着真难受,不知道啥时候能解决

 

 

Reply View the author
deepinnist
deepin
2021-03-23 23:46
#14

终于找到解决办法了

https://www.qedev.com/linux/339315.html

用管理员身份打开/etc/X11/Xsession.d/00deepin-dde-env,用#注释QT_LOGGING_RULES="*.debug=false",然后注销。

Reply View the author