MerosCrypto / Meros

An instant and feeless cryptocurrency for the future, secured by the Merit Caching Consensus Mechanism.
https://meroscrypto.io
Other
83 stars 19 forks source link

Platform support branch. #312

Open kayabaNerve opened 3 years ago

kayabaNerve commented 3 years ago

Tracking issue for https://github.com/MerosCrypto/Meros/tree/platform-support.

Ubuntu 18.04 and 20.04 should work without issue. Arch Linux should work without issue.

macOS has several issues.

And there may be more I have yet to find. I also needed to set a manual CPATH/LIBRARY_PATH so gmpy2 would build. I installed the dependencies with brew install gmp mpfr libmpc and it worked without issue, yet after rebooting, and deciding to rebuild on Python 3.8 instead of 3.9 as an experiment, I needed to set a CPATH for gmp and LIBRARY_PATH for all three...

Windows hasn't been supported in ages. I have no idea if we'll want to go with msvc or mingw when we add support for it. While it'd be great to say "MS ecosystem! msvc!", I do remember msvc has some quirks, such as not supporting C99, and I believe horrible CMake integration. That said, the last system I tried on had so much development cruft it's hard to actually say. Multiple libraries only have Linux build instructions. We also don't support tracking file handles on Windows, so Meros will fail to build there as well.

kayabaNerve commented 3 years ago

If we use the pr-applem1 branch from RandomX in mc_randomx, we'll have macOS support without issue; the library will also be ~6 months older than it currently is. That said, not only has no notable to us development happened in that time, it'd still be newer than our currently used commit. I'm personally hoping it's simply merged though and we can just update to the latest commit,

kayabaNerve commented 3 years ago

Pylint can't find the MultilineExpansionChecker. I have no idea why a scripted environment has difficulty here yet it does.

macOS and Windows use case insensitive file systems. The folder is named Pylint. It's trying to import from pylint proper instead of our custom folder.

kayabaNerve commented 3 years ago

For what it's worth, mc_lmdb expects msvc.

kayabaNerve commented 3 years ago

https://github.com/MerosCrypto/Meros/commit/8bf28f12c88503b68db813cd818b9e7f94e4cac8 fixed the WalletDB test failing. I'm hoping to get the other part of that checklist item via updating LMDB. Running every test on it now.

kayabaNerve commented 3 years ago

LMDB issues are all sorted.

kayabaNerve commented 3 years ago

Notably, running the Consensus test still prints 26 (invalid data!). On a second look, this doesn't appear to be from lmdb. It's printing next to RandomX debug statements I added, making that my next guess, yet I'm honestly not sure.

EDIT: It's Nim's system module. Apparently, a set is corrupted? I'm really not sure.

kayabaNerve commented 3 years ago

The issue was the RandomXFlags enum. Updating it now.

kayabaNerve commented 3 years ago

Updated mc_randomx, as well as the version of RandomX used, to solve all issues there. As far as macOS is concerned, it's solely the Python issues standing (and lack of choosenim which will not be considered a blocker).

kayabaNerve commented 3 years ago

Updating the argon2-cffi dependency fixed that issue. Possible new issue of pylint throwing plenty of no-member and c-extension-no-member errors.

kayabaNerve commented 3 years ago

ULimit didn't work properly, finding files 0 .. 9 and 10 if it exists, yet no others. Replaced it with a horrible shell execution which does work.

kayabaNerve commented 3 years ago

Except for choosenim on m1 Macs, macOS should work without issue now. I'd like to merge the platform support branch on that basis, yet keep it around pending further development on Windows. While I would like Ubuntu 14.04 support, as it's still a supported LTS branch, I understand it's 7 years old and not something we may want to officially support. I'm also just tired of tedious tasks, hence why I want to revisit Windows at a later date.