Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Linux: Seeking source code for 'w' command...

712 views
Skip to first unread message

Kenny McCormack

unread,
Feb 20, 2016, 10:53:39 AM2/20/16
to
I need to compile the 'w' command for a Linux distro that has no access to
conventional package management stuff. Therefore, I need the source code.

I expected it to be in 'coreutils', but it isn't. Furthermore, none of the
commonly available methods for tracking this sort of thing has worked.

See:

% where w df
/usr/bin/w
/bin/df
% dpkg -S /bin/df /usr/bin/w
coreutils: /bin/df
dpkg-query: no path found matching pattern /usr/bin/w
%

I've also tried various tips found online, such as searching at
http://packages.ubuntu.com. While these work for many commands, none have
worked for the 'w' command. Can anyone help me on this?

P.S., for reference, this is the 'w' command I am talking about. Note that
this command combines features of the 'uptime', 'who', and 'ps' command,
which is what makes it attractive.

% w
08:50:43 up 17 days, 6:14, 27 users, load average: 1.41, 1.55, 1.53
USER TTY FROM LOGIN@ IDLE JCPU PCPU WHAT
someuser pts/8 somewhere.com Mon22 10:23m 0.05s 0.05s -csh
etc, etc
%

--

First of all, I do not appreciate your playing stupid here at all.

- Thomas 'PointedEars' Lahn -

Richard Kettlewell

unread,
Feb 20, 2016, 11:11:00 AM2/20/16
to
gaz...@shell.xmission.com (Kenny McCormack) writes:
> I need to compile the 'w' command for a Linux distro that has no
> access to conventional package management stuff. Therefore, I need
> the source code.
>
> I expected it to be in 'coreutils', but it isn't. Furthermore, none
> of the commonly available methods for tracking this sort of thing has
> worked.
>
> See:
>
> % where w df
> /usr/bin/w
> /bin/df
> % dpkg -S /bin/df /usr/bin/w
> coreutils: /bin/df
> dpkg-query: no path found matching pattern /usr/bin/w
> %

araminta:~$ ls -l /usr/bin/w /etc/alternatives/w
lrwxrwxrwx 1 root root 17 Feb 6 2011 /etc/alternatives/w -> /usr/bin/w.procps
lrwxrwxrwx 1 root root 19 Dec 29 2008 /usr/bin/w -> /etc/alternatives/w
araminta:~$ dpkg -S /usr/bin/w.procps
procps: /usr/bin/w.procps

--
http://www.greenend.org.uk/rjk/

Noob

unread,
Feb 20, 2016, 12:38:05 PM2/20/16
to
On 20/02/2016 16:53, Kenny McCormack wrote:

> I need to compile the 'w' command for a Linux distro that has no access to
> conventional package management stuff. Therefore, I need the source code.
>
> I expected it to be in 'coreutils', but it isn't. Furthermore, none of the
> commonly available methods for tracking this sort of thing has worked.

http://packages.ubuntu.com/trusty/amd64/procps/filelist
https://gitlab.com/procps-ng/procps

0 new messages