Skip to content
This repository has been archived by the owner on Apr 16, 2020. It is now read-only.
This repository has been archived by the owner on Apr 16, 2020. It is now read-only.

add msbuild full framework support #164

Closed
ctaggart opened this issue Mar 9, 2017 · 18 comments
Closed

add msbuild full framework support #164

ctaggart opened this issue Mar 9, 2017 · 18 comments
Milestone

Comments

@ctaggart
Copy link
Owner

ctaggart commented Mar 9, 2017

See #156, #161. #163 for 2.0.1 just patched it to work for msbuild core. A bit more work and testing is needed for msbuild full framework.
cc @AArnott, @onovotny

@ctaggart
Copy link
Owner Author

ctaggart commented Mar 9, 2017

@onovotny Can you help me understand and enumerate the cases when it it not possible to move to dotnet msbuild and developers are stuck with msbuild? What is the correct terms to differentiate between the two? https://github.com/Microsoft/msbuild/#build-status

I'll start the list. "F# support for .NET Core Visual Studio tooling" is coming with the first update to Visual Studio 2017 and isn't quite ready yet.

@clairernovotny
Copy link

@ctaggart pretty much anyone who wants to build things other than .NET Desktop., .NET Core, or .NET Standard.

Checkout my repo where I show how:
https://github.com/onovotny/MSBuildSdkExtras
And my blog about how (this was before I released the package to make it easier): https://oren.codes/2017/01/04/multi-targeting-the-world-a-single-project-to-rule-them-all/

You can trivially multi-target any platform but those other platforms' targets and tasks don't support running on CoreCLR.

@AArnott
Copy link
Contributor

AArnott commented Mar 10, 2017

Can you help me understand and enumerate the cases when it it not possible to move to dotnet msbuild and developers are stuck with msbuild?

@ctaggart: All 3rd party MSBuild tasks will not work on dotnet msbuild because they were compiled for another version of MSBuild until they are updated. And updating MSBuild tasks to work on MSBuild Core is often non-trivial. As this is a brand new build system (similarity notwithstanding) with a new installation directory, and new extensions required, you can basically assume that only very new projects or older projects with owners that want to invest a lot into their build authoring will be able to use dotnet build for the next long while. Not supporting desktop MSBuild would therefore be a very audience-limiting move.

@ctaggart
Copy link
Owner Author

Thanks guys. Makes sense. Loud and clear now. Looks like you can still run dotnet sourcelink-git from the folders, so this should be pretty easy:

C:\Users\camer\cs\pinvoke\src\Kernel32>dotnet sourcelink-git
SourceLink Git 2.0.0
Source Code On Demand

Usage:  [options] [command]

Options:
  -h|--help  Show help information

Commands:
  create  creates the Source Link JSON file
  origin  prints the git repository url for origin
  repo    prints the repository path

Use " [command] --help" for more information about a command.

This looks like it will be simply be adding additional dependencies.

@ctaggart
Copy link
Owner Author

The builds from https://ci.appveyor.com/project/ctaggart/sourcelink/build/2.1.0-b412 may actually be working for dotnet-sourcelink-git and SourceLink.Create.GitHub may be working. There is a bug in the dotnet-sourcelink for validation that I'll need to fix before it can be published. @AArnott, I've been using pinvoke to test. It is creating the right sourcelink.json files and passing /sourcelink: to the compiler.

To try that build, add to your nuget.config

<add key="sourcelink" value="https://ci.appveyor.com/nuget/sourcelink/" />

@AArnott
Copy link
Contributor

AArnott commented Mar 10, 2017

Looks good to me.

@clairernovotny
Copy link

@AArnott looking forward to see how this works for your projects (sample) so I can put it in mine :)

@AArnott
Copy link
Contributor

AArnott commented Mar 10, 2017

@onovotny this is how we do it 🎵

@clairernovotny
Copy link

🆒 😎 :thatwaseasy:

@clairernovotny
Copy link

Any idea when this will hit NuGet.org?

@clairernovotny
Copy link

It's not working correctly for me --

https://ci.appveyor.com/project/dotnetfoundation/rx-net-la3iv/build/1.0.131

The repo is https://github.com/reactive-Extensions/Rx.NET in the develop branch.

I added the 2.1-b sourcelink-git cli tool and package ref but the build log shows that it's embedding the source files. It shouldn't be doing that... I did set the AppVeyor init to be git config --global core.autocrlf input

@ctaggart
Copy link
Owner Author

@onovotny Just a quick look, I'm wondering what this is:
image
That looks suspicious.

@ctaggart
Copy link
Owner Author

@onovotny Yeah, the NormalizeGitRepository surely messes things up for SourceLink. Can you try removing uses of it and report back?

ctaggart added a commit that referenced this issue Mar 11, 2017
* add net461 for msbuild full framework #164

* fixed index out of bounds with print-json when missing

* this will be 2.0.2

* IntermediateOutputPath

* IntermediateOutputPath
@ctaggart
Copy link
Owner Author

@AArnott & @onovotny, thanks for your help. I called it 2.0.2 & it has been published to NuGet Gallery.

@clairernovotny
Copy link

clairernovotny commented Mar 11, 2017 via email

@ctaggart
Copy link
Owner Author

I understand. This is just for troubleshooting to see if it a compatibility issue or something else.

@clairernovotny
Copy link

@ctaggart I pushed a commit that temporarily removed GitVersion but it still happens:
https://ci.appveyor.com/project/dotnetfoundation/rx-net-la3iv/build/1.0.132

@ctaggart
Copy link
Owner Author

Thanks. I may find some time next week to troubleshoot more.

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

No branches or pull requests

3 participants