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

Meta fails to load in VS2013 because Portable Class Libraries don't work #761

Open
xortuna opened this issue Jul 22, 2015 · 18 comments
Open

Comments

@xortuna
Copy link

xortuna commented Jul 22, 2015

Since the split meta project can no longer open in vs2013 due to it 'Targeting framework versions not supported or not yet implemented'

changing Meta.csproj

<Import Project="$(MSBuildExtensionsPath32)\Microsoft\Portable\$(TargetFrameworkVersion)\Microsoft.Portable.CSharp.targets" />

to

  <Import Project="..\.NET 4.5.targets" />

Fixes the issue

@kg
Copy link
Member

kg commented Jul 22, 2015

I'm using VS2013, what's different about your configuration?

@kg kg added the Integration label Jul 22, 2015
@xortuna
Copy link
Author

xortuna commented Jul 22, 2015

I cloned via GIT and did update modules, my vs2013 might be Update 1 however (I'll check when I'm home)

@xortuna
Copy link
Author

xortuna commented Jul 22, 2015

This was vs2013 without any updates, ill try installed update 5 and see if it launches

@kg
Copy link
Member

kg commented Jul 27, 2015

I couldn't reproduce this with update 4, and update 5 won't install here... things work fine on VS2015 also, though.

@aracdin
Copy link

aracdin commented Jul 30, 2015

Might be related:
screen shot 2015-07-30 at 18 51 21
Tool status

Microsoft Visual Studio Express 2013 for Web
Version 12.0.31101.00 Update 4
Microsoft .NET Framework
Version 4.6.00081

Installed Version: WD Express

Team Explorer for Visual Studio 2013 06156-004-0437007-02904
Microsoft Team Explorer for Visual Studio 2013

Visual Basic 2013 06156-004-0437007-02904
Microsoft Visual Basic 2013

Visual C# 2013 06156-004-0437007-02904
Microsoft Visual C# 2013

Application Insights Tools for Visual Studio Package 1.0
Application Insights Tools for Visual Studio

ASP.NET and Web Tools 12.4.51016.0
Microsoft Web Developer Tools contains the following components:
Support for creating and opening ASP.NET web projects
Browser Link: A communication channel between Visual Studio and browsers
Editor extensions for HTML, CSS, and JavaScript
Page Inspector: Inspection tool for ASP.NET web projects
Scaffolding: A framework for building and running code generators
Server Explorer extensions for Microsoft Azure Websites
Web publishing: Extensions for publishing ASP.NET web projects to hosting providers, on-premises servers, or Microsoft Azure

ASP.NET Web Frameworks and Tools 2012.2 4.1.21001.0
For additional information, visit http://go.microsoft.com/fwlink/?LinkID=309563

ASP.NET Web Frameworks and Tools 2013 5.2.21010.0
For additional information, visit http://www.asp.net/

Common Azure Tools 1.3
Provides common services for use by Azure Mobile Services and Microsoft Azure Tools.

NuGet Package Manager 2.8.50926.663
NuGet Package Manager in Visual Studio. For more information about NuGet, visit http://docs.nuget.org/.

PowerShell Tools 1.3
Provides file classification services using PowerShell

SQL Server Data Tools 12.0.41012.0
Microsoft SQL Server Data Tools

By the way, the Wiki says 10 works. It doesn't anymore :-(

@kg
Copy link
Member

kg commented Jul 30, 2015

Portable libraries are a disaster. I regret listening to people who asked me to adopt them :(

Is there a way to resolve this without killing the portable library thing for people who want it? I don't know anything about this stuff. I don't know why portable libraries would fail in so many modern configurations.

@kg kg changed the title Meta fails to load in VS2013 Meta fails to load in VS2013 because Portable Class Libraries don't work Jul 30, 2015
@iskiselev
Copy link
Member

PCL projects are not supported on VS Express Edition, but they should work on Community Edition (all except "enterprise" customer should be able to use Community Edition).
@kg, what problems have you found with PCL libraries? I also use them, but haven't seen any.
We always have an option provide both platform specific and PCL assemblies.

@kg
Copy link
Member

kg commented Jul 30, 2015

I want to have one JSIL.Meta csproj file that people can reference, instead of having 5 different copies of it that need to have their file lists maintained separately. Is there any way to do that? It sounded like some people need a PCL JSIL.Meta, but if entire VS product lines can't support PCLs, that's a non-starter.

@iskiselev
Copy link
Member

I'm pretty sure they can build it using MsBuild. Probably they will need to install PCL references Libraries before.
Using Protobuild (#739) should help with managing multi-platform builds (I've never played with it, but according to its description it should automatically create all platform-specific .csproj files and synchronize back their changes to its own config).
We also have an option try to "hack" PCL project file so that it will load in VS Express edition.

@kg
Copy link
Member

kg commented Jul 30, 2015

I will think about using an import like the .net 4.5 targets file to make it possible to have PCL and non-PCL Meta projects that share the same file list. That could work out.

@iskiselev
Copy link
Member

@aracdin, could you try build it using command line? So, open Visual Studio Developer Command Prompt and run msbuild JSIL.NoXNA.sln?

@iskiselev
Copy link
Member

@kg, I'm pretty sure, that VS express blocks loading project according to ProjectType GUID in .csproj file. If we replace it with standard C# project GUID it will probably work.

@aracdin
Copy link

aracdin commented Aug 2, 2015

Couldn't even get msbuild to run :-( .After some digging around, I found that Meta is asking for:

{786C830F-07A1-408B-BD7F-6EE04809D6DB};
{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}

Which according to: http://www.mztools.com/articles/2008/mz2008017.aspx are
"Store App Portable Universal" & C#. C# makes sense, but the other appears to be related to the Windows Store in some way (?). The GUID is in my registry, but only for a deleted 14.0 installation.

@aracdin
Copy link

aracdin commented Aug 16, 2015

Easiest fix is probably just to update the wiki and tell people to use 15. ;-)

@hach-que
Copy link
Contributor

I want to have one JSIL.Meta csproj file that people can reference, instead of having 5 different copies of it that need to have their file lists maintained separately. Is there any way to do that?

I know I'm reviving this thread from the dead, but this is precisely the scenario that led MonoGame to adopt Protobuild - this is one of the core features of it (getting rid of all the platform-specific C# files).

For people who want to use PCLs, you can just do Protobuild.exe --generate PCL, while anyone who wants to use a platform implementation can do Protobuild.exe --generate Windows, etc.

@iskiselev
Copy link
Member

Multi-targeting already possible with project.json/.xproj and dnx. It should work even with VS Code. So, let's see how it would work as soon as it will be RTM. Looks like it will solve most problems that Protobuild solve (at least how I understand them).

@hach-que
Copy link
Contributor

None of that is supported under MonoDevelop / Xamarin Studio, nor does it work under Mono or xbuild.

project.json/.xproj/dnx are entirely a CoreCLR thing and don't solve the same problems as Protobuild.

@iskiselev
Copy link
Member

I hope it will be supported in some way with MonoDevelop / Xamarin Studio when it will be released (or a little bit later). project.json structure is much simpler than msbuild files.
With project.json in frameworks section you can define all targets that you need - Net Core, Net Framework 4.x, different PCL profiles.
You will have nuget package as build artifact for such project.
Right now you cannot add project reference to .xproj from .csproj, but they promise to implement it.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants