Skip to content
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

Fix Pseudo-Relocation issue in MinGW #6

Open
ProofOfKeags opened this issue May 3, 2024 · 0 comments
Open

Fix Pseudo-Relocation issue in MinGW #6

ProofOfKeags opened this issue May 3, 2024 · 0 comments
Labels
bug Something isn't working help wanted Extra attention is needed

Comments

@ProofOfKeags
Copy link
Collaborator

There is currently an issue in our Windows build which yields the following:

libsecp256k1> test (suite: spec)
Mingw-w64 runtime failure:
32 bit pseudo relocation at 0000[7](https://github.com/haskell-bitcoin/libsecp256k1-haskell/actions/runs/8944022468/job/24570019972#step:11:8)FF778DA68C6 out of range, targeting 00007FFD7ADA4010, yielding the value 0000000601FFD746.
libsecp256k1> Test suite spec failed
Error: [S-72[8](https://github.com/haskell-bitcoin/libsecp256k1-haskell/actions/runs/8944022468/job/24570019972#step:11:9)2]
       Stack failed to execute the build plan.
       
       While executing the build plan, Stack encountered the error:
       
       Error: [S-1995]
       Test suite failure for package libsecp256k1-0.2.1
           spec:  exited with: ExitFailure (-1073740791)
       Logs printed to console

At the moment, none of the existing contributors runs Windows natively and so work on fixing this has been suspended indefinitely. If you are working in Windows and would like this fixed, we would like to invite you to contribute a patch to deal with this. It is possible it is a bug in GHC itself, and how it handles pointers in Windows executables. Information on that bug can be found here

Things that have been tried and failed:

  • Switching to a Debug build in the CMAKE installation of the underlying secp256k1 library

Things that could be tried:

  • Change the underlying representation of the secp256k1 types to not be native haskell types instead of ForeignPtr
  • Making functions strict or otherwise messing with execution order
  • Moving away from MinGW entirely (not sure how much sense this makes)
@ProofOfKeags ProofOfKeags added help wanted Extra attention is needed bug Something isn't working labels May 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant