Skip to content
Open

25.11 #490

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Changelog

## Release 24.11 (unreleased)
## Release 25.11 (unreleased)

## Release 24.05

Expand Down
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ for example:

{
environment.packages = [ pkgs.vim ];
system.stateVersion = "24.05";
system.stateVersion = "25.11";
}
```

Expand All @@ -67,7 +67,7 @@ An alternative location is `~/.config/nixpkgs/config.nix` with the key

{
environment.packages = [ pkgs.vim ];
system.stateVersion = "24.05";
system.stateVersion = "25.11";
};
}
```
Expand All @@ -80,7 +80,7 @@ To enable `home-manager` you simply need to follow the instructions already prov

1. Add `home-manager` channel:
```sh
nix-channel --add https://github.com/nix-community/home-manager/archive/release-24.05.tar.gz home-manager
nix-channel --add https://github.com/nix-community/home-manager/archive/release-25.11.tar.gz home-manager
nix-channel --update
```
2. Configure `home-manager`:
Expand All @@ -89,15 +89,15 @@ To enable `home-manager` you simply need to follow the instructions already prov

{
# Read Nix-on-Droid changelog before changing this value
system.stateVersion = "24.05";
system.stateVersion = "25.11";

# insert Nix-on-Droid config

home-manager.config =
{ pkgs, ... }:
{
# Read home-manager changelog before changing this value
home.stateVersion = "24.05";
home.stateVersion = "25.11";

# insert home-manager config
};
Expand Down Expand Up @@ -181,10 +181,10 @@ A minimal example could look like the following:
description = "Minimal example of Nix-on-Droid system config.";

inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.05";
nixpkgs.url = "github:NixOS/nixpkgs/nixos-25.11";

nix-on-droid = {
url = "github:nix-community/nix-on-droid/release-24.05";
url = "github:nix-community/nix-on-droid/release-25.11";
inputs.nixpkgs.follows = "nixpkgs";
};
};
Expand Down
8 changes: 4 additions & 4 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
nixpkgs.url = "github:NixOS/nixpkgs";

# for bootstrap zip ball creation and proot-termux builds, we use a fixed version of nixpkgs to ease maintanence.
# head of nixos-24.05 as of 2024-07-06
# head of nixos-25.11 as of 2025-12-04
# note: when updating nixpkgs-for-bootstrap, update store paths of proot-termux in modules/environment/login/default.nix
nixpkgs-for-bootstrap.url = "github:NixOS/nixpkgs/49ee0e94463abada1de470c9c07bfc12b36dcf40";
nixpkgs-for-bootstrap.url = "github:NixOS/nixpkgs/c97c47f2bac4fa59e2cbdeba289686ae615f8ed4";

home-manager = {
url = "github:nix-community/home-manager";
Expand Down
4 changes: 2 additions & 2 deletions modules/build/initial-build.nix
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
with lib;

let
defaultNixpkgsBranch = "nixos-24.05";
defaultNixOnDroidBranch = "release-24.05";
defaultNixpkgsBranch = "nixos-25.11";
defaultNixOnDroidBranch = "release-25.11";

defaultNixpkgsChannel = "https://nixos.org/channels/${defaultNixpkgsBranch}";
defaultNixOnDroidChannel = "https://github.com/nix-community/nix-on-droid/archive/${defaultNixOnDroidBranch}.tar.gz";
Expand Down
4 changes: 2 additions & 2 deletions modules/environment/login/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -87,8 +87,8 @@ in
prootStatic =
let
crossCompiledPaths = {
aarch64-linux = "/nix/store/7qd99m1w65x2vgqg453nd70y60sm3kay-proot-termux-static-aarch64-unknown-linux-android-unstable-2024-05-04";
x86_64-linux = "/nix/store/pakj3svvw84rhkzdc6211yhc2cgvc21f-proot-termux-static-x86_64-unknown-linux-android-unstable-2024-05-04";
aarch64-linux = "/nix/store/pvxjb26pknyppyn30k16hvzwdg4a8sz0-proot-termux-static-aarch64-unknown-linux-android-0-unstable-2025-10-19";
x86_64-linux = "/nix/store/i7gcbfp3nlnmcrzy7g20mc9pax7pkl7x-proot-termux-static-x86_64-unknown-linux-android-0-unstable-2025-10-19";
};
in
"${crossCompiledPaths.${targetSystem}}";
Expand Down
6 changes: 3 additions & 3 deletions modules/environment/login/nix-on-droid.nix.default
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
environment.etcBackupExtension = ".bak";

# Read the changelog before changing this value
system.stateVersion = "24.05";
system.stateVersion = "25.11";

# Set up nix for flakes
#nix.extraOptions = ''
Expand All @@ -41,7 +41,7 @@
#time.timeZone = "Europe/Berlin";

# After installing home-manager channel like
# nix-channel --add https://github.com/nix-community/home-manager/archive/release-24.05.tar.gz home-manager
# nix-channel --add https://github.com/nix-community/home-manager/archive/release-25.11.tar.gz home-manager
# nix-channel --update
# you can configure home-manager in here like
#home-manager = {
Expand All @@ -51,7 +51,7 @@
# { config, lib, pkgs, ... }:
# {
# # Read the changelog before changing this value
# home.stateVersion = "24.05";
# home.stateVersion = "25.11";
#
# # insert home-manager config
# };
Expand Down
1 change: 1 addition & 0 deletions modules/version.nix
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ with lib;
"23.05"
"23.11"
"24.05"
"25.11"
];
description = ''
It is occasionally necessary for Nix-on-Droid to change
Expand Down
36 changes: 22 additions & 14 deletions pkgs/android-integration/termux-am.nix
Original file line number Diff line number Diff line change
@@ -1,33 +1,41 @@
# Copyright (c) 2019-2024, see AUTHORS. Licensed under MIT License, see LICENSE.

{ stdenv, fetchFromGitHub, cmake }:
{ stdenv
, fetchFromGitHub
, cmake
,
}:

let
appPath = "/data/data/com.termux.nix/files/apps/com.termux.nix";
socketPath = "${appPath}/termux-am/am.sock";
in
stdenv.mkDerivation rec {
stdenv.mkDerivation (finalAttrs: {
name = "termux-am";
version = "1.5.0";

src = fetchFromGitHub {
owner = "termux";
repo = "termux-am-socket";
rev = version;
sha256 = "sha256-6pCv2HMBRp8Hi56b43mQqnaFaI7y5DfhS9gScANwg2I=";
tag = finalAttrs.version;
hash = "sha256-6pCv2HMBRp8Hi56b43mQqnaFaI7y5DfhS9gScANwg2I=";
};

nativeBuildInputs = [ cmake ];
patchPhase = ''
# Header generation doesn't seem to work on android

# Header generation doesn't seem to work on android
postPatch = ''
echo "#define SOCKET_PATH \"${socketPath}\"" > termux-am.h
# Fix the bash link so that nix can patch it + path to termux-am-socket
''
# Fix the bash link so that nix can patch it + path to termux-am-socket
+ ''
substituteInPlace termux-am.sh.in \
--replace @TERMUX_PREFIX@/bin/bash /bin/bash \
--replace \
"termux-am-socket \"\$am_command_string\"" \
"$out/bin/termux-am-socket \"\$am_command_string\""
--replace-fail "@TERMUX_PREFIX@/bin/bash" "/bin/bash" \
--replace-fail 'termux-am-socket "$am_command_string"' "$out/bin/termux-am-socket \"\$am_command_string\""
'';

# Scripts use 'am' as an alias.
postInstall = ''
# Scripts use 'am' as an alias.
ln -s $out/bin/termux-am $out/bin/am
ln --symbolic $out/bin/termux-am $out/bin/am
'';
}
})
51 changes: 26 additions & 25 deletions pkgs/android-integration/termux-tools.nix
Original file line number Diff line number Diff line change
@@ -1,53 +1,55 @@
# Copyright (c) 2019-2024, see AUTHORS. Licensed under MIT License, see LICENSE.

{ stdenvNoCC
{ stdenv
, fetchFromGitHub
, autoreconfHook
, makeWrapper
, gnused
, getopt
, termux-am
,
}:

stdenvNoCC.mkDerivation rec {
stdenv.mkDerivation (finalAttrs: {
name = "termux-tools";
version = "1.42.4";
version = "1.47.1";

src = fetchFromGitHub {
owner = "termux";
repo = "termux-tools";
rev = "v${version}";
sha256 = "sha256-LkkeaEQcY8HgunBYAg3Ymn5xYPvrGqGNCZTd/NyIOKY=";
tag = "v${finalAttrs.version}";
hash = "sha256-YfIxDegzIHyy62IlpSgrDz4fQiPoZNgSzXNtAk5lmn8=";
};
nativeBuildInputs = [ autoreconfHook makeWrapper ];

nativeBuildInputs = [
autoreconfHook
makeWrapper
];

propagatedInputs = [ termux-am ];

# https://github.com/termux/termux-tools/pull/95
patches = [ ./termux-tools.patch ];
postPatch = ''
substituteInPlace scripts/termux-setup-storage.in \
--replace @TERMUX_HOME@ /data/data/com.termux.nix/files/home/ \
--replace @TERMUX_APP_PACKAGE@ com.termux.nix
--replace-fail "@TERMUX_HOME@" "/data/data/com.termux.nix/files/home/" \
--replace-fail "@TERMUX_APP_PACKAGE@" "com.termux.nix"
substituteInPlace scripts/termux-open.in \
--replace 'getopt ' '${getopt}/bin/getopt '
--replace-fail "getopt " "${getopt}/bin/getopt "
substituteInPlace \
scripts/termux-open.in \
scripts/termux-wake-lock.in \
scripts/termux-wake-unlock.in \
--replace @[email protected] com.termux.app \
--replace @TERMUX_APP_PACKAGE@ com.termux.nix
--replace-fail "@[email protected]" "com.termux.app" \
--replace-fail "@TERMUX_APP_PACKAGE@" "com.termux.nix"
substituteInPlace scripts/termux-reload-settings.in \
--replace @TERMUX_APP_PACKAGE@ com.termux.nix
--replace-fail "@TERMUX_APP_PACKAGE@" "com.termux.nix"
${gnused}/bin/sed -i 's|^am |${termux-am}/bin/am |' scripts/*

rm -r doc # manpage is half misleading, pulling pandoc is not worth it
substituteInPlace Makefile.am --replace \
'SUBDIRS = . scripts doc mirrors motds' \
'SUBDIRS = . scripts'
substituteInPlace configure.ac --replace \
'AC_CONFIG_FILES([Makefile scripts/Makefile doc/Makefile' \
'AC_CONFIG_FILES([Makefile scripts/Makefile])'
substituteInPlace configure.ac --replace \
'mirrors/Makefile motds/Makefile])' ""
rm --recursive doc # manpage is half misleading, pulling pandoc is not worth it
substituteInPlace Makefile.am \
--replace-fail "SUBDIRS = . scripts doc mirrors motds src" "SUBDIRS = . scripts"
substituteInPlace configure.ac \
--replace-fail "AC_CONFIG_FILES([Makefile scripts/Makefile doc/Makefile" "AC_CONFIG_FILES([Makefile scripts/Makefile])" \
--replace-fail "mirrors/Makefile motds/Makefile src/Makefile])" ""
'';

outputs = [
Expand All @@ -67,7 +69,6 @@ stdenvNoCC.mkDerivation rec {
rm -d $out/etc

rm $out/bin/chsh # we offer a declarative way to change your shell
rm $out/bin/cmd # doesn't work because we overlay /system/bin
rm $out/bin/dalvikvm # doesn't work because we overlay /system/bin
rm $out/bin/df # works without the magic
rm $out/bin/getprop # doesn't work because we overlay /system/bin
Expand Down Expand Up @@ -121,4 +122,4 @@ stdenvNoCC.mkDerivation rec {
echo ./share/examples/termux/termux.properties >> expected # useful
diff -u expected effective
'';
}
})
Loading
Loading