Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. LIBS += -lUser32 is no longer working

LIBS += -lUser32 is no longer working

Scheduled Pinned Locked Moved Solved Qt Creator and other tools
33 Posts 5 Posters 8.3k Views 2 Watching
  • 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.
  • hskoglundH Offline
    hskoglundH Offline
    hskoglund
    wrote on last edited by
    #23

    Hi, to get rid of some of those historical artifacts, you could try creating a new user on your Windows PC and installing Qt logged in as that new user. And if that doesn't cut it, perhaps reformatting your C: and installing a brand new Windows is your best bet (but make a backup first :-)

    EngelardE 1 Reply Last reply
    0
    • hskoglundH hskoglund

      Hi, to get rid of some of those historical artifacts, you could try creating a new user on your Windows PC and installing Qt logged in as that new user. And if that doesn't cut it, perhaps reformatting your C: and installing a brand new Windows is your best bet (but make a backup first :-)

      EngelardE Offline
      EngelardE Offline
      Engelard
      wrote on last edited by Engelard
      #24

      @hskoglund no, i can not reinstall Windows.

      I want to understand first, is this problem on side of Qt, or Microsoft compiler?

      UPD:
      It definitely something wrong with Qt, i can't add MinGW(which i was using back then year ago), same issue "The compiler blablabla cannot produce code for Qt Version"

      Chris KawaC 1 Reply Last reply
      0
      • EngelardE Engelard

        @hskoglund no, i can not reinstall Windows.

        I want to understand first, is this problem on side of Qt, or Microsoft compiler?

        UPD:
        It definitely something wrong with Qt, i can't add MinGW(which i was using back then year ago), same issue "The compiler blablabla cannot produce code for Qt Version"

        Chris KawaC Offline
        Chris KawaC Offline
        Chris Kawa
        Lifetime Qt Champion
        wrote on last edited by
        #25

        @Engelard As we said before - you can't mix MinGW with Qt build for MSVC. That's what the message is saying. If you want to use MinGW you need Qt build for MinGW.

        If you go to %appdata%/QtProject/qtcreator/ there's a file toolchains.xml. Close Qt Creator, make a backup of that file, delete it and start Qt Creator again. It should redetect everything. If it doesn't on its own press Re-detect on the compilers tab. Does it detect the correct 2022 abi then?

        EngelardE 1 Reply Last reply
        1
        • Chris KawaC Chris Kawa

          @Engelard As we said before - you can't mix MinGW with Qt build for MSVC. That's what the message is saying. If you want to use MinGW you need Qt build for MinGW.

          If you go to %appdata%/QtProject/qtcreator/ there's a file toolchains.xml. Close Qt Creator, make a backup of that file, delete it and start Qt Creator again. It should redetect everything. If it doesn't on its own press Re-detect on the compilers tab. Does it detect the correct 2022 abi then?

          EngelardE Offline
          EngelardE Offline
          Engelard
          wrote on last edited by Engelard
          #26

          @Chris-Kawa said in LIBS += -lUser32 is no longer working:

          As we said before - you can't mix MinGW with Qt build for MSVC

          I get it, i mean, i was using MinGW Kit before, and now with current mess - i can't. It was properly setuped back then.

          @Chris-Kawa said in LIBS += -lUser32 is no longer working:

          delete it and start Qt Creator again

          After deleting toolchains something finally changed! It allows me to select proper compilers at least in 'Replacement(whatever that is)' Kit, and it gives normal icon instead of warning or error. But it's complaining in project scope now that there is no Kits to select, but i tried to create new project, and there was option to select that new 'Replacement" kit. After project creation it give out me same complaint and it's not working, but at least some progress i have now. Thank you.
          1444.JPG

          jsulmJ 1 Reply Last reply
          0
          • EngelardE Engelard

            @Chris-Kawa said in LIBS += -lUser32 is no longer working:

            As we said before - you can't mix MinGW with Qt build for MSVC

            I get it, i mean, i was using MinGW Kit before, and now with current mess - i can't. It was properly setuped back then.

            @Chris-Kawa said in LIBS += -lUser32 is no longer working:

            delete it and start Qt Creator again

            After deleting toolchains something finally changed! It allows me to select proper compilers at least in 'Replacement(whatever that is)' Kit, and it gives normal icon instead of warning or error. But it's complaining in project scope now that there is no Kits to select, but i tried to create new project, and there was option to select that new 'Replacement" kit. After project creation it give out me same complaint and it's not working, but at least some progress i have now. Thank you.
            1444.JPG

            jsulmJ Offline
            jsulmJ Offline
            jsulm
            Lifetime Qt Champion
            wrote on last edited by
            #27

            @Engelard What Qt version is selected in your "Replacement" Kit?

            https://forum.qt.io/topic/113070/qt-code-of-conduct

            EngelardE 1 Reply Last reply
            0
            • jsulmJ jsulm

              @Engelard What Qt version is selected in your "Replacement" Kit?

              EngelardE Offline
              EngelardE Offline
              Engelard
              wrote on last edited by
              #28

              @jsulm none. And if i try to:

              1555.jpg

              jsulmJ 1 Reply Last reply
              0
              • EngelardE Engelard

                @jsulm none. And if i try to:

                1555.jpg

                jsulmJ Offline
                jsulmJ Offline
                jsulm
                Lifetime Qt Champion
                wrote on last edited by
                #29

                @Engelard Can you show the configuration of that Qt version? According to its name it should actually work with that compiler.

                https://forum.qt.io/topic/113070/qt-code-of-conduct

                EngelardE 1 Reply Last reply
                0
                • jsulmJ jsulm

                  @Engelard Can you show the configuration of that Qt version? According to its name it should actually work with that compiler.

                  EngelardE Offline
                  EngelardE Offline
                  Engelard
                  wrote on last edited by
                  #30

                  @jsulm

                  1666.JPG

                  jsulmJ 1 Reply Last reply
                  0
                  • EngelardE Engelard

                    @jsulm

                    1666.JPG

                    jsulmJ Offline
                    jsulmJ Offline
                    jsulm
                    Lifetime Qt Champion
                    wrote on last edited by
                    #31

                    @Engelard Just realized: you selected msvc2005 compiler which of course is not compatible with Qt for msvc2017.

                    https://forum.qt.io/topic/113070/qt-code-of-conduct

                    Chris KawaC 1 Reply Last reply
                    0
                    • jsulmJ jsulm

                      @Engelard Just realized: you selected msvc2005 compiler which of course is not compatible with Qt for msvc2017.

                      Chris KawaC Offline
                      Chris KawaC Offline
                      Chris Kawa
                      Lifetime Qt Champion
                      wrote on last edited by Chris Kawa
                      #32

                      @jsulm He has VS2022 MSVC selected, which is fine for this Qt, but for some reason it detects it as 2005 abi.

                      @Engelard I'm not sure why this is happening, but maybe you can workaround it. On the compiler tab select the amd64 compiler, click Clone, select the cloned one and see if you can switch the abi to 2022 in the properties below.
                      Btw. it's not related to the issue but you should rename that kit to something more adequate. It's neither a replacement nor x32. Put Qt %{Qt:Version} %{Compiler:Name} in the Name field and it will autogenerate the name based on compiler and Qt build.
                      Also, just to make sure you actually have a current MSVC compiler installed (it's an optional component in VS installation) - open Visual Studio Installer, switch to Individual Components tab and see if you have MSVC v143 - VS 2022 C++ x64/x86 build tools (Latest) selected there. If not install that.

                      EngelardE 1 Reply Last reply
                      2
                      • Chris KawaC Chris Kawa

                        @jsulm He has VS2022 MSVC selected, which is fine for this Qt, but for some reason it detects it as 2005 abi.

                        @Engelard I'm not sure why this is happening, but maybe you can workaround it. On the compiler tab select the amd64 compiler, click Clone, select the cloned one and see if you can switch the abi to 2022 in the properties below.
                        Btw. it's not related to the issue but you should rename that kit to something more adequate. It's neither a replacement nor x32. Put Qt %{Qt:Version} %{Compiler:Name} in the Name field and it will autogenerate the name based on compiler and Qt build.
                        Also, just to make sure you actually have a current MSVC compiler installed (it's an optional component in VS installation) - open Visual Studio Installer, switch to Individual Components tab and see if you have MSVC v143 - VS 2022 C++ x64/x86 build tools (Latest) selected there. If not install that.

                        EngelardE Offline
                        EngelardE Offline
                        Engelard
                        wrote on last edited by Engelard
                        #33

                        @Chris-Kawa said in LIBS += -lUser32 is no longer working:

                        On the compiler tab select the amd64 compiler, click Clone, select the cloned one and see if you can switch the abi to 2022 in the properties below.

                        OMG finally, i can't even believe is that something gonna to work, thank you. I tried to do that like a week ago, but i wasn't selecting right version in Kit, or something else was wrong, so i gave up and forgot that.
                        1999.jpg

                        1777.JPG

                        1888.JPG

                        So with manual selection it works, and compiles. Auto-detected Kit and compilers still are not usable for some reason, but that does'nt matter for me, i'm happy with manually selected stuff.

                        P.S. in x32 Qt creator i can't select version of compiler precisely, simply because there is no such options)
                        2000.JPG

                        1 Reply Last reply
                        0

                        • Login

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