fix(pitaya-sharp): filter per-arch native libs in Unity <6000 builds#80
Open
tiagomartines11 wants to merge 1 commit into
Open
fix(pitaya-sharp): filter per-arch native libs in Unity <6000 builds#80tiagomartines11 wants to merge 1 commit into
tiagomartines11 wants to merge 1 commit into
Conversation
On Unity 2021/2022 the PluginImporter serializedVersion 3 layout used
since 1.0.11 doesn't filter the per-arch natives correctly. Unity sees
duplicate libpitaya_cpp.{so,dylib} filenames in the Linux64/OSXUniversal
slots, silently excludes them all, and the player crashes at runtime
with DllNotFoundException.
Adds a build-output post-process (gated on !UNITY_6000_0_OR_NEWER) that
filters the per-arch natives in the player's plugins directory after
every build, keeping only the variant that matches the active build
target — replacing wrong-arch variants and creating the file when Unity
dropped them all. Source assets and .meta files are never touched.
Unity 6 keeps using the authored .meta files.
Bumps version to 1.2.1-rc.1.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
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.
On Unity 2021/2022 the PluginImporter serializedVersion 3 layout used since 1.0.11 doesn't filter the per-arch natives correctly. Unity sees duplicate libpitaya_cpp.{so,dylib} filenames in the Linux64/OSXUniversal slots, silently excludes them all, and the player crashes at runtime with DllNotFoundException.
Adds a build-output post-process (gated on !UNITY_6000_0_OR_NEWER) that filters the per-arch natives in the player's plugins directory after every build, keeping only the variant that matches the active build target — replacing wrong-arch variants and creating the file when Unity dropped them all. Source assets and .meta files are never touched. Unity 6 keeps using the authored .meta files.
Bumps version to 1.2.1-rc.1.