[NCLUG] FreeBSD versus Linux?

Bob Proulx bob at proulx.com
Sat Mar 20 12:42:21 MST 2004


Alan Silverstein wrote:
> For odd reasons, I went looking for open sources for the old reliable
> "mailx" program.  I found a recent Debian version and got it to compile
> on FreeBSD (at frii.com), but it wasn't easy.  And at runtime it wants
> /usr/libexec/lockspool, which is absent.  Clearly there are some
> disappointing dialect issues here.

Note that /usr/libexec/lockspool is _not_ a Debian thing.  That must
have come out of the raw configuration of the original source.

BTW I have run into the reverse problem of porting BSD sources to
Linux, HP-UX, etc. and that route is frequently not easy either.

> Next I went hunting for a FreeBSD version of mailx.  Well I found the
> very nice www.freebsd.org site, but best I can tell, all it offers is
> the kernel/OS, no commands.  (So where did FRII get their commands
> sources?)
> 
> I'm having no luck finding the "FreeBSD version of mailx", only some
> references to the fact it might exist, as in, "ported their bug fixes
> back."

V7 called the old program 'mail' and put it in /bin/mail.  BSD rewrote
the mail program.  BSD called it 'mail' and I think put it in
/usr/ucb/bin.  But then depending upon the user's PATH you might get
the wrong one.  So they named it 'Mail' with a capital M.  SysV took
this program back.  But they did not like changing their commands and
wanted to keep both the old 'mail' and the new 'Mail' but without
capitalization.  So they renamed the BSD mail program to 'mailx'.  In
the grand scheme of things 'mailx' is the "hacked" name and not the
real name of it.  On BSD systems you should get the "real" name of
it.  But the BSD version was a rewrite of the original.  So there is
no right answer.

On FRII try running "Mail" and you should have the same old reliable
mailx program you are used to running.

Hey, I just logged into frii and they have all three of the commands
(all linked together) /usr/bin/{Mail,mail,mailx}!  So I assume they
installed it at your request or you would have seen the mailx there
previously.

Speaking of learning and "primacy" in my other note, still using mailx
is another example of it.  It identifies you as having learned it on
HP-UX.  :-) I also note that David Korn (of /bin/ksh) still uses mailx
to send mail too.

Bob



More information about the NCLUG mailing list