Aspnet_compiler ignores target directory and leaves DLL in ASP.NET temp directory

I am having trouble pre-compiling my ASP.NET MVC application. Here's the task <AspNetCompiler>

in my csproj project file:

<AspNetCompiler Clean="true"
                FixedNames="true"
                Updateable="false"
                VirtualPath="/"
                PhysicalPath="$(ProjectDir)"
                TargetPath="$(ProjectDir)..\PreCompiledOutput" />

      

Everything except the pre-compiled DLLs goes into the target path. Native precompiled DLLs are created in the ASP.NET temp directory.

This is a problem because the next MSBuild task in this build of the project is to run aspnet_merge on the pre-compiled DLLs. Since they are not in the target path, aspnet_merge complains that "it cannot find assemblies that can be merged into the application bin folder"


FWIW I tried to create a new ASP.NET MVC application and use the above task <AspNetCompiler>

in this project and I get the same behavior, i.e. everything except the precompiled DLLs ends up in the target path. Hence, it is not a specific project causing the problem. However, if I delete the task <AspNetCompiler>

and instead set up a publish profile configured to precompile the application, the precompiled DLLs end up in the target path.


Has anyone seen anything like this before? Is there something I am missing in the task <AspNetCompiler>

?

+3


source to share


1 answer


Well, it turns out it was caused by McAfee antivirus



I disabled on-access antivirus scanning, ran aspnet_compiler

it and everything worked as it should.

+2


source







All Articles