Atlasbooks.com Publishers retailers Bookmasters.com

Skip navigation.

 

Excerpt

Chapter 1. Introduction Unix: Built to Evolve

Complex systems come into existence in only two ways: through careful planning or through evolution. An airport is an example of something that is planned carefully beforehand, built, and then undergoes only minor changes for the rest of its existence. Complex organisms (like humans) are an example of something that has evolved continually from something simple.

In the end, organisms that are well suited to evolution will always win out over organisms that are less suited to evolve. For example, sexual reproduction helps create smooth and continuous evolution. As a result, nearly all complex organisms reproduce sexually.

An operating system evolves. Of course, the programmer who creates a new operating system designs it carefully, but in the end, an operating system that is well suited to evolution will replace an operating system that is not. It is, then, an interesting exercise to think about what traits make an operating system capable of evolution.

The first version of Unix was developed by Ken Thompson at Bell Laboratories in 1969. It was written in assembly language to run on a PDP-7. Dennis Ritchie, also at Bell Labs, invented the C programming language. Among computer languages, C is pretty low level, but it is still much more portable than assembly language. Together, Thompson and Ritchie completely rewrote Unix in C. By 1978, Unix was running on several different architectures. Portability, then, was the first indication that Unix is well suited to evolution.

In 1976, Bell Labs began giving the source code for Unix to research facilities. The Computer Systems Research Group at UC Berkeley got a copy and began tinkering with it. The design of Unix was exceedingly elegant and was deemed a perfect platform upon which to build two important technologies: virtual memory and TCP/IP networking. By freely distributing the source code, Bell Labs was inviting people to extend Unix. Extensibility was the second indication that Unix is well suited to evolution.

It should be noted here that Berkeley’s work on Unix was funded by DARPA. Without the warm glow of government grants for basic research, there would be no internet. These grants would be much more difficult to get in today’s political climate. In fact, not so long ago, the NSA discontinued all work to improve the security of Linux because of complaints that it was creating unfair competition for Microsoft.

4.4BSD was the last release of Unix produced by Berkeley. It was used as the basis for FreeBSD, OpenBSD, NetBSD, and Mac OS X. Today, Unix is used as an operating system for cellular phones and supercomputers. It is the most popular operating system for web servers, mail servers, and engineering workstations. The manner in which it has found a home in so many niches is yet another indication that Unix is capable of evolution.

Mac OS X is based upon 4.4BSD, but notice that this new niche, a desktop operating system that your grandmother will love, is very different from Unix’s previous purposes. To reach this goal, Apple has made several important additions to its Unix core.

The Unix part of Mac OS X is called Darwin. The large additions to Darwin that Apple has made are known as the core technologies. Apple, recognizing that Unix must continue to evolve, has released the source code to Darwin and most of the core technologies.

This Book

As Unix has evolved into this new niche, existing books have fallen behind. While there are several books on the graphical aspects of Mac programming, this is the only explanation of the plumbing that makes it all work. This is where you will learn the nitty-gritty that separates the experienced programmer from the beginners.

As someone who develops applications and servers for Mac OS X, there are large chunks of Unix that you probably do not care about. For example, do you need to know how to neatly format your text on a VT100 terminal?We will do our best to steer clear of historical curiosities and focus on technologies that you will actually need to understand.

When you finish this book, you will be able to:

• Create applications that leverage the full power of the Unix APIs.
• Use advanced ideas like multithreading and interprocess communications to increase the performance and reliability of your application.
• Add networking capabilities to event-driven applications.
• Make networked applications Bonjour-aware.
• Use the keychain and authorization capabilities of the security framework.
• Use distributed objects to create client/server applications.
• Understand and use gcc, the linker, the debugger, and cvs.
• Use the performance tools to evaluate and improve the responsiveness of your existing applications.

 

Search Categories | Featured Publishers | New Titles | Author Spotlight | Reading Room | Publishers | Retailers | BookMasters | Home | Contact

AtlasBooks® is a Division of BookMasters®, Inc.
© Copyright 1997- 2008, All rights reserved.