I try to build Windows Store app using MSBuild.
C:\Windows\Microsoft.NET\Framework\v4.0.30319>MSBuild.exe /t:build /p:Configurat
ion=Release;Platform=x86 E:\MyApp.W8.csproj /logger:FileLogger,Microsoft.Build.Engine;logfile=E:/log/test.txt /p:OutputPath=E:/result
And I got this error:
"E:\MyApp.W8.csproj
" (build target) (1) ->
(CopyGeneratedXaml target) ->
C:\Program Files (x86)\MSBuild\Microsoft\WindowsXaml\v12.0\8.1\Microsoft.Wind
ows.UI.Xaml.Common.targets(476,9): error MSB3021: Unable to copy file "obj\x86\
Release\E:\MyApp.Shared\App.xbf" to "E:\result\E:\MyApp.Shared\App.xbf". The given path's format is not
supported. [E:\MyApp.W8.csproj]
I don`t know why MSBuild tries to use
obj\x86\Release\E:\MyApp.Shared\App.xbf
instead obj\x86\Release\App.xbf
or absolute path to App.xbf.
According to this post, inside your .projitems file you'll find the following code:
<ApplicationDefinition Include="$(MSBuildThisFileDirectory)App.xaml">
<SubType>Designer</SubType>
</ApplicationDefinition>
Replace this with:
<ApplicationDefinition Include="$(MSBuildThisFileDirectory)App.xaml">
<SubType>Designer</SubType>
<Link>App.xaml</Link>
</ApplicationDefinition>
Related
For context, I am encountering this immediately after resolving this issue:
Xcode error: unable to create directory '/[PATH_TO_APP]/[APP_NAME].app' (in target '[TARGET]' from project '[PROJECT]')
Here is the full error details text (with redactions in [] for privacy):
Details
The file “[APP NAME].app” couldn’t be opened because there is no such file.
Domain: NSCocoaErrorDomain
Code: 260
Failure Reason: The file doesn’t exist.
User Info: {
NSFilePath = "/[APP NAME].app";
}
--
The operation couldn’t be completed. No such file or directory
Domain: NSPOSIXErrorDomain
Code: 2
Failure Reason: No such file or directory
--
System Information
macOS Version 10.15.5 (Build 19F101)
Xcode 11.5 (16139)
Running ls -l in the project folder shows the [APP NAME].app now present, but navigating to the same location and selecting the file in Finder shows a "crossed out circle" over the app's icon. Removing the file and building again results in the same thing. I've also tried renaming the project and restarting, etc, to no avail.
NSFilePath = "/[APP NAME].app" feels like a missing or misspelled environment variable.
If the build expects custom environment variable like $(MyBuildDir) to be defined, when it's not, then running a command with $(MyBuildDir)/[APP NAME].app would result in "/[APP NAME].app"
The same is true for if the environment variable misspelled. For example, using $(UBILD_DIR)/[APP NAME].app instead of BUILD_DIR would result in "/[APP NAME].app"
I am trying to build QGIS open source application in Windows. I used this link for it -> link
But I am getting the error "Microsoft.CppCommon.targets(171,5): error MSB6006: "cmd.exe" exited with code -1073741515". I think it is about some missing dlls. Also, the error is related(opinion) about crssync.exe because building fails after running that exe file. Additionally, when i tried debug start new instace from Visual studio 2015 it shows me (on console) not loaded 3 dlls but two of them are system one is about OSGeo4W. Then shows a missing dll error on the screen about gdal301.dll and proj_6_3.dll.
I tried to execute crsyync.exe directly. It gave me lots of dll missing error two of them is same with above. I add their locations on the path variable then tried again, problems solved no errors. However when i builded again it gave me same error. When i clicked the error it shows me "Microsoft.CppCommon.targets" file.
<CustomBuild
Sources ="#(CustomBuild)"
BuildSuffix ="$(_BuildSuffix)"
TrackerLogDirectory ="%(CustomBuild.TrackerLogDirectory)"
MinimalRebuildFromTracking ="%(CustomBuild.MinimalRebuildFromTracking)"
TLogReadFiles ="#(CustomBuildTLogReadFiles)"
TLogWriteFiles ="#(CustomBuildTLogWriteFiles)"
TrackFileAccess ="$(TrackFileAccess)"
ToolArchitecture ="$(CustomBuildToolArchitecture)"
TrackerFrameworkPath ="$(CustomBuildTrackerFrameworkPath)"
TrackerSdkPath ="$(CustomBuildTrackerSdkPath)"
AcceptableNonZeroExitCodes ="%(CustomBuild.AcceptableNonZeroExitCodes)"
>
</CustomBuild>
The problem is it can not find the gdal301.dll and proj_6_3.dll in the apps folder. Because it looks at the OSGeo4W\bin folder. When i copied and pasted them into that folder it worked and run the qgis.
When I build the application, I get the following error message
The command "dotnet "C:\Users\Adminuser\.nuget\packages\nswag.msbuild\13.0.6\build\../tools/NetCore22/dotnet-nswag.dll" run /variables:Configuration=Debug" exited with code
-2147450730. Northwind.WebUI C:\Users\Adminuser\Documents\Visual Studio 2017\Projects\NorthwindTraders-master\Northwind.WebUI\Northwind.WebUI.csproj 60
Any Idea how to fix this issue?
Swagger doesn't like it when two or more endpoints in the same Controller share the same name. make use of routing attributes and make sure they are unique.
Try to install NSwagStudio then re open your visual studio.
That's should solve your problem.
If it's still not working
give a look about your output console when you try to compile your project, you should see something like this
1>Executing file 'nswag.json' with variables 'Configuration=Debug'...
1>Launcher directory:
C:\Users\Shadow.nuget\packages\nswag.msbuild\13.1.6\tools\NetCore30
You should have a file called dotnet-nswag.exe in your c:\user...\tools\netcore30 directory.
Put this exe in your environnement path.
Re open visual studio and your error should be gone.
I'm getting errors when Creating App Packages for a UWP Win 10 application.
On my machine the error is:
C:\Users\Developer\.nuget\packages\nodatime\2.4.0\lib\netstandard2.0\NodaTime.pdb : fatal error CMF1106: failed to open input PDB file for reading (PDB error code = 11)3 input PDB file is not generated by /DEBUG:fastlinkW must read and agree to the Data Collection Policy at MSPDBCMF : fatal error CMF1000: internal error
The pdb file exists in the mentioned directory: C:\Users\Developer\.nuget\packages\nodatime\2.4.0\lib\netstandard2.0
On a hosted VSTS build the error message is even more cryptic:
C:\Users\VssAdministrator\.nuget\packages\nodatime\2.4.0\lib\netstandard2.0\NodaTime.pdb : fatal error CMF1106: failed to open input PDB file for reading (PDB error code = 11)3 input PDB file is not generated by /DEBUG:fastlinkW must read and agree to the Data Collection Policy at ??? before using /errorreport:send1 warning treated as error; the PDB file is intact# specified output filename is too long (exceeding 0 characters)
Note 1: On my machine the package is actaully successfully created but on the VSTS build the step fails as it detects the error in logs and stops.
Note 2: I'm pretty sure this is not NodaTime specific. This is about something else...
My msbuild switches are:
/p:AppxBundlePlatforms="$(BuildPlatform)"
/p:AppxPackageDir="$(Build.ArtifactStagingDirectory)\AppxPackages\"
/p:AppxBundle=Never
/p:UapAppxPackageBuildMode=StoreUpload
I am now trying with extra /p:DebugSymbols=false /p:DebugType=None, but even if it fails, I would like to understand and eliminate the 'fastlink' errors.
Explicitly setting DebugType to pdbonly worked in my case, but not sure if you need portable debug symbols or not, so this might not be an option for you.
<PropertyGroup>
<DebugType>pdbonly</DebugType>
</PropertyGroup>
Trying to launch my project on appharbor and it fails with this:
"D:\temp\cijsrn4n.1kq\input\TinyBlogMvc4.sln" (default target)
(1) ->
"D:\temp\cijsrn4n.1kq\input\TinyBlogMvc4\TinyBlogMvc4.csproj" (default
target) (2) -> (_CopyWebApplicationLegacy target) ->
C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v10.0\WebApplica
tions\Microsoft.WebApplication.targets(178,5): error MSB3021: Unable
to copy file "obj\Debug\build.force" to "D:\temp\cijsrn4n.
1kq\output_PublishedWebsites\TinyBlogMvc4\obj\Debug\build.force".
Could not find a part of the path 'obj\Debug\build.force'.
[D:\temp\cijsrn4n.1kq\input\TinyBlogMvc4\TinyBlogMvc4.csproj]
C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v10.0\WebApplica
tions\Microsoft.WebApplication.targets(178,5): error MSB3021: Unable
to copy file
"obj\Debug\DesignTimeResolveAssemblyReferencesInput.cache" to
"D:\temp\cijsrn4n. 1kq\output_PublishedWebsites\TinyBlogMvc4\obj
\Debug\DesignTimeResolveAssemblyReferencesInput.cache". Could not find
a part of the path
'obj\Debug\DesignTimeResolveAssemblyReferencesInput.cache'.
[D:\temp\cijsrn4n. 1kq\input\TinyBlogMvc4\TinyBlogMvc4.csproj]
0 Warning(s) 2 Error(s)
It builds on my pc just fine, any ideas what I'm missing?
.NET Framework version is 4.0
I've created project from scratch and then compared and found this:
<Content Include="obj\Debug\build.force" />
How it appeared there, have no idea, but that was the reason.
I had the same problem and I solved removed from the .csproj file these rows:
<Content Include="obj\Debug\AqAUI.csproj.FileListAbsolute.txt" />
<Content Include="obj\Debug\AqAUI.csprojResolveAssemblyReference.cache" />
<Content Include="obj\Debug\build.force" />
<Content Include="obj\Debug\DesignTimeResolveAssemblyReferencesInput.cache" />
It looks like the _CopyWebApplicationLegacy target in your project file is causing problems. If you don't need it, consider removing it. Alternatively, you should fix the path issue. It looks like an invalid path is generated: output_PublishedWebsites should probably be output\_PublishedWebsites. There are suggestions on how to debug stuff like this in the FAQ