Compile QT/embedded
An error occurred during compilation:
Error 1
/Root/2410 clqt/qt-2.3.2/include/qvaluestack. h: 57: error: the argument '1' of 'int remove (const char *) 'cannot be '1' from 'qvaluelistiterator <qmap <qstring, qstring> 'convert to 'const char *'
/Root/2410 clqt/qt-2.3.2/include/qvaluestack. H: In member function 'tqvaluestack <t >:: POP () [with T = qstring] ':
XML/qxml. cpp: 2502: instantiated from here
/Root/2410 clqt/qt-2.3.2/include/qvaluestack. h: 57: error: the parameter '1' of 'int remove (const char *) 'cannot be converted from 'qvaluelistiterator <qstring>' to 'const char *'
Make [2]: *** [XML/qxml. O] Error 1
Make [2]: Leaving directory '/root/2410 clqt/qt-2.3.2/src'
Make [1]: *** [Sub-Src] Error 2
Make [1]: Leaving directory/root/2410 clqt/qt-2.3.2'
Make: *** [init] Error 2
Solving:
Gedit $ qtdir/include/qvaluestack. H &
Change remove (this-> fromlast (); to this-> remove (this-> fromlast ());
Error2: 'qwsinputmethod' has not been declared
Correction Method:
CD $ qtdir/src/kernel // $ dtdir =/home/opiehome/qt-2.3.10
Gedit qwindowsystem_qws.h
Add the following two lines
Class qwsinputmethod;
Class qwsgesturemethod;
Error:
Kernel/qpixmapcache. cpp: 125: 57: Error: ASM/page. H: No file or directory
In File sorted ded from kernel/qgfx_qws.h: 39,
From kernel/qpixmapcache. cpp: 112:
Kernel/qimage. H: In member function 'int qimagetextkeylang: Operator <(const qimagetextkeylang &) const ':
Kernel/qimage. h: 58: warning: we recommend that you add brackets before and after the & in the | operand
Kernel/qpixmapcache. cpp: In constructor 'qsharedmemorymanager: qsharedmemorymanager ()':
Kernel/qpixmapcache. cpp: 539: Error: 'page _ size' not declared in this scope
Kernel/qpixmapcache. cpp: 539: Error: 'page _ mask' not declared in this scope
Kernel/qpixmapcache. cpp: In member function 'void qsharedmemorymanager: internal_free (qsmemptr )':
Kernel/qpixmapcache. cpp: 773: Error: 'page _ size' not declared in this scope
Kernel/qpixmapcache. cpp: 773: Error: 'page _ mask' not declared in this scope
Make [2]: *** [kernel/qpixmapcache. O] Error 1
Make [2]: Leaving directory '/root/2410 clqt/qt-2.3.10/src'
Make [1]: *** [Sub-Src] Error 2
Make [1]: Leaving directory/root/2410 clqt/qt-2.3.10'
Make: *** [init] Error 2
Solving:
[Root @ localhost kernel] # cp/home/John/Embedded-system/setup-DIR/linux-2.4.21/include/asm-i386/page. h/usr/include/ASM/
Error3
P143
While trying the forth step:
Export qtdir = $ qtedir
Export Path = $ qtedir/bin: $ path
Export LD_LIBRARY_PATH = $ qtedir/lib: $ qt2dir/lib: $ LD_LIBRARY_PATH
[Root @ localhost Launcher] # $ qtedir/bin/qvfb-width 640-height 480
/Root/2410 clqt/qt-2.3.10/bin/qvfb: Error while loading shared libraries: libstdc ++. so.5: cannot open shared object file: no such file or directory
Then:
I try:
[Root @ localhost lib] # pwd
/Usr/lib
[Root @ localhost lib] # ls libstdc ++. So *
Libstdc ++. so.6 libstdc ++. so.6.0.10
There is no libstdc ++. so.5:
So I try to create a link
[Root @ localhost lib] # ln-s libstdc ++. so.6 libstdc ++. so.5
But new problem exist;
[Root @ localhost Launcher] # $ qtedir/bin/qvfb-width 640-height 480
/Root/2410 clqt/qt-2.3.10/bin/qvfb:/usr/lib/libstdc ++. so.5: Version 'glibcpp _ 3.2 'not found (required by/root/2410 clqt/qt-2.3.10/bin/qvfb)
/Root/2410 clqt/qt-2.3.10/bin/qvfb:/usr/lib/libstdc ++. so.5: Version 'cxxabi _ 1.2 'not found (required by/root/2410 clqt/qt-2.3.10/bin/qvfb)
So I download this low version:
Rm/usr/lib/libstdc ++. so.5
Then download: http://mirror.centos.org/centos/4/ OS /i386/CentOS/RPMS/compat-libstdc++-33-3.2.3-47.3.i386.rpm
Reinstall
Rpm-IVH compat-libstdc ++-33-3.2.3-47.3.i386.rpm
Result:
[Root @ localhost lib] # ls libstdc ++. So *
Libstdc ++. so.5.0.7 libstdc ++. so.6 libstdc ++. so.6.0.10
[Root @ localhost lib] # ln-s libstdc ++. so.5.0.7 libstdc ++. so.5
[Root @ localhost lib] #
Now
[Root @ localhost Launcher] # $ qtedir/bin/qvfb-width 640-height 480
OK, virtual frambuffer start successfully
Then, I open a new shell window.
And try to start a example Program
[Root @ localhost John] # Cd ~ /2410 clqt
[Root @ localhost 2410 clqt] # export qtedir = $ PWD/qt-2.3.10
[Root @ localhost 2410 clqt] # cd $ qtedir/examples/Launcher
[Root @ localhost Launcher] #./launcher-qws
Cannot find font definition file/lib/fonts/fontdir-is $ qtdir set correctly?
[Root @ localhost Launcher] #
Now try to solving this new problem
[Root @ localhost Launcher] # export qtdir = $ qtedir
[Root @ localhost Launcher] # export Path = $ qtedir/bin: $ path
[Root @ localhost Launcher] # export LD_LIBRARY_PATH = $ qtedir/lib: $ qt2dir/lib: $ LD_LIBRARY_PATH
[Root @ localhost Launcher] #./launcher-qws
Libpng error: Valid palette required for paletted Images
[Root @ localhost Launcher] #
It works correctly,
But still have an error.
Maybe, following link is associated with this problem, but now, I am too tired to continue my work today.
Http://lists.trolltech.com/qt4-preview-feedback/2005-01/thread00058-0.html
Error 2:
Qvaluestack. h: 57: Error: cannot be converted from 'qvaluelistiterator <qstring> 'to 'const char *'. It is an actual parameter '1' (belonging to 'int remove (const char *)')
Correction Method:
Gedit $ qtdir/include/qvaluestack. H &
Change remove (this-> fromlast (); to this-> remove (this-> fromlast ());
Make has the following problems during build qt2.3.2:
XML/qxml. h: 214: Warning: 'class qxmlreader' has a virtual function but no virtual destructor.
XML/qxml. h: 402: Warning: 'class qxmlcontenthandler' has virtual functions but no virtual destructor
XML/qxml. h: 419: Warning: 'class qxmlerrorhandler' has virtual functions but no virtual destructor
XML/qxml. h: 428: Warning: 'class qxmldtdhandler' has virtual functions but no virtual destructor
XML/qxml. h: 436: Warning: 'class qxmlentityresolver 'has a virtual function but no virtual destructor
XML/qxml. h: 443: Warning: 'class qxmllexicalhandler' has a virtual function but no virtual destructor
XML/qxml. h: 456: Warning: 'class qxmldeclhandler' has virtual functions but no virtual destructor
XML/qxml. cpp: 1518: Warning: Unused parameter 'ret'
/QT/qtx11/include/qvaluestack. H: In member function 'tqvaluestack <t >:: POP () [with T = qmap <qstring, qstring>] ':
XML/qxml. cpp: 513: instantiated from here
/QT/qtx11/include/qvaluestack. h: 57: Error: cannot be converted from 'qvaluelistiterator <qmap <qstring, qstring> 'to 'const char *', is the real parameter '1' (belonging to 'int remove (const char *)')
/QT/qtx11/include/qvaluestack. H: In member function 'tqvaluestack <t>: Pop () [with T = qstring] ':
XML/qxml. cpp: 2502: instantiated from here
/QT/qtx11/include/qvaluestack. h: 57: Error: cannot be converted from 'qvaluelistiterator <qstring> 'to 'const char *'. It is an actual parameter '1' (belonging to 'int remove (const char *)')
Make [2]: *** [XML/qxml. O] Error 1
Make [2]: Leaving directory '/QT/qtx11/src'
Make [1]: *** [Sub-Src] Error 2
Make [1]: Leaving directory '/QT/qtx11'
Make: *** [init] Error 2
Methods for successful compilation:
Change the source code for src/tools/qvaluestack. h 57th lines in the qt-2.3.2 Folder:
Remove (this-> formlast ());
Is:
This-> remove (this-> formlast ());
Use the following statement when configuring configure:
./Configure-debug-no-OpenGL-no-xft
Q2: Make has the following problems during build QT/Embedded:
Error: 'qwsinputmethod' has not been declared
Correction Method:
CD $ qtdir/src/kernel // $ dtdir =/home/opiehome/qt-2.3.10
Gedit qwindowsystem_qws.h
Add the following two lines to the front:
Class qwsinputmethod;
Class qwsgesturemethod;
Q3: When NFS is used, an NFS error occurs when some files in the CP are larger:
NFS: Server *** not responding, still trying
Modification method:
NFS crashes during NFS mount. Mount the NFS as follows:
Mount-T nfs-O intr, nolock, rsize = 1024, wsize = 1024 192.168.1.3/root/somedir/Host
Q4: During the test, "./progressbar-qws" prompts the same as Q3, which should be handled by Q3.
This article from the csdn blog, reproduced please indicate the source: http://blog.csdn.net/dongliqiang2006/archive/2009/07/13/4343122.aspx
Next:
/Home/work/armqt/qtlibsource/temp/qt-2.3.7/include/qsortedlist. h: 51: Error: 'clear' real parameters do not depend on template parameters, so 'clear' Declaration must be available
/Home/work/armqt/qtlibsource/temp/qt-2.3.7/include/qsortedlist. h: 51: Error: (if you use '-fpermission', G ++ will accept your code, but the undefined name is allowed to be outdated)
Solution:
VI Include/qsortedlist. h
The row 51st is modified as follows:
~ Qsortedlist () {clear ();} -- à ~ Qsortedlist () {This-> clear ();}
Next: the error is returned here.
Kernel/qwindowsystem_qws.cpp: 1810: Error: Comparison between distinct pointer types 'qwsserver: wsinputmethod * 'and 'qwsinputmethod *' lacks a cast
Kernel/qwindowsystem_qws.cpp: 1812: Error: cannot convert 'qwsserver: wsinputmethod * 'to 'qwsinputmethod *' in assignment
Static qwsinputmethod * current_im = 0; // current_im Definition
Void qwsserver: setcurrentinputmethod (qwsinputmethod * IM)
{
If (current_im_state! = Imend & (qwsinputmethod *) Im! = Current_im & qwsserver) // 1810 rows
Qwsserver-> sendimevent (imend, "",-1, 0 );
Current_im = (qwsinputmethod *) im; // 1812 rows
}
I think it should be a C ++ syntax problem. I cannot convert the (qwsinputmethod *) method to the IM type. How can I modify it? No one has ever met it?