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. Visual Studio doesn't find Qt static source for debug mode
Forum Updated to NodeBB v4.3 + New Features

Visual Studio doesn't find Qt static source for debug mode

Scheduled Pinned Locked Moved Unsolved General and Desktop
3 Posts 3 Posters 288 Views 1 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.
  • C Offline
    C Offline
    Cesar
    wrote on 23 Sept 2022, 01:01 last edited by
    #1

    I have compiled the static source of qt 6.3.1 with Visual Studio 2022 and the following command:

    configure.bat -static -debug-and-release -platform win32-msvc -opensource -confirm-license -prefix "D:\Qt\Static\Release"
    

    When i compile any project under release it work correctly.

    When i try compiling under debug it fails and prompt: cannot open file 'D:\Qt\Static\Release\plugins\styles\qwindowsvistastyled.lib'

    I dont have any qwindowsvistastyled.lib in this folder, i do have it on:

    D:\Qt\Static\qt-everywhere-src-6.3.1\qtbase\plugins\styles

    I tried adding these config under the Qt VS Tools plugin:

    pic

    And modified the project settings to use it under debug:
    enter image description here

    But it continues searching for qwindowsvistastyled.lib in the

    'D:\Qt\Static\Release\plugins\styles\qwindowsvistastyled.lib'
    folder

    I tried cleaning project, rebuilding, restarting the editor, what I'm missing?

    cross-post: Stack

    C 1 Reply Last reply 23 Sept 2023, 11:42
    0
    • S Offline
      S Offline
      scwangpeng_139
      wrote on 23 Sept 2023, 00:45 last edited by scwangpeng_139
      #2

      configure -prefix "d:\qt5-qtbase" -shared -release -nomake examples -nomake tests -opensource -confirm-license
      nmake module-qtbase
      cd qtbase
      nmake install

      modify project setting from "DEBUG" -> "RELEASE", or compile source file for share

      1 Reply Last reply
      0
      • C Cesar
        23 Sept 2022, 01:01

        I have compiled the static source of qt 6.3.1 with Visual Studio 2022 and the following command:

        configure.bat -static -debug-and-release -platform win32-msvc -opensource -confirm-license -prefix "D:\Qt\Static\Release"
        

        When i compile any project under release it work correctly.

        When i try compiling under debug it fails and prompt: cannot open file 'D:\Qt\Static\Release\plugins\styles\qwindowsvistastyled.lib'

        I dont have any qwindowsvistastyled.lib in this folder, i do have it on:

        D:\Qt\Static\qt-everywhere-src-6.3.1\qtbase\plugins\styles

        I tried adding these config under the Qt VS Tools plugin:

        pic

        And modified the project settings to use it under debug:
        enter image description here

        But it continues searching for qwindowsvistastyled.lib in the

        'D:\Qt\Static\Release\plugins\styles\qwindowsvistastyled.lib'
        folder

        I tried cleaning project, rebuilding, restarting the editor, what I'm missing?

        cross-post: Stack

        C Offline
        C Offline
        Chris Kawa
        Lifetime Qt Champion
        wrote on 23 Sept 2023, 11:42 last edited by
        #3

        @Cesar Since you're using -debug-and-release both configurations are built, but you need to install them separately, so after you build do

        cmake --install .
        cmake --install . --config Debug
        

        the first one installs the Release config and the other one Debug.

        With that you shouldn't add two versions in the VS tools dialog. It's the same build and you switch between them with the configuration switch combo box.

        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