Category Archives: Linux

How Microsoft Won The API War on Windows only

Another release out of the door, and some time to put my thoughts in writing.

Did Microsoft lose the API war?

The title of this post is of course referring to the famous “HowMicrosoft Lost the API War” by Joel. I kept going back to that article when we were porting our product to Vista, as well as trying some of my personal projects on Vista. The more I think about it, The Raymond Chen Camp in Microsoft is still strong, and the API war is far from lost. And this article does not indent to pick on Joel, it just uses his article (which was very true in 2004) as a base to make a point.

  • Speculations in the article that Win32 will be replaced by WinFX or Avalon or whatever did not happen. Win32 is still there, still working fine. All the previous code I have tried worked seamlessly on Vista.
  • I still have not found a user application that worked on XP and does not work well on Vista (drivers and hardware – completely other story).
  • It took us about 2-3 weeks to get a product (involving a lot of complex kernel-mode drivers and system service) that worked on XP to work on Vista. As a comparison Panther to Tiger took six months. So Microsoft did really make it seamless to port even system software. User-mode software did not need any porting.

Who makes the best APIs?

Also, apart from not losing backward compatibility, Microsoft are still kings at making their APIs developer-friendly.

Example – you want you application to make an HTTP request and get the result. Both Apple and Microsoft have an API (Apple calls its CFNetwork, MS calls theirs WinINet) for that. Ok, so you write you application to use the OS-supplied API for the task. But you have customers behind corporate firewalls, using proxies. The user has set its proxy setting in the system, and their browser is working fine, but you application is not. What to do?

Well Microsoft will advise you to simply call InternetOpen with INTERNET_OPEN_TYPE_PRECONFIG, which will make your application inherit the browser settings (direct or proxy). What do Apple suggest…. this! Tenths of lines of code against a simple parameter of a function.

This happened in a multi-platform project I managed. The Windows developer just took a glimpse at MSDN, added the flag and the proxy issue was forgotten on Windows. The Apple developer took almost half a day to understand the article, copy-paste the example and adapt it to his code. A big productivity win for Microsoft.

Does it matter?

Still, sadly, Joel was right about the outcome. Developers no longer care to learn new APIs from Redmond, and .NET is not very popular either. It is not because of the API war though. The API war played its part but what really mattered is the market and the widespread use of virtualization technology.

No matter how small the combined market of Linux and OS X is, companies don’t want to neglect that. These days you see more and more application sites offering OS X or Linux versions of their software, and more and more hardware vendors provide Linux drivers for their hardware. It is not a single OS world anymore. And this affects developers’ choices of tools and languages. Joel was talking a lot about the backward compatibility and the old code. But how about new code? What will you choose today, if you are starting a brand new software? If possible of course you will choose a technology that does not limit you deployment abilities. If you ever have the choice of .NET over Java – you will choose Java, or regret it later when a customer says “We like you application a lot, but we are a Linux shop, does it run on Linux?”. In that moment, it is not very comforting to say to yourself “Ok, we lost that sale, but hey, Linux is only 2%, why should I care”. And if you choose a technology that binds you to an OS, which today has 99% of the market, you are still gambling, betting all your money on the chance the OS market does not change in the lifetime of your product. Of course, all this is valid for a certain range of applications. But for this range, the developers have started turning away from APIs and technologies that are bound to a specific OS (.NET, Objective C) , and preferring (where possible) cross-platform tools and languages like Java, Python, wxWidgets etc.

As a developer, I am a huge .NET fan. This is the combination of framework and development environment that IMHO makes a developer most effective. As a development manager though, I am a Java/Python fan. Even with somewhat less productivity with the later two, you are ready to deploy on any platform out there and this is becoming more important.

The role of virtualization

The other thing that hurt Microsoft bad is the virtualization technology boom. The biggest advantage of Windows is the huge amount of software available on it. A lot of people have been tempted to switch to Apple or Linux, but were being held back by that specific application that they can’t live without, which is available on Windows only. Well, with the Apple switching to Intel (enabling software like VMWare and Parallels on the Mac) and VMWare doing a Linux version it is not a problem anymore. I know a lot of people that switched and are now running that favorite application in a virtual machine.

Conclusion

So Microsoft won the API war. It did not matter. To win the developers back to Microsoft tools and technologies, they should make them available on all platforms. If there was .NET for Mac and Linux I would, as a development manager, push the developers to use .NET. With .NET being bound to Windows – it is a hard call to make since you are burning your bridges for a Mac or Linux version.

Share

The coolest way to install an OS

I’ve been doing a lot of OS re-installs lately, both at home and office. And I soon found out I hate installing XP, Vista, Red Hat, but I simply love installing Ubuntu. Why is that? One simple reason – the live CD. Once you boot the live CD you have internet, Firefox, icq, games, everything. You start the install and instead of watching stupid progress bars and slogans you can read some news on the internet, chat with friends, play a game or write a blog post (yes, I am writing this while ubuntu is installing in the background).

Share

Is Linux ready for me?

Is Linux ready for me?

In parallel to my efforts to completely switch to Vista in my office, I decided to
check out on the progress of Linux. I was curious can I do all my daily job under Linix, so I installed the latest Ubuntu alpha in parallel to my Vista. I planned to spend roughly half my working day in Vista and the other half in Ubuntu. For the purpose I used my company Fujitsu-Siemens T4210 tablet PC, Vista business edition and Ubuntu 7.04.

Installation

Ubuntu installation was a breeze, but I had to put in additional 2 hours of
effort (reading forums mainly) to get the tablet and tablet buttons working. The Ubuntu forums are really helpful, and it is quick and easy to find exact steps to get your hardware working. I never managed to get the built-in microphone working, though.

Wireless networking is greatly improved in the latest Ubuntu. Much more stuff works out-of-the-box. Overall no problems here.

Doing work stuff

I started doing what I do normally, and overall I was able to to most of my work
under Linux. This included:

  • E-mail: no problem connecting to the company exchange server, delivering additional
    POP3 boxes to the exchange store. No problems here at all.
  • Source control: we are very lucky to be using Subversion, so everything was pretty
    smooth here
  • Bug database: Our bug-base as any modern one has cool web interface, so this was no
    different than Vista
  • Merging: Meld is a pretty good open-source 3-way merge tool. While not as good as
    the Windows-one, it was sufficient
  • Document processing: OpenOffice was perfect for my humble Word/Excel/Powerpoing needs, the compatibility with MS is not great, but bearable. We keep documentation in a wiki anyway, so there are not a lot of documents around
  • Instant messaging: Skype, ICQ run with no problems.
  • Running Virtual Machines: Here Linux really shines. I don’t install any development tools/sdks on my machine, but rather setup a virtual
    development machines for different products/setups. VMWare for Linux is great, install is very straightforward and simple. But why it is times better than Windows you ask? Because Ubuntu eats up much less memory than the Vista monstrosity, and VM run times faster.

But I also found out I had to re-boot to Vista for some tasks. What I did not manage to do under my Linux:

  • Doing Skype conferences – that was because I could not get the built-in microphone to run. Other then that the Linux Skype version is simply great.
  • Project planning – Microsoft Project has no equivalent under Linux that comes even close. I gave at least 6 open-source alternatives a try and none of them had more then 20% of the MS Project features
  • UI Prototyping – Visio and Photoshops’s closes alternatives – Dia and Gimp were
    far away from the functionality and ease-of-use to the Windows versions
  • WebEx conferences – No WebEx for Linux…

Doing fun stuff

  • Music and sound – Due to its lack of a singe, standard sound HAL, anything sound-related is a pain in the ass. Yes, I can listen to my mp3 and hear the sound of flash applets, but not together, unless I spend hours of configuring. No thanks, was about to do fun stuff, and configuring 100 sound-using applications to work together is no fun in my book.
  • Ur-Quan Masters – I love this open-source game, and being under Linux I decided
    it will run better than the Windows build. I was very wrong. Due to the lack of
    a single, standard graphics HAL – it wouldn’t run under my Ubuntu. It behaved like
    an old DOS game that was run on EGA using CGA settings. Pathetic. The Windows version runs perfect on any XP/Vista I ever tried.

The conclusion

Linux has improved greatly for the last year. If I was writing this article for Ubuntu 5.x, it would have been much, much worse. It is now almost suited for work stuff. If I had found a reasonable Project, Visio and Photoshop alternatives – I would have switched, since overall I started to like Ubuntu very much.

For the fun part – its greatest strength (the huge freedom and choice) is its biggest
curse. Until there are world-wide Linux standard HALs for hardware accelerated video
and modern 3d sound, Linux is totally not ready for the fun part. And it is my favorite
part….

Share