[Interest] Qt6 porting guidance: (MSDEV) QMAKE_CXXFLAGS += /source-charset

Thiago Macieira thiago.macieira at intel.com
Fri Jul 9 21:15:04 CEST 2021


On Friday, 9 July 2021 00:49:53 PDT Alexandru Croitor wrote:
> I think adding
> 
> CONFIG += no_utf8_source
> 
> to your qmake project should help.

Please note that you can choose to use a different source character set, but 
since Qt 5.0, the 8-bit strings passed to QString must be UTF-8. This is not 
configurable any more, like it used to be.

Moreover, since 6.0, the locale character set on Unix systems must also be 
UTF-8. You'll get a warning from QCoreApplication if it isn't, then it'll 
forcibly change the locale to one with UTF-8.

-- 
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel DPG Cloud Engineering





More information about the Interest mailing list