doscmd under 8-stable, anyone?

Kostik Belousov kostikbel at gmail.com
Wed Jun 15 14:50:28 UTC 2011


On Wed, Jun 15, 2011 at 04:44:55PM +0200, Joerg Wunsch wrote:
> As Kostik Belousov wrote:
> 
> > Do sysctl security.bsd.map_at_zero=1
> 
> Just for the record, this sysctl also makes my really really old utree
> binary work again.  The binary dates back to 386BSD 0.0, and I'm only
> keeping it out of curiosity:
> 
> j at uriah 66% ls -l /usr/local/bin/utree
> -rwxr-xr-x  1 bin  bin  179639 Apr 30  1992 /usr/local/bin/utree*
> 
> The only thing to make it run is to use a termcap entry that is
> smaller than 1024 byte, as this used to be a hard-coded limitation in
> the termcap library of those days, and the binary is statically
> linked.  TERM=vt100 works, xterm no longer does.
> 
> The ability to run this binary only serves as a proof that no backward
> compatibility has ever been broken in FreeBSD. ;-)  (Obviously, all
> the various COMPAT_* options must be present in the kernel config.)

Yes, doscmd and N-magic a.out binaries were the arguments to implement
the sysctl instead of outright disable of the mapping at address 0.
You are the first documented case of the wiseness of the decision :).

BTW, I semi-jokingly committed the support for FreeBSD-1.0/i386 ABI
on amd64 on April 1. Would be interesting to see how does your binary
behaves.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-stable/attachments/20110615/22d10ea7/attachment.pgp


More information about the freebsd-stable mailing list