I'm working on an IOS/android app built with QtCreator. For Android, I need both 32 and 64 bit versions of the APK to be able to upload it to the Playstore. My 32 bit version works perfectly fine but my 64bit version doesn't save any configuration. I'm using Qsettings to create a .conf file. When I do it with the 32 bit application I can easily find my .conf file wherever I create it but with my 64bit version, the folder remains empty. I checked and I'm able to create folders and files on the same folder that I'm using for my .conf file so it doesn't seem to be a permission issue. Does anyone knows if Qsettings need something special to be able to write file for 64bit applications ? I've read the doc (https://doc.qt.io/qt-5/qsettings.html) but wasn't able to find any information.
QSettings::setPath(QSettings::NativeFormat,QSettings::UserScope,QStandardPaths::writableLocation(QStandardPaths::StandardLocation::GenericDataLocation) + "/private");
QSettings settings("Settings", "test");
settings.setValue("test", "text");
settings.sync();
I finally found my answer. I was using an older version of Qt (5.10) and there is a bug (https://bugreports.qt.io/browse/QTBUG-68344) that affect QSettings. If you are in this situation, an easy fix is to rebuild Qt with that argument for the configure command :
-no-feature-linkat