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

[Component Licensing] SDK needs to make sure that licenses.licx ends up as "EmbeddedResource" #3631

Open
davkean opened this issue Sep 12, 2019 · 10 comments

Comments

@davkean
Copy link
Member

davkean commented Sep 12, 2019

Visual Studio Version:

Summary:
The Visual Studio support for Windows Forms licensing was implemented in dotnet/project-system#5468, and works well if you opt out of the globs. VS will automatically add it to EmbeddedResource:

<Project Sdk="Microsoft.NET.Sdk">

  <PropertyGroup>
    <OutputType>Exe</OutputType>
    <TargetFramework>net472</TargetFramework>
    <EnableDefaultNoneItems>false</EnableDefaultNoneItems>
  </PropertyGroup>

  <ItemGroup>
    <Reference Include="C:\Program Files (x86)\DevExpress 19.1\Components\Bin\Framework\*.dll" />
    <Reference Include="System.Windows.Forms" />
  </ItemGroup>

  <ItemGroup>
    <EmbeddedResource Include="licenses.licx" />
  </ItemGroup>

</Project>

However with globs turned on, we don't add a specific item if a glob covers it. Based on that, the SDK needs to cover licenses.licx in EmbeddedResource item.

Steps to Reproduce:

  1. Install DevExpress controls: https://www.devexpress.com/subscriptions/new-2019-1.xml
  2. Create a project with the following:
<Project Sdk="Microsoft.NET.Sdk">

  <PropertyGroup>
    <OutputType>Exe</OutputType>
    <TargetFramework>net472</TargetFramework>
  </PropertyGroup>

  <ItemGroup>
    <Reference Include="C:\Program Files (x86)\DevExpress 19.1\Components\Bin\Framework\*.dll" />
    <Reference Include="System.Windows.Forms" />
  </ItemGroup>

</Project>
  1. Add a Form (Windows Forms) to the project
  2. Open designer, choose Toolbox -> DX.19.1: Reporting and drag RibbonReportDesigner onto the form

Expected Behavior:
Properties\licenses.licx gets created and ends up in EmbeddedResource item

Actual Behavior:
Properties\licenses.licx gets created but ends up in None item type

User Impact:
Licensed controls don't work at runtime.

@davkean
Copy link
Member Author

davkean commented Sep 12, 2019

License.licx can live in both the AppDesigner folder (which can be renamed to something custom) and in the root of the project.

tag @nguerrera

@davkean
Copy link
Member Author

davkean commented Sep 12, 2019

@livarcocc Can you put this in the milestone that corresponds with 16.4 as per offline agreement?

@nguerrera nguerrera added this to the 3.1.1xx milestone Sep 12, 2019
@nguerrera
Copy link
Contributor

@vatsan-madhavan @dsplaisted should this globbing go in WindowsDesktop sdk?

@nguerrera
Copy link
Contributor

@davkean I’ve put it in 3.1.1xx milestone, which matches 16.4. Thank you for the detailed issue.

@vatsan-madhavan
Copy link
Member

Sure, that’s ok by me. What’s the plan for LC.exe? Wouldn’t we want a netcoreapp version of it as well?

@weltkante
Copy link

weltkante commented Sep 12, 2019

@vatsan-madhavan LC.exe executes code so controls can generate the license data you are embedding (you are not embedding the literal licx file, its just instructions for LC.exe which controls need a license).

Desktop version of LC.exe won't be able to execute .NET Core code, so yes, LC.exe needs to be ported if you don't want to replace the whole licensing mechanism with something different.

Once its clear who will own LC.exe I have some follow-up issues to create for future improvements, historically LC.exe is very fragile and errors are hard to diagnose, but lets first get things actually working. Since WebForms are gone WinForms is probably the only one still using this kind of licensing, but I'm not entirely sure of that.

@weltkante
Copy link

Any news for who is going to be responsible for porting LC.exe? There's dotnet/winforms#1462 but it has seen no action since this issue was created. If you want to get this into 3.1 this probably needs to be picked up soonish.

@livarcocc
Copy link
Contributor

The issue in winforms is the right one to track that.

@OliaG
Copy link
Member

OliaG commented Nov 12, 2019

My understanding is that we are not bringing LC.ee to .NET Core and instead @terrajobst will work on a newer way of licensing .NET Core apps.

rainersigwald pushed a commit that referenced this issue Jul 20, 2020
….2 (#3631)

- Microsoft.DotNet.Cli.Runtime - 3.1.100-rtm.19568.2
@jespersh
Copy link

jespersh commented Nov 9, 2020

@terrajobst @OliaG where can curious people follow this progress?

@marcpopMSFT marcpopMSFT added the needs team triage Requires a full team discussion label Aug 24, 2021
@marcpopMSFT marcpopMSFT removed this from the 3.1.1xx milestone Aug 24, 2021
@marcpopMSFT marcpopMSFT added Area-NetSDK and removed needs team triage Requires a full team discussion labels Aug 25, 2021
@marcpopMSFT marcpopMSFT added this to the Backlog milestone Aug 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

8 participants