Go Back   PCMech Forums > Linux Support > Linux OS and Software Assistance

Need Some Help? Type Your Keywords Here:

Reply
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
Old 02-18-2004, 12:49 AM   #1
Mondsreitersmann
 
Nuclear Krusader's Avatar
 
Join Date: Jul 1999
Location: Skingrad
Posts: 8,781
Pissed Can't run programs

Why can't I run my C programs in Red Hat 9.1?

They compile fine and the executables are created, but when I try to run the executables I receive a "bash: hello: command not found" error (where hello is the name of the executable).

This is frustrating.

Any suggestions?

TIA
__________________
Darum still, füg' ich mich, wie Gott es will. Nun, so will ich wacker streiten, und sollt' ich den Tod erleiden, stirbt ein braver Reitersmann.
Nuclear Krusader is offline   Reply With Quote
Old 02-18-2004, 12:55 AM   #2
Mondsreitersmann
 
Nuclear Krusader's Avatar
 
Join Date: Jul 1999
Location: Skingrad
Posts: 8,781
Just found out this is happening with *every* program. I tried to run the Flash installer and got the same error message.
Nuclear Krusader is offline   Reply With Quote
Old 02-19-2004, 07:44 PM   #3
Mondsreitersmann
 
Nuclear Krusader's Avatar
 
Join Date: Jul 1999
Location: Skingrad
Posts: 8,781
Ah, never mind, nuked that annoying Red Hat and installed Mandrake. Everything is fine now.

Thanks for dropping by.
Nuclear Krusader is offline   Reply With Quote
Old 02-19-2004, 07:52 PM   #4
Member (7 bit)
 
Join Date: Sep 2003
Posts: 90
well, you are going to find that linux is going to be very difficult for you if your mentality is "if it don't work, forget it". even if it is mandrake.

personally, i don't see how mandrake is "easier" than red hat. but i deal mainly with shells and terminals which can be made the same across all unixes/linuxes.

how were you running your programs? linux is not dos. you cannot type "hello" unless "." is in your current PATH. you have to type "./hello". type "echo $PATH" to see what is in your system variable PATH.

AS

Last edited by AerynSedai; 02-19-2004 at 07:54 PM.
AerynSedai is offline   Reply With Quote
Old 02-19-2004, 09:21 PM   #5
Mondsreitersmann
 
Nuclear Krusader's Avatar
 
Join Date: Jul 1999
Location: Skingrad
Posts: 8,781
Linux is a pain. Really. Linux is cryptic and doesn't give much information about what is going on. Even to install RH was a complete ordeal.

If it were not for my CS class, I wouldn't touch it with a ten feet pole.

The programs I was trying to run were all in the same working directory, and yes, I tried both hello and ./hello. In the school it worked no problem, so why here it didn't is beyond me.

No problems running those same programs from the terminal in Mandy, tho.
Nuclear Krusader is offline   Reply With Quote
Old 02-19-2004, 10:47 PM   #6
Member (7 bit)
 
Join Date: Sep 2003
Posts: 90
well, i guess we will never know what went wrong.

but, in defence of linux, it is not cryptic, per se. but, people seem to find anything that is not windows as cryptic and take an instant dislike to it because it doesn't act like windows. think about all your minor complaints about it. it even took me a while to get over this. well, go figure.

anywho, i don't recommend linux to anyone without a programming background and i avoid windows/linux debates with non-programmers as well.

if you really need to use gcc or make, then i would suggest cygwin and xemacs, both of which are free and can run in windows.

AS

Last edited by AerynSedai; 02-19-2004 at 10:50 PM.
AerynSedai is offline   Reply With Quote
Old 02-21-2004, 09:33 AM   #7
Premium Member
 
Statica's Avatar
 
Join Date: Jun 1999
Posts: 9,231
Just because people can use Windows, doesnt automatically qualify them to know what Linux is. Linux is designed from the ground up to be a stable, professional OS that is capable of more things than Windows is. The thing I absolute can't figure out is how people assume they know everything about computers just because they can install or move a mouse on Windows or a click YES on a packaged, foil-wrapped installshield binary. Here's the way it works, if you open your mind ESPECIALLY to something you do not know, you might end up learning something that will aid your experiences. I've been checking out numerous threads that you have debated on how Linux is a pain, and while I never cared to respond to them - because I feel understand what Linux is, I feel I understand what Unix is and I also feel I understand what Windows is - because I have used them all EXTENSIVELY - both personally and professionally, I'll say this - it is entirely up to you to understand that
(a) You do not know about every OS out there
(b) Linux is different from Windows
(c) If every time you come up with a problem you say its a pain and format and install something else, you really havent solved your own problems.
Of course, this isnt mean to be a debate since you have your heart set on how Linux is a pain, but a friendly tip that Linux, as with everything else, is a very logical OS - it is not prone to randomness, and there is a LOGICAL solution to your problem, if you care to research and read on it. If I were to start using Symbian or writing for Symbian, I personally would read books, read online sources, and work with it and try to understand the operating system - because I know that just because I can mount a drive, or run a httpd server or write an application using a mysql dbase doesnt mean that I know diddly about the Symbian OS.

I have yet to find an OS that I hate and I am also yet to find an OS that I like universally. Form follows function my good man, not the other way around.

Last edited by Statica; 02-21-2004 at 09:37 AM.
Statica is offline   Reply With Quote
Old 02-21-2004, 12:08 PM   #8
Barefoot on the Moon!
Staff
Premium Member
 
Force Flow's Avatar
 
Join Date: Aug 2002
Location: Northeastern USA
Posts: 13,382
http://www.mandrakeusers.org - good forums

http://www.mandrakehelp.com - the undernet channel #mandrake has many helpful people there

http://ozzzy.dhis.org/ - some good info from a guy on #mandrake
__________________
There are two secrets to staying young, being happy, and achieving success. You have to laugh and find humor every day, and you have to have a dream.
Force Flow is offline   Reply With Quote
Old 02-21-2004, 12:40 PM   #9
Member (14 bit)
 
bailey's Avatar
 
Join Date: Mar 1999
Location: Christmas, Florida
Posts: 10,661
not sure how to word this but I will make a attempt.

I have been working with most all the differant os's starting with cp/m, I what I have found is that they all have a differant learnning curve. most use the same namming comventions for the usall operations and sre somewhat common sense with the names,

linux on the other hand has some of the strangest names for things that it is almost humorest in the names it uses,
this does make the learnning curve more channalging. if it were not part of the curriclum at school, I probly would not be able to say anything positive about linux.
learnning the commands and the syntax to use and all the switches to use with the commands has made it a lot more interesting,
it seame the more I learn about it , the more I am likeing it,
they say red hat is the most diffcult to learn and that is the one I am learnning.

who knows, by the time I am done, I may even try for the linux+ certification.
bailey is offline   Reply With Quote
Old 02-21-2004, 05:43 PM   #10
Mondsreitersmann
 
Nuclear Krusader's Avatar
 
Join Date: Jul 1999
Location: Skingrad
Posts: 8,781
I do not like Linux. Period.

I just want to get my job done in the least amount of time possible. I don't have time to do research and read dozens of pages every time I run into a problem with this OS. Yes I am a NOOBSTER programmer, and I am only using it only because I need to generate logs of my programs output. I do all my C coding in Windows using DevC++, but I cannot generate logs in the command line in Windows. That is why I was forced to install Linux in my PC.

I cannot be wasting my time perusing pages and pages and pages of info just to solve a single and/or simple problem. Especially when my assignments are due and time is of the essence. I just want to get my job done! And that is why I asked a question here. A question that nobody cared to answer until I announced here that my frustration reached such levels that the only path my feeble computer-ignorant mind saw was nuking the thing that was not working and installing one that worked. It was then when people jumped on me and bashed me for disliking the mighty Unix-based OS.

The funny thing is, that even after all the lectures I got, my initial question remains unanswered.

Alas, I withdraw from this thread before it turns into a heated debate, something that was not my intention in the first place.

Mine apologies for my stupidity and for offending you by bashing your favorite OS.
Nuclear Krusader is offline   Reply With Quote
Old 02-22-2004, 02:34 AM   #11
Member (7 bit)
 
Join Date: Sep 2003
Posts: 90
please read all of this helpful message.

cygwin and xemacs.

cygwin will emulate a unix terminal on a windows machine. you can redirect outputs just like in linux, which is what i am assuming you are doing with linux in the first place.

xemacs is just an editor. i moved away from bloodshed's dev-c because it just only goes so far.

actually, if all you are doing simple file descriptor redirection, then there is no need for linux nor cygwin. you can do this inside the code with a simple call to dup() in the beginning. dup() is a standard c function which will allow you to redirect the output to one file descriptor to another. which means, you can redirect all traffic going to stdout to myfile.txt. this is essentially what the sidewise carets do in a terminal "<" and ">". The pipe "|" does something a little different.

you can find more about dup at your local library or you can ask me.

AS
AerynSedai is offline   Reply With Quote
Reply

Bookmarks

Still Need Help? Type Your Keywords Here:


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -5. The time now is 06:57 AM.
Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2012, vBulletin Solutions, Inc.
SEO by vBSEO 3.6.0 PL2