I want to see all commands while building/releasing on the output window.
When I build my app I only see this:
------ Build started: Project: CemKutuphane, Configuration: Debug Any CPU ------
CemKutuphane -> D:\Projects\Test\CemKutuphane\CemKutuphane\bin\Debug\CemKutuphane.dll
========== Build: 1 succeeded or up-to-date, 0 failed, 0 skipped ==========
There is no csc.exe args in these lines. But visual studio ide is running behind of this.
Is there any way to see the all commands?
dknaack's answer is correct so I'll repeat it in its entirity until he un-deletes it:
You can set the verbosity level on
Options > Projects and Solutions > Build and Run > MSBuild project
build output verbosity
I've tried this and found that setting the logging to "Normal" or above showed the csc.exe command line being executed, like this:
1>CoreCompile:
1> C:\Windows\Microsoft.NET\Framework\v4.0.30319\Csc.exe /noconfig /nowarn:2008,1701,1702 ...
Note that you might need to Clean the project beforehand in order to see this - if the project is already up-to-date then MSBuild will skip several tasks.
Related
Simple question , after build i have the following :
========== Build: 68 succeeded, 5 failed, 1 up-to-date, 0 skipped ==========
Now , i do not have any errors(which means my error list in VS shows 0 errors) , how do i know which projects and why fail to build ?
Yeah VS 2015 doesn't show errors at times or show errors that were already fixed.I don't know why. Our solution also had around 70 projects
So What i used to do was to check the Build Log in Output tab. This will have the log of each project including errors if any. Or do MsBuild from Msbuild command prompt of VS 2015. Easy to identify the issue.
I have a solution where my main project is a uwp app, and two other projects referenced by the app :
UWP App ---> references 2.
Universal Class library ----> references 3.
PCL Library
2 --> uses EF7 and SQLight.
3 --> uses PCLCrypto
Now, everything works just fine and excellent when I'm on Debug mode x86 targeting local machine.
I want to compile the solution in release mode using .Net native tool chain, here's my config :
When I launch the compilation, it takes a remarkably long time, and too much memory is consumed by the .Net native tools :
After some time, everything stops with 2 errors on visual studio :
Here's what the output window says :
1>------ Build started: Project: ServerCommunication, Configuration:
Release Any CPU ------ 1> ServerCommunication ->
C:\Users\aymen\Documents\Visual Studio
2015\Projects\Applinova\Liberte\ServerCommunication\bin\Release\ServerCommunication.dll
2>------ Build started: Project: NewspaperDataLayer, Configuration:
Release x86 ------ 2>C:\Users\aymen\Documents\Visual Studio
2015\Projects\Applinova\Liberte\packages\Microsoft.Bcl.Build.1.0.14\tools\Microsoft.Bcl.Build.targets(225,5):
warning : All projects referencing ServerCommunication.csproj must
install nuget package Microsoft.Bcl.Build. For more information, see
http://go.microsoft.com/fwlink/?LinkID=317569. 2> NewspaperDataLayer
-> C:\Users\aymen\Documents\Visual Studio 2015\Projects\Applinova\Liberte\NewspaperDataLayer\bin\x86\Release\NewspaperDataLayer.dll
3>------ Build started: Project: Liberte, Configuration: Release x86
--some warnings here that I just skipped
3> Starting .NET Native compilation 3> Processing application code
3>C:\Users\aymen\Documents\Visual Studio
2015\Projects\Applinova\Liberte\Liberte\Resources.System.Linq.Expressions.rd.xml(35):
warning : Method 'CreateLambda' within
'System.Linq.Expressions.Expression' could not be found.
3>C:\Users\aymen\Documents\Visual Studio
2015\Projects\Applinova\Liberte\Liberte\Resources.System.Linq.Expressions.rd.xml(91):
warning : Method 'ParameterIsAssignable' within
'System.Linq.Expressions.Expression' could not be found. 3> Computing
application closure and generating interop code 3> Generating
serialization code 3> Compiling interop code 3> Cleaning up
unreferenced code 3> Generating native code 3>STARTPROCESSTASK :
error : Out of Memory 3>C:\Program Files
(x86)\MSBuild\Microsoft.NetNative\x86\ilc\IlcInternals.targets(1129,5):
error : ILT0005: 'C:\Program Files
(x86)\MSBuild\Microsoft.NetNative\x86\ilc\Tools\nutc_driver.exe
#"C:\Users\aymen\Documents\Visual Studio
2015\Projects\Applinova\Liberte\Liberte\obj\x86\Release\ilc\intermediate\MDIL\Liberte.rsp"'
returned exit code 1
========== Build: 2 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
========== Deploy: 0 succeeded, 0 failed, 0 skipped ==========
What would possibly be wrong with this please ??
I had the same problem (I am also using EF7 and other libraries) but I solved using Visual Studio 15 preview (it is not visual studio 2015 update 2, which I didn't try). They improved the .NET native tools so now you should not have any problem, even if using a lot of third party library.
UPDATE
I have solved all my issues after i have installed visual studio 2015 update 3 and switched from EF7 to EF core also available via nuget
I have been struggled past few days around trying to fix this problem, but currently there is no easy solution for it.
There is a closed Issue on EF7 github, more info here (https://github.com/aspnet/EntityFramework/issues/4387) where they suggest as solution update EF7 to v1.0.0-rc2-16898.
I didn't manage how to update and as it still a nightly version, my final solution ("fast" workaround) was change my entire DB to sqlite-pcl (https://visualstudiogallery.msdn.microsoft.com/4913e7d5-96c9-4dde-a1a1-69820d615936).
If you aren't in a rush to lunch your application, you can always wait until final version of RC2 it should be done during April.
I am compile a sample C# .NET project using build.cmd file. The content of the build.cmd is as bellow.
build.cmd
#echo off
setlocal
set devenv="c:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\devenv.com"
del *.log >nul
%devenv% WindowsFormsApplication3.sln /rebuild "Release" /out WindowsFormsApplication3.log
if ERRORLEVEL 1 GOTO failed
findstr /C:"========== Rebuild All: 1 succeeded, 0 failed, 0 skipped ==========" WindowsFormsApplication3.log >nul
if ERRORLEVEL 1 GOTO failed
echo *** BUILD SUCCESSFUL ***
pause
goto :EOF
:failed
echo.
echo.
echo *** BUILD FAILED ***
pause
Project compiles properly. But when i opened the log file it hassome error
WindowsFormsApplication3.log
1>------ Rebuild All started: Project: WindowsFormsApplication3, Configuration: Release Any CPU ------
Package 'Code Analysis Package' failed to load.
1> WindowsFormsApplication3 -> E:\Bin\junk\WindowsFormsApplication3\WindowsFormsApplication3\bin\Release\WindowsFormsApplication3.exe
========== Rebuild All: 1 succeeded, 0 failed, 0 skipped ==========
I don't why i am getting this error (Package 'Code Analysis Package' failed to load) in log file.
I searched online but did not get any help.
how to solve this problem?
Note: WindowsFormsApplication3 is a sample project. i Opened VS2015 and New Project -> Visual C# -> Windows Form Application. I did not change any thing in the project.
Give Microsoft a chance to analyze and fix the problem.
I created a connect issue because the problem occurs on two PCs that both have vanilla VS 2015 installations.
https://connect.microsoft.com/VisualStudio/feedback/details/2423616/package-code-analysis-package-failed-to-load
Within the next few weeks, a guy from Microsoft will probably comment on that. You can followup there.
The other day I started up my monogame project and started it up to do a quick play test. It wouldn't work. I was getting 2 errors.
Error 1 The command "SETX MONOGAME_PLATFORM "PSM" > NUL" exited with code 9009. GameName1
Error 2 Metadata file 'C:\Users\Sean\Desktop\Prog\Learning\3D Learning\GameName1\GameName1\bin\PSM\IgnoreMe.dll' could not be found C:\Users\Sean\Desktop\Prog\Learning\3D Learning\3D Learning\CSC 3D Learning
And here is the output from the build.
1>------ Build started: Project: Learnplscon, Configuration: PSM Any CPU ------
1> MonoGame Platform PSM
1> 'SETX' is not recognized as an internal or external command,
1> operable program or batch file.
1>C:\Program Files (x86)\MSBuild\MonoGame\v3.0\MonoGame.ContentPipeline.targets(22,7): error MSB3073: The command "SETX MONOGAME_PLATFORM "PSM" > NUL" exited with code 9009.
2>------ Build started: Project: learnpls, Configuration: Debug x86 ------
2>CSC : error CS0006: Metadata file 'C:\Users\Sean\Desktop\Prog\Learning\learnpls\Learnplscon\Learnplscon\bin\PSM\IgnoreMe.dll' could not be found
========== Build: 0 succeeded, 2 failed, 0 up-to-date, 0 skipped ==========
But Building from last successful build works.
I did not change anything. And any new project I make gets the same problem.
The problem only happens when I add a reference to my content project.
(Referenced project this way: monogame-managing-content )
I made a new project, ran it, everything worked fine. Created a mono game content project, ran it and everything worked fine. Then I added the reference and got the errors. And when I remove the reference Error 2 goes away but error 1 is still there, but the project will run fine.
I have tried reinstalling xna, and monogame. Also tried to reinstall visual studios. I spent all night trying to find an answer online but came up with nothing.
I am using the most recent version of XNA and Monogame 3.2, and I am using windows 8.1.
In case you're still having this problem, or someone else finds the question (like I did trying to solve this a little while ago): for me, the problem was that my windows/system32 directory wasn't in my 'path' environment variable. That's where the setx.exe program resides, and the XNA content project seems to assume that it can call setx without qualifying the path.
Note: Visual Studio seems to need to be restarted after you've added your /system32 directory to the path.
When you build in 'quiet' mode in Visual Studio 2008, the output looks like this:
Compile complete -- 0 errors, 0 warnings
------ Build started: Project: JLTA.JBS.UI.Office.VSTODocument, Configuration: Debug Any CPU ------
------ Build started: Project: JLTA.JBS.UI.Office.VSTOWorkbook, Configuration: Debug Any CPU ------
------ Build started: Project: JLTA.JBS.UI.GeneralLedgerUpdater, Configuration: Debug Any CPU ------
Compile complete -- 0 errors, 0 warnings
========== Build: 86 succeeded or up-to-date, 0 failed, 0 skipped ==========
This is good because the last two lines of the output quickly show me the result of the build (success/fail).
In Visual Studio 2010 Microsoft added a build summary after this. So, when I build in VS 2010 with the same settings (eg. 'quiet' option), I get the following displayed after the stuff that's already shown in VS 2008:
------ Build started: Project: JLTA.JBS.UI.TestBed, Configuration: Debug Any CPU ------
========== Build: 78 succeeded or up-to-date, 0 failed, 0 skipped ==========
Build Summary
-------------
00:06.772 - Success - UI\TestBed\JLTA.JBS.UI.TestBed.csproj
00:05.926 - Success - UI\Main\JLTA.JBS.UI.Main.csproj
... <bunch of lines deleted here>
00:00.035 - Success - Bus\Budget\JLTA.JBS.Bus.Budget.csproj
00:00.032 - Success - Core\JLTA.JBS.Core.csproj
Total build time: 01:06.088
This is a step backwards by MS, because now I have to scroll up in the build output window to see whether the build succeeded or not.
Is there any way of getting this back to the old VS 2008 behaviour?
This output is not from Visual Studio or MSBuild, it is provided by the VSCommands add-in - see this blog entry. You can investigate settings for that add-in and see if this summary can be disabled, or remove the add-in so that you no longer see this summary detail.
For those that are interested, I found this with this Google query.
archive.org 2011/12/30 mokosh.co.uk/post/tag/vscommands/
archive.org 2011/09/16 mokosh.co.uk/post/2010/05/03/vscommands-2-2-0-0-released/
I get it like VS2008 by selecting "Minimal" for project build output verbosity (Tools --> Options --> Projects and Solutions --> Build and Run)