Building a Chinese operating system

There have been recent stories about the Chinese government cracking down on Microsoft (and others) for various reasons from anti-trust violations to price fixing to potential security threats, but one of the more interesting stories to emerge in recent days has been the news that China is working on its own operating system.

Theoretically a Chinese-built OS could lessen that country’s reliance on all things Windows and foster the development of more home-grown applications.

On the surface this seems like a daunting task. After all, it has taken Microsoft, Apple and others years and years to develop their operating systems (and they are still tinkering with them). The number of lines of code in something like Windows or OS X must be in the tens of thousands by now and there are still bugs that need fixing. There are so many parts, so much code, so many potential difficulties that it would take years. So how is the Chinese government going to catch up? 

But then I thought about all the operating systems of the past that have come and gone. Over the past 50 years or so there have been dozens if not hundreds of different operating systems – some of them were a bit clunky but some of them have been quite clever. And some of them were built fairly quickly by relatively small teams.

Granted, a lot of those old operating systems didn’t have to run legacy software since they were going to be deployed on completely new hardware and they were expecting people to write entire suites of completely new software to run on the new OS. They also didn’t have nearly the same capabilities or sophistication of modern OSs. Many of them were little more than hardware abstraction layers without a lot of user interface bells and whistles (the applications were supposed to take care of most of that stuff).

The question is, what exactly do you want an operating system to do? The earliest operating systems did little more than allow you to read and write data to a disk drive (DOS = disk operating system).

Now if you are trying to build an operating system that will run Windows or iOS or Android applications that could be a bit difficult. There are tons of libraries and functions and interfaces you would have to emulate and it gets even trickier if you don’t have the source code.

Also, if you are mainly concerned about security issues then even starting out with something like Linux could require a lot work. (Rumors are that the Chinese are basing their new OS on Linux so that could give them a head start.) But a paranoid person would want to go over just about every bit of code since it came from so many sources (unless you trust the open source vetting process).

Of course, you could just buy one of those old operating systems and give it a facelift. I bet you could pick up something like CPM or AmgiaDOS for a song.