Page MenuHomePhabricator

[NixOS] Allow for usage of Android NDK binaries
AbandonedPublic

Authored by jon on Jul 21 2022, 12:36 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Oct 22, 3:08 PM
Unknown Object (File)
Sun, Oct 20, 5:22 PM
Unknown Object (File)
Wed, Oct 16, 12:33 PM
Unknown Object (File)
Sun, Oct 13, 8:56 PM
Unknown Object (File)
Sun, Oct 13, 8:56 PM
Unknown Object (File)
Sun, Oct 13, 8:56 PM
Unknown Object (File)
Sun, Oct 13, 8:56 PM
Unknown Object (File)
Sun, Oct 13, 8:55 PM

Details

Reviewers
varun
ashoat
Summary

Android NDK distributes pre-compiled binaries which link against
libstdc++.so.6 and zlib. NixOS can't run them without some hacks, and
LD_LIBRARY_PATH is the quickest fix.

Test Plan

On NixOS, nix develop then build android

Diff Detail

Repository
rCOMM Comm
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

Rebase to avoid CI breaking changes

Re-order after tunnelbroker additions

I don't really expect anyone to review this, setting up a NixOS machine is pretty niche, but it is helpful when doing android work on my desktop.

varun requested changes to this revision.Jul 26 2022, 10:38 AM
In D4602#131740, @jon wrote:

I don't really expect anyone to review this, setting up a NixOS machine is pretty niche, but it is helpful when doing android work on my desktop.

Do we want to land this diff?

This revision now requires changes to proceed.Jul 26 2022, 10:38 AM

I would like to land the diff. Should be a no-op on darwin.

I don't really expect anyone to review this, setting up a NixOS machine is pretty niche, but it is helpful when doing android work on my desktop.

This comment confused me, but I understand now that you meant you don't expect anyone to test this diff on their machine. Are we supporting NixOS for all development workflows or just Android?

ashoat requested changes to this revision.Jul 27 2022, 6:23 AM

Repeating my feedback from D4483:

Was chatting with @atul and neither of us is really sure what the product impact here is. The team (outside of @jon) doesn't use NixOS, so the only benefits I can see here are:

  1. To improve @jon's personal custom workflow. Here, I wonder if we should be spending cycles supporting a custom niche use case, as opposed to having @jon use macOS primarily like the rest of the team
  2. To provide an alternative to the CI build that we currently do with Debian. Here, it's not really clear if the change will be that impactful

At a high-level, I think we should be prioritizing Nix work that has an immediate impact on dev velocity and dev experience across all devs on the team. Until the whole team is actively using Nix for the primary development workflow, I'd prefer if we could deprioritize any other Nix work.

To help make the prioritization super clear, here are some clarificiations:

  1. NixOS support should be deprioritized in favor of macOS Nix support
  2. CI Nix support should be deprioritized in favor of dev environment Nix support
  3. Nix as a replacement for Docker should be deprioritized in favor of Nix as a replacement for Homebrew and the dev environment instructions

I want to talk through the pattern of @jon using NixOS while trying to support the rest of the team (who are using Nix on macOS) in our 1:1 later today. We can follow-up on this diff after that.

This revision now requires changes to proceed.Jul 27 2022, 6:23 AM

Talked to @jon, we're going to avoid NixOS-specific diffs in favor of everyone on the team using Nix on Darwin for the near future

going to abandon for now, to clean up my queue