Существует несколько решений (бизнес-логики c et c), которые копируют свои * .dll и * .pdb в некоторые каталоги.
<PropertyGroup>
<PostBuildEvent>copy $(TargetPath) $(DllDir)\*.*
copy $(TargetDir)*.pdb $(SymbolsFolder)\*.pdb </ PostBuildEvent> </ PropertyGroup>
есть несколько GUI -решений, которые ссылается на эти dll (а не на каждый из них, только на несколько) для лучшего опыта отладки, было бы здорово иметь возможность во время компиляции или после успешной сборки копировать * .pdb ссылочных сборок из $ (SymbolsFolder) в каталог bin / debug build GUI -project
что-то вроде этого в GUI * .csproj файле:
<Target Name="Compile">
<MSBuild Projects="@(Reference)" Targets="Build" >
copy $(SymbolsFolder)\'%(Name)'.pdb $(TargetDir)*.pdb
</MSBuild>
этот код не работает. Можете ли вы помочь мне исправить этот псевдокод, пожалуйста?
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{15E44798-6182-44B0-9302-C96532A334FF}</ProjectGuid>
<OutputType>library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>GuiControls</RootNamespace>
<AssemblyName>GuiControls</AssemblyName>
<TargetFrameworkVersion>v4.5.2</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
<WarningLevel>4</WarningLevel>
<TargetFrameworkProfile />
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Prefer32Bit>false</Prefer32Bit>
<UseVSHostingProcess>true</UseVSHostingProcess>
<PlatformTarget>AnyCPU</PlatformTarget>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<PropertyGroup>
<SignAssembly>true</SignAssembly>
</PropertyGroup>
<PropertyGroup>
<AssemblyOriginatorKeyFile>test21.snk</AssemblyOriginatorKeyFile>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug_x86|AnyCPU'">
<DebugSymbols>true</DebugSymbols>
<OutputPath>bin\Debug_x86\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<DebugType>full</DebugType>
<PlatformTarget>AnyCPU</PlatformTarget>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x86'">
<DebugSymbols>true</DebugSymbols>
<OutputPath>bin\x86\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<DebugType>full</DebugType>
<PlatformTarget>x86</PlatformTarget>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x86'">
<OutputPath>bin\x86\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<Optimize>true</Optimize>
<DebugType>pdbonly</DebugType>
<PlatformTarget>x86</PlatformTarget>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug_x86|x86'">
<DebugSymbols>true</DebugSymbols>
<OutputPath>bin\x86\Debug_x86\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<DebugType>full</DebugType>
<PlatformTarget>x86</PlatformTarget>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Releasex86|AnyCPU'">
<OutputPath>bin\Releasex86\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<Optimize>true</Optimize>
<DebugType>pdbonly</DebugType>
<PlatformTarget>AnyCPU</PlatformTarget>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Releasex86|x86'">
<OutputPath>bin\x86\Releasex86\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<Optimize>true</Optimize>
<DebugType>pdbonly</DebugType>
<PlatformTarget>x86</PlatformTarget>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<ItemGroup>
<Reference Include="Accessibility" />
<Reference Include="Pr21BusinessObjects5">
<HintPath>..\..\..\Product21Projects2018\DllsProduct21\Pr21BusinessObjects5.dll</HintPath>
</Reference>
<Reference Include="Pr21BusinessObjects5.DataAccess">
<HintPath>..\..\..\Product21Projects2018\DllsProduct21\Pr21BusinessObjects5.DataAccess.dll</HintPath>
</Reference>
<Reference Include="Pr21BusinessObjectsFlat">
<HintPath>..\..\..\Product21Projects2018\DllsProduct21\Pr21BusinessObjectsFlat.dll</HintPath>
</Reference>
<Reference Include="Pr21Common">
<HintPath>..\..\..\Product21Projects2018\DllsProduct21\Pr21Common.dll</HintPath>
</Reference>
<Reference Include="Product21.Datamodel">
<HintPath>..\..\..\Product21Projects2018\DllsProduct21\Product21.Datamodel.dll</HintPath>
</Reference>
<Reference Include="Product21.Factory">
<HintPath>..\..\..\Product21Projects2018\DllsProduct21\Product21.Factory.dll</HintPath>
</Reference>
<Reference Include="Product21.Utilities">
<HintPath>..\..\..\Product21Projects2018\DllsProduct21\Product21.Utilities.dll</HintPath>
</Reference>
<Reference Include="Product21CodingLists">
<HintPath>..\..\..\Product21Projects2018\DllsProduct21\Product21CodingLists.dll</HintPath>
</Reference>
<Reference Include="Pr21Interfaces">
<HintPath>..\..\..\Product21Projects2018\DllsProduct21\Pr21Interfaces.dll</HintPath>
</Reference>
<Reference Include="Pr21UtilsHelpers">
<HintPath>..\..\..\Product21Projects2018\DllsProduct21\Pr21UtilsHelpers.dll</HintPath>
</Reference>
<Reference Include="BusinessObjects">
<HintPath>..\..\..\Product21Projects2018\DllsProduct21\BusinessObjects.dll</HintPath>
</Reference>
<Reference Include="ConfigurationProduct21, Version=1.0.0.0, Culture=neutral, PublicKeyToken=549588756ec70082, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\Product21Projects2018\DllsProduct21\ConfigurationProduct21.dll</HintPath>
</Reference>
<Reference Include="InfragisticsWPF4.Controls.Charts.XamDataChart.v13.1, Version=13.1.20131.2406, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\Product21Projects2018\DllsExternal\Infragistics\Infragistics2013\SharedXAML\InfragisticsWPF4.Controls.Charts.XamDataChart.v13.1.dll</HintPath>
</Reference>
<Reference Include="InfragisticsWPF4.DataPresenter.v13.1, Version=13.1.20131.2406, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\Product21Projects2018\DllsExternal\Infragistics\Infragistics2013\WPFOnly\InfragisticsWPF4.DataPresenter.v13.1.dll</HintPath>
</Reference>
<Reference Include="InfragisticsWPF4.DataVisualization.v13.1, Version=13.1.20131.2406, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\Product21Projects2018\DllsExternal\Infragistics\Infragistics2013\SharedXAML\InfragisticsWPF4.DataVisualization.v13.1.dll</HintPath>
</Reference>
<Reference Include="InfragisticsWPF4.Editors.v13.1, Version=13.1.20131.2406, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\Product21Projects2018\DllsExternal\Infragistics\Infragistics2013\WPFOnly\InfragisticsWPF4.Editors.v13.1.dll</HintPath>
</Reference>
<Reference Include="InfragisticsWPF4.v13.1, Version=13.1.20131.2406, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\Product21Projects2018\DllsExternal\Infragistics\Infragistics2013\WPFOnly\InfragisticsWPF4.v13.1.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Expression.Interactions, Version=4.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\Product21Projects2018\DllsExternal\Microsoft.Expression.Interactions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.mshtml, Version=7.0.3300.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<EmbedInteropTypes>True</EmbedInteropTypes>
</Reference>
<Reference Include="Microsoft.Practices.Prism">
<HintPath>..\..\..\Product21Projects2018\DllsExternal\Microsoft.Practices.Prism.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.Prism.Interactivity">
<HintPath>..\..\..\Product21Projects2018\DllsExternal\Microsoft.Practices.Prism.Interactivity.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.Prism.MefExtensions">
<HintPath>..\..\..\Product21Projects2018\DllsExternal\Microsoft.Practices.Prism.MefExtensions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.Prism.UnityExtensions">
<HintPath>..\..\..\Product21Projects2018\DllsExternal\Microsoft.Practices.Prism.UnityExtensions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.ServiceLocation">
<HintPath>..\..\..\Product21Projects2018\DllsExternal\Microsoft.Practices.ServiceLocation.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.Unity">
<HintPath>..\..\..\Product21Projects2018\DllsExternal\Microsoft.Practices.Unity.dll</HintPath>
</Reference>
<Reference Include="Newtonsoft.Json, Version=9.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.9.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
<HintPath>..\packages\NLog.4.0.0\lib\net45\NLog.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="PresentationUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL" />
<Reference Include="Prism, Version=7.1.0.431, Culture=neutral, PublicKeyToken=40ee6c3a2184dc59, processorArchitecture=MSIL">
<HintPath>..\packages\Prism.Core.7.1.0.431\lib\net45\Prism.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="ReachFramework" />
<Reference Include="System" />
<Reference Include="System.ComponentModel.Composition" />
<Reference Include="System.ComponentModel.DataAnnotations" />
<Reference Include="System.Configuration" />
<Reference Include="System.Data" />
<Reference Include="System.Deployment" />
<Reference Include="System.Drawing" />
<Reference Include="System.IO.Compression" />
<Reference Include="System.Net.Http" />
<Reference Include="System.Printing" />
<Reference Include="System.ValueTuple, Version=4.0.1.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
<HintPath>..\packages\System.ValueTuple.4.3.0\lib\netstandard1.0\System.ValueTuple.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="System.Windows.Forms" />
<Reference Include="System.Windows.Interactivity, Version=4.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<HintPath>..\packages\Expression.Blend.Sdk.1.0.2\lib\net45\System.Windows.Interactivity.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="System.Xml" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="System.Xaml">
<RequiredTargetFramework>4.0</RequiredTargetFramework>
</Reference>
<Reference Include="Telerik.Windows.Controls, Version=2020.1.218.45, Culture=neutral, PublicKeyToken=5803cfa389c90ce7, processorArchitecture=MSIL" />
<Reference Include="Telerik.Windows.Controls.FixedDocumentViewers, Version=2020.1.218.45, Culture=neutral, PublicKeyToken=5803cfa389c90ce7, processorArchitecture=MSIL" />
<Reference Include="telerik.windows.controls.fixeddocumentviewersui, Version=2020.1.218.45, Culture=neutral, PublicKeyToken=5803cfa389c90ce7, processorArchitecture=MSIL" />
<Reference Include="Telerik.Windows.Controls.ImageEditor, Version=2020.1.218.45, Culture=neutral, PublicKeyToken=5803cfa389c90ce7, processorArchitecture=MSIL" />
<Reference Include="Telerik.Windows.Controls.Input, Version=2020.1.218.45, Culture=neutral, PublicKeyToken=5803cfa389c90ce7, processorArchitecture=MSIL" />
<Reference Include="Telerik.Windows.Controls.Navigation, Version=2020.1.218.45, Culture=neutral, PublicKeyToken=5803cfa389c90ce7, processorArchitecture=MSIL" />
<Reference Include="Telerik.Windows.Controls.RibbonView, Version=2020.1.218.45, Culture=neutral, PublicKeyToken=5803cfa389c90ce7, processorArchitecture=MSIL" />
<Reference Include="Telerik.Windows.Controls.RichTextBoxUI, Version=2020.1.218.45, Culture=neutral, PublicKeyToken=5803cfa389c90ce7, processorArchitecture=MSIL" />
<Reference Include="Telerik.Windows.Documents, Version=2020.1.218.45, Culture=neutral, PublicKeyToken=5803cfa389c90ce7, processorArchitecture=MSIL" />
<Reference Include="Telerik.Windows.Documents.Core, Version=2020.1.212.40, Culture=neutral, PublicKeyToken=5803cfa389c90ce7, processorArchitecture=MSIL" />
<Reference Include="Telerik.Windows.Documents.Fixed, Version=2020.1.212.40, Culture=neutral, PublicKeyToken=5803cfa389c90ce7, processorArchitecture=MSIL" />
<Reference Include="TXTextControl, Version=19.0.1200.500, Culture=neutral, PublicKeyToken=6b83fe9a75cfb638, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\Program Files\Text Control GmbH\TX Text Control 19.0.NET for WPF\Assembly\TXTextControl.dll</HintPath>
</Reference>
<Reference Include="UIAutomationProvider" />
<Reference Include="UIAutomationTypes" />
<Reference Include="WindowsBase" />
<Reference Include="PresentationCore" />
<Reference Include="PresentationFramework" />
<Reference Include="WindowsFormsIntegration" />
</ItemGroup>
<ItemGroup>
<Compile Include="Properties\AssemblyInfo.cs">
<SubType>Code</SubType>
</Compile>
<Compile Include="Properties\Resources.Designer.cs">
<AutoGen>True</AutoGen>
<DesignTime>True</DesignTime>
<DependentUpon>Resources.resx</DependentUpon>
</Compile>
<Compile Include="Properties\Settings.Designer.cs">
<AutoGen>True</AutoGen>
<DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
<EmbeddedResource Include="Properties\Resources.resx">
<Generator>ResXFileCodeGenerator</Generator>
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
</EmbeddedResource>
<None Include="Product21.snk" />
<None Include="Pr21p.config" />
<None Include="packages.config" />
<None Include="Properties\Settings.settings">
<Generator>SettingsSingleFileGenerator</Generator>
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
</None>
<AppDesigner Include="Properties\" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<PropertyGroup>
<PostBuildEvent>copy $(TargetPath) $(Pr21DllDir)\*.*
copy $(TargetName).pdb $(Product21SymbolsFolder)\$(TargetName).pdb
if $(ConfigurationName) == Debug (
copy $(Product21SymbolsFolder)\Pr21BusinessObjects5.pdb $(TargetDir)\*.*
copy $(Product21SymbolsFolder)\Pr21BusinessObjectsFlat.pdb $(TargetDir)\*.*
copy $(Product21SymbolsFolder)\Pr21Common.pdb $(TargetDir)\*.*
copy $(Product21SymbolsFolder)\Pr21Constants.pdb $(TargetDir)\*.*
copy $(Product21SymbolsFolder)\Product21.Datamodel.pdb $(TargetDir)\*.*
copy $(Product21SymbolsFolder)\Product21.Factory.pdb $(TargetDir)\*.*
copy $(Product21SymbolsFolder)\Pr21Interfaces.pdb $(TargetDir)\*.*
copy $(Product21SymbolsFolder)\Pr21Styles.pdb $(TargetDir)\*.*
copy $(Product21SymbolsFolder)\BusinessObjects.pdb $(TargetDir)\*.*
)</PostBuildEvent>
</PropertyGroup>
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>