Skip to content
Snippets Groups Projects
Commit c2b4f229 authored by Jean-Paul Calderone's avatar Jean-Paul Calderone
Browse files

some additional flailing

parent ccd7bee6
No related branches found
No related tags found
No related merge requests found
...@@ -4,6 +4,30 @@ ...@@ -4,6 +4,30 @@
* Build an app that can read magic-folders and download linked files * Build an app that can read magic-folders and download linked files
* Build an app that runs a Haskell Tahoe-LAFS implementation on Android
* Reflex-FRP / Obsidian Systems Obelisk?
https://reflex-frp.org/tutorial
https://github.com/obsidiansystems/obelisk
* The Obelisk readme basically works.
* Adding a native extension seems tricky.
* Obelisk pins a reflex-platform
* reflex-platform pins a nixpkgs
* reflex-platform various arguments to control nixpkgs
* nixpkgsFunc to completely replace the nixpkgs used
* nixpkgsOverlays to contribute overlays to nixpkgs
* config to pass other config to nixpkgs
* Obelisk does not accept nixpkgsFunc or nixpkgsOverlays
* But it does accept reflex-platform-func
* So override this with a version that passes an overlay to reflex, I guess
* Build an app that runs the Python Tahoe-LAFS implementation on Android * Build an app that runs the Python Tahoe-LAFS implementation on Android
* Build Tahoe-LAFS & ZKAPAuthorizer for Android * Build Tahoe-LAFS & ZKAPAuthorizer for Android
......
...@@ -60,16 +60,16 @@ ...@@ -60,16 +60,16 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1667821506, "lastModified": 1669145459,
"narHash": "sha256-u4HKBBfTOPpFsGnM7sjS0+F67Hmf2or3uHKNVxXZtiM=", "narHash": "sha256-NN18jHL7UvYjfCjnwH5eX64D9R+4TNAd+YyPpTfYJAw=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "ebf65554b18ee053311f43e5faa5a3f36626c52e", "rev": "fd83da2b640e05c6dd14fad4b741714b069ae0d7",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "NixOS", "owner": "NixOS",
"ref": "nixos-22.05", "ref": "staging",
"repo": "nixpkgs", "repo": "nixpkgs",
"type": "github" "type": "github"
} }
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
description = "The PrivateStorage Mobile application"; description = "The PrivateStorage Mobile application";
inputs = { inputs = {
nixpkgs = { nixpkgs = {
url = "github:NixOS/nixpkgs?ref=nixos-22.05"; url = "github:NixOS/nixpkgs?ref=staging";
}; };
flake-utils.url = "github:numtide/flake-utils"; flake-utils.url = "github:numtide/flake-utils";
pypi-deps-db = { pypi-deps-db = {
...@@ -111,7 +111,7 @@ ...@@ -111,7 +111,7 @@
''; '';
}; };
in { in {
# packages.host-python = (import nixpkgs { system = "aarch64-linux-android"; }).python3Minimal.override { self = self.packages.host-python; }; packages.host-python = pkgs.pkgsCross.aarch64-android.python3Minimal;
packages.apk = pkgs.androidenv.buildApp { packages.apk = pkgs.androidenv.buildApp {
name = "PrivateStorage Mobile"; name = "PrivateStorage Mobile";
...@@ -137,6 +137,30 @@ ...@@ -137,6 +137,30 @@
in in
"${emulator}/bin/run-test-emulator"; "${emulator}/bin/run-test-emulator";
}; };
apps.emulate-python = {
type = "app";
program = let
emulator = pkgs.androidenv.emulateApp {
name = "PrivateStorage Mobile";
inherit platformVersion;
abiVersion = "x86_64";
systemImageType = "default";
app = self.self.packages.${system}.apk;
package = "MyApp";
activity = "MainActivity";
};
in
"${emulator}/bin/run-test-emulator";
};
devShells.cross = pkgs.mkShell rec {
buildInputs = with pkgs.pkgsCross.aarch64-android; [
python3Minimal
binutils
];
};
devShells.gradle = pkgs.mkShell rec { devShells.gradle = pkgs.mkShell rec {
name = "nix-native"; name = "nix-native";
version = "2022.11.09"; version = "2022.11.09";
...@@ -310,7 +334,11 @@ ...@@ -310,7 +334,11 @@
# (Q) Does something put the host Python's _sysconfigdata__linux_.py on # (Q) Does something put the host Python's _sysconfigdata__linux_.py on
# the build Python's PYTHONPATH? What? How? # the build Python's PYTHONPATH? What? How?
# #
# (Q) # (Q) Who is trying to set _PYTHON_SYSCONFIGDATA_NAME, what are they
# trying to set it to, and what purpose are they trying to achieve?
#
# (Q) Did https://github.com/NixOS/nixpkgs/pull/104201 fix
# something relevant to us?
# #
# And now for something completely different. # And now for something completely different.
...@@ -321,6 +349,10 @@ ...@@ -321,6 +349,10 @@
# our nixpkgs-cross-compiled CPython would be a good complement? # our nixpkgs-cross-compiled CPython would be a good complement?
# #
# QEMU can emulate ARM!
# https://azeria-labs.com/arm-on-x86-qemu-user/
# https://www.bennee.com/~alex/blog/2014/05/09/running-linux-in-qemus-aarch64-system-emulation-mode/
# packages.host-python = pkgsCross.aarch64-android.python3Minimal.withPackages (ps: [ # packages.host-python = pkgsCross.aarch64-android.python3Minimal.withPackages (ps: [
# # The nixpkgs zfec has some extra dependencies that we might not # # The nixpkgs zfec has some extra dependencies that we might not
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment