0

C# WPF 应用程序的这个构建输出是怎么回事?

------ Rebuild All started: Project: CACI.Common, Configuration: Debug Any CPU ------
  CACI.Common -> D:\SvnSource\Main\InSite\trunk\insite\InsUi\Common\bin\Debug\CACI.Common.dll
------ Rebuild All started: Project: CACI.InSite, Configuration: Debug Any CPU ------
D:\SvnSource\Main\InSite\trunk\insite\InsUi\InSite\View\SingleSelectTreeVw.xaml.cs(9,10): warning CS0105: The using directive for 'System.Windows.Controls' appeared previously in this namespace
d:\SvnSource\Main\InSite\trunk\insite\InsUi\InSite\Infrastructure\CustomMessageBox\MessageBoxVw.xaml(32,48): warning CS0108: 'CACI.InSite.Infrastructure.CustomMessageBox.MessageBoxVw.Icon' hides inherited member 'System.Windows.Window.Icon'. Use the new keyword if hiding was intended.
D:\SvnSource\Main\InSite\trunk\insite\InsUi\InSite\Model\ManagedQuery\IOrderingQueryComponent.cs(78,33): warning CS0108: 'CACI.InSite.Model.ManagedQuery.IOrderingQueryComponent.ComponentType' hides inherited member 'CACI.InSite.Model.ManagedQuery.IQueryComponent.ComponentType'. Use the new keyword if hiding was intended.
D:\SvnSource\Main\InSite\trunk\insite\InsUi\InSite\Model\ManagedQuery\IQueryComponent.cs(26,33): (Related location)
D:\SvnSource\Main\InSite\trunk\insite\InsUi\InSite\Model\ManagedQuery\IOrderingQueryComponent.cs(83,12): warning CS0108: 'CACI.InSite.Model.ManagedQuery.IOrderingQueryComponent.HaveDefinition' hides inherited member 'CACI.InSite.Model.ManagedQuery.IQueryComponent.HaveDefinition'. Use the new keyword if hiding was intended.
D:\SvnSource\Main\InSite\trunk\insite\InsUi\InSite\Model\ManagedQuery\IQueryComponent.cs(30,12): (Related location)
... LOADS MORE ERRORS

Compile complete -- 0 errors, 51 warnings
  Starting pre-build event
  Stopping InsDB80 service.
  The InSite80 DB Server service is not started.

  More help is available by typing NET HELPMSG 3521.

  PREBUILD EVENT INFO InsDB80 service already stopped.
  Registering project COM dependencies.
  COM Reference 'InsCtl8Lib' is the interop assembly for ActiveX control 'AxInsCtl8Lib' but was marked to be linked by the compiler with the /link flag. This COM reference will be treated as a reference and will not be linked.
C:\Windows\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(1558,9): warning : At least one of the arguments for 'ISMKeyStoreKeys.GetKeyString2' cannot be marshaled by the runtime marshaler.  Such arguments will therefore be passed as a pointer and may require unsafe code to manipulate.
C:\Windows\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(1558,9): warning : At least one of the arguments for 'SMKeyStore.GetKeyString2' cannot be marshaled by the runtime marshaler.  Such arguments will therefore be passed as a pointer and may require unsafe code to manipulate.
View\SingleSelectTreeVw.xaml.cs(9,10): warning CS0105: The using directive for 'System.Windows.Controls' appeared previously in this namespace
Model\ManagedQuery\IGroupingQueryComponent.cs(54,33): warning CS0108: 'CACI.InSite.Model.ManagedQuery.IGroupingQueryComponent.ComponentType' hides inherited member 'CACI.InSite.Model.ManagedQuery.IQueryComponent.ComponentType'. Use the new keyword if hiding was intended.
Model\ManagedQuery\IGroupingQueryComponent.cs(59,12): warning CS0108: 'CACI.InSite.Model.ManagedQuery.IGroupingQueryComponent.HaveDefinition' hides inherited member 'CACI.InSite.Model.ManagedQuery.IQueryComponent.HaveDefinition'. Use the new keyword if hiding was intended.
Model\ManagedQuery\IGroupingQueryComponent.cs(147,45): warning CS0108: 'CACI.InSite.Model.ManagedQuery.IGroupingQueryComponent.GetEnumerator()' hides inherited member 'System.Collections.Generic.IEnumerable<CACI.InSite.Model.ManagedQuery.IGroupingQueryExpression>.GetEnumerator()'. Use the new keyword if hiding was intended.
... LOADS MORE ERRORS
  CACI.InSite -> D:\SvnSource\Main\InSite\trunk\insite\InsUi\InSite\bin\Debug\CACI.InSite.exe
========== Rebuild All: 2 succeeded, 0 failed, 0 skipped ==========

显然,存在大量编译警告这一事实是一个问题,但这是我无法控制的。我不明白的是输出本身的结构。

它从编译 .cs 文件生成的大量警告开始,这些警告使用文件的完全根路径并包含扩展某些警告的“(相关位置)”条目。

然后有一个“编译完成”消息指示有多少警告,然后是预构建事件的运行(重新启动数据库服务)。现在称我为老式的,但我的方式相当成熟,我通常希望我的预构建事件在我的文件构建之前运行。

最后还有第二个警告块,它主要是第一个块的重复,但这次它包括与链接相关的错误,不使用完全根目录的路径,也不包含“(相关位置)”添加。

第一个问题:在我看来,这个输出看起来像一个非理性的混乱,实际上在某种程度上我不理解是合乎逻辑的吗?

第二个问题:无论如何我可以强制 VS 输出一些更传统的东西

1. Pre-build event.
2. Compiler warnings with inserted "(Related location)" markers.
3. Link errors.
4. Build summary.

编辑:我更新了输出以反映实际上有 2 个项目正在构建的事实,但第一个项目在没有错误或警告的情况下完成。

4