Skip to content

Releases: termux/termux-packages

Bootstrap archives for Termux application

14 Jul 00:16
Compare
Choose a tag to compare
bootstrap-2024.07.14-r1+apt-android-7

rebuild(main/command-not-found): to update database

Bootstrap archives for Termux application

09 Jul 08:34
63d01ed
Compare
Choose a tag to compare
fix(main/termux-keyring): fix force rebuild which failed due to creat…

…ing the key symlink at path which already existed from previous build as `ln -f` flag was not passed

This all removes any keys left over from previous versions that do not exist in newer version.

```
./build-package.sh termux-keyring
./build-package.sh -f termux-keyring
ln: failed to create symbolic link '/data/data/com.termux/files/usr/etc/apt/trusted.gpg.d/2096779623.gpg': File exists
```

Bootstrap archives for Termux application

07 Jul 00:15
Compare
Choose a tag to compare
bootstrap-2024.07.07-r1+apt-android-7

rebuild(main/command-not-found): to update database

Bootstrap archives for Termux application

30 Jun 00:14
Compare
Choose a tag to compare
bootstrap-2024.06.30-r1+apt-android-7

rebuild(main/command-not-found): to update database

Bootstrap archives for Termux application

23 Jun 00:14
Compare
Choose a tag to compare
bootstrap-2024.06.23-r1+apt-android-7

rebuild(main/command-not-found): to update database

Bootstrap archives for Termux application

17 Jun 19:02
7827140
Compare
Choose a tag to compare
scripts(bootstrap/termux-bootstrap-second-stage.sh): redesign and fix…

… termux bootstrap second stage as per package managers spec

- `apt`/`dpkg`:
  - `dpkg` allows any type of executable file like binaries or shell scripts as maintainer scripts instead of just a script to be run with `bash`, so we execute the file directly instead of passing to `bash`.
  - Set the execute permission for the file before execution, just like `dpkg`, as we are now executing directly instead of passing it to a shell.
  - Change current working directory to `/` before execution, that is consistent with behaviour of normal package installation with `dpkg`, even though it may cause problems.
  - Export the internal environment variables that `dpkg` exports while executing maintainer scripts.
  - Pass `configure` as the first argument to `postinst` script when executing it as per `dpkg` spec. This fixes bootstrap second stage for `apt`/`dpkg` Termux packages, like `nano`, which check if first argument is `configure` before running `postinst` logic. `nano` is currently the only package with a `postinst` script in the default bootstrap generated, and `postinst` logic wouldn't run for `apt` package manager and only for `pacman` before. The `termux-tools` package is the only package with a `preinst` script that deletes files for mirrors that were deleted/invalid, but that does not need to be executed for a working package configuration on a fresh install as only working mirror files would get extracted.
  Check https://github.com/termux/termux-packages/blob/903902eaa2ca20d7150096b36055c4bc09939e23/packages/nano/build.sh#L28 for `postinst` example.
- `pacman`:
  - Unset `post_install` function if already defined in the env before sourcing package `install` file.
  - Make a more strict check for `post_install` function existence.
  - Change current working directory to `/` before execution, that is consistent with behaviour of normal package installation with `pacman`, even though it may cause problems.
  - Pass the package version as the first argument to `post_install` function when executing it as per `pacman` spec.
- Global changes:
  - The `termux-bootstrap-second-stage.sh` file will now be installed under the `$TERMUX_BOOTSTRAP_CONFIG_DIR_PATH` directory at `$TERMUX__PREFIX/etc/termux/bootstrap` instead of as a `profile.d` script.
  - The Termux app will add support to run the `termux-bootstrap-second-stage.sh` file after it extracts the bootstrap before any shell starts, unlike previously where it was executed as a `profile.d` script by the `login` shell, whose run order could be after other `profile.d` scripts. The second stage will now only be allowed to run once based on the `termux-bootstrap-second-stage.sh.lock` file as a symlink in the same directory as `termux-bootstrap-second-stage.sh` file and only the first instance of `termux-bootstrap-second-stage.sh` which was able to create the symlink as an atomic operation would be allowed to run the second stage in the entire lifetime of the rootfs, check its help for more info.
  - The `profile.d` script support is still left as a fallback with the new `01-termux-bootstrap-second-stage-fallback.sh` script with a potentially higher run order due to `01-` prefix, which calls the `termux-bootstrap-second-stage.sh` file  if the `termux-bootstrap-second-stage.sh.lock` file  does not exist and deletes itself afterwards so that it is not sourced again. This will be removed in future when support has been added in the Termux app to officially install pacman bootstraps, which are currently been extracted from a shell instead of by the app, requiring the need for a `profile.d` script to run the second stage. Check the file comments for more info.
  - If any maintainer script fails, second stage will exit with failure as that implies that bootstrap setup has failed and rootfs shouldn't be used. The Termux app will also wipe prefix directory if that happens so that a broken prefix isn't used, so full bootstrap installation must be checked before any new app releases. The fallback bootstrap second stage will not wipe the prefix though as that may wipe other changes done to prefix and users should wipe manually if needed.

Bootstrap archives for Termux application

16 Jun 00:14
Compare
Choose a tag to compare
bootstrap-2024.06.16-r1+apt-android-7

rebuild(main/command-not-found): to update database

Bootstrap archives for Termux application

09 Jun 00:15
Compare
Choose a tag to compare
bootstrap-2024.06.09-r1+apt-android-7

rebuild(main/command-not-found): to update database

Bootstrap archives for Termux application

02 Jun 00:14
Compare
Choose a tag to compare
bootstrap-2024.06.02-r1+apt-android-7

rebuild(main/command-not-found): to update database

Bootstrap archives for Termux application

26 May 00:14
Compare
Choose a tag to compare
bootstrap-2024.05.26-r1+apt-android-7

rebuild(main/command-not-found): to update database