mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-03 17:56:44 +02:00
<!-- Enter a brief description/summary of your PR here. What does it fix/what does it change/how was it tested (even manually, if necessary)? --> ## Summary of the Pull Request Update project references across multiple projects to utilize `$(RepoRoot)` for paths, ensuring consistency and improving maintainability. <!-- Please review the items on the PR checklist before submitting--> ## PR Checklist - [ ] Closes: N/A - [ ] **Communication:** I've discussed this with core contributors already. If the work hasn't been agreed, this work might be rejected - [x] **Tests:** Added/updated and all pass - [ ] **Localization:** All end-user-facing strings can be localized - [ ] **Dev docs:** Added/updated - [ ] **New binaries:** Added on the required places - [ ] [JSON for signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json) for new binaries - [ ] [WXS for installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs) for new binaries and localization folder - [ ] [YML for CI pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml) for new test projects - [ ] [YML for signed pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml) - [ ] **Documentation updated:** If checked, please file a pull request on [our docs repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys) and link it here: #xxx <!-- Provide a more detailed description of the PR, other things fixed, or any additional comments/features here --> ## Detailed Description of the Pull Request / Additional comments This change affects the following projects: - `src/common/ManagedCsWin32/ManagedCsWin32.csproj` - `src/common/Common.Search/Common.Search.csproj` - `src/common/AllExperiments/AllExperiments.csproj` - `src/modules/peek/Peek.Common/Peek.Common.csproj` - `src/common/UITestAutomation/UITestAutomation.csproj` - `src/common/GPOWrapperProjection/GPOWrapperProjection.csproj` - `src/modules/powerrename/PowerRenameUITest/PowerRename.UITests.csproj` - `src/common/LanguageModelProvider/LanguageModelProvider.csproj` - `src/modules/Hosts/Hosts.Tests/HostsEditor.UnitTests.csproj` - `tools/StylesReportTool/StylesReportTool.vcxproj` - `src/common/interop/interop-tests/Common.Interop.UnitTests.csproj` - `tools/MonitorReportTool/MonitorReportTool.vcxproj` - `src/common/ManagedTelemetry/Telemetry/ManagedTelemetry.csproj` - `src/modules/peek/Peek.FilePreviewer/Peek.FilePreviewer.csproj` - `src/settings-ui/Settings.UI.Controls/Settings.UI.Controls.csproj` - `src/common/Themes/Themes.vcxproj` - `src/common/COMUtils/COMUtils.vcxproj` - `src/modules/cmdpal/Tests/Microsoft.CmdPal.UITests/Microsoft.CmdPal.UITests.csproj` - `src/modules/imageresizer/tests/ImageResizer.UnitTests.csproj` The changes were validated by running existing unit tests, which all passed successfully. <!-- Describe how you validated the behavior. Add automated tests wherever possible, but list manual validation steps taken as well --> ## Validation Steps Performed Executed all unit tests related to the modified projects, confirming that all tests passed without issues. ```
158 lines
7.3 KiB
XML
158 lines
7.3 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
|
<PropertyGroup Label="NuGet">
|
|
<!-- Tell NuGet this is PackageReference style -->
|
|
<RestoreProjectStyle>PackageReference</RestoreProjectStyle>
|
|
|
|
<!-- Tell NuGet we're a native project -->
|
|
<NuGetTargetMoniker>native,Version=v0.0</NuGetTargetMoniker>
|
|
|
|
<!-- Tell NuGet we target Windows (use your existing WindowsTargetPlatformVersion) -->
|
|
<NuGetTargetPlatformIdentifier>Windows</NuGetTargetPlatformIdentifier>
|
|
<NuGetTargetPlatformVersion>$(WindowsTargetPlatformVersion)</NuGetTargetPlatformVersion>
|
|
</PropertyGroup>
|
|
<PropertyGroup Label="Globals">
|
|
<VCProjectVersion>15.0</VCProjectVersion>
|
|
<ProjectGuid>{e94fd11c-0591-456f-899f-efc0ca548336}</ProjectGuid>
|
|
<Keyword>Win32Proj</Keyword>
|
|
<RootNamespace>FindMyMouse</RootNamespace>
|
|
<ProjectName>FindMyMouse</ProjectName>
|
|
<CppWinRTOptimized>true</CppWinRTOptimized>
|
|
<CppWinRTEnableComponentProjection>false</CppWinRTEnableComponentProjection>
|
|
<CppWinRTGenerateWindowsMetadata>false</CppWinRTGenerateWindowsMetadata>
|
|
<WindowsAppSdkBootstrapInitialize>false</WindowsAppSdkBootstrapInitialize>
|
|
<WindowsAppSDKSelfContained>false</WindowsAppSDKSelfContained>
|
|
<WindowsAppSDKVerifyTransitiveDependencies>false</WindowsAppSDKVerifyTransitiveDependencies>
|
|
</PropertyGroup>
|
|
<ItemGroup>
|
|
<PackageReference Include="Microsoft.WindowsAppSDK" GeneratePathProperty="true"/>
|
|
<PackageReference Include="Microsoft.WindowsAppSDK.Foundation" GeneratePathProperty="true"/>
|
|
<PackageReference Include="Microsoft.Windows.CppWinRT" GeneratePathProperty="true"/>
|
|
</ItemGroup>
|
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
|
<PropertyGroup Condition="'$(Configuration)'=='Debug'" Label="Configuration">
|
|
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
|
<UseDebugLibraries>true</UseDebugLibraries>
|
|
|
|
<CharacterSet>Unicode</CharacterSet>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition="'$(Configuration)'=='Release'" Label="Configuration">
|
|
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
|
<UseDebugLibraries>false</UseDebugLibraries>
|
|
|
|
<WholeProgramOptimization>true</WholeProgramOptimization>
|
|
<CharacterSet>Unicode</CharacterSet>
|
|
</PropertyGroup>
|
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
|
<ImportGroup Label="ExtensionSettings">
|
|
</ImportGroup>
|
|
<ImportGroup Label="Shared">
|
|
</ImportGroup>
|
|
<ImportGroup Label="PropertySheets">
|
|
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
|
</ImportGroup>
|
|
|
|
<PropertyGroup Label="UserMacros" />
|
|
<PropertyGroup>
|
|
<OutDir>$(RepoRoot)$(Platform)\$(Configuration)\</OutDir>
|
|
<TargetName>PowerToys.FindMyMouse</TargetName>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition="'$(Configuration)'=='Debug'">
|
|
<LinkIncremental>true</LinkIncremental>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition="'$(Configuration)'=='Release'">
|
|
<LinkIncremental>false</LinkIncremental>
|
|
</PropertyGroup>
|
|
<ItemDefinitionGroup Condition="'$(Configuration)'=='Debug'">
|
|
<ClCompile>
|
|
<WarningLevel>Level3</WarningLevel>
|
|
<Optimization>Disabled</Optimization>
|
|
<SDLCheck>true</SDLCheck>
|
|
<PreprocessorDefinitions>_DEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
|
<ConformanceMode>true</ConformanceMode>
|
|
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
|
|
<LanguageStandard>stdcpplatest</LanguageStandard>
|
|
</ClCompile>
|
|
<Link>
|
|
<SubSystem>Windows</SubSystem>
|
|
<GenerateDebugInformation>true</GenerateDebugInformation>
|
|
<OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>
|
|
</Link>
|
|
</ItemDefinitionGroup>
|
|
<ItemDefinitionGroup Condition="'$(Configuration)'=='Release'">
|
|
<ClCompile>
|
|
<WarningLevel>Level3</WarningLevel>
|
|
<Optimization>MaxSpeed</Optimization>
|
|
<FunctionLevelLinking>true</FunctionLevelLinking>
|
|
<IntrinsicFunctions>true</IntrinsicFunctions>
|
|
<SDLCheck>true</SDLCheck>
|
|
<PreprocessorDefinitions>NDEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
|
<ConformanceMode>true</ConformanceMode>
|
|
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
|
<LanguageStandard>stdcpplatest</LanguageStandard>
|
|
</ClCompile>
|
|
<Link>
|
|
<SubSystem>Windows</SubSystem>
|
|
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
|
<OptimizeReferences>true</OptimizeReferences>
|
|
<GenerateDebugInformation>true</GenerateDebugInformation>
|
|
<OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>
|
|
</Link>
|
|
</ItemDefinitionGroup>
|
|
<ItemDefinitionGroup>
|
|
<ClCompile>
|
|
<!-- Add Generated Files folder so #include <winrt/...> finds projected headers -->
|
|
<AdditionalIncludeDirectories>$(GeneratedFilesDir);$(RepoRoot)src\;$(RepoRoot)src\modules;$(RepoRoot)src\common\Telemetry;$(MSBuildThisFileDirectory)..\..\..\..\src\;$(MSBuildThisFileDirectory)..\..\..\..\src\modules;$(MSBuildThisFileDirectory)..\..\..\..\src\common\Telemetry;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
|
</ClCompile>
|
|
</ItemDefinitionGroup>
|
|
<ItemGroup>
|
|
<ClInclude Include="FindMyMouse.h" />
|
|
<ClInclude Include="pch.h" />
|
|
<ClInclude Include="resource.h" />
|
|
<ClInclude Include="trace.h" />
|
|
<ClInclude Include="WinHookEventIDs.h" />
|
|
</ItemGroup>
|
|
<ItemGroup>
|
|
<ClCompile Include="dllmain.cpp" />
|
|
<ClCompile Include="FindMyMouse.cpp" />
|
|
<ClCompile Include="pch.cpp">
|
|
<PrecompiledHeader Condition="'$(UsePrecompiledHeaders)' != 'false'">Create</PrecompiledHeader>
|
|
</ClCompile>
|
|
<ClCompile Include="trace.cpp" />
|
|
<ClCompile Include="WinHookEventIDs.cpp" />
|
|
</ItemGroup>
|
|
|
|
<ItemGroup>
|
|
<ProjectReference Include="$(RepoRoot)src\common\logger\logger.vcxproj">
|
|
<Project>{d9b8fc84-322a-4f9f-bbb9-20915c47ddfd}</Project>
|
|
</ProjectReference>
|
|
<ProjectReference Include="$(RepoRoot)src\common\SettingsAPI\SettingsAPI.vcxproj">
|
|
<Project>{6955446d-23f7-4023-9bb3-8657f904af99}</Project>
|
|
</ProjectReference>
|
|
</ItemGroup>
|
|
<ItemGroup>
|
|
<ResourceCompile Include="FindMyMouse.rc" />
|
|
</ItemGroup>
|
|
<!-- Deduplicate WindowsAppRuntimeAutoInitializer.cpp (added twice via transitive imports causing LNK4042). Remove all then add exactly once. -->
|
|
<Target Name="FixWinAppSDKAutoInitializer" BeforeTargets="ClCompile" AfterTargets="WindowsAppRuntimeAutoInitializer">
|
|
<ItemGroup>
|
|
<!-- Remove ALL injected versions of the file -->
|
|
<ClCompile Remove="@(ClCompile)" Condition="'%(Filename)' == 'WindowsAppRuntimeAutoInitializer'" />
|
|
|
|
<!-- Add ONE copy back manually -->
|
|
<ClCompile Include="$(PkgMicrosoft_WindowsAppSDK_Foundation)\include\WindowsAppRuntimeAutoInitializer.cpp">
|
|
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
|
</ClCompile>
|
|
</ItemGroup>
|
|
</Target>
|
|
<Target Name="RemoveManagedWebView2CoreFromNativeOutDir" AfterTargets="Build">
|
|
<ItemGroup>
|
|
<_ToDelete Include="$(OutDir)Microsoft.Web.WebView2.Core.dll" />
|
|
</ItemGroup>
|
|
<Delete Files="@(_ToDelete)" Condition="Exists('%(Identity)')" />
|
|
</Target>
|
|
|
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
|
<Import Project="$(RepoRoot)deps\spdlog.props" />
|
|
</Project>
|