!UUYziobKGGxpovWyAN:nixos.org

Robotnix

244 Members
Build Android (AOSP) using Nix | https://github.com/danielfullmer/robotnix75 Servers

Load older messages


SenderMessageTime
5 Sep 2021
@jcie74:matrix.orgpie_nitpick, https://docs.robotnix.org/ still mentions freenode17:07:56
@jcie74:matrix.orgpie_ danielrf: btw, isnt --arg applied everywhere/every function invocation? im always a little weirded out when someone recommends using it 17:44:07
@jcie74:matrix.orgpie_meanwhile, turns out the person offering me the beefy machine for builds cant offer it anymore, so i again need to find someone that can give me build time18:06:32
@jcie74:matrix.orgpie_ * nitpick, https://docs.robotnix.org/ and https://docs.robotnix.org/modules/flavors.html still mentions freenode18:14:16
@samueldr:matrix.orgsamueldr --arg passes the --arg value only to functions it directly encounters AFAIUI; e.g. if the expression you evaluate is a list of function, it will pass the arguments to the functions from that list, but not further.;
This mirrors the nix-build behaviour where building a list of derivations build all of them; if you have a list of expressions needing to be parameterized to produce derivations to build, I guess it makes sense to provide args to all of them
18:34:09
@samueldr:matrix.orgsamueldr (I'm going from the description in the man page, haven't actually seen --arg being given to anything else than a top-level function, and I've been using --arg extensively in Mobile NixOS) 18:35:53
@danielrf:matrix.orgdanielrf
In reply to @jcie74:matrix.org
nitpick, https://docs.robotnix.org/ and https://docs.robotnix.org/modules/flavors.html still mentions freenode
Thanks, just pushed a fix that should propagate to docs.robotnix.org soon
18:36:38
@danielrf:matrix.orgdanielrf My understanding is about --arg matches what samueldr said. The original idea was to have configuration as a top-level argument, so that it matched what NixOS does in nixpkgs/nixos/default.nix. 18:37:50
@danielrf:matrix.orgdanielrf The newer nix command line interface when using flakes does not support --arg on the commandline, you currently have to make a flake.nix and call robotnix.lib.robotnixSystem 18:39:46
@danielrf:matrix.orgdanielrf But if the configuration is short enough (and I'm just testing something out), I like the convenience of specifying the options directly on the command line, as opposed to making a .nix file every time. 18:42:02
@samueldr:matrix.orgsamueldr(off-topic) huh, I didn't know that about flakes... a step backward in UX imho18:42:42
@danielrf:matrix.orgdanielrf kranzes: Hey, that's great! If you're interested in figuring out exactly what is breaking it in the lineageos configuration, you can start commenting out the sections that don't seem needed and testing. Bth, my best guess now actually is the webview configuration overrides we do in the lineageos flavor 18:46:50
@danielrf:matrix.orgdanielrf * kranzes: Hey, that's great! If you're interested in figuring out exactly what is breaking it in the lineageos configuration, you can start commenting out the sections that don't seem needed and testing. Tbh, my best guess now actually is the webview configuration overrides we do in the lineageos flavor 18:46:57
@danielrf:matrix.orgdanielrf samueldr: I have mixed feelings about it as well. Things that should be easy take a bit of boilerplate to make work. Reproducibility/purity benefits outweigh the costs for me though. 18:48:16
@kranzes:matrix.orgkranzesThat would take me ages18:48:18
@kranzes:matrix.orgkranzesevery build is 3 hours18:48:26
@kranzes:matrix.orgkranzesand i don't even know where to start18:48:42
@danielrf:matrix.orgdanielrfup to you if you want to continue tracking it down. The long turnaround time is an unfortunate thing we deal with on android.18:50:21
@danielrf:matrix.orgdanielrfBut I'd probably start with commenting out the webview stuff like so:18:50:38
@danielrf:matrix.orgdanielrf
diff --git a/flavors/lineageos/default.nix b/flavors/lineageos/default.nix
index 1216ca8..5407fc8 100644
--- a/flavors/lineageos/default.nix
+++ b/flavors/lineageos/default.nix
@@ -106,9 +106,9 @@ in mkIf (config.flavor == "lineageos")
         })
       ];
 
-      # LineageOS will sometimes force-push to this repo, and the older revisions are garbage collected.
-      # So we'll just build chromium webview ourselves.
-      "external/chromium-webview".enable = false;
+#      # LineageOS will sometimes force-push to this repo, and the older revisions are garbage collected.
+#      # So we'll just build chromium webview ourselves.
+#      "external/chromium-webview".enable = false;
     }
   ] ++ optionals (deviceMetadata ? "${config.device}") [
     # Device-specific source dirs
@@ -134,16 +134,16 @@ in mkIf (config.flavor == "lineageos")
   source.manifest.url = mkDefault "https://github.com/LineageOS/android.git";
   source.manifest.rev = mkDefault "refs/heads/${LineageOSRelease}";
 
-  # Enable robotnix-built chromium / webview
-  apps.chromium.enable = mkDefault true;
-  webview.chromium.availableByDefault = mkDefault true;
-  webview.chromium.enable = mkDefault true;
-
-  # This is the prebuilt webview apk from LineageOS. Adding this here is only
-  # for convenience if the end-user wants to set `webview.prebuilt.enable = true;`.
-  webview.prebuilt.apk = config.source.dirs."external/chromium-webview".src + "/prebuilt/${config.arch}/webview.apk";
-  webview.prebuilt.availableByDefault = mkDefault true;
-  removedProductPackages = [ "webview" ];
+#  # Enable robotnix-built chromium / webview
+#  apps.chromium.enable = mkDefault true;
+#  webview.chromium.availableByDefault = mkDefault true;
+#  webview.chromium.enable = mkDefault true;
+#
+#  # This is the prebuilt webview apk from LineageOS. Adding this here is only
+#  # for convenience if the end-user wants to set `webview.prebuilt.enable = true;`.
+#  webview.prebuilt.apk = config.source.dirs."external/chromium-webview".src + "/prebuilt/${config.arch}/webview.apk";
+#  webview.prebuilt.availableByDefault = mkDefault true;
+#  removedProductPackages = [ "webview" ];
 
   # Needed by included kernel build for some devices (pioneer at least)
   envPackages = [ pkgs.openssl.dev ] ++ optionals (config.androidVersion == 11) [ pkgs.gcc.cc pkgs.glibc.dev ];
18:50:48
@danielrf:matrix.orgdanielrf * up to you if you want to continue tracking it down. The long build/test cycle time is an unfortunate thing we deal with on android.18:51:33
@jcie74:matrix.orgpie_ samueldr: danielrf https://gist.github.com/cleverca22/240c21dab528666c85a95c4edfdeae58 19:13:40
@jcie74:matrix.orgpie_re: --arg19:13:43
@jcie74:matrix.orgpie_i couldnt remember where to find the relevant part of the source though19:13:53
@samueldr:matrix.orgsamueldrah, I think that's because they float up to the top-level19:15:00
@samueldr:matrix.orgsamueldror something like that19:15:26
@samueldr:matrix.orgsamueldrthough I guess it's less of an issue than could be thought, as I've literally never seen that being an issue19:15:45
@jcie74:matrix.orgpie_i think what happens is that things passed via such get added to a global autoargs variable19:15:51
@jcie74:matrix.orgpie_yeah im not sure why it never appears to be a problem19:16:10
@jcie74:matrix.orgpie_maybe they are only set when an argument isnt otherwise passed or something?19:16:28

Show newer messages


Back to Room ListRoom Version: 6