[Bug 232687] New: can't compile "Hello World" with the qt3-library
https://bugzilla.novell.com/show_bug.cgi?id=232687 Summary: can't compile "Hello World" with the qt3-library Product: openSUSE 10.2 Version: Final Platform: x86-64 OS/Version: Other Status: NEW Severity: Blocker Priority: P5 - None Component: Development AssignedTo: pth@novell.com ReportedBy: l.steen@freenet.de QAContact: qa@suse.de Hello Sir or Mam Before I write this I had posted it under: opensuse-programming-de the response were as I sugested: nobody could help me Well, my System is openSuSE 10.2 final x86_64 on a Core2Duo Server. All Patches from Zen- and the Online-Updater were Installed I am trying to learn QT for an idea I have. So, I started Kdevelop and used the Projekt->NewProjekt->C++->q-Make-Projekts->"HelloWorld"-Programm. I finalized the Dialog for the new project and compiled and run the source code. All OK everything was easy because it was Terminal-Program! Now, I wanted to compile a small qt-program. I opened up the Tutorial#1 and started with the example "Hello World". This is the Source-code of the Program(without GNU-preamble) #ifdef HAVE_CONFIG_H #include <config.h> #endif #include <stdio.h> #include <stdlib.h> #include <qapplication.h> #include <qlabel.h> int main(int argc, char* argv[]) { QApplication myApp(argc, argv); QLabel* myLabel = new QLabel("Hello world"); myLabel->resize(80, 30); myApp.setMainWidget(&myLabel); myLabel->show(); return myApp.exec(); } Jepp, that's all so I made a : qmake -project and afterwards a : qmake both finished clear without any prompt. But when I compile the whole(small) program the following message appears: cd '/home/ls/Programmierung/hello4' && QTDIR="/usr/lib/qt3" gmake -j1 clean && QTDIR="/usr/lib/qt3" gmake -j1 rm -f qmake_image_collection.cpp rm -f hello4.o rm -f *~ core *.core g++ -c -m64 -pipe -O2 -Wall -W -D_REENTRANT -DQT_NO_DEBUG -DQT_GUI_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/share/qt4/mkspecs/default -I. -I/usr/include/QtCore -I/usr/include/QtCore -I/usr/include/QtGui -I/usr/include/QtGui -I/usr/include -I. -I. -I. -o hello4.o src/hello4.cpp src/hello4.cpp:40:2: warning: no newline at end of file src/hello4.cpp: In function ‘int main(int, char**)’: src/hello4.cpp:36: error: ‘class QApplication’ has no member named ‘setMainWidget’ gmake: *** [hello4.o] Fehler 1 *** Beendet mit Status: 2 *** Some things to say: The Maschine name is: core the user is : ls the program name is hello4 the rest should be clear to you. So, what the message say's is : The method "setMainWidget" is missing! Why A member of the mailing list mentioned that the setMainWidget is available for qt3 but not for qt4. From this notice I was disturbed and realised that there could be realy a change in the library. So, I went to :/usr/lib/qt3/qapplication.h and looked for a method as named as above described. But I did not found any setMainWidget-method in the qt3 library qapplication.h. Did I do anything wrong? Is there a change to qt4 in the qt3-tree?(couldn't be or?) I did not a installation of the qt4-files - the whole system should be "out of the box" from the installationsource DVD-x86_64 with all patches. What's up? My question is: How can I compile with my actual system the tutorial #1 to learn QT? Oh, well, I am german and would prefer a german answer, if possible because my english is not so good, in other words to say : my english is quite simple - thanks with best regards Lars Steen -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug, or are watching someone who is.
https://bugzilla.novell.com/show_bug.cgi?id=232687 stbinner@novell.com changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |INVALID ------- Comment #1 from stbinner@novell.com 2007-01-08 14:11 MST ------- Dupe of 232650 and still wrong forum. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug, or are watching someone who is.
participants (1)
-
bugzilla_noreply@novell.com