CONFIG: Fix Linux native library PackagePath in LibPostalNet - #101
Merged
Conversation
The libpostal-1.so content item was being packed to a PackagePath ending in .dll. Because the source and destination extensions did not match, NuGet treated the destination as a directory rather than a file rename, producing: contentFiles/linux_x86_64/libpostal-1.dll/libpostal-1.so NHSISL.LibPostalNet.targets resolves LinuxNativeFiles from contentFiles/linux_x86_64/libpostal-1.so, so on Linux the item matched nothing, the Copy task silently copied no files, and the native library never reached the output directory. Verified the rebuilt package now places the file at contentFiles/linux_x86_64/libpostal-1.so. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
There was a problem hiding this comment.
Pull request overview
This PR corrects the NuGet package layout for the Linux native libpostal-1.so in NHSISL.LibPostalNet so that the packed path matches what NHSISL.LibPostalNet.targets consumes at build/publish time, preventing missing native library copies for Linux consumers.
Changes:
- Fix
PackagePathforlibpostal-1.soto end in.so(not.dll) so NuGet treats it as a file path, not a directory. - Align packaged Linux native file location with
NHSISL.LibPostalNet.targets’sLinuxNativeFilesinclude path.
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
cjdutoit
approved these changes
Aug 24, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes AB#29898 (follow-up to #84)
Problem
libpostal-1.sowas being packed to aPackagePathending in.dll:Because the source and destination extensions do not match, NuGet treats the destination as a directory rather than a file rename. The resulting package contained:
NHSISL.LibPostalNet.targetsresolvesLinuxNativeFilesfromcontentFiles/linux_x86_64/libpostal-1.so. That item therefore matched nothing on Linux, theCopytask silently copied zero files, and the native library never reached the output directory — aDllNotFoundExceptionat runtime for Linux consumers.Fix
One line — the destination now matches the source extension.
Verification
Rebuilt the package and inspected it:
contentFiles/linux_x86_64/libpostal-1.dll/libpostal-1.socontentFiles/linux_x86_64/libpostal-1.soThis now matches what the targets file expects.
NHSISL.LibPostalClient.csprojalready used the correct pattern.Why now
NHSISL.LibPostalNetbecame packable and part of the solution in #84 but has not yet been published to nuget.org. Fixing the layout before the first release avoids it becoming a breaking change for consumers later.🤖 Generated with Claude Code