0

我最近在 Lubuntu 中安装了 Qt,但出现以下错误

错误显示函数 qNextPowerOfTwo 未在此范围内声明

该函数由文件中包含的 QtMath 库提供。

在此处输入图像描述

这里有什么建议吗?我在 Windows 中有相同的项目,但我没有这样的问题。谢谢你的时间。此致

彼得

PS我附上了.pro文件,问题的相关代码已经在图像中。我正在使用 Qt 5.2.1 (GCC 4.8.2, 32bit)

#-------------------------------------------------
#
# Project created by QtCreator 2016-04-26T18:35:07
#
#-------------------------------------------------

QT       += core gui

greaterThan(QT_MAJOR_VERSION, 4): QT += widgets printsupport

QMAKE_CXXFLAGS += -std=c++0x

TARGET = WaveMod
TEMPLATE = app


SOURCES +=\
    mainwindow.cpp \
trace_ex.cpp \
trace_group_ex.cpp \
qcustomplot.cpp \
main.cpp \
fft_complx.cpp \
geom_ex.cpp


HEADERS  += mainwindow.h \
trace_ex.h \
trace_group_ex.h \
qcustomplot.h \
fft_complx.h \
geom_ex.h \

FORMS    += mainwindow.ui \
trace_ex.ui \
trace_group_ex.ui \
geom_ex.ui

DISTFILES += \
geom_map.qml
4

1 回答 1

0

在它说的函数文档中。

这个函数是在 Qt 5.4 中引入的。

如果您需要该功能,请尝试升级您的 Qt 设置,或查看此处

于 2017-01-28T08:52:28.443 回答