OT - therefore my first and only post on this. In message <a63e44a5-cc29-48c2-9a88-978275bd6...@rfc1035.com> Jim Reid writes: > > > On 13 Mar 2016, at 15:06, Robert Chalmers <rob...@chalmers.com.au> wrote: > > > > Nice hardware, but the software is really recycled FreeBSD. say what? > > The MacOSX kernel is based on Mach, not BSD, though that Mach kernel > presents a largely BSD-flavour/POSIX API to user mode applications. It > might be fairer to say FreeBSD is recycled MacOSX given the > engineering resources Apple has contributed to FreeBSD. :-) > > Most MacOSX command line tools come from FreeBSD or GNU, apart from > the obvious independent open source projects like postfix, openssl, > BIND, ntpd and so on.
https://en.wikipedia.org/wiki/Mac_OS#OS_X https://en.wikipedia.org/wiki/Darwin_%28operating_system%29 https://en.wikipedia.org/wiki/XNU https://en.wikipedia.org/wiki/Hybrid_kernel Briefly: Mach is an OS based on a minimalist microkernel. FS, VM, all outside the microkernel. In a microkernel all OS services are outside the kernel. This is best for security and to some extent reliability. There are performance penalties. OS/X uses the Darwin OS based on XNU which is a hybrid kernel. In a hybrid kernel that evolved from a more minimalist microkernel, some OS features that are performance critical are moved into the kernel. A monolithic kernel has lots of stuff in the kernel. A classic monolithic kernel has lots of stuff running unprotected and is therefore reliant on it all being very reliable in order to be secure. BSD was originally a monolithic kernel. Various BSD flavors have moved in the hybrid kernel direction with protected kernel spaces and loadable modules and loadable drivers. BSD is considered monolithic with modules. Linux is monolithic with modules. So OS/X is neither Mach or BSD but has parts of both. XNU isn't really Mach anymore just as the utility set isn't really FreeBSD. If you have better info, then go ahead and update the wikipedia pages. > > So all I need - if I'm bothered, is the source of FreeBSD's mail, > > and rebuild it myself so it links to postfix's sendmail where I want > > it properly. > > Source code for the pretty much the entire OS excluding Apple's > GUI-based tools and the window manager can be downloaded from > http://www.opensource.apple.com. You may be better off compiling from > that instead of FreeBSD source so you know you're starting from the > same baseline code Apple is using. Maybe Apple have changed > /usr/bin/mail somehow. They probably haven't, but you'll never know > for sure unless you check. > > Some command line tools have been "enhanced" by Apple. For instance > openssh has been hacked to work with Keychain and although the source > code for those changes is freely available, it's not yet found its way > into the official openssh distribution. btw- FreeBSD base contains sendmail. Postfix 2.11, 3.1 and 3.2 are in the FreeBSD ports collection as mail/postfix211, mail/postfix, and mail/postfix-current (last I checked postfix/postfix-2.11.7.tar.gz with patches, postfix-3.1.0.tar.gz and postfix-3.2-20160224.tar.gz). It does seem that using src/usr.bin/mail might work but maybe with a little work. Most of the code in src (the base source distribution) is not keen on being pulled out and compiled in any old environment which is why "tools" is built first and everything compiled (or cross compiled) using that tool set and a known set of include files and library files. So I don't give it good odds on being a drop in and compile solution. Mail is very simple and fairly self contained and probably hasn't changed significantly in decades so it might drop in. I'd exhaust other options first. Curtis