-+ static char realpath_buffer[4096/*PATH_MAX*/];
-+ char* result = realpath("/data/data/com.termux/files/home/.termux/shell", realpath_buffer);
-+ if (result == NULL || access(realpath_buffer, /*X_OK*/1) == -1) {
-+ char const* bash_path = "/data/data/com.termux/files/usr/bin/bash";
-+ if (access(bash_path, /*X_OK*/1) != -1) pw->pw_shell = (char*) bash_path;
-+ else pw->pw_shell = "/data/data/com.termux/files/usr/bin/sh";
++ char const* result = "@TERMUX_PREFIX@/bin/login";
++ if (result == NULL || access(result, /*X_OK*/1) == -1) {
++ pw->pw_shell = "@TERMUX_PREFIX@/bin/bash";