I have a small windows mobile app with roughly 25 forms and maybe 50 classes split into 3 projects. When I'm building the project it takes 25 to 40 minutes for a normal CTRL-SHIFT-B in debug mode.
I have tried the skip platform verification hack, but it doesn't seem to help.
The environment is VS 2008
Windows Mobile 6.5.3
Compact Framework 2.0
<ProductVersion>9.0.30729</ProductVersion>
<OSVersion>5.02</OSVersion>
<TargetFrameworkVersion>v2.0</TargetFrameworkVersion>
<NativePlatformName>Windows Mobile 6.5.3 Professional DTK</NativePlatformName>
The computer is an HP EliteBook 8440p with a i3 @2,4Ghz, 4gb ram.
There is plenty Ram available (2,2 Gb used).
CPU usage around 25% during compilation.
When I build, visual studio and all of it's child windows goes blank for 95% of the time.
The eventviewer doesn't show any particular warnings like a bad hard disk or so.
Update 1
In the process monitor trace I can see that there's regular network activity in devenv.exe during the build. Could VSS have something to do with the build? (I reach the vss-repository through a vpn tunnel that I have had in bypass mode today.)
First the good news: you can shorten long build times and
here we go with the "bad news", the work:
Common issues during Build:
Run when build updates the project output
in the BuildEvents Properties of the Project to call the PostBuild events only if the Build changes the binaries.You can use a Visual Studio Macro to start your MSBUILD for the curently opened solution:
Public Module Builder
Sub BuildSolutionDebug()
SaveAll()
Run("", "C:\WINDOWS\Microsoft.NET\Framework\v3.5\MSBuild.exe", """" & GetSolutionName() & """ /t:ReBuild /p:Configuration=Debug /p:Platform=""Mixed Platforms""")
End Sub
Sub Run(ByVal folder As String, ByVal file As String, ByVal arguments As String)
Dim process As New System.Diagnostics.Process()
process.Start(System.IO.Path.Combine(folder, file), arguments)
Try
process.WaitForExit()
Catch ex As Exception
End Try
End Sub
Sub SaveAll()
DTE.ExecuteCommand("File.SaveAll")
End Sub
Function GetSolutionName() As String
Return DTE.Solution.FullName
End Function
End Module
Please contact me if you have further questions or want to discuss a point. I would be glad helping you.
I would also enjoy reading your solution to the problem, and in which point your build was slow!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With