-
Notifications
You must be signed in to change notification settings - Fork 84
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
Single file deployment support #45
Comments
As long as I can see, its a matter of typing
in project file, so of course I will do that after 5.0 release :) |
Thank you |
@adoconnection Thanks for the great library! If you also want to support single file deployment in .NET 5, you'll need to change the way the 7z.dll library is loaded. When NativeLibrary.Load(sevenZipLibPath, Assembly.GetEntryAssembly(), null); In this case, To support relative paths, you'll need to remove the SevenZipExtractor/SevenZipExtractor/ArchiveFile.cs Lines 278 to 281 in aaf6f24
I also added an extra else
{
this.libraryFilePath = Path.Combine(currentArchitecture, "7z.dll");
} added to SevenZipExtractor/SevenZipExtractor/ArchiveFile.cs Lines 255 to 270 in aaf6f24
An alternative approach to handle single file apps would be to expose an ArchiveFile constructor that takes an IntPtr instead of libraryFilePath, and let the user load the library themselves using |
Hi, thanks for kind words and detailed info! I’ll implement it as soon as got some spare time. |
Any plans to port to .NET5? Would be great!
Thx
Patrick
The text was updated successfully, but these errors were encountered: