The getuid() root checks produces undesired behavior if this function is used
instead of proper checks for file permissions whether the `/proc/stat` can be
accessed or not.
- If `htop` runs in fake root environments (proot/fakeroot), the getuid()
function would obviously return the root user id. as a result, it will use the
actual /proc/stat file and would fail in case the user does not have `/proc/stat` access.
- The getuid() checks is the unreliable way of checking the
permissions of `/proc/stat` file as suppose that it would always require root for
checking the readability of the process status file and use it.
using access() function should allow proper checks regardless of a logged user account.
This change would likely replace the postinst checks of /proc/stat file and include
the fake process status file in the deb package instead
There are some users have root access but they don't have read access
to /proc/stat if not into root context which in this case for SELinux
enforced devices and during the postinst step it will still check the
file unprivileged
Only engineering builds of Lineage OS allow free access to /proc/stat.
Remove the mention of "install Lineage OS" to avoid confusion since official
releases restrict /proc/stat access just like stock Android.
Variables
TERMUX_PKG_PLATFORM_INDEPENDENT
TERMUX_DEBUG
TERMUX_PKG_HAS_DEBUG
TERMUX_PKG_ESSENTIAL
TERMUX_SUBPKG_ESSENTIAL
TERMUX_PKG_NO_STATICSPLIT
TERMUX_PKG_BUILD_IN_SRC
TERMUX_PKG_FORCE_CMAKE
TERMUX_PKG_HOSTBUILD
should not accept arbitrary values for marking them "enabled". Instead
they should accept boolean values which makes them easier to handle and
also makes their meaning clear.
build-package.sh should make decision based on variable's value but not on
whether it is set or empty.
%ci:no-build