Results 1 to 11 of 11

Thread: Porting 4.4.2 to 4.7.0

  1. #1
    Join Date
    Oct 2010
    Posts
    2
    Qt products
    Qt4
    Platforms
    Windows

    Default Porting 4.4.2 to 4.7.0

    Hi,

    We have an application that has been developed using C++ and Qt 4.4.2 Commercial under Visual Studio 2008.

    I have installed the latest version of Qt (4.7.0 LGPL and Commercial). When I create a new Qt project in VS2008, the new code compiles with no problem, so there is nothing wrong with the installation itself.

    My aim has been to port the application written in QT 4.4.2 to QT 4.7.0. However, after importing the code, the code fails to compile with multiple compilation issues.

    Could anyone advise why this may be happening, or point me to any QT resources that may help with porting older QT code to the latest version?

    If an older system is written with a commercial release, does that prohibit porting the system to a later LGPL version?

    Cheers,
    Lee.

  2. #2
    Join Date
    Jan 2006
    Location
    Belgium
    Posts
    1,938
    Thanked 268 Times in 268 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Wiki edits
    20

    Default Re: Porting 4.4.2 to 4.7.0

    Quote Originally Posted by Lee B View Post
    Could anyone advise why this may be happening, or point me to any QT resources that may help with porting older QT code to the latest version?
    Can you post the error messages please?

    As far as I know, Qt 4.x code should work over the whole line of Qt 4.x libraries (backwards that is)

  3. #3
    Join Date
    Jan 2008
    Location
    Davao City, Philippines
    Posts
    77
    Thanks
    16
    Thanked 4 Times in 4 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: Porting 4.4.2 to 4.7.0

    Hi Lee,

    Quote Originally Posted by Lee B View Post
    My aim has been to port the application written in QT 4.4.2 to QT 4.7.0. However, after importing the code, the code fails to compile with multiple compilation issues.
    I had similar problems too in the past. So, if you don't have a better idea and the project is important for you, do it step by step.

    Here you can get the old versions of Qt: http://download.qt.nokia.com/qt/source

    Try to convert it from 4,4.2 to - let's say - 4.5 and then to 4.6 and so on.

    Yes, I know, it's a heavy job ...
    Last edited by gboelter; 18th October 2010 at 17:08. Reason: spelling corrections
    DavaoSOFT, the home of ERPel
    ERPel, das deutsche Warenwirtschaftssystem fuer LINUX
    http://www.davaosoft.com

  4. #4
    Join Date
    Jan 2006
    Location
    Germany
    Posts
    4,380
    Thanks
    19
    Thanked 1,005 Times in 913 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows Symbian S60
    Wiki edits
    5

    Default Re: Porting 4.4.2 to 4.7.0

    Quote Originally Posted by Lee B View Post
    If an older system is written with a commercial release, does that prohibit porting the system to a later LGPL version?
    This way it is no problem. But if you want to change from LGPL to commercial there are some "difficulties".

    Quote Originally Posted by gboelter View Post
    Try to convert it from 4,4.2 to - let's say - 4.5 and then to 4.6 and so on.
    Yeah, and don't forget to convert it first to Python, then Java, from there to Basic and then back to Qt. Seriously why do you want to do more work by stepping through older releases? That doesn't make sense. Just target 4.7 straight forward. The errors probably only because of some API changes which could be cleaned by some search&replace.

  5. #5
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,364
    Thanks
    3
    Thanked 5,012 Times in 4,791 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Porting 4.4.2 to 4.7.0

    Quote Originally Posted by Lee B View Post
    I have installed the latest version of Qt (4.7.0 LGPL and Commercial).
    Based on MinGW or Visual Studio?

    However, after importing the code, the code fails to compile with multiple compilation issues.
    After "importing" it where?

    Could anyone advise why this may be happening, or point me to any QT resources that may help with porting older QT code to the latest version?
    You shouldn't need to port anything. 4.7 is compatible with 4.4 on the source code level.

    If an older system is written with a commercial release, does that prohibit porting the system to a later LGPL version?
    You can switch between LGPL/commercial freely (both ways). This wasn't the case when Qt was GPL, then Trolls were getting angry if someone was switching from GPL to commercial.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  6. #6
    Join Date
    Jan 2008
    Location
    Davao City, Philippines
    Posts
    77
    Thanks
    16
    Thanked 4 Times in 4 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: Porting 4.4.2 to 4.7.0

    Quote Originally Posted by Lykurg View Post
    Yeah, and don't forget to convert it first to Python, then Java, from there to Basic and then back to Qt. Seriously why do you want to do more work by stepping through older releases? That doesn't make sense. Just target 4.7 straight forward. The errors probably only because of some API changes which could be cleaned by some search&replace.
    Lykurg, I know that you are good, but Lee is a beginner in Qt. If there are to many error-messages, that's very frustrating for a beginner.

    So, what's wrong in doing it step by step if the project is really important for him?

    I had a similar problem just a few weeks ago. To compile my source with 4.7 instead 4.6.3 was now problem under Linux. Under windows I got many error-messages.
    DavaoSOFT, the home of ERPel
    ERPel, das deutsche Warenwirtschaftssystem fuer LINUX
    http://www.davaosoft.com

  7. #7
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,364
    Thanks
    3
    Thanked 5,012 Times in 4,791 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Porting 4.4.2 to 4.7.0

    Quote Originally Posted by gboelter View Post
    So, what's wrong in doing it step by step if the project is really important for him?
    Apart from doing the same thing 10 times? Nothing, I guess. If you have a couple of evenings to spare with nothing better to do then go ahead.

    The errors OP is getting are probably unrelated to the version change at all. Most likely there are some stale files in the project directory, the compiler or the environment (as in available libraries and stuff) have been changed by the project developer. In times such as this people tend to forget they installed/uninstalled/reinstalled/modified something in their system and/or project source code.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  8. #8
    Join Date
    Jan 2006
    Location
    Germany
    Posts
    4,380
    Thanks
    19
    Thanked 1,005 Times in 913 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows Symbian S60
    Wiki edits
    5

    Default Re: Porting 4.4.2 to 4.7.0

    Quote Originally Posted by wysota View Post
    You can switch between LGPL/commercial freely (both ways). This wasn't the case when Qt was GPL, then Trolls were getting angry if someone was switching from GPL to commercial.
    Damn, yes you are right, it was about GPL. It's nice to heare that they have no trouble with LGPL/comercial switches.

  9. #9
    Join Date
    Jan 2008
    Location
    Davao City, Philippines
    Posts
    77
    Thanks
    16
    Thanked 4 Times in 4 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: Porting 4.4.2 to 4.7.0

    Quote Originally Posted by wysota View Post
    The errors OP is getting are probably unrelated to the version change at all. Most likely there are some stale files in the project directory, the compiler or the environment (as in available libraries and stuff) have been changed by the project developer. In times such as this people tend to forget they installed/uninstalled/reinstalled/modified something in their system and/or project source code.
    May be, may be not! I have not seen any error messages from Lee until now.

    What's going on here? From what I understand, he has an application it's developed under Qt 4.4.2 and while trying to compile it under 4.7.0, he got many errors. So, what's wrong to install Qt 4.4.2 and compile the programm with that?

    Later on he can try to compile it with a newer version of Qt ...
    DavaoSOFT, the home of ERPel
    ERPel, das deutsche Warenwirtschaftssystem fuer LINUX
    http://www.davaosoft.com

  10. #10
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,364
    Thanks
    3
    Thanked 5,012 Times in 4,791 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Porting 4.4.2 to 4.7.0

    Quote Originally Posted by gboelter View Post
    May be, may be not!
    Maybe they are related to the phase of the current that happened to be flowing through the power socket when he clicked the build button...

    I have not seen any error messages from Lee until now.
    Qt 4.7 is source-compatible with Qt 4.4.
    So, what's wrong to install Qt 4.4.2 and compile the programm with that?
    1. time/money spent downloading/installing/setting up Qt 4.4.2
    2. no progress - he wants to build the application with 4.7 and not 4.4.
    3. no relation between getting things to build with 4.4 and 4.7 - even if it builds against 4.4, it doesn't mean 4.7 incompatibility is to "blame", for example if you make some stupid mistake each time you install 4.7, the fact that your 4.4 installation works correctly will get you nowhere if you keep repeating the same mistake during each and every install of 4.7.

    And between 4.4 there were also 4.5 and 4.6 and releases of each of the minor versions. This gives well over 10 installations you need to perform just to click one "build" button to see nothing has changed since the previous release.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  11. #11
    Join Date
    Oct 2010
    Posts
    2
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Porting 4.4.2 to 4.7.0

    Hi,

    Thanks to everyone who has posted replies. The information given has been very helpful and thought provoking, and I will follow up the various strategies you have suggested to get the application running.
    I am unable to post the exact error messages etc at the moment due to being away from the office. I will look at trying some of your ideas as soon as I get back.

    Thanks again,
    Lee.

Similar Threads

  1. Need some help porting from Qt3 to Qt4
    By psadhukhan in forum Qt Programming
    Replies: 3
    Last Post: 27th November 2008, 10:02
  2. Porting qt3 to qt4
    By divya balachandran in forum Qt Programming
    Replies: 1
    Last Post: 5th September 2008, 23:49
  3. Porting Qt3 To Qt4
    By fruzzo in forum Qt Programming
    Replies: 1
    Last Post: 6th August 2008, 14:59
  4. Porting from qwt-4.2.0 to qwt-5.0.2
    By vheinitz in forum Qwt
    Replies: 3
    Last Post: 31st January 2008, 12:39
  5. Porting from Qt3 to Qt4
    By Opilki_Inside in forum Installation and Deployment
    Replies: 1
    Last Post: 1st February 2006, 18:20

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.