This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: /usr/bin exists not; man can't find nroff; permissions inconsistent


A lot of times, when you see something like this on a shell script, it's
the program it's trying to run to run the shell script.  In other words,
/usr/bin/nroff is a shell script that requires /bin/sh (the first line).
Is /bin/sh defined?

Then the next question is, since nroff is emulated by groff, does
/usr/bin/groff exist?

Chris Carlson
iStor Networks, Inc.


-----Original Message-----
From: cygwin-owner@cygwin.com [mailto:cygwin-owner@cygwin.com] On Behalf
Of Carlo Florendo
Sent: Tuesday, June 22, 2004 3:54 PM
To: Carlo Florendo
Cc: cygwin@cygwin.com
Subject: Re: /usr/bin exists not; man can't find nroff; permissions
inconsistent

Sorry, forgot cygcheck.  Here it is:

Carlo Florendo wrote:

> Hello,
>
> After installing cygwin, I am encountering some issues.  cygcheck's 
> output attached:
>
> First, I tried to man bash.  Nothing appeared on screen so I hit `q'.

> Then, it says that nroff was not found.
>
> $ man bash
> /usr/bin/nroff: not found
>
> Then,  I checked whether nroff existed:
>
> $ ls -l /usr/bin/nroff
> -rw-r--r--    1 Carlo    None         1955 Dec 16  2002 /usr/bin/nroff
>
> Thus, I thought it existed but the permissions were not set well.  I 
> then tried to change the permissions:
>
> $ chmod 755 /usr/bin/nroff
> chmod: changing permissions of `/usr/bin/nroff': No such file or 
> directory
>
> As you see, it says that the file does not exist.  Strange, isnt't 
> it?  Then, I tried catting the file. Here's what I got.
>
> $ cat /usr/bin/nroff
> cat: /usr/bin/nroff: No such file or directory
>
> Thus, I tried going to the /usr/bin directory itself and catted nroff 
> to see if it really existed:
>
> $ cd /usr/bin
>
> $ ls -l nroff
> -rwxr-xr-x    1 Carlo    None         1955 Dec 16  2002 nroff
>
> $ cat nroff
> #!/bin/sh
> # Emulate nroff with groff.
>
> prog="$0"
> # Default device.
> # First try the "locale charmap" command, because it's most reliable.
>
> <Rest of output snipped>
>
> Thus, it exists.
> Then, I again tried doing an `ls -l' on nroff, first *not* specifying 
> its fully qualified name (FQN), and afterwards, specifying its FQN.  
> Here's what I got:
>
> $ pwd     /usr/bin
>
> $ ls -l nroff
> -rwxr-xr-x    1 Carlo    None         1955 Dec 16  2002 nroff
>
> $ ls -l /usr/bin/nroff
> -rw-r--r--    1 Carlo    None         1955 Dec 16  2002 /usr/bin/nroff
>
> As you can see, the first listing says the permission is a 755.  The 
> second listing says the permission is a 644.   This seems to me 
> strange.  Why does the permission for the same file appear differently

> when accessed via different means.  (i.e. specifying its FQN; not 
> specifying its FQN)?
>
> Thus, I thought that /usr/bin/nroff was probably hardlinked from 
> /bin/nroff and that this linking might have caused some problems so I 
> checked out /bin/nroff.  /bin/nroff existed.  I found out that 
> /usr/bin/nroff is indeed a hardlink to /bin/nroff but I didn't see why

> this could really cause a problem.
>
> Then, I tried opening a cmd prompt to check if there is any clue I 
> could get from it. This is what I got:
>
> --------Start windows cmd output------------
> $ cmd
> Microsoft Windows 2000 [Version 5.00.2195]
> (C) Copyright 1985-2000 Microsoft Corp.
>
> d:\cygwin>cd usr
> cd usr
>
> D:\cygwin\usr>dir /w dir /w
> Volume in drive D is PROGRAMS
> Volume Serial Number is 701A-F5A8
>
> Directory of D:\cygwin\usr
>
> [.]               [..]          [src]         [local]
> [tmp]             [include]     [share]       [doc]
> [man]             [sbin]        [autotool]    [info]
> [i686-pc-cygwin]  [etc]         [var]         [X11R6]
> [grace]           [ssl]         [libexec]     [logs]
> [i686-pc-mingw32]
>           0 File(s)              0 bytes
>          21 Dir(s)   1,703,936,000 bytes free
>
> D:\cygwin\usr>dir bin
> dir bin
> Volume in drive D is PROGRAMS
> Volume Serial Number is 701A-F5A8
>
> Directory of D:\cygwin\usr
>
> File Not Found
>
> D:\cygwin\usr>dir d:\cygwin\usr\bin
> dir d:\cygwin\usr\bin
> Volume in drive D is PROGRAMS
> Volume Serial Number is 701A-F5A8
>
> Directory of d:\cygwin\usr
>
> File Not Found
>
> d:\cygwin\usr>
>
> --------End windows cmd output------------
>
> The directory d:\cygwin\usr\bin does not exist. (i.e. It is neither 
> listed with `dir /w' nor `dir bin' nor `dir d:\cygwin\usr\bin') It 
> appears to be linked somewhere else.
>
> I would appreciate it very much if anyone could point out which part 
> of the source code I could tweak.  I'd like to learn diagnosing 
> problems in source code level.
> Another thing to note is that cygcheck reports several warnings of 
> this sort:
>
> Found: d:\cygwin\\bin\ls.exe
> Found: d:\cygwin\bin\ls.exe
> Warning: d:\cygwin\\bin\ls.exe hides d:\cygwin\bin\ls.exe
>
> What could be the problem on my system?  I know I'm  missing
something.
>
> Thank you so much!
>
> Best Regards,
>
> Carlo
> ------
> Carlo Florendo y Flora
> Astra Philippines Inc.
> www.astra.ph
>
> -- 
> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
> Problem reports:       http://cygwin.com/problems.html
> Documentation:         http://cygwin.com/docs.html
> FAQ:                   http://cygwin.com/faq/
>
>


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]