From owner-freebsd-hackers Sun Feb 4 18:18:10 1996 Return-Path: owner-hackers Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id SAA22885 for hackers-outgoing; Sun, 4 Feb 1996 18:18:10 -0800 (PST) Received: from rover.village.org (rover.village.org [204.144.255.49]) by freefall.freebsd.org (8.7.3/8.7.3) with SMTP id SAA22879 for ; Sun, 4 Feb 1996 18:17:53 -0800 (PST) Received: from localhost (localhost [127.0.0.1]) by rover.village.org (8.6.11/8.6.6) with SMTP id MAA14828; Sun, 4 Feb 1996 12:59:04 -0700 Message-Id: <199602041959.MAA14828@rover.village.org> Subject: Re: Another Pentium gcc patch, -D__FreeBSD__=2 -Dbsd4_4 To: Heikki Suonsivu , freebsd-hackers@FreeBSD.ORG In-reply-to: Your message of Sun, 04 Feb 1996 09:25:20 MST Date: Sun, 04 Feb 1996 12:59:04 -0700 From: Warner Losh Sender: owner-hackers@FreeBSD.ORG Precedence: bulk : : All this is completely broken, BSD systems should converge, not further : : split up, as splitting up means disappearing into noise generated by Linux : : and big commercial ones. : : FreeBSD can't do it alone. Not can we do it w/o the cooperation of : all the BSD systems out there. I was a bit harsh on my initial reply. I found the wording incredibaly offensive to me because I have spent the last several years porting different software to different platforms. I found it insanely arrogant for you to presume to know what platforms that I have used, so I reacted with much bile. My applogies if it was a bit much. BSD does have a standard way of doing things. It is relatively easy to do. Most, if not all, of the Unix platforms provide sys/param.h. It is easy to have code that looks like #ifdef unix #include #endif #ifdef BSD4_4 /* Do blah #endif "unix" is defined on all the BSD systems that I'm aware of. In the commercial porting I've done (both OI and later TIA), on all systems where it is defined, sys/param.h was present. We were able to use this to bring OI to the Windows NT API (well, the Win32 flavour de jour) because it didn't define unix. Unix typically isn't defined on platforms that aren't unixlike enough to have sys/param.h. Heck, VMS even has this include (but it doesn't define unix, typically). If you want, I'll give you a list of all the platforms that OI and/or TIA has been ported to, and they both use this trick. It is too late to do anything "standard" with "one true define" for BSD systems because there are too many of them. There are those built by Sun, HP (kinda), FreeBSD, NetBSD, OpenBSD, Digitial, etc. Most of them are, at this point, legacy systems that cannot change. Unless/until you can get a consensus amount the various flavors of BSD that exist today, a single "one true flag" will not happen. Also, all of the *BSD people don't have congruent goals. The {Net,Open}BSD people want to have their system on as many different disparate platforms as possible and have gone to great lengths to do that. FreeBSD has traditionally been a i386 only platform. Over time, the goals of the groups are changing... It is likely too late to get all of these folk, plus BSDi, to agree to something that isn't in BSD 4.4 lite. bsd4_4 is defined, in gcc at least, only on the mips-dec-bsd platform and nowhere else. Since there are some FreeBSD isms that do need the __FreeBSD__ for various things, it is the right way to do this. Again, sorry for the excess bile in hackers... Warner