Description of problem: Building sqliteman in rawhide fails: /usr/bin/c++ -DQT_GUI_LIB -DQT_XML_LIB -DQT_SQL_LIB -DQT_CORE_LIB -DQT_NO_DEBUG -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ss\ p-buffer-size=4 -m64 -mtune=generic -O2 -Wall -I/usr/include/QtGui -I/usr/include/QtXml -I/usr/include/QtSql -I/usr/include/QtCore -I/rpm/BUILD/sqliteman-1.2.1 -I/rp\ m/BUILD/sqliteman-1.2.1/sqliteman -I/rpm/BUILD/sqliteman-1.2.1/sqliteman/. -I/rpm/BUILD/sqliteman-1.2.1/sqliteman/qscintilla2/Qt4 -I/rpm/BUILD/sqliteman-1.2.1/sqlitem\ an/qscintilla2/Qt4/Qsci -DTRANSLATION_DIR=\"/usr/share/sqliteman/\" -DDOC_DIR=\"/usr/share/sqliteman/doc/\" -DICON_DIR=\"/usr/share/sqliteman/icons\" -DSQLITE_BINAR\ Y=\"sqlite3\" -DSQLITEMAN_VERSION=\"1.2.1\" -o CMakeFiles/sqliteman.dir/altertabledialog.o -c /rpm/BUILD/sqliteman-1.2.1/sqliteman/altertabledialog.cpp /rpm/BUILD/sqliteman-1.2.1/sqliteman/altertabledialog.cpp: In member function 'virtual void AlterTableDialog::createButton_clicked()': /rpm/BUILD/sqliteman-1.2.1/sqliteman/altertabledialog.cpp:164: error: call of overloaded 'QString(int)' is ambiguous /usr/include/QtCore/qstring.h:427: note: candidates are: QString::QString(const QByteArray&) /usr/include/QtCore/qstring.h:425: note: QString::QString(const char*) /usr/include/QtCore/qstring.h:726: note: QString::QString(const QString&) /usr/include/QtCore/qstring.h:106: note: QString::QString(QChar) /usr/include/QtCore/qstring.h:105: note: QString::QString(const QChar*) make[2]: *** [sqliteman/CMakeFiles/sqliteman.dir/altertabledialog.o] Error 1 Also see bug #599939 Sources in altertabledialog.cpp: void AlterTableDialog::createButton_clicked() { ui.resultEdit->clear(); // rename table if it's required if (!renameTable()) return; // drop columns first // if (m_dropColumns > 0) { QStringList existingObjects = Database::getObjects().keys(); // <---- Line 164 is here // indexes and triggers on the original table QStringList originalSrc = originalSource(); It builds just fine in Fedora 7 -> Fedora 13, seems like some changes in Qt 4.7 broke it. Any ideas?
sqliteman will require patching to remove any instances of ambiguous QString(0), which was silently accepted with < qt-4.7
I take that back, not just 0, any instance of QString(foo), where foo is of type int.
That was my fear :-) Thanks for the quick response!
Actually, QString(non-0 integer) was never accepted. 0 is special in C++, it can be silently converted to any pointer type. QString(0) was previously interpreted as QString((char*)0). Now there's also a QString(QChar *), so now it's ambiguous. But since QString((char*)0) is the same and less efficient as just QString(), the best fix is to just remove the 0.
(Actually, it's const char * and const QChar *.)
Created attachment 424566 [details] Patch to make SQLiteman build against Qt 4.7 I made a patch, but the SQLiteman Bugtracker won't let me register, so I'm posting it here... This patch is against trunk, but it also applies to the stable version (1.2.1).
I have pushed the fix to rawhide and updated the SQLiteman Bugtracker with relevant information. Thank you very much Alec!
hi guys, I'm the author of Sqliteman. At first - I'd like to thank you for your investigation (and patch of course). Trunk and 1.2.x branch are patched and it's working. I did a new release - 1.2.2. It contains fixes for: #146: Views with spaces in name are not displayed correctly #163: sqliteman 1.2.1 don't build with qt 4.7 source tarballs are located at sourceforge. Some binary packages for Suse and Fedora are already prebuilt in OpenSuse's build service: http://download.opensuse.org/repositories/home:/subik/ spec file is in the SVN in Packagers directory (if you are interested). Please contact me again when you will face another issues. at last - I do apologise for so much delayed reaction. Sqliteman is not my main project and I don't monitor its bugtracker daily (yes, e-mail notifications were broken). all the best, Petr