Author Topic: QT "Compiler Setup" worked before. Why not now?  (Read 4608 times)

ClintReese

  • Jr. Member
  • **
  • Posts: 69
    • View Profile
QT "Compiler Setup" worked before. Why not now?
« on: March 30, 2004, 09:50:26 am »
Hi.

History:
First, I followed the directions at this group for \"Compiler Setup\" under development how-to\'s on one of my PCs.  With some time, effort, and help from other Linux users, they worked.  It compiled the example application for the x86 and the arm.  They both worked.  The arm one worked on the Z.  Then,  I struggled with getting Linux connectivity set up.  In the process, I recompiled so many kernels and reinstalled the OS so many times that I removed my old QT compiler setup.  \"That\'s ok,\" I thought.  \"I\'ve recorded exactly what I did.\"  With help from people on this group, my Linux connectivity now works.

However, when I do what I did the first time to get the compiler set up, it doesn\'t work this time.  I\'ve tried reinstalling the original OS I used and following the instructions 3 times.  I seem to keep getting the same errors.  Here are the steps I performed, copied from my screen:

[clint@localhost gcc2.95.3]$ su
Password:
[root@localhost gcc2.95.3]# rpm -U --oldpackage cpp-2.95.3.1owl.i386.rpm
error: open of cpp-2.95.3.1owl.i386.rpm failed: No such file or directory
[root@localhost gcc2.95.3]# rpm -U --oldpackage cpp-2.95.3-1owl.i386.rpm
error: Failed dependencies:
        cpp = 3.2.2-5 is needed by (installed) gcc-3.2.2-5
        /usr/bin/cpp is needed by (installed) XFree86-4.3.0-2
[root@localhost gcc2.95.3]# cd /setup
bash: cd: /setup: No such file or directory
[root@localhost gcc2.95.3]# cd /home/clint/setup
[root@localhost setup]# ls
compiler  connectivity  gcc2.95.1-3  gcc2.95.3  terminal
[root@localhost setup]# cd gcc 2.95.1-3
bash: cd: gcc: No such file or directory
[root@localhost setup]# cd gcc2.95.1-3
[root@localhost gcc2.95.1-3]# ls
cpp-2.95.1-3.i386.rpm  gcc-2.95.1-3.i386.rpm
[root@localhost gcc2.95.1-3]# rpm -U --oldpackage cpp-2.95.1.1-3.i386.rpm
error: open of cpp-2.95.1.1-3.i386.rpm failed: No such file or directory
[root@localhost gcc2.95.1-3]# rpm -U --oldpackage cpp-2.95.1-3.i386.rpm
[root@localhost gcc2.95.1-3]# rpm -U --oldpackage gcc-2.95.1-3.i386.rpm
[root@localhost gcc2.95.1-3]# cd /home/clint/support
bash: cd: /home/clint/support: No such file or directory
[root@localhost gcc2.95.1-3]# cd /home/clint/
[root@localhost clint]# ls
setup
[root@localhost clint]# cd setup
[root@localhost setup]# ls
compiler  connectivity  gcc2.95.1-3  gcc2.95.3  terminal
[root@localhost setup]# cd compiler
[root@localhost compiler]# ls
binutils-cross-arm-2.11.2-0.i386.rpm  gcc-cross-sa1100-2.95.2-0.i386.rpm         qtopia-free-1.5.0-1.i386.rpm
dev-arm-qpe.sh                        glibc-arm-2.2.2-0.i386.rpm
dev-x86-qpe.sh                        linux-headers-arm-sa1100-2.4.6-3.i386.rpm
[root@localhost compiler]# rpm -Uvh gcc-cross-sa1100-2.95.2-0.i386.rpm
Preparing...                ########################################### [100%]
   1:gcc-cross-sa1100       ########################################### [100%]
[root@localhost compiler]# rpm -Uvh binutils-cross-arm-2.11.2-0.i386.rpm
Preparing...                ########################################### [100%]
   1:binutils-cross-arm     ########################################### [100%]
[root@localhost compiler]# rpm -Uvh glibc-arm-2.2.2-0.i386.rpm
Preparing...                ########################################### [100%]
   1:glibc-arm              ########################################### [100%]
[root@localhost compiler]# rpm -Uvh linux-headers-arm-sa1100-2.4.6-3.i386.rpm
Preparing...                ########################################### [100%]
   1:linux-headers-arm-sa110########################################### [100%]
[root@localhost compiler]# rpm -Uvh qtopia-free-1.5.0-1.i386.rpm
Preparing...                ########################################### [100%]
   1:qtopia-free            ########################################### [100%]
[root@localhost compiler]# cd /home/clint/setup
[root@localhost setup]# ls
compiler  connectivity  gcc2.95.1-3  gcc2.95.3  terminal
[root@localhost setup]# cd compiler
[root@localhost compiler]# ls
binutils-cross-arm-2.11.2-0.i386.rpm  gcc-cross-sa1100-2.95.2-0.i386.rpm         qtopia-free-1.5.0-1.i386.rpm
dev-arm-qpe.sh                        glibc-arm-2.2.2-0.i386.rpm
dev-x86-qpe.sh                        linux-headers-arm-sa1100-2.4.6-3.i386.rpm
[root@localhost compiler]# mv dev-arm-qpe.sh /home
[root@localhost compiler]# mv dev-x86-qpe.sh /home
[root@localhost compiler]# cd /home
[root@localhost home]# ls
clint  dev-arm-qpe.sh  dev-x86-qpe.sh
[root@localhost home]# source dev-x86-qpe.sh
Altered environment for Sharp Zaurus Development x86
[root@localhost home]# cp -r /opt/Qtopia/example /home
[root@localhost home]# cd
[root@localhost root]# cd /home
[root@localhost home]# ls
clint  dev-arm-qpe.sh  dev-x86-qpe.sh  example
[root@localhost home]# cd example
[root@localhost example]# ls
examplebase.ui  example.control  example.cpp  example.desktop  example.h  example.html  Example.png  example.pro  main.cpp
[root@localhost example]# rm Makefile
rm: cannot lstat `Makefile\': No such file or directory
[root@localhost example]# make clean
make: *** No rule to make target `clean\'.  Stop.
[root@localhost example]# tmake -o Makefile example.pro
[root@localhost example]# make
/opt/Qtopia/bin/uic examplebase.ui -o ./examplebase.h
g++ -c -pipe -DQWS -fno-exceptions -fno-rtti -Wall -W -O2 -fno-default-inline -DNO_DEBUG -I/opt/Qtopia/include -I/opt/Qtopia/include -o main.o main.cpp
In file included from /opt/Qtopia/include/qcstring.h:50,
                 from /opt/Qtopia/include/qstring.h:43,
                 from /opt/Qtopia/include/qvariant.h:42,
                 from examplebase.h:12,
                 from example.h:3,
                 from main.cpp:1:
/usr/include/string.h:33:20: stddef.h: No such file or directory
In file included from /opt/Qtopia/include/qcstring.h:50,
                 from /opt/Qtopia/include/qstring.h:43,
                 from /opt/Qtopia/include/qvariant.h:42,
                 from examplebase.h:12,
                 from example.h:3,
                 from main.cpp:1:
/usr/include/string.h:39: type specifier omitted for parameter `size_t\'
/usr/include/string.h:39: parse error before `)\' token
/usr/include/string.h:42: type specifier omitted for parameter `size_t\'
/usr/include/string.h:42: parse error before `)\' token
/usr/include/string.h:51: type specifier omitted for parameter `size_t\'
/usr/include/string.h:51: parse error before `)\' token
/usr/include/string.h:58: type specifier omitted for parameter `size_t\'
/usr/include/string.h:58: parse error before `)\' token
/usr/include/string.h:61: type specifier omitted for parameter `size_t\'
/usr/include/string.h:61: parse error before `)\' token
/usr/include/string.h:65: type specifier omitted for parameter `size_t\'
/usr/include/string.h:65: parse error before `)\' token
/usr/include/string.h:75: type specifier omitted for parameter `size_t\'
/usr/include/string.h:75: parse error before `)\' token
/usr/include/string.h:86: type specifier omitted for parameter `size_t\'
/usr/include/string.h:86: parse error before `)\' token
/usr/include/string.h:93: type specifier omitted for parameter `size_t\'
/usr/include/string.h:93: parse error before `)\' token
/usr/include/string.h:99: type specifier omitted for parameter `size_t\'
/usr/include/string.h:99: parse error before `)\' token
/usr/include/string.h:106: syntax error before `(\' token
In file included from /opt/Qtopia/include/qcstring.h:50,
                 from /opt/Qtopia/include/qstring.h:43,
                 from /opt/Qtopia/include/qvariant.h:42,
                 from examplebase.h:12,
                 from example.h:3,
                 from main.cpp:1:
/usr/include/string.h:120: syntax error before `(\' token
/usr/include/string.h:133: type specifier omitted for parameter `size_t\'
/usr/include/string.h:133: parse error before `)\' token
/usr/include/string.h:176: syntax error before `(\' token
/usr/include/string.h:180: syntax error before `(\' token
/usr/include/string.h:215: type specifier omitted for parameter `size_t\'
/usr/include/string.h:215: parse error before `,\' token
/usr/include/string.h:222: type specifier omitted for parameter `size_t\'
/usr/include/string.h:222: parse error before `)\' token
/usr/include/string.h:224: type specifier omitted for parameter `size_t\'
/usr/include/string.h:224: parse error before `)\' token
/usr/include/string.h:230: syntax error before `(\' token
/usr/include/string.h:236: syntax error before `(\' token
/usr/include/string.h:248: type specifier omitted for parameter `size_t\'
/usr/include/string.h:248: parse error before `)\' token
/usr/include/string.h:253: type specifier omitted for parameter `size_t\'
/usr/include/string.h:253: parse error before `)\' token
/usr/include/string.h:257: type specifier omitted for parameter `size_t\'
/usr/include/string.h:257: parse error before `)\' token
/usr/include/string.h:260: type specifier omitted for parameter `size_t\'
/usr/include/string.h:260: parse error before `)\' token
/usr/include/string.h:263: type specifier omitted for parameter `size_t\'
/usr/include/string.h:263: parse error before `)\' token
/usr/include/string.h:291: type specifier omitted for parameter `size_t\'
/usr/include/string.h:291: parse error before `)\' token
/usr/include/string.h:302: type specifier omitted for parameter `size_t\'
/usr/include/string.h:302: parse error before `,\' token
/usr/include/string.h:330: type specifier omitted for parameter `size_t\'
/usr/include/string.h:330: parse error before `)\' token
/usr/include/string.h:332: type specifier omitted for parameter `size_t\'
/usr/include/string.h:332: parse error before `)\' token
/usr/include/string.h:338: type specifier omitted for parameter `size_t\'
/usr/include/string.h:338: parse error before `)\' token
In file included from /opt/Qtopia/include/qstring.h:43,
                 from /opt/Qtopia/include/qvariant.h:42,
                 from examplebase.h:12,
                 from example.h:3,
                 from main.cpp:1:
/opt/Qtopia/include/qcstring.h: In function `uint cstrlen(const char*)\':
/opt/Qtopia/include/qcstring.h:87: `strlen\' undeclared (first use this
   function)
/opt/Qtopia/include/qcstring.h:87: (Each undeclared identifier is reported only
   once for each function it appears in.)
In file included from /opt/Qtopia/include/qwindowdefs.h:48,
                 from /opt/Qtopia/include/qwidget.h:42,
                 from examplebase.h:13,
                 from example.h:3,
                 from main.cpp:1:
/usr/include/limits.h:124:26: no include path in which to find limits.h
make: *** [main.o] Error 1

OK, QT people, what did I not do these 3 times that I did the first time that I got it working?  It worked before.  These error messages indicate to me that the string.h header file can\'t be found, but you can see where redhat told me that the header file packages were installed.  What is going on here?

My first thought is to give up on buying QT and try Squeak, but I don\'t know if Squeak will work in real-time.

Any ideas, anyone?

Clint Reese
Clint Reese
C.H.E.I.F. - Cyborgs Having & Encouraging Individual Freedom
http://books.lulu.com/content/70176
Yahoo ID: justphilanthrope

ClintReese

  • Jr. Member
  • **
  • Posts: 69
    • View Profile
QT "Compiler Setup" worked before. Why not now?
« Reply #1 on: March 30, 2004, 10:08:09 am »
I neglected to mention my distribution and system information.  The OS which I reinstalled 3 times was Red Hat 9.  I got the CD\'s from \"The Red Hat 9 Bible.\"

System information (with IP address erased):

[clint@xxxxxxxxxx clint]$ uname -a
Linux xxxxxxxxxx.com 2.4.20-8 #1 Thu Mar 13 17:18:24 EST 2003
i686 athlon i386 GNU/Linux
Clint Reese
C.H.E.I.F. - Cyborgs Having & Encouraging Individual Freedom
http://books.lulu.com/content/70176
Yahoo ID: justphilanthrope

lardman

  • Hero Member
  • *****
  • Posts: 4512
    • View Profile
    • http://people.bath.ac.uk/enpsgp/Zaurus/
QT "Compiler Setup" worked before. Why not now?
« Reply #2 on: March 30, 2004, 10:14:12 am »
Firstly, why are you running as root (other than for rpm)? Sounds dangerous to me.... anyway onwards:

Looks like this is the problem you\'re having with your x86 build

] stddef.h: No such file or directory

Possibly because you can\'t install the native version of GCC 2.95. I don\'t know how to make this work, sorry, I don\'t ever compile stuff for x86 so I\'m not sure I even have a native GCC 2.95.

Try cross compiling the same thing and see whether that works. BTW you can\'t run \'make clean\' if the Makefile doesn\'t still exist to tell \'make\' what to do for \'clean\'.

Simon
C750 OZ3.5.4 (GPE, 2.6.x kernel)
SL5500 OZ3.5.4 (Opie)
Nokia 770
Serial GPS, WCF-12, Socket Ethernet & BT, Ratoc USB
WinXP, Mandriva

ClintReese

  • Jr. Member
  • **
  • Posts: 69
    • View Profile
QT "Compiler Setup" worked before. Why not now?
« Reply #3 on: March 30, 2004, 10:40:57 am »
Quote from: \"lardman\"
Firstly, why are you running as root (other than for rpm)? Sounds dangerous to me.... anyway onwards:
/quote]

Thanks for the reply.  

I\'m running as root because I just reinstalled the OS 3 times, and typed what you see in the post.  If I corrupted the system by typing something wrong in the post, I\'ll just reinstall the OS again.  I didn\'t want the screen littered with \"permission denied\" when I posted.  Thanks for the concern.

Quote

Looks like this is the problem you\'re having with your x86 build

] stddef.h: No such file or directory

That\'s what it looked like to me too.

Quote

Possibly because you can\'t install the native version of GCC 2.95.

These dependencies for GCC are interesting, aren\'t they?  Red Hat 9 ships with a version of GCC which supposedly won\'t work with the QT cross compiler.  So, I just searched the internet for RPMs.  The installed RPM\'s worked before, I think.  Maybe I should just download the sources from GNU and learn how to install it manually?

Quote from: \"lardman\"

 I don\'t know how to make this work, sorry, I don\'t ever compile stuff for x86 so I\'m not sure I even have a native GCC 2.95.
/quote]

Thanks for replying, anyway.

Quote

Try cross compiling the same thing and see whether that works. BTW you can\'t run \'make clean\' if the Makefile doesn\'t still exist to tell \'make\' what to do for \'clean\'.

Hehe.  Yes, I knew that.  But, I wanted to post EXACTLY what I typed after reinstalling the OS, so that there was no confusion

Quote

Simon

Thanks again for the fast reply Simon.  Any other input from you is welcome, too.  Does anyone else have any ideas?

Clint Reese
Clint Reese
C.H.E.I.F. - Cyborgs Having & Encouraging Individual Freedom
http://books.lulu.com/content/70176
Yahoo ID: justphilanthrope

jdf

  • Newbie
  • *
  • Posts: 33
    • View Profile
    • http://
QT "Compiler Setup" worked before. Why not now?
« Reply #4 on: March 30, 2004, 12:58:31 pm »
I CAN\'T explain why, I just know what worked for me.  
I have Fedora Core 1 which is pretty much RedHat 9 as I understand it.  I followed how-to\'s with all the gcc2.95 references and had several errors, but then found I DID NOT HAVE TO DO the backward compatible gcc rpms.  Just used what came with default install of Fedora.  Everything worked.   Maybe this will give you a clue to your problem.

http://www.zaurususergroup.com/index.php?n...iewtopic&t=2045

or this one

http://www.zaurususergroup.com/index.php?n...viewtopic&t=431

jdf
JDF
SL-5500; CF MODEM; CF Wireless; CF & SD Storage;
Fedora CORE 1; WinXP

ClintReese

  • Jr. Member
  • **
  • Posts: 69
    • View Profile
QT "Compiler Setup" worked before. Why not now?
« Reply #5 on: March 31, 2004, 11:14:45 am »
Quote
I can explain why, I just know what worked for me. 
I have Fedora Core 1 which is pretty much RedHat 9 as I understand it.  I followed how-to\'s with all the gcc2.95 references and had several errors, but then found I DID NOT HAVE TO DO the backward compatible gcc rpms.  Just used what came with default install of Fedora.  Everything worked.   Maybe this will give you a clue to your problem.

http://www.zaurususergroup.com/index.php?n...iewtopic&t=2045

or this one

http://www.zaurususergroup.com/index.php?n...viewtopic&t=431

jdf

Thanks!  That makes sense.  Now that you mentioned it, I think that I did downloaded QT directly from Tolltech\'s site last time.

I intend to try it.

Thanks again!

Clint Reese
Clint Reese
C.H.E.I.F. - Cyborgs Having & Encouraging Individual Freedom
http://books.lulu.com/content/70176
Yahoo ID: justphilanthrope

ClintReese

  • Jr. Member
  • **
  • Posts: 69
    • View Profile
QT "Compiler Setup" worked before. Why not now?
« Reply #6 on: April 03, 2004, 05:30:55 pm »
Quote
I can explain why, I just know what worked for me. 
I have Fedora Core 1 which is pretty much RedHat 9 as I understand it.  I followed how-to\'s with all the gcc2.95 references and had several errors, but then found I DID NOT HAVE TO DO the backward compatible gcc rpms.  Just used what came with default install of Fedora.  Everything worked.   Maybe this will give you a clue to your problem.

http://www.zaurususergroup.com/index.php?n...iewtopic&t=2045

or this one

http://www.zaurususergroup.com/index.php?n...viewtopic&t=431

jdf

Sorry for starting a new thread.  I just found out that I should have looked under \"Linux Issues\" instead of QT/Qtopia.  I should have looked under both before posting.

The second link which you gave describes EXACTLY the problems which I\'ve been having.  I\'m just a month late.

I seem to be at the point where markb was when he was getting the errors about the JPEG stuff.  Onward!

Anyway, thank you for posting so helpfully.   I\'ll start posting on the right thread now, if I have trouble.

Clint Reese
Clint Reese
C.H.E.I.F. - Cyborgs Having & Encouraging Individual Freedom
http://books.lulu.com/content/70176
Yahoo ID: justphilanthrope