Errors while compiling C, C++ in linux

  • chandrika21
  • Born
  • Born
  • chandrika21
  • Posts: 3

Post 3+ Months Ago

1.Cannot compile C, C++ with RedHat Enterprise Linux 3.0.(gcc 3.2.3)

I recently dual booted Linux and Windows XP. They work fine. But I have a problem compiling C, C++ in linux. Whenever I compile C files , "it says stdio.h: No such file or directory". When I compile C++ files , it gives out thousands of errors , with first few saying:"cstdio.h:No such file or directory". I checked and saw that gcc package has been installed and glibc etc...all the libraries that come come with it have been installed. i am very new to linux . Can someone help me?

2. Installing Java

I downloaded the j2sdk1.4.2 self extracting rpm package by running the self executable text file. I used "j2sdk -ql" to query if package has been installed. It displays several file paths which confirms that the package has been installed.bUt when I use javac , it says "command not found". Something must be missing here too. Cna someone tell me how to solve this problem?

3. Transfer files between linux and Windows.
i wanted to copy a text file edited in linux to windows, through a floppy disk. Since both OS have different file partition schemes each of the operating systems asks to format the floppy . I am not sure , but is there a way I can copy files from linux to windows?

I would appreciate if my questions are answered. I am very new to linux.
Thanks
  • Anonymous
  • Bot
  • No Avatar
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post 3+ Months Ago

  • sanjustudy
  • Novice
  • Novice
  • sanjustudy
  • Posts: 15

Post 3+ Months Ago

hai chadrika ,
while running the c,c++ files u r getting the problem of header files check out whether these header files are avialable in /usr/lib

for eg stdio.h this .h has to be available in /urs/lib/ similarly others also then both ur c, c++ works fine if still problem then mail me at sanju@inbox.com

Rergards
Sanju
  • sanjustudy
  • Novice
  • Novice
  • sanjustudy
  • Posts: 15

Post 3+ Months Ago

hai ,
for java in linux means just type rpm -qa java if it shows version number then type javac if error means u may have missed java compiler try again installing it

Regards
Sanju
  • chandrika21
  • Born
  • Born
  • chandrika21
  • Posts: 3

Post 3+ Months Ago

Thank You Sanju. I followed your instructions ...when it didn't work, I reinstalled RedHat Enterprise lInux 3 and now C, C++ programs work fine. I don't know what went wrong in the first place.

Now, I would like to know how i could use this version(gcc 3.2.3 ) to compile and run java programs.
I used "rpm -qa java and saw that java is not installed.
I thought the javac compiler comes with the installation CDs, but that does not seem the case.
If I would like to use 'javac ' compiler , what is it that I should do? Should I install another package explicitly to work on Java in Linux?

Thanks in advance.
  • sanjustudy
  • Novice
  • Novice
  • sanjustudy
  • Posts: 15

Post 3+ Months Ago

Hai Chandrika ,
first uninstall all the java related packages for ur system and get downlaod the package from the following page

java.sun.com/j2se/1.4.2/install-linux.htm

Regards
Sanju
  • chandrika21
  • Born
  • Born
  • chandrika21
  • Posts: 3

Post 3+ Months Ago

Thank you for the information. I am sorry to reply so late. Now everything works fine.
Thanks

Post Information

  • Total Posts in this topic: 6 posts
  • Users browsing this forum: No registered users and 37 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
cron
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.