Skip to content

Paket pack doesn't properly parse OutDir when you use $(Targetframework) #2450

Closed

Description

@TOTBWF

Description

When using TargetFrameworks, the default value for OutDir is ./bin/$(Configuration)/$(TargetFramework). When packaging, paket will look for the requisite .dlls in ./bin/Release/<Dll Name> instead of ./bin/Release/<Target Framework>/<Dll Name>

Repro steps

  1. Create a .fsproj file that uses <TargetFrameworks> and set <OutDir> to ./bin/$(Configuration)/$(TargetFramework)/

  2. Run paket pack

Expected behavior

Paket properly creates a package

Actual behavior

Paket fails with

Paket failed with:
-> FileNotFoundException: Could not find file "<Path to Project>/bin/Release/<ProjectName>.dll".

Known workarounds

None

Activity

  1. forki commented on Jun 20, 2017

    @forki
    Member
  2. batzen commented on Jun 20, 2017

    @batzen
    Contributor

    @forki You think this is related to my SpecificVersion PR?

  3. forki commented on Jun 20, 2017

    @forki
    Member

    It's using the feature you added, isn't it?

  4. forki commented on Jun 20, 2017

    @forki
    Member

    @TOTBWF Can we please get a zip with everything already built so that we only need to call Pack to get the error? Thx

  5. TOTBWF commented on Jun 20, 2017

    @TOTBWF
    Author

    Here is the most pared down example I could make

    Example.zip

  6. forki commented on Jun 20, 2017

    @forki
    Member

    I think I wanted to cc @bhugot

  7. bhugot commented on Jun 20, 2017

    @bhugot
    Contributor

    I knew this problem before I did my PR. It s a problem with type project template and the csproj parsing. I will try to look at it when I have a bit of time

  8. bhugot commented on Jun 29, 2017

    @bhugot
    Contributor

    Hi guys I m trying to fix it. I found a fix for but for as paket is not working for multiple Framework it's alot of change. I think GetTargetProfile in ProjectFile.fs should return a list of framework and not one framework.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions