msbuild icon indicating copy to clipboard operation
msbuild copied to clipboard

[Broken Build]: Want to generate all platform appxupload build

Open dunward opened this issue 3 years ago • 3 comments

Issue Description

I'm now using jenkins for automation generate .appxupload.

The first step is working good (I guess), cause the first ARM build output dir is no problem. build\bin\Master\ARM\GameAssembly.lib - This is no problem. But the next build for other architecture(in this case is x86) I got error like this

(CreateWinMD target) -> 
  LINK : fatal error LNK1181: cannot open input file 'build\bin\ARM\Master\x64\My Project\GameAssembly.lib' [Project path\My Project\Club Vegas.vcxproj]

Why x64 directory is created inside ARM build?

Steps to Reproduce

msbuild "My Project.sln" -p:Configuration:"Master" -p:UapAppxPackageBuildMode="StoreUpload" This is my vcxproj property.

  <PropertyGroup>
    <OutDir>$(SolutionDir)build\bin\$(Platform)\$(Configuration)\</OutDir>
    <IntDir>$(SolutionDir)build\obj\$(MSBuildProjectName)\$(Platform)\$(Configuration)\</IntDir>
    <AppxBundle>Always</AppxBundle>
    <UseDotNetNativeToolchain>true</UseDotNetNativeToolchain>
    <GenerateAppInstallerFile>False</GenerateAppInstallerFile>
    <AppxPackageSigningTimestampDigestAlgorithm>SHA256</AppxPackageSigningTimestampDigestAlgorithm>
    <AppxAutoIncrementPackageRevision>True</AppxAutoIncrementPackageRevision>
    <GenerateTestArtifacts>True</GenerateTestArtifacts>
    <AppxBundlePlatforms>ARM|x86|x64</AppxBundlePlatforms>
    <HoursBetweenUpdateChecks>0</HoursBetweenUpdateChecks>
  </PropertyGroup>

Expected Behavior

I want to get appxupload file like this. App Name_version_x86_x64_arm_bundle_Master.appxupload

This appxupload I can generate inside Visual Studio - Create App Packages wizard.

Actual Behavior

(CreateWinMD target) -> 
  LINK : fatal error LNK1181: cannot open input file 'build\bin\ARM\Master\x64\My Project\GameAssembly.lib' [Project path\My Project\Club Vegas.vcxproj]

Ask us questions

No response

dunward avatar May 25 '23 07:05 dunward

Team triage: @olgaark, can you please have a look if this is related to cpp build infra?

AR-May avatar May 30 '23 14:05 AR-May

I cannot say much without binlog, but "build\bin\ARM\Master\x64\My Project\GameAssembly.lib" contains "ARM" and "x64" which does not look right, especially for building x86 and indicates that OutDir was redefined somewhere in targets.

olgaark avatar May 30 '23 16:05 olgaark

OutDir is no problem in my vcxproj. I found -p:UseSubFolderForOutputDirDuringMultiPlatformBuild=false param, and this helping for me in this case.

dunward avatar Jun 01 '23 07:06 dunward