We're a community of 1.1M IT Pros here for help, advice, solutions, professional growth and fun. Join us!
1,080,464 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Start New Discussion Reply to this Discussion

QT4 and Liscence Terms

I'm just wondering if the below is true? I pulled this from another forum. Does this mean that a application using qt4 can be built and used in a bank without getting permission or paying fees for it's use?

The Framework is freely available for Windows, Linux, MacOS X, and a couple of mobile systems. Since version 4.5 the license is LGPL, which basically means that you can use Qt even in commercial applications.

thanks
danny2000

3
Contributors
6
Replies
16 Hours
Discussion Span
1 Year Ago
Last Updated
8
Views
Question
Answered
danny2000
Junior Poster
192 posts since Dec 2007
Reputation Points: 10
Solved Threads: 0
Skill Endorsements: 0

Assuming you meet the requirements of LGPL, it seems that way. This is cool, I wasn't aware Qt had moved to an open source library model. That's what had kept me from using it. :)

deceptikon
Challenge Accepted
Administrator
3,502 posts since Jan 2012
Reputation Points: 822
Solved Threads: 481
Skill Endorsements: 58

I agree deceptikon. I have been doing the same. I was just about to buy a book on wxwidgets and found that post. http://stackoverflow.com/questions/875686/advice-for-c-gui-programming
If anyone could let me know if I've interpreted this correctly that would be great. Like most, I just want to know for sure before using it full time.

thanks
danny2000

danny2000
Junior Poster
192 posts since Dec 2007
Reputation Points: 10
Solved Threads: 0
Skill Endorsements: 0

Here's another post on this subject. Maybe it helps clarrify things. I need to get my understanding of dynamic and statically linked dll's squared away to understand this.

http://stackoverflow.com/questions/352896/qt-commercial-licenses

danny2000
Junior Poster
192 posts since Dec 2007
Reputation Points: 10
Solved Threads: 0
Skill Endorsements: 0

Yet another good post on this topic. Would anyone know what is meant by dynamically linking to qt libraries??
Does this mean that when compiling a project build in qt4 I need to be online? Any way to clarrify this. thanks.

http://blog.qt.nokia.com/2009/11/30/qt-making-the-right-licensing-decision/

danny2000
Junior Poster
192 posts since Dec 2007
Reputation Points: 10
Solved Threads: 0
Skill Endorsements: 0

Would anyone know what is meant by dynamically linking to qt libraries??

Well, this is just a matter of knowing what dynamic linking means. Take wiki for a start. As a quick explanation, let me start from the basics. You have some code. In a usual project, you'll have a bunch of cpp files and their corresponding header files (declaring what is in the cpp files). Normally, on a small project, you compile all the cpp files together into an executable. In reality, the compiler compiles each cpp file separately into object files (.o or .obj) which contain the compiled code for the code in each cpp file, then, after the compiler is done, the linker puts all the object files together and links all the function calls to their corresponding binary code. Well, on a bigger project, or when using external libraries, you often won't do that. Instead, you can compile a bunch of cpp files and put all the resulting binary code into a library, which is like a repository of precompiled code (functions, classes, etc.). You can use that code in any program if you have all the header files for that library, but you don't need the cpp files (where all the real source code is), you only need to tell the compiler to link the library into your project. Now, there are two kinds of libraries, static and dynamic. A static library is merely a bundle of object files, and when you link to it in your own project, all the code that you use from it gets physically incorporated (copied) into your final executable. A dynamic library (like a DLL or .so) is a bit more than a bundle of object files and it is meant to be linked with your program at run-time (or load-time) of your application. This means that the DLL or .so file must be installed on the system directories of the OS, and when you launch your application, it will find this DLL or .so on your system, load it, and link to it (in order to be able to find code that is needed by your application). So, the dynamic libraries must be installed separately on the system, ahead of time (of course, you can check for that when you package your installer for you application).

The point with LGPL in a context like Qt, is that the Qt "platform" consists of a bunch of dynamic libraries and their associated header files. You write your program, using the header files to access to functions and all, you compile it, and then run it using the dynamic libraries installed on the system. If that is all you do, then your program can be commercial, proprietary, whatever... It is only if you modify the source (cpp files) of Qt libraries (to suite your own needs) that you must either make your own program open-source or negociate another licensing deal with Qt (possibly paying them royalty, because Qt does offer commercial licenses as well). But as long as you don't modify anything in Qt, and as long as you don't recompile Qt code and include it statically into your application, you're fine to use it for whatever purpose.

Does this mean that when compiling a project build in qt4 I need to be online?

No. It only means that if you distribute your application, you will need to direct the user to install Qt (run-time) on their system if they haven't done so already. You can also bundle the Qt installation with your own. This is the same as many computer games that include the "latest" DirectX version on their CD or DVD, the installer checks if you have the minimum required version already on your computer, if not, it starts the DirectX installer. You can basically do the same, or just check if the minimum required version of Qt is installed already, and if not, direct the user to the online downloader / installer for Qt run-time libraries. Here is more information, go to the "shared library" section ("shared library" and "dynamic-link library" are synonyms, although "shared library" is more traditionally used by Unix/Linux developers).

mike_2000_17
21st Century Viking
Moderator
3,167 posts since Jul 2010
Reputation Points: 2,082
Solved Threads: 637
Skill Endorsements: 42

can basically do the same, or just check if the minimum required version of Qt is installed already, and if not, direct the user to the online downloader / installer for Qt run-time libraries. Here is more information, go to the "shared library" section ("shared library" and "dynamic-link library" are synonyms, although "shared library" is more traditionally used by Unix/Linux developers).

brilliant, thanks for the help on this. I'm happy I understand this now. Yes, I definetly have some work to do.

cheers
danny2000

danny2000
Junior Poster
192 posts since Dec 2007
Reputation Points: 10
Solved Threads: 0
Skill Endorsements: 0
Question Answered as of 1 Year Ago by mike_2000_17 and deceptikon

This question has already been solved: Start a new discussion instead

Post: Markdown Syntax: Formatting Help
 
You
 
© 2013 DaniWeb® LLC
Page generated in 0.0818 seconds using 2.78MB