oleg-shilo/wixsharp

Getting ICE03 Invalid Language ID error for numerous dlls referred while building MSI

abskulkarni opened this issue · 6 comments

Hi @oleg-shilo

I had referred Dac Nuget package in my ClientApp.EXE project which is then getting built as a feature under Wix for MSI.

Now, in Wix project, I am getting below error for numerous dlls referred in my ClientApp.EXE project

LGHT0204 ICE03: Invalid Language Id; Table: File, Column: Language, Key(s): Microsoft.Data.Tools.Schema.Sql.resources.dll_3185449638

image

What is this error and how to resolve this?

Can you please provide the test project that demonstrates your problem.

The sample project that I created according to your description compiles just fine (attached).
WixSharp Setup17.zip

Note, in the attached sample you will need to update the path in program.cs

Hi @oleg-shilo

Sorry to be wordy below in advance... :(

Problem comes with Wix# project when I refer Nuget package Microsoft.SqlServer.DacFx (version 162.3.563) in client app.

Here are the steps I did to get error:

  1. Create client app (simple C# Win Form app .NET framework 4.8)
  2. Copy its output to C:\Test folder... i.e. C:\Test\MyWixProduct\ClientApp.exe etc.
  3. Create Wix V3 project. This will be having Managed UI of Feature tree (project.UI = WUI.WixUI_FeatureTree;) and taking C:\Test as source directory.
  4. Build Wix V3. It does compile smoothly. All smooth

Now comes a twist..

  1. In ClientApp project, I add Nuget package Microsoft.SqlServer.DacFx (version 162.3.563)... It installs whole lot of other dependent packages.
  2. Build ClientApp and copy its output again to C:\Test\MyWixProduct folder
  3. Try to rebuild Wix V3 projject and boom!! you get below error.

image

image

image

My simple sample app becomes 180 MB and unable to attach here. I hope you may be able to recreate error through my steps explained above.

Thank you for the test case. Will check on weekend

Hm... I cannot reproduce the problem.
I have attached the sample it builds just fine.

ConsoleApp3.zip

My simple sample app becomes 180 MB...

Not if you do not build it and share just project(s).

Hi @oleg-shilo
It is a C# WinForm project I have used not console app. Just take normal C# WinForm project targeting .NET framework 4.8, add a button in Form1.
Then add Nuget package as discussed above.

Also I have attached POC project without build, hope it will be sufficient for you to reproduce my issue.

WixPOC.zip

I look (I cannot run it) at you sample and see that you are adding combinations of files and features based on the files that you have discovered in the local dir.
This is a problem as you as if you have 10 files and t10 features your will have 100 file entries in your MSI. Thes the same file may be added to msi multiple times.

What you want is 1:N relationship. One set of files that is associated with multiple featuires:

new Files($@"{sourceDir}\*.exe") { Features = new[] { feature1, feature2, ...} },

Note this has nothing to do with Language ID. I cannot reach this stage without runable sample. But if you resolve this 1:N problem you may see better what is going on there.