Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Profile259 assembly ends up in "net45" directory in package #797

Closed
dsyme opened this issue Apr 23, 2015 · 10 comments
Closed

Profile259 assembly ends up in "net45" directory in package #797

dsyme opened this issue Apr 23, 2015 · 10 comments
Labels

Comments

@dsyme
Copy link
Contributor

dsyme commented Apr 23, 2015

I'm fairly new to all of this, so it may be my mistake. I created a profile 259 PCL assembly and packed it using the standard stuff:
Target "NuGet" (fun _ -> Paket.Pack(fun p -> { p with Version = release.NugetVersion ReleaseNotes = toLines release.Notes})

However in the resulting package the DLL was put into the "lib\net45" folder. I guess I expected it to go into a lib/portable-net45 netcore45 wpa81 wp8 MonoAndroid1 MonoTouch1 folder or equivalent.

The DLL that got packed was built with normal settings and placed into a "bin" folder

<TargetFrameworkVersion>v4.5</TargetFrameworkVersion> <TargetFrameworkProfile>Profile259</TargetFrameworkProfile> <TargetProfile>netcore</TargetProfile> <TargetFSharpCoreVersion>3.259.3.1</TargetFSharpCoreVersion>
My understanding from this is that the DLL should end up in the right "lib" directory automagically.

Tomorrow I'll poke around the paket source to see if I can figure out what's going on.

@dsyme dsyme added the question label Apr 23, 2015
@forki forki added bug and removed question labels Apr 23, 2015
@forki
Copy link
Member

forki commented Apr 23, 2015

Yes this is not implemented yet. But I consider this a bug.

The issue is that we already have good mapping from /lib/whatever/lib.dll to targetframwork (incl. silverlight and portable) but not the way back. IIRC we only support plain .NET framework versions and silverlight at the moment.

I will look into this later today and hope I can provide you a fixed version for testing.

@dsyme
Copy link
Contributor Author

dsyme commented Apr 23, 2015

Is there a workaround for this? I tried this but it didn't seem to work:
files ../../bin/4.0/FSharp.Core.Fluent-4.0.* ==> lib/portable-net45 netcore45 wpa81 wp8 MonoAndroid1 MonoTouch1

@forki
Copy link
Member

forki commented Apr 23, 2015

Yes this looks like a valid workaround. But since the whole pack thing is really new I assume you discovered another bug. Is your project open source? Will try to fix that too.

Sorry....

@dsyme
Copy link
Contributor Author

dsyme commented Apr 23, 2015

Np. If I do this

..\..\bin\3.1\FSharp.Core.Fluent-3.1.* ==> lib\portable-net45 netcore45 wpa81 wp8 MonoAndroid1 MonoTouch1

then it says ..\..\bin\3.1\FSharp.Core.Fluent-3.1.* not found. If I change to explicit file names:

..\..\bin\3.1\FSharp.Core.Fluent-3.1.dll ==> lib\portable-net45 netcore45 wpa81 wp8 MonoAndroid1 MonoTouch1
..\..\bin\3.1\FSharp.Core.Fluent-3.1.pdb ==> lib\portable-net45 netcore45 wpa81 wp8 MonoAndroid1 MonoTouch1
..\..\bin\3.1\FSharp.Core.Fluent-3.1.xml ==> lib\portable-net45 netcore45 wpa81 wp8 MonoAndroid1 MonoTouch1

then I get files in both "net45" and "portable-net45 netcore45 wpa81 wp8 MonoAndroid1 MonoTouch1". Is there any way to get it to stop putting the files in "net45"?

Thanks!
Don

@forki
Copy link
Member

forki commented Apr 23, 2015

You would need to change the type to file at the top of your paket.template file. The type project will always add the project output to whatever it thinks is a good idea.

But be careful IIRC the file type will not discover things like the project dependencies to maintain your transitive nuget dependencies in the nuspec

@dsyme
Copy link
Contributor Author

dsyme commented Apr 23, 2015

OK, got it, thanks!

@forki
Copy link
Member

forki commented Apr 23, 2015

just tried your project with

..\..\bin\3.1\FSharp.Core.Fluent-3.1.* ==> lib\portable-net45 netcore45 wpa81 wp8 MonoAndroid1 MonoTouch1

worked for me. Strange.

@forki
Copy link
Member

forki commented Apr 23, 2015

I implemented the infrastructure for this. see 30e589b

Now we need some help from the community to implement ToString for all the known portable profiles in 30e589b#diff-42d3481f9056752a7b3b551f9f92165dR191

I'm looking for volunteers - maybe someone knows a official list and can copy/paste this.

@matthid
Copy link
Member

matthid commented Apr 23, 2015

I always have this open in a tab: http://embed.plnkr.co/03ck2dCtnJogBKHJ9EjY/preview
Never found another (or official) source for this. I'm a bit too busy right now to start the implementation but I figured to share it at least.

@forki
Copy link
Member

forki commented Apr 23, 2015

thanks. this helps a lot.

@forki forki closed this as completed in e136f17 Apr 23, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants