You are not logged in.

#1 2005-03-30 04:26:16

rshetye
Member
Registered: 2004-02-10
Posts: 11

MANPATH: Undefined variable.

I use tcsh and on logging into the box, my tcsh shell displays

MANPATH: Undefined variable.
> 

Note the ">" character. My local .tcshrc is not being executed and there is NO /etc/tcshrc. Any ideas ? Has anyone else run into this problem ? My Arch box has been running quietly for over a year.

thanks

Offline

#2 2005-03-30 04:44:13

rshetye
Member
Registered: 2004-02-10
Posts: 11

Re: MANPATH: Undefined variable.

Fixed it. I am guessing that KDE is majorly b0rked.

1. in /etc/csh.cshrc
Moved the MANPATH code to the very top BEFORE any of the /etc/profile.d/* files are called

2. in /etc/profile.d/kde.csh - this file is definitely b0rked.

modified

setenv PKG_CONFIG_PATH $KDEDIR/lib/pkgconfig:$PKG_CONFIG_PATH

to

if ( ! $?PKG_CONFIG_PATH ) then
        setenv PKG_CONFIG_PATH $KDEDIR/lib/pkgconfig
else
        setenv PKG_CONFIG_PATH $KDEDIR/lib/pkgconfig:$PKG_CONFIG_PATH
endif

If you wish to avoid step 1, you can give step2 style protection to the MANPATH variable too in /etc/profile.d/kde.csh

Didn't take too long to track down, but a waste of time nonetheless. Hope this helps somebody else too.

Offline

#3 2005-03-30 04:46:52

Snowman
Developer/Forum Fellow
From: Montreal, Canada
Registered: 2004-08-20
Posts: 5,212

Re: MANPATH: Undefined variable.

MANPATH is defined in /etc/csh.cshrc

Offline

#4 2005-03-30 05:00:31

rshetye
Member
Registered: 2004-02-10
Posts: 11

Re: MANPATH: Undefined variable.

I know, but /etc/profile.d/kde.csh is being called by /etc/csh.cshrc even before /etc/csh.cshrc itself initializes the MANPATH variable, and /etc/profile.d/kde.csh just assumes that MANPATH already exists and starts using it.

End result is the /etc/profile.d/kde.csh references a non-existing variable, MANPATH, and all initialization grinds to a halt, leaving me with a ">" prompt!

Offline

#5 2005-03-30 05:01:16

Snowman
Developer/Forum Fellow
From: Montreal, Canada
Registered: 2004-08-20
Posts: 5,212

Re: MANPATH: Undefined variable.

A lot of packages only provide a sh script in /etc/profile.d
If you use kdm, you can make this link:
ln -s /etc/profile /etc/xprofile
that way the sh scripts in profile.d will be sourced.

Offline

#6 2006-07-13 06:09:31

rshetye
Member
Registered: 2004-02-10
Posts: 11

Re: MANPATH: Undefined variable.

The correct way to fix this is in the package, by invoking "#!/usr/bin/env sh" at the start of the script.

Offline

#7 2006-07-14 00:41:56

Snowman
Developer/Forum Fellow
From: Montreal, Canada
Registered: 2004-08-20
Posts: 5,212

Re: MANPATH: Undefined variable.

rshetye wrote:

The correct way to fix this is in the package, by invoking "#!/usr/bin/env sh" at the start of the script.

That's an old thread. lol If it's not fixed yet, please submit a bug report.

Offline

Board footer

Powered by FluxBB