Re: [kln2-devel] Problems installing...using make
Brought to you by:
wiecko
From: Marek W. <mar...@o2...> - 2004-02-17 23:55:28
|
Mo, On Monday 16 February 2004 21:53, Mo wrote: > Not sure if this is a bug or if there is something I can do > help ease the installation process.=20 This part comes from CVoiceControl. Yep, it is written in quite a bad=20 C. And generally C++ is much more strict than C. I changed a few=20 places in the source, but I stopped as soon as things started to work=20 for me. :( Anyway, the places which ended as errors in your case, on my machine=20 just write out warnings. One day, yes, the source will have to be=20 fixed. But for now, I think it would be easier, to let your compiler=20 not to be so touchy. Try '--disable-strict' option of configure. =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D If this does not help, I'm not sure what to do. The command that in my=20 case successfully compiles the voicerecognition.cpp file is if g++ -DHAVE_CONFIG_H -I. -I. -I.. -I/usr/include/kde=20 -I/usr/lib/qt3-gcc2.96/include -I/usr/X11R6/include - DQT_THREAD_SUPPORT -D_REENTRANT -Wnon-virtual-dtor -Wno-long-long=20 -Wundef -Wall -pedantic -W -Wpointer-arith -Wmissing-prototypes -Wwrite-strings -ansi -D_XOPEN_SOURCE=3D500=20 -D_BSD_SOURCE -Wcast-align -Wconversion -Wchar -subscripts -O2 -fno-exceptions -fno-check-new -fno-common -MT=20 voice_recognition.o -MD -MP -MF ".deps/voice_r ecognition.Tpo" \ -c -o voice_recognition.o `test -f 'voice_recognition.cpp' || echo=20 './'`voice_recognition.cpp; \ then mv ".deps/voice_recognition.Tpo" ".deps/voice_recognition.Po"; \ else rm -f ".deps/voice_recognition.Tpo"; exit 1; \ fi How is it different (except from libs/includes locations) from yours? For example: there should NOT be '-pedantic-errors' or '-Werror'=20 options. ~Marek PS. About the lines with errors: voice_recognition.cpp:2467: error: ISO C++ forbids variable-size array=20 ` prefetch_buf' Actually, Mo, I think you have an old version of the source. Get the=20 new one from cvs (it is not much different though). Anyway, in the=20 new version it is line 2566. The problem is fixed by adding 'const'=20 to line 2564; it should look like: const int prefetch_N =3D 5; 2612 and 2637:"`void *' in pointer arithmetic": we have an void* v1=20 pointer and an integer v2 counting how many bytes farther the memcpy=20 should copy some data; the warning is caused by 'v1+v2'. How to move=20 from a void* pointer by few bytes in a decent way? Anybody? Anyway, there are LOTS of other warnings in other parts coming from=20 CVoiceControl, so it will need some work to fix them all. For now, I=20 hope --disable-strict will work. M. --=20 \/ /|\ Marek Wieckowski ##### | | | =3D . . =3D \|/ Institute of Theoretical Physics U | Warsaw University / ~ \___ | <| | | > . < | http://www.fuw.edu.pl/~wiecko <<___>> | http://klearnnotes2.sourceforge.net |