LWN.net Logo

Nokia relicenses Qt

January 21, 2009

This article was contributed by Derek Kite

When Nokia purchased Trolltech in early 2008, it stated that the acquisition would "enable the acceleration of their cross-platform software strategy for mobile devices and desktop applications, and to develop its Internet services business." It is not entirely clear what that means, but one thing is certain: Nokia is now a major player on the free desktop since it owns the library upon which KDE is based. The free software community is not unfamiliar with large, well-established firms taking an interest in and contributing to an endeavor. But there is always the question: How well would Nokia work with the community?

It was a pleasant surprise, then, when Nokia announced that the Qt library will be released under the LGPL version 2.1. This is for the coming Qt 4.5 release that is due in March 2009, and applies across almost all its products. The new license is in addition to the existing commercial and GPL licenses.

Some history

Trolltech (now known as Qt Software) started marketing the Qt cross-platform library in 1996, and made the X11 version available under a free use, code available license. It was later offered under the Q Public License (QPL), which is an OSI approved license. Later Linux versions were released under the GPL. If someone desired to write a closed source binary application, they could purchase developer licenses from Trolltech.

Shortly after the initial release of Qt, Matthias Ettrich proposed using the library as a basis for the Kool Desktop Environment, better known as KDE.

One can think of many examples of successful business ventures based on free software, but they are usually in the server market. The desktop is much more challenging; against a well entrenched and rather rich competitor, we have something not quite done, but free. What Trolltech managed to accomplish is noteworthy. It had a library with a free license; the KDE developers tested it, learned how to use it, and evangelized about it. Trolltech got a large developer pool eager to use the product, and the irreplaceable hard knocks feedback from KDE developers. Over the years many KDE developers got jobs with Trolltech, or established consulting businesses selling services based on Qt, cementing the good will further.

But that necessity of selling licenses caused friction. The desire of Trolltech to own and control the code created a situation where outside patches were rarely accepted. KDE has long maintained a patch set called qt-copy, while they awaited the next version of Qt with the fixes written by a Troll (Trolltech engineer). The trend in free software has been to offer libraries under a license which allows closed source application development but, with Qt, that required paying for a license.

Although KDE is a vigorous project with a large user and developer base, the licensing and Trolltech's tight control over its library has relegated KDE and Qt somewhat to the margins within the free desktop stack. The rejection of the Qt due to its license prompted the creation of GTK and Gnome as a free alternative, and even elicited condemnation from Richard Stallman. Happily the relationship has improved to the point where both desktops are having a joint developer conference.

Opening the repository to contribution

Along with the license change, Qt Software is proposing to open the source repository to external contribution. The purpose is to make it easier for external developers to contribute to Qt, while still maintaining the quality and cross platform characteristics of the library.

Knut Yrvin, the Open Source Community Manager for Qt Software outlined the proposed criteria for accepting external contributions. In order to be accepted, the code would:

  1. follow Qt coding conventions
  2. be reviewed by another developer
  3. use a license compatible with Qt licenses
  4. follow Qt branch commit guidelines
  5. not add regressions except for new test cases

Qt Software will give full access to the internal unit tests that Qt developers have been using. It has already switched to Git internally, and is setting up Gitorious for hosting Git repositories.

There is more to the task than just providing access, as Mr. Yrvin described:

Unit tests, Qt guidelines, Git and Gitorious are just tools. The development process and workflow are important too. I label this as the social side of the development process. When opening up we are also making communication more transparent, increasing our effort with the community code camps and developer gatherings.

Mr. Yrvin described how Nokia benefits from all this. He explained that instead of having different code bases for the same application when targeting different devices, Qt can improve the time to market, targeting desktop, mobile and embedded platforms with a single code base. The increased use, contributions, and feedback from projects across all the platforms will ensure a high quality library. Nokia and all users of the platform benefit.

George Makrydakis raised some questions regarding the LGPL and C++ templates. Mr. Yrvin said that the legal department is aware of this and are currently investigating the template situation. They will come back with more details. He said that Nokia wants to ensure that it will be easy for developers to adopt Qt. It's worthwhile to note that gtkmm, the GTK C++ bindings, has the same issue.

This is a significant step for Nokia. It has been very difficult to attract developers to large commercial code releases. Nokia and Qt Software seem aware of the difficulties, and with feedback from KDE developers are attempting to avoid the pitfalls and make the process mutually beneficial. Let's not forget that Nokia makes phones, so it will be interesting to see how this move will play out in the briskly competitive smart phone marketplace.


(Log in to post comments)

Nokia relicenses Qt

Posted Jan 22, 2009 4:57 UTC (Thu) by cuboci (subscriber, #9641) [Link]

Er... wasn't Gtk created as an alternative to Motif? Afaik, the GIMP was based on Motif but because of the latter's non-freeness Gtk was created. Only GNOME was created in response to Qt's licensing restrictions, I think.

Nokia relicenses Qt

Posted Jan 22, 2009 8:38 UTC (Thu) by boudewijn (subscriber, #14185) [Link]

Yes, that's right. I still have the source of a motif-based gimp somewhere.
But the situation in those days was awfully confused: it was okay to build
a GPL application like Gimp motif. Nedit is still based on Motif, but went
GPL in 2000. There was Lyx using XForms, which at the time was only
available in binary format. I'm not sure when GTK first became available
separately from Gimp, but it was quite early on, I remember from an old
Linux Journal article I can no longer find. Having tried Motif an XForms
for a project, I started using Qt directly I read the first article about
it in Linux Journal (http://www.linuxjournal.com/article/201).

Wonderful times, fond memories. Everyone seemed to be hyped by all the work
everyone was doing, no matter in which technology.

Nokia relicenses Qt

Posted Jan 22, 2009 10:07 UTC (Thu) by yodermk (subscriber, #3803) [Link]

This is fantastic indeed. I had always wavered on whether or not to learn Qt because, although much of what I want to write would be GPL, I wanted at least the possibility of being able to use the same knowledge to write commercially. I also wavered on learning GTK because it wasn't as good as Qt (sorry if that's taken as flamebait, but I think most would acknowledge that it is true). As a result, I never put much effort into GUI applications on Linux.

Since this announcement I've been digging heavily into Qt. I hope to release a GPL application in a month or so.

Nokia relicenses Qt

Posted Jan 22, 2009 11:12 UTC (Thu) by hppnq (guest, #14462) [Link]

I also wavered on learning GTK because it wasn't as good as Qt (sorry if that's taken as flamebait, but I think most would acknowledge that it is true).

It is not your opinion about Gtk that is flamebait, but your assertion that it applies to most of us. I have always hated the looks of Qt. I don't even use it.

As a result, I never put much effort into GUI applications on Linux.

Real men program against the X libraries!

Nokia relicenses Qt

Posted Jan 22, 2009 11:51 UTC (Thu) by nix (subscriber, #2304) [Link]

The looks of Qt are skinnable to an enormous extent (just as is true for Gtk).

Nokia relicenses Qt

Posted Jan 22, 2009 13:19 UTC (Thu) by aleXXX (subscriber, #2742) [Link]

Real men...
http://xkcd.com/378/

Alex

Nokia relicenses Qt

Posted Jan 25, 2009 9:16 UTC (Sun) by quotemstr (subscriber, #45331) [Link]

Real men program against the X libraries!
No, real men talk directly to the X server. :-)

Nokia relicenses Qt

Posted Jan 22, 2009 17:22 UTC (Thu) by iabervon (subscriber, #722) [Link]

On the programming side, Gtk is kind of lame (the programmer has to do a lot of dumb things, like tell it that each UI element should be shown). Qt is kind of overly complicated (some stuff in a language barely recognizable as C++, some stuff in a custom language).

There's really no reason not to learn Gtk; it'll take a week and be informative.

Nokia relicenses Qt

Posted Jan 23, 2009 14:11 UTC (Fri) by cventers (guest, #31465) [Link]

There's really no reason not to learn Gtk; it'll take a week and be informative.

I agree... although I am in the "Qt is much better than Gtk" camp, I've written software for both, and I much prefer the C language to C++. Though I generally always reach for Qt when doing a GUI app, I think the time I spent learning enough to do basic Gtk apps was worthwhile, and it has led to me using glib in other projects.

Nokia relicenses Qt

Posted Jan 22, 2009 14:02 UTC (Thu) by clugstj (subscriber, #4020) [Link]

What does this line mean: "applies across almost all its products"

If it is licensed LGPL, then Nokia can't limit what product it is used in.

Nokia relicenses Qt

Posted Jan 22, 2009 15:32 UTC (Thu) by aleXXX (subscriber, #2742) [Link]

They have more products than just plain Qt, I think e.g. Qt Extended
(with the phone applications etc.).

Alex

Nokia relicenses Qt

Posted Mar 9, 2009 3:37 UTC (Mon) by csamuel (✭ supporter ✭, #2624) [Link]

Nokia's development of Qt Extended is now finished, I'm afraid, they're going to fold parts of it back into Qt. However, the sources are still available for others to continue on with.

Nokia relicenses Qt

Posted Jan 22, 2009 16:21 UTC (Thu) by dkite (guest, #4577) [Link]

The lgpl isn't retroactive. If they have a product based on a previous
version, it doesn't apply.

From my understanding, they also have some modules within the commercial
release of Qt that are of third party origin, and are not included in the
lgpl offerings.

Also, what was once known as Qtopia, the os/interface used on the Sharp
Zaurus, which is called something else now and still offered as a product,
isn't relicensed.

Derek

Nokia relicenses Qt

Posted Jan 29, 2009 19:21 UTC (Thu) by oak (guest, #2786) [Link]

Currently they own all the code so they can decide where the (LGPL)
license applies (e.g. not on Windows CE), that's why the announcement
about them accepting contributions is important.

Nokia relicenses Qt

Posted Jan 22, 2009 21:13 UTC (Thu) by giraffedata (subscriber, #1954) [Link]

Mr. Yrvin described how Nokia benefits from all this. He explained that instead of having different code bases for the same application when targeting different devices, Qt can improve the time to market, targeting desktop, mobile and embedded platforms with a single code base.

There is a logical leap here. What about offering an LGPL license for all this code, and accepting external contributions, means Qt no longer will have different code bases for the same application on different devices?

Nokia relicenses Qt

Posted Jan 23, 2009 2:50 UTC (Fri) by dkite (guest, #4577) [Link]

Back up a little. Nokia bought Qt for the benefits of a cross platform
library. They can have one code base for their applications that run on
numerous platforms.

The 4.5 version will include a port for symbian, which Nokia owns.
Under the previous arrangement, there would be some shops that would port
their application to that platform, commercial applications, maybe
vertical market. Maybe some gpl stuff would be ported, a qt or kde app that
a developer wanted to use on his S60 phone. More than
likely Nokia themselves would be the biggest user doing most of the testing
and finding the
corner case bugs.

If the lgpl license attracts new developers who target the phone market,
they will probably test the S60 port along with the CE and linux based
ports. And find bugs, suggest or submit improvements. Phonon started as a
KDE solution to the thorny question of what sound library to use. It is now
part of Qt. Nokia benefits from the improved library, all the while the
developers benefit from a great library that will open up platforms that
they would never have considered before. And applications sell hardware.

It's an interesting strategy. Microsoft is a step ahead in the platform
building game, Apple has their peculiar way of building a market that is
probably impossible for anyone to copy. Google is trying to build a
platform with Android. Same with Palm. The last two are late in the game,
but have some advantages to offer. It looks like Nokia is trying to
leverage the existing Qt developer base to build a platform. The call it Qt
everywhere.

I understood the Trolltech/KDE relationship. I've had two
platforms disappear underneath me, losing the learning and development
effort. I don't want to repeat that too many times. When Nokia bought
Trolltech I could see why they bought it. Excellent technology that
probably even if used internally would make sense to them. But that
wouldn't make sense for KDE. And if it didn't make sense, it wouldn't last.

But I see how Nokia benefits from KDE. If KDE does well, keeps vigorous,
new developers learn the api and Qt, come up with neat ideas, Nokia's
platform benefits. As does KDE.

Interesting. We shall see how it plays out.

Derek

Care needed with the term "free"

Posted Jan 29, 2009 5:16 UTC (Thu) by bignose (subscriber, #40) [Link]

LWN is usually careful when referring to something as "free". This article, though, regresses somewhat:

> Trolltech (now known as Qt Software) started marketing the Qt cross-platform library in 1996, and made the X11 version available under a free use, code available license.

No, they made the code available under a *zero-cost*, code-available license. It was certainly not free use (notably, it restricted redistribution of modified versions); that was, indeed, the entire point of the controversy around the license.

Stallman's criticism

Posted Jan 29, 2009 16:50 UTC (Thu) by donbarry (guest, #10485) [Link]

I'd like to correct a misapprehension in the article concerning
Stallman's role: his criticism was against Qt's original non-free
license! When Trolltech converted from the QPL to the GPL, Stallman
congratulated them and retracted his concerns, though he still preferred
to cheer the GNOME camp because they had had to take up the mantra
from scratch, and were considered part of the GNU team (remember,
GNOME stands for GNU Object Model Environment -- even if the
corporate-types shunned Stallman from the GNOME board, which is forever
to their discredit).


Stallman's criticism

Posted Jan 29, 2009 22:30 UTC (Thu) by nix (subscriber, #2304) [Link]

GNOME stands (stood?) for GNU Network Object Model Environment.

With the demise of bonobo the Network part seems to have been lost :/

Copyright © 2009, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds