Skip to content
This repository has been archived by the owner on Aug 22, 2018. It is now read-only.

Android project fails to build #3

Closed
xoofx opened this issue Sep 1, 2014 · 9 comments
Closed

Android project fails to build #3

xoofx opened this issue Sep 1, 2014 · 9 comments
Assignees
Labels
Milestone

Comments

@xoofx
Copy link

xoofx commented Sep 1, 2014

From @gitfool http://answers.paradox3d.net/questions/31/android-project-fails-to-build.html

I have all the prerequisites installed and created a new project with JumpyJet sample.

First of all, from within Game Studio the JumpyJet.Windows code project is not shown bold. It always seems to build and run the Windows project. I can't select the JumpyJet.Android project as the startup project.

Switching to Visual Studio, I set JumpyJet.Android as the startup project, change the Solution Platform to Android with my device selected as the Target Android Device, and finally set the project properties to compile using Android version API Level 15 (4.0.3). Then trying to build the project I get the following warnings and errors:

Package Paradox with version [] not found. Use version 1.0.0-alpha05 instead
The "GetSdkToolFullPath" task could not be instantiated from the assembly ...
The "GetSdkToolFullPath" task has been declared or used incorrectly, or failed during construction ...

See attached build log for complete output.

@xoofx xoofx added the bug label Sep 1, 2014
@xoofx xoofx self-assigned this Sep 1, 2014
@xoofx
Copy link
Author

xoofx commented Sep 2, 2014

We can't reproduce this. Could you attach a full msbuild log in diagnostic mode? (in VS Tools/Options/Build And Run/MSBuild project output verbosity)

@gitfool
Copy link

gitfool commented Sep 2, 2014

Github doesn't support file attachments and I can't attach it to the Paradox Q&A site since you closed the 'question' there.

@xoofx
Copy link
Author

xoofx commented Sep 2, 2014

Ah, just use service like pastebin.com we will grab it from there

@gitfool
Copy link

gitfool commented Sep 2, 2014

@xoofx
Copy link
Author

xoofx commented Sep 2, 2014

Could you give more details about your OS, Visual Studio version installed? (with which update...etc.)
(Here it is working, but we have a standard VS2013 Pro install, so just checking why you don't have this)

@gitfool
Copy link

gitfool commented Sep 2, 2014

Looking at that build log, the error seems to be that two different versions of Microsoft.Build.Framework.dll are being referenced - SiliconStudio.Assets.CompilerApp.exe expects v4.0.0.0 via SiliconStudio.Assets.dll dependency, but Microsoft.Build.AppXPackage.dll expects v12.0.0.0.

I've managed to work around the problem by adding a binding redirect file SiliconStudio.Assets.CompilerApp.exe.config with contents:

<?xml version="1.0" ?> 
<configuration> 
  <runtime> 
    <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">  
      <dependentAssembly> 
        <assemblyIdentity name="Microsoft.Build.Framework" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/>  
        <bindingRedirect oldVersion="0.0.0.0-12.0.0.0" newVersion="12.0.0.0"/>
      </dependentAssembly> 
    </assemblyBinding> 
  </runtime> 
</configuration>

Edit: I should clarify, the versions are not in the build log; I looked at the suspect assemblies with .NET Reflector.

@xoofx
Copy link
Author

xoofx commented Sep 2, 2014

Hm, interesting. Need to check why we don't have this behavior on our machine.

Alternatively, you can also add this property to the .Game.csproj
false

Ok, we will try to fix this for next alpha release. Thanks for the follow up.

@gitfool
Copy link

gitfool commented Sep 2, 2014

Makes more sense after reading MSBuild is now part of Visual Studio (AppxMSBuildToolsPath = C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\AppxPackage).

You must've built your executable against the previous MSBuild tools (via VS 2012?)

Oh right, changing the .Game.csproj to use ToolsVersion="12.0" is much easier and works too. ;)

@xoofx
Copy link
Author

xoofx commented Sep 3, 2014

You must've built your executable against the previous MSBuild tools (via VS 2012?)

Yes, as we are using nuget which is build with msbuild 4.0, we can't use the 12.0 version

@xen2 xen2 modified the milestone: alpha06 Sep 4, 2014
This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

3 participants