-
Notifications
You must be signed in to change notification settings - Fork 2
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
Fixes for macOS #18
Fixes for macOS #18
Conversation
This is excellent! Thanks for your work. I hope Nix wasn't too frustrating :) |
Nix has been mostly pain free. A bit confused on by |
also fixes up some nix noob mistakes
Basil build is fixed on my computer by 302dd59. This happened because the configure phase was not being run in the dependency derivation, which mkSbtDerivation runs to download all dependencies (evidenced by the Propagating the replacement command makes it work. I suspect some caching was at play to make it succeed locally. |
Re protobuf abseil linking errors: https://www.github.com/protocolbuffers/protobuf/issues/12637 |
gtirb: Proper fix for abseil linking aslp-cpp: Build with clang 17 on macOS alive2-regehr: Disable 'no-error=maybe-uninitialized' option on macOS alive2: Build with clang 17 on macOS llvm-custom: Fix hardcoded /build path to $NIX_BUILD_TOP ocaml-llvm: Bump ctypes-foreign to 0.23.0 to build on macOS
From what I see locally, the only remaining issue is the determinism fix for ddisasm not working on macOS. If this isn't used, I suspect it would be far easier to disable the test. |
Add additional search path to BAP wrapper
It looks really good now! Just one thing left, we should make the ddisasm test use a "nolibc" variant of the compiler so it doesn't spin cross-compiling libc. I can look into this if you want. Edit: Or simply vendor an aarch64 ELF binary (somewhere not in the git repo) - the test is not about the cross compiler. |
Thanks! I'll leave it to you. I was wondering if it would be possible to have Nix provide a full cross compiling environment on macOS anyway, as full tests aren't practical without it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
todo notes for myself
@ncough real quick about using Nix as a cross-compile environment, this is definitely possible. but the main problem is the Nix-provided compilers are not hermetic - they will look for and may or may not find libraries on your system. It is especially dicey if the Nix compilers call a non-Nix tool which it finds through PATH. The solutions I can conceptualise are:
|
fixed conflicts in gtirb.nix and ddisasm.nix arising from patches and ddisasm-deterministic
In advancing the nixpkgs version for arm-tv, it seems that ocaml is broken on aarch64-darwin https://www.github.com/NixOS/nixpkgs/issues/350394. This seems to be fixed now https://hydra.nixos.org/build/276865224 |
Flake lock file updates: • Updated input 'nixpkgs': 'github:nixos/nixpkgs/18536bf04cd71abd345f9579158841376fdd0c5a' (2024-10-25) → 'github:nixos/nixpkgs/e24d868aba3d21acacdcc319066ce8c4eb692605' (2024-10-31)
[skip ci] for now.
until they fix aarch64 things
Flake lock file updates: • Updated input 'nixpkgs': 'github:nixos/nixpkgs/e24d868aba3d21acacdcc319066ce8c4eb692605' (2024-10-31) → 'github:nixos/nixpkgs/4633a7c72337ea8fd23a4f2ba3972865e3ec685d' (2024-11-25)
problems on macos and it didnt do much anyway [skip ci]
Partial fixes for getting builds to work on macOS. Many fixes are quite hacky, hopefully someone who knows what they are doing can fix them properly.
gtirb
, as a dependency of protobuf. Not clear why this isn't done automatically.#include <map>
ingtirb-pprinter
.protoc
tobasil
, due to issues downloading and caching it.ocamlPackages.z3
.python-gtirb