Skip to content

0.15 - The API hash is different between 64-bit and 32-bit builds #177

Description

@enbyted

The generated API hash seems to depend on pointer width somehow.
When building for i686-pc-windows-msvc and x86_64-pc-windows-msvc the generated API version hash is different even though the rust source and generated c# (apart form the hash) remains the same.

I believe this is a bug - ABI mismatch on this level will be detected by the operating system - you cannot load a 32-bit library into 64-bit process and vice versa. If otherwise bindings stay the same then hashes should be the same.

In particular, this requires me to modify the generated c# bindings in order to support AnyCPU builds. For that I have to choose at runtime (depending on what architecture I'm running on) which DLL to load and thus I have to adjust the bindings to support 2 different hashes.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingcoreInteroptopus Core Crate

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions