이 페이지에서

Windows용 Qt - Windows App SDK

구성

Qt 앱에서 Windows App SDK를 사용하려면 SDK 경로를 구성하십시오.

사용 방법 Qt Creator

Qt Creator 에서 Windows App SDK를 구성하려면 ‘ Preferences ’ > ‘ SDKs ’로 이동하십시오.

\QC SDK 환경 설정.

자세한 내용은 Qt Creator 문서를 참조하십시오.

명령줄에서

  1. 빈 디렉토리로 이동합니다.

    예:

    mkdir C:\Dev\wasdk
    cd C:\Dev\wasdk
  2. 해당 디렉터리에 NuGet을 다운로드합니다.

    예를 들어, PowerShell을 사용하여 명령줄에서 다운로드하려면:

    powershell.exe -Command "& {Invoke-WebRequest https://dist.nuget.org/win-x86-commandline/latest/nuget.exe -OutFile nuget.exe}"
  3. NuGet을 사용하여 Windows App SDK를 다운로드하십시오.
    nuget.exe install Microsoft.WindowsAppSDK -OutputDirectory ./
  4. WIN_APP_SDK_ROOT 환경 변수를 Windows App SDK 디렉터리(일반적으로 Microsoft.WindowsAppSDK.{Version})로 설정합니다.

    예를 들어, 명령줄을 사용하는 경우:

    cd Microsoft.WindowsAppSDK.*
    set WIN_APP_SDK_ROOT=%cd%
    setX WIN_APP_SDK_ROOT %cd%

Qt 앱에서 Windows App SDK 사용하기

프로젝트의 CMake 파일에서 qt_add_win_app_sdk(ProjectName) CMake 함수를 호출하십시오. ProjectName을 프로젝트 이름으로 대체하십시오.

다음과 같은 조건을 사용하여 빌드가 MSVC 빌드용으로만 수행되도록 하십시오:

if (MSVC)
    qt_add_win_app_sdk(ProjectName)
endif()

© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.