MANPATH: Undefined variable. % ?

  • Thread starter Thread starter Atr cheema
  • Start date Start date
  • Tags Tags
    Ubuntu Variable
Atr cheema
Messages
67
Reaction score
0
I am installing an installing an open source software -on Ubuntu 16.04- by reading its 'http://ftp://ftp.chesapeakebay.net/../Modeling/Phase5/community/P53/README.txt' file. At certain point (point 3b in the link) the guideline requires me to run a .csh file located in a certain directory in order to generate executables. When I type csh on terminal in the required directory I am met with following line on terminal
Code:
MANPATH: undefined variable.
%

By pressing enter or Ctl+C nothing happens and I have to close the terminal. Can anyone guide me where is the error?
 
on Phys.org
Atr cheema said:
I am installing an installing an open source software -on Ubuntu 16.04- by reading its 'http://ftp://ftp.chesapeakebay.net/../Modeling/Phase5/community/P53/README.txt' file. At certain point (point 3b in the link) the guideline requires me to run a .csh file located in a certain directory in order to generate executables. When I type csh on terminal in the required directory I am met with following line on terminal
Code:
MANPATH: undefined variable.
%

By pressing enter or Ctl+C nothing happens and I have to close the terminal. Can anyone guide me where is the error?
Is this step optional? I set up Ubuntu VMs all the time and there shouldn’t be any manual command line stuff unless you’re doing a very custom install or doing stuff after that’s company-specific.

MANPATH sounds like an environment variable and points to the command “man” which displays application manuals.

Not sure how it didn’t get installed but I’m assuming it can be fixed with
Sudo apt-get install man
Or
Sudo yum install manIf man already exists, you can simply set a perma-variable for it that points to the executable.
 
newjerseyrunner said:
Is this step optional? I set up Ubuntu VMs all the time and there shouldn’t be any manual command line stuff unless you’re doing a very custom install or doing stuff after that’s company-specific.

MANPATH sounds like an environment variable and points to the command “man” which displays application manuals.

Not sure how it didn’t get installed but I’m assuming it can be fixed with
Sudo apt-get install man
Or
Sudo yum install manIf man already exists, you can simply set a perma-variable for it that points to the executable.
If I execute the csh file from ubuntu terminal without going into interactive shell, the error persists. man is already installed and following is the output of manpath command when executed from terminal
Code:
/home/atrcheema/share/man:/usr/local/man:/usr/local/share/man:/usr/share/man
 
newjerseyrunner said:
MANPATH sounds like an environment variable and points to the command “man” which displays application manuals.
No, MANPATH is supposed to point to the location of the "man pages" that the "man" command displays (e.g. "man ls").

Atr cheema said:
man is already installed and following is the output of manpath command when executed from terminal

Apparently the value of MANPATH isn't being carried over from your login shell to the shell that runs the script. Unfortunately, it's been a while since I've done this sort of thing, and I don't remember ever using a C shell script for this anyway, so my memory and knowledge are a bit fuzzy here. You might try looking at the script to see if there's a section that sets variables like this, using commands like "set" or "setenv". Or maybe you simply need to invoke the script in a different way that does carry over your environment variables such as MANPATH.
 
Atr cheema said:
If I execute the csh file from ubuntu terminal without going into interactive shell, the error persists. man is already installed and following is the output of manpath command when executed from terminal
Code:
/home/atrcheema/share/man:/usr/local/man:/usr/local/share/man:/usr/share/man

Try running
Bash:
echo $MANPATH
(with MANPATH capitalised) in a terminal window. If this doesn't display anything then try doing
Bash:
export MANPATH=$(manpath)
before running your .csh script.
 

Similar threads

Replies
2
Views
3K
  • · Replies 13 ·
Replies
13
Views
5K
  • · Replies 5 ·
Replies
5
Views
6K
  • · Replies 12 ·
Replies
12
Views
4K