Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Porting from Qt 5.15.2 to Qt 6.3.1

Porting from Qt 5.15.2 to Qt 6.3.1

Scheduled Pinned Locked Moved Unsolved General and Desktop
8 Posts 3 Posters 903 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • SPlattenS Offline
    SPlattenS Offline
    SPlatten
    wrote on last edited by SPlatten
    #1

    I'm trying to build an existing project previous using Qt 5.15.2, I've added the kit for 5.6.3.1, some differences in the folder structure, also a lot of things now won't compile, errors like:

    /Users/sy/XMLMPAM/clsJSON.cpp:14: error: 'QTextCodec' file not found
    ../clsJSON.cpp:14:10: fatal error: 'QTextCodec' file not found
    #include <QTextCodec>
             ^~~~~~~~~~~~
    /Users/sy/XMLMPAM/clsMainWnd.h:379: error: 'QDesktopWidget' file not found
    In file included from ../clsMainWnd.cpp:7:
    In file included from ../../XMLMPAM/clsCNT.h:50:
    ../../XMLMPAM/clsMainWnd.h:379:14: fatal error: 'QDesktopWidget' file not found
        #include <QDesktopWidget>
                 ^~~~~~~~~~~~~~~~
    :-1: error: [clsJSON.o] Error 1
    /Users/sy/XMLMPAM/clsDebugService.cpp:59: error: no member named 'midRef' in 'QString'
    ../clsDebugService.cpp:59:43: error: no member named 'midRef' in 'QString'
                    uint16DebugLevel = strMsg.midRef(0, intLevelLength).toUInt();
                                       ~~~~~~ ^
    

    Is this possible to port ? Is there a guide ?

    Kind Regards,
    Sy

    JKSHJ 1 Reply Last reply
    0
    • SPlattenS SPlatten

      I'm trying to build an existing project previous using Qt 5.15.2, I've added the kit for 5.6.3.1, some differences in the folder structure, also a lot of things now won't compile, errors like:

      /Users/sy/XMLMPAM/clsJSON.cpp:14: error: 'QTextCodec' file not found
      ../clsJSON.cpp:14:10: fatal error: 'QTextCodec' file not found
      #include <QTextCodec>
               ^~~~~~~~~~~~
      /Users/sy/XMLMPAM/clsMainWnd.h:379: error: 'QDesktopWidget' file not found
      In file included from ../clsMainWnd.cpp:7:
      In file included from ../../XMLMPAM/clsCNT.h:50:
      ../../XMLMPAM/clsMainWnd.h:379:14: fatal error: 'QDesktopWidget' file not found
          #include <QDesktopWidget>
                   ^~~~~~~~~~~~~~~~
      :-1: error: [clsJSON.o] Error 1
      /Users/sy/XMLMPAM/clsDebugService.cpp:59: error: no member named 'midRef' in 'QString'
      ../clsDebugService.cpp:59:43: error: no member named 'midRef' in 'QString'
                      uint16DebugLevel = strMsg.midRef(0, intLevelLength).toUInt();
                                         ~~~~~~ ^
      

      Is this possible to port ? Is there a guide ?

      JKSHJ Offline
      JKSHJ Offline
      JKSH
      Moderators
      wrote on last edited by
      #2

      @SPlatten said in Porting from Qt 5.15.2 to Qt 5.6.3.1:

      Is this possible to port ? Is there a guide ?

      Porting guides normally describe how to port to a newer version, not to an older version.

      Having said that, Qt 5.6 definitely has QTextCodec, QDesktopWidget, and QString::midRef().

      some differences in the folder structure

      This is probably the cause of your errors. Don't change the folder structure.

      Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

      J.HilkJ SPlattenS 2 Replies Last reply
      0
      • JKSHJ JKSH

        @SPlatten said in Porting from Qt 5.15.2 to Qt 5.6.3.1:

        Is this possible to port ? Is there a guide ?

        Porting guides normally describe how to port to a newer version, not to an older version.

        Having said that, Qt 5.6 definitely has QTextCodec, QDesktopWidget, and QString::midRef().

        some differences in the folder structure

        This is probably the cause of your errors. Don't change the folder structure.

        J.HilkJ Offline
        J.HilkJ Offline
        J.Hilk
        Moderators
        wrote on last edited by
        #3

        @JKSH I'm almost 100% sure the OP meant Qt 6.3.1 instead of Qt 5.6.3.1

        @SPlatten take a look here for at least a general guideline :
        https://doc.qt.io/qt-6/portingguide.html


        Be aware of the Qt Code of Conduct, when posting : https://forum.qt.io/topic/113070/qt-code-of-conduct


        Q: What's that?
        A: It's blue light.
        Q: What does it do?
        A: It turns blue.

        JKSHJ 1 Reply Last reply
        1
        • JKSHJ JKSH

          @SPlatten said in Porting from Qt 5.15.2 to Qt 5.6.3.1:

          Is this possible to port ? Is there a guide ?

          Porting guides normally describe how to port to a newer version, not to an older version.

          Having said that, Qt 5.6 definitely has QTextCodec, QDesktopWidget, and QString::midRef().

          some differences in the folder structure

          This is probably the cause of your errors. Don't change the folder structure.

          SPlattenS Offline
          SPlattenS Offline
          SPlatten
          wrote on last edited by SPlatten
          #4

          @JKSH, Sorry that was a typo/mistake on my part it should have read 6.3.1.

          Kind Regards,
          Sy

          1 Reply Last reply
          0
          • J.HilkJ J.Hilk

            @JKSH I'm almost 100% sure the OP meant Qt 6.3.1 instead of Qt 5.6.3.1

            @SPlatten take a look here for at least a general guideline :
            https://doc.qt.io/qt-6/portingguide.html

            JKSHJ Offline
            JKSHJ Offline
            JKSH
            Moderators
            wrote on last edited by
            #5

            @J-Hilk said in Porting from Qt 5.15.2 to Qt 5.6.3.1:

            @JKSH I'm almost 100% sure the OP meant Qt 6.3.1 instead of Qt 5.6.3.1

            D'oh, of course 😂

            6.3.1 doesn't have QTextCodec, QDesktopWidget, and QString::midRef() indeed!

            Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

            SPlattenS 1 Reply Last reply
            0
            • JKSHJ JKSH

              @J-Hilk said in Porting from Qt 5.15.2 to Qt 5.6.3.1:

              @JKSH I'm almost 100% sure the OP meant Qt 6.3.1 instead of Qt 5.6.3.1

              D'oh, of course 😂

              6.3.1 doesn't have QTextCodec, QDesktopWidget, and QString::midRef() indeed!

              SPlattenS Offline
              SPlattenS Offline
              SPlatten
              wrote on last edited by
              #6

              @JKSH , thank you, is there a way forward ?

              Kind Regards,
              Sy

              JKSHJ 1 Reply Last reply
              0
              • SPlattenS SPlatten

                @JKSH , thank you, is there a way forward ?

                JKSHJ Offline
                JKSHJ Offline
                JKSH
                Moderators
                wrote on last edited by
                #7

                @SPlatten said in Porting from Qt 5.15.2 to Qt 6.3.1:

                @JKSH , thank you, is there a way forward ?

                You're welcome. Yes, the link that @J-Hilk posted shows you how to move forward. The first part of the process is to eliminate all deprecation warnings when you build with Qt 5.15.

                Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

                SPlattenS 1 Reply Last reply
                2
                • JKSHJ JKSH

                  @SPlatten said in Porting from Qt 5.15.2 to Qt 6.3.1:

                  @JKSH , thank you, is there a way forward ?

                  You're welcome. Yes, the link that @J-Hilk posted shows you how to move forward. The first part of the process is to eliminate all deprecation warnings when you build with Qt 5.15.

                  SPlattenS Offline
                  SPlattenS Offline
                  SPlatten
                  wrote on last edited by
                  #8

                  @JKSH , @J-Hilk , thank you, will take a look now.

                  Kind Regards,
                  Sy

                  1 Reply Last reply
                  1

                  • Login

                  • Login or register to search.
                  • First post
                    Last post
                  0
                  • Categories
                  • Recent
                  • Tags
                  • Popular
                  • Users
                  • Groups
                  • Search
                  • Get Qt Extensions
                  • Unsolved