Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 01-03-2005, 12:37 PM   #1
LQ Newbie
Registered: Aug 2004
Posts: 9

Rep: Reputation: 0
do I need ./ to run?

Dear sirs,
I ve been trying to compile some source codes, and I am following exactly the instructions provided with the code: I went to the directory indicated and ran a script ("Allmake") which supposedly would compile everything...

I obsiously checked and found Allmake in the said directory, but I was not able to run it. It says couldnot find command...

When I run with ./ (./Allmake) it did find the command, but inside the script other commands were supposed to be run, and again, without the "./" they dont work...

I desperately need these things to work, so I wonder if I am missing anything, like a way to make scripts to be run without the need of ./...

I am on a bash shell.

Old 01-03-2005, 12:59 PM   #2
Senior Member
Registered: Jun 2002
Location: Eastern PA, USA
Distribution: K/Ubuntu 18.04-14.04, Scientific Linux 6.3-6.4, Android-x86, Pretty much all distros at one point...
Posts: 1,802

Rep: Reputation: 157Reputation: 157
bash allmake

make sure your caps are all in the right place as Linux is upper/lower case dependant, unlike windoze...
Old 01-03-2005, 01:32 PM   #3
LQ Newbie
Registered: Aug 2004
Posts: 9

Original Poster
Rep: Reputation: 0
But there is still a problem when other scripts are called from inside the main script...
I dont want to add "bash" to all lines inside the main script calling other scripts...

My point is, in RH9 I could run simply by calling the script ($ Allmake), and know, in SuSE9.1 I need to call ./Allmake or bash Allmake, which does not help me, since Allmake calls other scripts...

Do you know how to make SuSE works the way RH was? Is this stuff configurable and did I miss it?

Thanks again...
Old 01-03-2005, 02:17 PM   #4
Senior Member
Registered: Dec 2004
Distribution: Slackware, ROCK
Posts: 1,973

Rep: Reputation: 46
Some distro's set the current working directory in your PATH and some do not ( for security). Go back to the directory and type:

export PATH=$PATH:.

this will add the current working directory to your path and eliminate the need for ./
Old 01-03-2005, 05:15 PM   #5
LQ Newbie
Registered: Aug 2004
Posts: 9

Original Poster
Rep: Reputation: 0
It still does not work.
It works for simple scripts now, but not for scripts invoking other scripts...
It is a step forward, tough
Old 01-03-2005, 05:37 PM   #6
Registered: Nov 2003
Distribution: slackware 14
Posts: 542

Rep: Reputation: 33
Check first scripts invoked by yours are not using some bash commands not included in your $PATH.
Most distributions (to be honest I don't know if SUSE does), put /sbin and /bin directory in the root $PATH.
If that is the case you should be able to run the script if logged as root (take care doing that).
Hope this helps


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Cannot get to run properly doctorwebbox Linux - Hardware 0 02-06-2005 07:18 AM
Not able to run audio Cds (not MP3) and run VCDS.. satish427 Linux - Newbie 4 09-25-2004 12:27 AM
Trying to run photoshop in wine. Install, but wont run. bruno buys Linux - Software 14 07-15-2004 05:30 PM
will delphi run on winex ? (i cant run kylix3 :(( ) hunter_one Linux - Software 0 10-19-2003 09:41 AM
Java applets run fine in Konqueror, but won't run in MS IE. OAnimal Linux - Software 7 12-04-2002 07:32 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:36 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration