我在尝试为 Android 编译 Qt 5(在 linux x86_64 上)时遇到此错误:
cc1plus: error: -Werror=literal-suffix: no option -Wliteral-suffix
有人见过它或知道如何解决它吗?
编译器版本是“arm-linux-androideabi-g++ (GCC) 4.7”
发生错误时 make 正在运行的整个编译命令:
/home/triumph/Documents/android-ndk-r8e/toolchains/arm-linux-androideabi-4.7/prebuilt/linux-x86_64/bin/arm-linux-androideabi-g++ -c -Wno-psabi -march=armv7-a -mfloat-abi=softfp -mfpu=vfp -ffunction-sections -funwind-tables -fstack-protector -fno-short-enums -DANDROID -Wa,--noexecstack -std=gnu++0x -Werror -Wno-error=cpp -Wno-error=deprecated-declarations -Wno-error=strict-overflow -Wno-error=literal-suffix -g -g -gdwarf-2 -marm -O0 -fno-omit-frame-pointer -fvisibility=hidden -fvisibility-inlines-hidden -Wall -Wno-psabi -W -D_REENTRANT -fPIC -DQT_NO_PRINTER -DQT_NO_PRINTDIALOG -DQT_NO_LIBUDEV -DQT_NO_XCB -DQT_NO_XKBCOMMON -DQT_NO_USING_NAMESPACE -DQT_BUILD_CORE_LIB -DQT_BUILDING_QT -DQT_NO_CAST_TO_ASCII -DQT_ASCII_CAST_WARNINGS -DQT_MOC_COMPAT -DQT_USE_QSTRINGBUILDER -DQT_DEPRECATED_WARNINGS -DQT_DISABLE_DEPRECATED_BEFORE=0x050000 -DPCRE_HAVE_CONFIG_H -DQT_CORE_LIB -I../../mkspecs/android-g++ -I. -I../../include -I../../include/QtCore -I../../include/QtCore/5.2.0 -I../../include/QtCore/5.2.0/QtCore -Iglobal -I../3rdparty/pcre -I../3rdparty/harfbuzz/src -I../3rdparty/md5 -I../3rdparty/md4 -I../3rdparty/sha3 -I.moc/debug-shared -I/home/triumph/Documents/android-ndk-r8e/sources/cxx-stl/gnu-libstdc++/4.7/include -I/home/triumph/Documents/android-ndk-r8e/sources/cxx-stl/gnu-libstdc++/4.7/libs/armeabi-v7a/include -I/home/triumph/Documents/android-ndk-r8e/platforms/android-9/arch-arm/usr/include -o .obj/debug-shared/qabstractanimation.o animation/qabstractanimation.cpp