mirror of
https://github.com/termux-pacman/glibc-packages.git
synced 2025-03-16 09:40:59 +00:00
new packages to gpkg (#95)
gpkg/bash-completion gpkg/pam gpkg/util-linux gpkg/e2fsprogs gpkg/libevent gpkg/krb5 gpkg/libverto gpkg/libcurl gpkg/libarchive
This commit is contained in:
gpkg-disabled/libelf
build.shelfutils.subpackage.shlibasm-static.subpackage.shlibasm.subpackage.shlibdebuginfod.subpackage.shlibdw-static.subpackage.shlibdw.subpackage.sh
gpkg
bash-completion
e2fsprogs
krb5
libarchive
libbz2
libcap
libcurl
libevent
libpam
libverto
openssl
util-linux
17
gpkg-disabled/libelf/build.sh
Normal file
17
gpkg-disabled/libelf/build.sh
Normal file
@ -0,0 +1,17 @@
|
||||
TERMUX_PKG_HOMEPAGE=https://sourceware.org/elfutils/
|
||||
TERMUX_PKG_DESCRIPTION="ELF object file access library"
|
||||
TERMUX_PKG_LICENSE="GPL-2.0"
|
||||
TERMUX_PKG_MAINTAINER="@termux-pacman"
|
||||
TERMUX_PKG_VERSION=0.189
|
||||
TERMUX_PKG_SRCURL="https://sourceware.org/elfutils/ftp/${TERMUX_PKG_VERSION}/elfutils-${TERMUX_PKG_VERSION}.tar.bz2"
|
||||
TERMUX_PKG_SHA256=39bd8f1a338e2b7cd4abc3ff11a0eddc6e690f69578a57478d8179b4148708c8
|
||||
TERMUX_PKG_DEPENDS="zlib-glibc, zstd-glibc"
|
||||
TERMUX_PKG_BUILD_IN_SRC=true
|
||||
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
|
||||
--program-prefix="eu-"
|
||||
--enable-deterministic-archives
|
||||
"
|
||||
|
||||
termux_step_pre_configure() {
|
||||
autoreconf -ivf
|
||||
}
|
3
gpkg-disabled/libelf/elfutils.subpackage.sh
Normal file
3
gpkg-disabled/libelf/elfutils.subpackage.sh
Normal file
@ -0,0 +1,3 @@
|
||||
TERMUX_SUBPKG_DESCRIPTION="A collection of utilities to read, create and modify ELF binary files"
|
||||
TERMUX_SUBPKG_INCLUDE="glibc/bin/eu-* glibc/etc/profile.d/debuginfod.* glibc/share/man/man8/* glibc/share/man/man1/*"
|
||||
TERMUX_SUBPKG_DEPENDS="libarchive-glibc, libasm-glibc, libdebuginfod-glibc, libdw-glibc, libmicrohttpd, libsqlite"
|
3
gpkg-disabled/libelf/libasm-static.subpackage.sh
Normal file
3
gpkg-disabled/libelf/libasm-static.subpackage.sh
Normal file
@ -0,0 +1,3 @@
|
||||
TERMUX_SUBPKG_INCLUDE="glibc/lib/libasm.a"
|
||||
TERMUX_SUBPKG_DESCRIPTION="Static library to assemble and disassemble instructions"
|
||||
TERMUX_SUBPKG_DEPENDS="libasm-glibc"
|
3
gpkg-disabled/libelf/libasm.subpackage.sh
Normal file
3
gpkg-disabled/libelf/libasm.subpackage.sh
Normal file
@ -0,0 +1,3 @@
|
||||
TERMUX_SUBPKG_INCLUDE="glibc/lib/libasm*.so* glibc/include/elfutils/libasm.h"
|
||||
TERMUX_SUBPKG_DESCRIPTION="Library to assemble and disassemble instructions"
|
||||
TERMUX_SUBPKG_DEPENDS="libdw-glibc"
|
3
gpkg-disabled/libelf/libdebuginfod.subpackage.sh
Normal file
3
gpkg-disabled/libelf/libdebuginfod.subpackage.sh
Normal file
@ -0,0 +1,3 @@
|
||||
TERMUX_SUBPKG_DESCRIPTION="Library for debuginfod"
|
||||
TERMUX_SUBPKG_INCLUDE="glibc/lib/libdebuginfod*.so* glibc/include/elfutils/debuginfod.h glibc/lib/pkgconfig/libdebuginfod.pc glibc/share/man/man3/debuginfod_*"
|
||||
TERMUX_SUBPKG_DEPENDS="libcurl-glibc"
|
3
gpkg-disabled/libelf/libdw-static.subpackage.sh
Normal file
3
gpkg-disabled/libelf/libdw-static.subpackage.sh
Normal file
@ -0,0 +1,3 @@
|
||||
TERMUX_SUBPKG_INCLUDE="glibc/lib/libdw.a"
|
||||
TERMUX_SUBPKG_DESCRIPTION="Static library to read DWARF information"
|
||||
TERMUX_SUBPKG_DEPENDS="libdw-glibc"
|
3
gpkg-disabled/libelf/libdw.subpackage.sh
Normal file
3
gpkg-disabled/libelf/libdw.subpackage.sh
Normal file
@ -0,0 +1,3 @@
|
||||
TERMUX_SUBPKG_INCLUDE="glibc/lib/libdw*.so* glibc/lib/pkgconfig/libdw.pc glibc/include/elfutils/known-dwarf.h glibc/include/elfutils/libdwfl.h glibc/include/elfutils/libdw.h glibc/include/dwarf.h"
|
||||
TERMUX_SUBPKG_DESCRIPTION="Library to read DWARF information"
|
||||
TERMUX_SUBPKG_DEPENDS="libbz2-glibc, liblzma-glibc"
|
12
gpkg/bash-completion/build.sh
Normal file
12
gpkg/bash-completion/build.sh
Normal file
@ -0,0 +1,12 @@
|
||||
TERMUX_PKG_HOMEPAGE=https://github.com/scop/bash-completion
|
||||
TERMUX_PKG_DESCRIPTION="Programmable completion for the bash shell"
|
||||
TERMUX_PKG_LICENSE="GPL-2.0"
|
||||
TERMUX_PKG_MAINTAINER="@termux-pacman"
|
||||
TERMUX_PKG_VERSION=2.11
|
||||
TERMUX_PKG_SRCURL=https://github.com/scop/bash-completion/releases/download/${TERMUX_PKG_VERSION}/bash-completion-${TERMUX_PKG_VERSION}.tar.xz
|
||||
TERMUX_PKG_SHA256=73a8894bad94dee83ab468fa09f628daffd567e8bef1a24277f1e9a0daf911ac
|
||||
TERMUX_PKG_DEPENDS="bash-glibc"
|
||||
TERMUX_PKG_PLATFORM_INDEPENDENT=true
|
||||
TERMUX_PKG_RM_AFTER_INSTALL="
|
||||
share/bash-completion/completions/makepkg
|
||||
"
|
13
gpkg/bash-completion/completions-man.patch
Normal file
13
gpkg/bash-completion/completions-man.patch
Normal file
@ -0,0 +1,13 @@
|
||||
diff -uNr bash-completion-2.9/completions/man bash-completion-2.9.mod/completions/man
|
||||
--- bash-completion-2.9/completions/man 2019-04-27 11:54:49.000000000 +0300
|
||||
+++ bash-completion-2.9.mod/completions/man 2019-05-02 15:36:06.454990217 +0300
|
||||
@@ -51,8 +51,7 @@
|
||||
return
|
||||
fi
|
||||
|
||||
- local manpath=$(manpath 2>/dev/null || command man -w 2>/dev/null)
|
||||
- [[ -z $manpath ]] && manpath="/usr/share/man:/usr/local/share/man"
|
||||
+ local manpath="@TERMUX_PREFIX@/share/man"
|
||||
|
||||
# determine manual section to search
|
||||
local sect
|
31
gpkg/e2fsprogs/build.sh
Normal file
31
gpkg/e2fsprogs/build.sh
Normal file
@ -0,0 +1,31 @@
|
||||
TERMUX_PKG_HOMEPAGE=https://e2fsprogs.sourceforge.net
|
||||
TERMUX_PKG_DESCRIPTION="EXT 2/3/4 filesystem utilities"
|
||||
TERMUX_PKG_LICENSE="GPL-2.0, LGPL-2.0"
|
||||
TERMUX_PKG_LICENSE_FILE="NOTICE"
|
||||
TERMUX_PKG_MAINTAINER="@termux-pacman"
|
||||
TERMUX_PKG_VERSION=1.47.0
|
||||
TERMUX_PKG_SRCURL=https://www.kernel.org/pub/linux/kernel/people/tytso/e2fsprogs/v$TERMUX_PKG_VERSION/e2fsprogs-$TERMUX_PKG_VERSION.tar.xz
|
||||
TERMUX_PKG_SHA256=144af53f2bbd921cef6f8bea88bb9faddca865da3fbc657cc9b4d2001097d5db
|
||||
TERMUX_PKG_CONFFILES="glibc/etc/mke2fs.conf"
|
||||
TERMUX_PKG_NO_STATICSPLIT=true
|
||||
TERMUX_PKG_DEPENDS="libblkid-glibc, libuuid-glibc, bash-glibc"
|
||||
|
||||
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
|
||||
--sbindir=${TERMUX_PREFIX}/bin
|
||||
--with-crond_dir=${TERMUX_PREFIX}/etc/cron.d
|
||||
--enable-symlink-install
|
||||
--enable-symlink-build
|
||||
--enable-relative-symlinks
|
||||
--enable-elf-shlibs
|
||||
--disable-fsck
|
||||
--disable-uuidd
|
||||
--disable-libuuid
|
||||
--disable-libblkid
|
||||
"
|
||||
|
||||
termux_step_make_install() {
|
||||
make install install-libs
|
||||
install -Dm600 \
|
||||
"$TERMUX_PKG_SRCDIR"/misc/mke2fs.conf.in \
|
||||
"$TERMUX_PREFIX"/etc/mke2fs.conf
|
||||
}
|
347
gpkg/e2fsprogs/setdirs.patch
Normal file
347
gpkg/e2fsprogs/setdirs.patch
Normal file
@ -0,0 +1,347 @@
|
||||
diff --git a/debugfs/debugfs.c b/debugfs/debugfs.c
|
||||
index 9b6321d..7e029cc 100644
|
||||
--- a/debugfs/debugfs.c
|
||||
+++ b/debugfs/debugfs.c
|
||||
@@ -93,7 +93,7 @@ static int debugfs_setup_tdb(const char *device_name, char *undo_file,
|
||||
*/
|
||||
tdb_dir = ss_safe_getenv("E2FSPROGS_UNDO_DIR");
|
||||
if (!tdb_dir)
|
||||
- tdb_dir = "/var/lib/e2fsprogs";
|
||||
+ tdb_dir = "@TERMUX_PREFIX@/var/lib/e2fsprogs";
|
||||
|
||||
if (!strcmp(tdb_dir, "none") || (tdb_dir[0] == 0) ||
|
||||
access(tdb_dir, W_OK))
|
||||
diff --git a/debugfs/util.c b/debugfs/util.c
|
||||
index 9e88054..9c94244 100644
|
||||
--- a/debugfs/util.c
|
||||
+++ b/debugfs/util.c
|
||||
@@ -61,7 +61,7 @@ void reset_getopt(void)
|
||||
}
|
||||
|
||||
static const char *pager_search_list[] = { "pager", "more", "less", 0 };
|
||||
-static const char *pager_dir_list[] = { "/usr/bin", "/bin", 0 };
|
||||
+static const char *pager_dir_list[] = { "@TERMUX_PREFIX@/bin", 0 };
|
||||
|
||||
static const char *find_pager(char *buf)
|
||||
{
|
||||
diff --git a/e2fsck/e2fsck.h b/e2fsck/e2fsck.h
|
||||
index 3f2dc30..db43347 100644
|
||||
--- a/e2fsck/e2fsck.h
|
||||
+++ b/e2fsck/e2fsck.h
|
||||
@@ -53,7 +53,7 @@
|
||||
#define NLS_CAT_NAME "e2fsprogs"
|
||||
#endif
|
||||
#ifndef LOCALEDIR
|
||||
-#define LOCALEDIR "/usr/share/locale"
|
||||
+#define LOCALEDIR "@TERMUX_PREFIX@/share/locale"
|
||||
#endif
|
||||
#else
|
||||
#define _(a) (a)
|
||||
diff --git a/e2fsck/unix.c b/e2fsck/unix.c
|
||||
index e5b672a..a3cdbf5 100644
|
||||
--- a/e2fsck/unix.c
|
||||
+++ b/e2fsck/unix.c
|
||||
@@ -1333,7 +1333,7 @@ static int e2fsck_setup_tdb(e2fsck_t ctx, io_manager *io_ptr)
|
||||
tdb_dir = getenv("E2FSPROGS_UNDO_DIR");
|
||||
if (!tdb_dir) {
|
||||
profile_get_string(ctx->profile, "defaults",
|
||||
- "undo_dir", 0, "/var/lib/e2fsprogs",
|
||||
+ "undo_dir", 0, "@TERMUX_PREFIX@/var/lib/e2fsprogs",
|
||||
&tdb_dir);
|
||||
free_tdb_dir = 1;
|
||||
}
|
||||
diff --git a/ext2ed/init.c b/ext2ed/init.c
|
||||
index 4e58431..4d37d71 100644
|
||||
--- a/ext2ed/init.c
|
||||
+++ b/ext2ed/init.c
|
||||
@@ -613,8 +613,8 @@ void check_mounted (char *name)
|
||||
|
||||
mounted=0;
|
||||
|
||||
- if ( (fp=fopen ("/etc/mtab","rt"))==NULL) {
|
||||
- wprintw (command_win,"Error - Failed to open /etc/mtab. Assuming filesystem is mounted.\n");
|
||||
+ if ( (fp=fopen ("@TERMUX_PREFIX@/etc/mtab","rt"))==NULL) {
|
||||
+ wprintw (command_win,"Error - Failed to open @TERMUX_PREFIX@/etc/mtab. Assuming filesystem is mounted.\n");
|
||||
refresh_command_win ();mounted=1;return;
|
||||
};
|
||||
|
||||
diff --git a/lib/ext2fs/ismounted.c b/lib/ext2fs/ismounted.c
|
||||
index a7db1a5..f217788 100644
|
||||
--- a/lib/ext2fs/ismounted.c
|
||||
+++ b/lib/ext2fs/ismounted.c
|
||||
@@ -231,7 +231,7 @@ static errcode_t check_mntent(const char *file, int *mount_flags,
|
||||
errcode_t retval;
|
||||
|
||||
#ifdef DEBUG
|
||||
- retval = check_mntent_file("/tmp/mtab", file, mount_flags,
|
||||
+ retval = check_mntent_file("@TERMUX_PREFIX_CLASSICAL@/tmp/mtab", file, mount_flags,
|
||||
mtpt, mtlen);
|
||||
if (retval == 0)
|
||||
return 0;
|
||||
diff --git a/lib/ss/invocation.c b/lib/ss/invocation.c
|
||||
index 7d7458a..cd07b74 100644
|
||||
--- a/lib/ss/invocation.c
|
||||
+++ b/lib/ss/invocation.c
|
||||
@@ -74,7 +74,7 @@ int ss_create_invocation(const char *subsystem_name, const char *version_string,
|
||||
strcpy(new_table->prompt, subsystem_name);
|
||||
strcat(new_table->prompt, ": ");
|
||||
#ifdef silly
|
||||
- new_table->abbrev_info = ss_abbrev_initialize("/etc/passwd", code_ptr);
|
||||
+ new_table->abbrev_info = ss_abbrev_initialize("/system/etc/passwd", code_ptr);
|
||||
#else
|
||||
new_table->abbrev_info = NULL;
|
||||
#endif
|
||||
diff --git a/lib/support/nls-enable.h b/lib/support/nls-enable.h
|
||||
index 2f62c01..af3c2c0 100644
|
||||
--- a/lib/support/nls-enable.h
|
||||
+++ b/lib/support/nls-enable.h
|
||||
@@ -12,7 +12,7 @@
|
||||
#define NLS_CAT_NAME "e2fsprogs"
|
||||
#endif
|
||||
#ifndef LOCALEDIR
|
||||
-#define LOCALEDIR "/usr/share/locale"
|
||||
+#define LOCALEDIR "@TERMUX_PREFIX@/share/locale"
|
||||
#endif
|
||||
#else
|
||||
#define _(a) (a)
|
||||
diff --git a/lib/uuid/gen_uuid.c b/lib/uuid/gen_uuid.c
|
||||
index 2f02886..ddbdc56 100644
|
||||
--- a/lib/uuid/gen_uuid.c
|
||||
+++ b/lib/uuid/gen_uuid.c
|
||||
@@ -313,7 +313,7 @@ static int get_clock(uint32_t *clock_high, uint32_t *clock_low,
|
||||
|
||||
if (state_fd == -2) {
|
||||
save_umask = umask(0);
|
||||
- state_fd = open("/var/lib/libuuid/clock.txt",
|
||||
+ state_fd = open("@TERMUX_PREFIX@/var/lib/libuuid/clock.txt",
|
||||
O_RDWR|O_CREAT, 0660);
|
||||
(void) umask(save_umask);
|
||||
if (state_fd >= 0) {
|
||||
diff --git a/lib/uuid/uuidd.h b/lib/uuid/uuidd.h
|
||||
index c71f4b7..cc43afb 100644
|
||||
--- a/lib/uuid/uuidd.h
|
||||
+++ b/lib/uuid/uuidd.h
|
||||
@@ -35,10 +35,10 @@
|
||||
#ifndef _UUID_UUIDD_H
|
||||
#define _UUID_UUIDD_H
|
||||
|
||||
-#define UUIDD_DIR "/var/lib/libuuid"
|
||||
+#define UUIDD_DIR "@TERMUX_PREFIX@/var/lib/libuuid"
|
||||
#define UUIDD_SOCKET_PATH UUIDD_DIR "/request"
|
||||
#define UUIDD_PIDFILE_PATH UUIDD_DIR "/uuidd.pid"
|
||||
-#define UUIDD_PATH "/usr/sbin/uuidd"
|
||||
+#define UUIDD_PATH "@TERMUX_PREFIX@/bin/uuidd"
|
||||
|
||||
#define UUIDD_OP_GETPID 0
|
||||
#define UUIDD_OP_GET_MAXOP 1
|
||||
diff --git a/misc/badblocks.c b/misc/badblocks.c
|
||||
index 2b5ff6d..b85e3c0 100644
|
||||
--- a/misc/badblocks.c
|
||||
+++ b/misc/badblocks.c
|
||||
@@ -1006,7 +1006,7 @@ static void check_mount(char *device_name)
|
||||
fprintf(stderr, _("%s is mounted; "), device_name);
|
||||
if (force) {
|
||||
fputs(_("badblocks forced anyway. "
|
||||
- "Hope /etc/mtab is incorrect.\n"), stderr);
|
||||
+ "Hope @TERMUX_PREFIX@/etc/mtab is incorrect.\n"), stderr);
|
||||
return;
|
||||
}
|
||||
abort_badblocks:
|
||||
diff --git a/misc/e2initrd_helper.c b/misc/e2initrd_helper.c
|
||||
index b39fe15..7ac8beb 100644
|
||||
--- a/misc/e2initrd_helper.c
|
||||
+++ b/misc/e2initrd_helper.c
|
||||
@@ -342,9 +342,9 @@ static void get_root_type(ext2_filsys fs)
|
||||
struct fs_info fs_info;
|
||||
int ret;
|
||||
|
||||
- retval = get_file(fs, "/etc/fstab", &file);
|
||||
+ retval = get_file(fs, "@TERMUX_PREFIX@/etc/fstab", &file);
|
||||
if (retval) {
|
||||
- com_err(program_name, retval, "couldn't open /etc/fstab");
|
||||
+ com_err(program_name, retval, "couldn't open @TERMUX_PREFIX@/etc/fstab");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
diff --git a/misc/e2undo.c b/misc/e2undo.c
|
||||
index bc78fb2..b9100f7 100644
|
||||
--- a/misc/e2undo.c
|
||||
+++ b/misc/e2undo.c
|
||||
@@ -250,7 +250,7 @@ static int e2undo_setup_tdb(const char *name, io_manager *io_ptr)
|
||||
*/
|
||||
tdb_dir = getenv("E2FSPROGS_UNDO_DIR");
|
||||
if (!tdb_dir)
|
||||
- tdb_dir = "/var/lib/e2fsprogs";
|
||||
+ tdb_dir = "@TERMUX_PREFIX@/var/lib/e2fsprogs";
|
||||
|
||||
if (!strcmp(tdb_dir, "none") || (tdb_dir[0] == 0) ||
|
||||
access(tdb_dir, W_OK))
|
||||
diff --git a/misc/e4crypt.c b/misc/e4crypt.c
|
||||
index 67d25d8..8b83dda 100644
|
||||
--- a/misc/e4crypt.c
|
||||
+++ b/misc/e4crypt.c
|
||||
@@ -614,7 +614,7 @@ static void insert_key_into_keyring(const char *keyring, struct salt *salt)
|
||||
|
||||
static void get_default_salts(void)
|
||||
{
|
||||
- FILE *f = setmntent("/etc/mtab", "r");
|
||||
+ FILE *f = setmntent("@TERMUX_PREFIX@/etc/mtab", "r");
|
||||
struct mntent *mnt;
|
||||
|
||||
while (f && ((mnt = getmntent(f)) != NULL)) {
|
||||
diff --git a/misc/e4defrag.c b/misc/e4defrag.c
|
||||
index e3011d7..cfc12e1 100644
|
||||
--- a/misc/e4defrag.c
|
||||
+++ b/misc/e4defrag.c
|
||||
@@ -219,7 +219,7 @@ static int get_mount_point(const char *devname, char *mount_point,
|
||||
|
||||
fp = setmntent(mtab, "r");
|
||||
if (fp == NULL) {
|
||||
- perror("Couldn't access /etc/mtab");
|
||||
+ perror("Couldn't access @TERMUX_PREFIX@/etc/mtab");
|
||||
return -1;
|
||||
}
|
||||
|
||||
@@ -286,7 +286,7 @@ static int is_ext4(const char *file, char devname[PATH_MAX + 1])
|
||||
|
||||
fp = setmntent(mtab, "r");
|
||||
if (fp == NULL) {
|
||||
- perror("Couldn't access /etc/mtab");
|
||||
+ perror("Couldn't access @TERMUX_PREFIX@/etc/mtab");
|
||||
return -1;
|
||||
}
|
||||
|
||||
diff --git a/misc/fsck.c b/misc/fsck.c
|
||||
index 1769a10..4fd9240 100644
|
||||
--- a/misc/fsck.c
|
||||
+++ b/misc/fsck.c
|
||||
@@ -65,7 +65,7 @@
|
||||
#include "blkid/blkid.h"
|
||||
|
||||
#ifndef _PATH_MNTTAB
|
||||
-#define _PATH_MNTTAB "/etc/fstab"
|
||||
+#define _PATH_MNTTAB "@TERMUX_PREFIX@/etc/fstab"
|
||||
#endif
|
||||
|
||||
static const char *ignored_types[] = {
|
||||
@@ -121,7 +121,7 @@ static char *progname;
|
||||
static char *fstype = NULL;
|
||||
static struct fs_info *filesys_info = NULL, *filesys_last = NULL;
|
||||
static struct fsck_instance *instance_list;
|
||||
-static const char *fsck_prefix_path = "/sbin:/sbin/fs.d:/sbin/fs:/etc/fs:/etc";
|
||||
+static const char *fsck_prefix_path = "@TERMUX_PREFIX@/bin:@TERMUX_PREFIX@/bin/fs.d:@TERMUX_PREFIX@/bin/fs:@TERMUX_PREFIX@/etc/fs:@TERMUX_PREFIX@/etc";
|
||||
static char *fsck_path = 0;
|
||||
static blkid_cache cache = NULL;
|
||||
|
||||
@@ -368,9 +368,9 @@ static void load_fs_info(const char *filename)
|
||||
if (old_fstab && filesys_info) {
|
||||
fputs("\007\007\007", stderr);
|
||||
fputs(_(
|
||||
- "WARNING: Your /etc/fstab does not contain the fsck passno\n"
|
||||
+ "WARNING: Your @TERMUX_PREFIX@/etc/fstab does not contain the fsck passno\n"
|
||||
" field. I will kludge around things for you, but you\n"
|
||||
- " should fix your /etc/fstab file as soon as you can.\n\n"), stderr);
|
||||
+ " should fix your @TERMUX_PREFIX@/etc/fstab file as soon as you can.\n\n"), stderr);
|
||||
|
||||
for (fs = filesys_info; fs; fs = fs->next) {
|
||||
fs->passno = 1;
|
||||
@@ -891,7 +891,7 @@ static int ignore(struct fs_info *fs)
|
||||
*/
|
||||
if (opt_in_list("bind", fs->opts)) {
|
||||
fprintf(stderr,
|
||||
- _("%s: skipping bad line in /etc/fstab: bind mount with nonzero fsck pass number\n"),
|
||||
+ _("%s: skipping bad line in @TERMUX_PREFIX@/etc/fstab: bind mount with nonzero fsck pass number\n"),
|
||||
fs->mountpt);
|
||||
return 1;
|
||||
}
|
||||
diff --git a/misc/fuse2fs.c b/misc/fuse2fs.c
|
||||
index 0dc77ea..974a9b4 100644
|
||||
--- a/misc/fuse2fs.c
|
||||
+++ b/misc/fuse2fs.c
|
||||
@@ -52,7 +52,7 @@
|
||||
#define NLS_CAT_NAME "e2fsprogs"
|
||||
#endif
|
||||
#ifndef LOCALEDIR
|
||||
-#define LOCALEDIR "/usr/share/locale"
|
||||
+#define LOCALEDIR "@TERMUX_PREFIX@/share/locale"
|
||||
#endif
|
||||
#else
|
||||
#define _(a) (a)
|
||||
diff --git a/misc/ismounted.c b/misc/ismounted.c
|
||||
index 6aa0e04..e0b3cc7 100644
|
||||
--- a/misc/ismounted.c
|
||||
+++ b/misc/ismounted.c
|
||||
@@ -197,7 +197,7 @@ int is_mounted(const char *file)
|
||||
if (mount_flags)
|
||||
return 1;
|
||||
#endif /* __linux__ */
|
||||
- retval = check_mntent_file("/etc/mtab", file, &mount_flags);
|
||||
+ retval = check_mntent_file("@TERMUX_PREFIX@/etc/mtab", file, &mount_flags);
|
||||
if (retval)
|
||||
return 0;
|
||||
return (mount_flags);
|
||||
diff --git a/misc/mke2fs.c b/misc/mke2fs.c
|
||||
index 4a9c1b0..d9a87bc 100644
|
||||
--- a/misc/mke2fs.c
|
||||
+++ b/misc/mke2fs.c
|
||||
@@ -2812,7 +2812,7 @@ static int mke2fs_setup_tdb(const char *name, io_manager *io_ptr)
|
||||
tdb_dir = getenv("E2FSPROGS_UNDO_DIR");
|
||||
if (!tdb_dir) {
|
||||
profile_get_string(profile, "defaults",
|
||||
- "undo_dir", 0, "/var/lib/e2fsprogs",
|
||||
+ "undo_dir", 0, "@TERMUX_PREFIX@/var/lib/e2fsprogs",
|
||||
&tdb_dir);
|
||||
free_tdb_dir = 1;
|
||||
}
|
||||
diff --git a/misc/tune2fs.c b/misc/tune2fs.c
|
||||
index 458f7cf..c601b49 100644
|
||||
--- a/misc/tune2fs.c
|
||||
+++ b/misc/tune2fs.c
|
||||
@@ -2964,7 +2964,7 @@ static int tune2fs_setup_tdb(const char *name, io_manager *io_ptr)
|
||||
*/
|
||||
tdb_dir = getenv("E2FSPROGS_UNDO_DIR");
|
||||
if (!tdb_dir)
|
||||
- tdb_dir = "/var/lib/e2fsprogs";
|
||||
+ tdb_dir = "@TERMUX_PREFIX@/var/lib/e2fsprogs";
|
||||
|
||||
if (!strcmp(tdb_dir, "none") || (tdb_dir[0] == 0) ||
|
||||
access(tdb_dir, W_OK))
|
||||
diff --git a/misc/util.c b/misc/util.c
|
||||
index 3e83169..0f365a5 100644
|
||||
--- a/misc/util.c
|
||||
+++ b/misc/util.c
|
||||
@@ -139,7 +139,7 @@ void check_mount(const char *device, int force, const char *type)
|
||||
if (mount_flags & EXT2_MF_MOUNTED) {
|
||||
fprintf(stderr, _("%s is mounted; "), device);
|
||||
if (force >= 2) {
|
||||
- fputs(_("mke2fs forced anyway. Hope /etc/mtab is "
|
||||
+ fputs(_("mke2fs forced anyway. Hope @TERMUX_PREFIX@/etc/mtab is "
|
||||
"incorrect.\n"), stderr);
|
||||
return;
|
||||
}
|
||||
diff --git a/resize/main.c b/resize/main.c
|
||||
index 94f5ec6..f784596 100644
|
||||
--- a/resize/main.c
|
||||
+++ b/resize/main.c
|
||||
@@ -198,7 +198,7 @@ static int resize2fs_setup_tdb(const char *device, char *undo_file,
|
||||
*/
|
||||
tdb_dir = getenv("E2FSPROGS_UNDO_DIR");
|
||||
if (!tdb_dir)
|
||||
- tdb_dir = "/var/lib/e2fsprogs";
|
||||
+ tdb_dir = "@TERMUX_PREFIX@/var/lib/e2fsprogs";
|
||||
|
||||
if (!strcmp(tdb_dir, "none") || (tdb_dir[0] == 0) ||
|
||||
access(tdb_dir, W_OK))
|
||||
diff --git a/resize/resize2fs.h b/resize/resize2fs.h
|
||||
index 96a878a..05348de 100644
|
||||
--- a/resize/resize2fs.h
|
||||
+++ b/resize/resize2fs.h
|
||||
@@ -51,7 +51,7 @@
|
||||
#define NLS_CAT_NAME "e2fsprogs"
|
||||
#endif
|
||||
#ifndef LOCALEDIR
|
||||
-#define LOCALEDIR "/usr/share/locale"
|
||||
+#define LOCALEDIR "@TERMUX_PREFIX@/share/locale"
|
||||
#endif
|
||||
#else
|
||||
#define _(a) (a)
|
48
gpkg/krb5/build.sh
Normal file
48
gpkg/krb5/build.sh
Normal file
@ -0,0 +1,48 @@
|
||||
TERMUX_PKG_HOMEPAGE=https://web.mit.edu/kerberos
|
||||
TERMUX_PKG_DESCRIPTION="The Kerberos network authentication system"
|
||||
TERMUX_PKG_LICENSE="custom"
|
||||
TERMUX_PKG_LICENSE_FILE="../NOTICE"
|
||||
TERMUX_PKG_MAINTAINER="@termux-pacman"
|
||||
TERMUX_PKG_VERSION=1.21
|
||||
TERMUX_PKG_SRCURL=https://web.mit.edu/kerberos/dist/krb5/${TERMUX_PKG_VERSION}/krb5-$TERMUX_PKG_VERSION.tar.gz
|
||||
TERMUX_PKG_SHA256=69f8aaff85484832df67a4bbacd99b9259bd95aab8c651fbbe65cdc9620ea93b
|
||||
TERMUX_PKG_DEPENDS="e2fsprogs-glibc, libverto-glibc"
|
||||
TERMUX_PKG_CONFFILES="glibc/etc/krb5.conf glibc/var/krb5kdc/kdc.conf"
|
||||
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
|
||||
--disable-static
|
||||
--sbindir=$TERMUX_PREFIX/bin
|
||||
--enable-shared
|
||||
--with-system-et
|
||||
--with-system-ss
|
||||
--without-tcl
|
||||
--without-ldap
|
||||
--enable-dns-for-realm
|
||||
--with-system-verto
|
||||
DEFCCNAME=$TERMUX_PREFIX/tmp/krb5cc_%{uid}
|
||||
DEFKTNAME=$TERMUX_PREFIX/etc/krb5.keytab
|
||||
DEFCKTNAME=$TERMUX_PREFIX/var/krb5/user/%{euid}/client.keytab
|
||||
"
|
||||
#--with-ldap
|
||||
|
||||
termux_step_post_get_source() {
|
||||
TERMUX_PKG_SRCDIR+="/src"
|
||||
}
|
||||
|
||||
termux_step_pre_configure() {
|
||||
export PATH="$PATH:$TERMUX_PREFIX/bin"
|
||||
}
|
||||
|
||||
termux_step_post_make_install() {
|
||||
# Enable logging to STDERR by default
|
||||
echo -e "\tdefault = STDERR" >> $TERMUX_PKG_SRCDIR/config-files/krb5.conf
|
||||
|
||||
# Sample KDC config file
|
||||
install -dm 700 $TERMUX_PREFIX/var/krb5kdc
|
||||
install -pm 600 $TERMUX_PKG_SRCDIR/config-files/kdc.conf $TERMUX_PREFIX/var/krb5kdc/kdc.conf
|
||||
|
||||
# Default configuration file
|
||||
install -pm 600 $TERMUX_PKG_SRCDIR/config-files/krb5.conf $TERMUX_PREFIX/etc/krb5.conf
|
||||
|
||||
install -dm 700 $TERMUX_PREFIX/share/aclocal
|
||||
install -m 600 $TERMUX_PKG_SRCDIR/util/ac_check_krb5.m4 $TERMUX_PREFIX/share/aclocal
|
||||
}
|
24
gpkg/krb5/config-files-kdc.conf.patch
Normal file
24
gpkg/krb5/config-files-kdc.conf.patch
Normal file
@ -0,0 +1,24 @@
|
||||
--- ./config-files/kdc.conf 2017-03-03 03:36:02.000000000 +0530
|
||||
+++ ../kdc.conf 2017-04-02 20:29:55.296108766 +0530
|
||||
@@ -1,14 +1,14 @@
|
||||
[kdcdefaults]
|
||||
- kdc_listen = 88
|
||||
- kdc_tcp_listen = 88
|
||||
+ kdc_listen = 1088
|
||||
+ kdc_tcp_listen = 1088
|
||||
|
||||
[realms]
|
||||
ATHENA.MIT.EDU = {
|
||||
- database_name = /usr/local/var/krb5kdc/principal
|
||||
- acl_file = /usr/local/var/krb5kdc/kadm5.acl
|
||||
- key_stash_file = /usr/local/var/krb5kdc/.k5.ATHENA.MIT.EDU
|
||||
- kdc_listen = 88
|
||||
- kdc_tcp_listen = 88
|
||||
+ database_name = @TERMUX_PREFIX@/var/krb5kdc/principal
|
||||
+ acl_file = @TERMUX_PREFIX@/var/krb5kdc/kadm5.acl
|
||||
+ key_stash_file = @TERMUX_PREFIX@/var/krb5kdc/.k5.ATHENA.MIT.EDU
|
||||
+ kdc_listen = 1088
|
||||
+ kdc_tcp_listen = 1088
|
||||
max_life = 10h 0m 0s
|
||||
max_renewable_life = 7d 0h 0m 0s
|
||||
}
|
12
gpkg/libarchive/archive_util.c.patch
Normal file
12
gpkg/libarchive/archive_util.c.patch
Normal file
@ -0,0 +1,12 @@
|
||||
diff -uNr libarchive-3.3.3/libarchive/archive_util.c libarchive-3.3.3.mod/libarchive/archive_util.c
|
||||
--- libarchive-3.3.3/libarchive/archive_util.c 2018-09-02 09:05:18.000000000 +0300
|
||||
+++ libarchive-3.3.3.mod/libarchive/archive_util.c 2019-03-02 02:14:39.252942170 +0200
|
||||
@@ -374,7 +374,7 @@
|
||||
#ifdef _PATH_TMP
|
||||
tmp = _PATH_TMP;
|
||||
#else
|
||||
- tmp = "/tmp";
|
||||
+ tmp = "@TERMUX_PREFIX@/tmp";
|
||||
#endif
|
||||
archive_strcpy(temppath, tmp);
|
||||
if (temppath->s[temppath->length-1] != '/')
|
2
gpkg/libarchive/bsdtar.subpackage.sh
Normal file
2
gpkg/libarchive/bsdtar.subpackage.sh
Normal file
@ -0,0 +1,2 @@
|
||||
TERMUX_SUBPKG_INCLUDE="glibc/bin/ glibc/share/man/man1/"
|
||||
TERMUX_SUBPKG_DESCRIPTION="The tar(1) and cpio(1) programs from FreeBSD, using libarchive"
|
19
gpkg/libarchive/build.sh
Normal file
19
gpkg/libarchive/build.sh
Normal file
@ -0,0 +1,19 @@
|
||||
TERMUX_PKG_HOMEPAGE=https://www.libarchive.org/
|
||||
TERMUX_PKG_DESCRIPTION="Multi-format archive and compression library"
|
||||
TERMUX_PKG_LICENSE="BSD 2-Clause"
|
||||
TERMUX_PKG_MAINTAINER="@termux-pacman"
|
||||
TERMUX_PKG_VERSION="3.7.1"
|
||||
TERMUX_PKG_SRCURL=https://github.com/libarchive/libarchive/releases/download/v$TERMUX_PKG_VERSION/libarchive-$TERMUX_PKG_VERSION.tar.gz
|
||||
TERMUX_PKG_SHA256=5d24e40819768f74daf846b99837fc53a3a9dcdf3ce1c2003fe0596db850f0f0
|
||||
TERMUX_PKG_DEPENDS="libacl-glibc, libbz2-glibc, libexpat-glibc, liblz4-glibc, openssl-glibc, liblzma-glibc, zlib-glibc, zstd-glibc"
|
||||
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
|
||||
--without-xml2
|
||||
--without-nettle
|
||||
--disable-static
|
||||
"
|
||||
|
||||
termux_step_post_make_install() {
|
||||
# https://github.com/libarchive/libarchive/issues/1766
|
||||
sed -i '/^Requires\.private:/s/ iconv//' \
|
||||
$TERMUX_PREFIX/lib/pkgconfig/libarchive.pc
|
||||
}
|
@ -3,7 +3,7 @@ TERMUX_PKG_DESCRIPTION="BZ2 format compression library"
|
||||
TERMUX_PKG_LICENSE="BSD"
|
||||
TERMUX_PKG_MAINTAINER="@termux-pacman"
|
||||
TERMUX_PKG_VERSION=1.0.8
|
||||
TERMUX_PKG_REVISION=1
|
||||
TERMUX_PKG_REVISION=2
|
||||
TERMUX_PKG_SRCURL=https://fossies.org/linux/misc/bzip2-${TERMUX_PKG_VERSION}.tar.xz
|
||||
TERMUX_PKG_SHA256=47fd74b2ff83effad0ddf62074e6fad1f6b4a77a96e121ab421c20a216371a1f
|
||||
TERMUX_PKG_DEPENDS="glibc, bash-glibc"
|
||||
@ -41,5 +41,6 @@ termux_step_make_install() {
|
||||
ln -sf bzip2.1 $TERMUX_PREFIX/share/man/man1/bzcat.1
|
||||
ln -sf bzip2.1 $TERMUX_PREFIX/share/man/man1/bzip2recover.1
|
||||
|
||||
install -Dm644 ${TERMUX_PKG_BUILDER_DIR}/bzip2.pc -t $TERMUX_PREFIX/lib/pkgconfig
|
||||
sed -e "s|@TERMUX_PREFIX@|$TERMUX_PREFIX|g" \
|
||||
${TERMUX_PKG_BUILDER_DIR}/bzip2.pc > $TERMUX_PREFIX/lib/pkgconfig/bzip2.pc
|
||||
}
|
||||
|
@ -1,5 +1,5 @@
|
||||
prefix=/usr
|
||||
exec_prefix=/usr
|
||||
prefix=@TERMUX_PREFIX@
|
||||
exec_prefix=@TERMUX_PREFIX@
|
||||
bindir=${exec_prefix}/bin
|
||||
libdir=${exec_prefix}/lib
|
||||
includedir=${prefix}/include
|
||||
|
@ -4,17 +4,16 @@ TERMUX_PKG_LICENSE="BSD 3-Clause, GPL-2.0"
|
||||
TERMUX_PKG_LICENSE_FILE="License"
|
||||
TERMUX_PKG_MAINTAINER="@termux-pacman"
|
||||
TERMUX_PKG_VERSION=2.69
|
||||
TERMUX_PKG_REVISION=1
|
||||
TERMUX_PKG_SRCURL=https://kernel.org/pub/linux/libs/security/linux-privs/libcap2/libcap-${TERMUX_PKG_VERSION}.tar.xz
|
||||
TERMUX_PKG_SHA256=f311f8f3dad84699d0566d1d6f7ec943a9298b28f714cae3c931dfd57492d7eb
|
||||
TERMUX_PKG_DEPENDS="glibc, gcc-glibc-libs-dev"
|
||||
TERMUX_PKG_DEPENDS="libpam-glibc"
|
||||
TERMUX_PKG_BUILD_IN_SRC=true
|
||||
|
||||
termux_step_make() {
|
||||
# At the moment we don't have pam-glibc
|
||||
make CC="$CC" PREFIX="$TERMUX_PREFIX" PAM_CAP=no
|
||||
make CC="$CC" PREFIX="$TERMUX_PREFIX"
|
||||
}
|
||||
|
||||
termux_step_make_install() {
|
||||
# At the moment we don't have pam-glibc
|
||||
make CC="$CC" prefix="$TERMUX_PREFIX" RAISE_SETFCAP=no lib=/lib install PAM_CAP=no
|
||||
make CC="$CC" prefix="$TERMUX_PREFIX" RAISE_SETFCAP=no lib=/lib install
|
||||
}
|
||||
|
28
gpkg/libcurl/build.sh
Normal file
28
gpkg/libcurl/build.sh
Normal file
@ -0,0 +1,28 @@
|
||||
TERMUX_PKG_HOMEPAGE=https://curl.se/
|
||||
TERMUX_PKG_DESCRIPTION="Easy-to-use client-side URL transfer library"
|
||||
TERMUX_PKG_LICENSE="MIT"
|
||||
TERMUX_PKG_MAINTAINER="@termux-pacman"
|
||||
TERMUX_PKG_VERSION="8.2.1"
|
||||
TERMUX_PKG_SRCURL=https://github.com/curl/curl/releases/download/curl-${TERMUX_PKG_VERSION//./_}/curl-${TERMUX_PKG_VERSION}.tar.xz
|
||||
TERMUX_PKG_SHA256=dd322f6bd0a20e6cebdfd388f69e98c3d183bed792cf4713c8a7ef498cba4894
|
||||
TERMUX_PKG_DEPENDS="libnghttp2-glibc, libssh2-glibc, openssl-glibc (>= 3.0.3), krb5-glibc, brotli-glibc"
|
||||
TERMUX_PKG_ESSENTIAL=true
|
||||
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
|
||||
--with-ca-bundle=$TERMUX_PREFIX/etc/ssl/certs/ca-certificates.crt
|
||||
--with-ca-path=$TERMUX_PREFIX/etc/ssl/certs
|
||||
--disable-ldap
|
||||
--disable-ldaps
|
||||
--disable-manual
|
||||
--enable-ipv6
|
||||
--enable-threaded-resolver
|
||||
--with-libssh2
|
||||
--with-openssl
|
||||
--enable-versioned-symbols
|
||||
--with-random=/dev/urandom
|
||||
"
|
||||
|
||||
termux_step_pre_configure() {
|
||||
# Configure compiles binaries for testing that return a `Segmentation fault (core dumped)` error when run.
|
||||
# I don't know why this happens like this.
|
||||
sed -i 's/cross_compiling=no/cross_compiling=yes/' ${TERMUX_PKG_SRCDIR}/configure
|
||||
}
|
3
gpkg/libcurl/curl.subpackage.sh
Normal file
3
gpkg/libcurl/curl.subpackage.sh
Normal file
@ -0,0 +1,3 @@
|
||||
TERMUX_SUBPKG_INCLUDE="glibc/bin/curl glibc/share/man/man1/curl.1.gz"
|
||||
TERMUX_SUBPKG_DESCRIPTION="Command line tool for transferring data with URL syntax"
|
||||
TERMUX_SUBPKG_ESSENTIAL=true
|
15
gpkg/libevent/build.sh
Normal file
15
gpkg/libevent/build.sh
Normal file
@ -0,0 +1,15 @@
|
||||
TERMUX_PKG_HOMEPAGE=https://libevent.org/
|
||||
TERMUX_PKG_DESCRIPTION="Library that provides asynchronous event notification"
|
||||
TERMUX_PKG_LICENSE="BSD 3-Clause"
|
||||
TERMUX_PKG_MAINTAINER="@termux-pacman"
|
||||
TERMUX_PKG_VERSION=2.1.12
|
||||
TERMUX_PKG_SRCURL=https://github.com/libevent/libevent/archive/release-${TERMUX_PKG_VERSION}-stable.tar.gz
|
||||
TERMUX_PKG_SHA256=7180a979aaa7000e1264da484f712d403fcf7679b1e9212c4e3d09f5c93efc24
|
||||
TERMUX_PKG_RM_AFTER_INSTALL="glibc/bin/event_rpcgen.py"
|
||||
TERMUX_PKG_DEPENDS="openssl-glibc"
|
||||
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
|
||||
-DCMAKE_BUILD_TYPE=None
|
||||
-DCMAKE_SKIP_INSTALL_RPATH=TRUE
|
||||
-DEVENT__LIBRARY_TYPE=SHARED
|
||||
-DEVENT__DISABLE_REGRESS=OFF
|
||||
"
|
14
gpkg/libpam/build.sh
Normal file
14
gpkg/libpam/build.sh
Normal file
@ -0,0 +1,14 @@
|
||||
TERMUX_PKG_HOMEPAGE=http://linux-pam.org
|
||||
TERMUX_PKG_DESCRIPTION="PAM (Pluggable Authentication Modules) library"
|
||||
TERMUX_PKG_LICENSE="GPL-2.0"
|
||||
TERMUX_PKG_MAINTAINER="@termux-pacman"
|
||||
TERMUX_PKG_VERSION=1.5.3
|
||||
TERMUX_PKG_SRCURL=https://github.com/linux-pam/linux-pam/releases/download/v$TERMUX_PKG_VERSION/Linux-PAM-$TERMUX_PKG_VERSION.tar.xz
|
||||
TERMUX_PKG_SHA256=7ac4b50feee004a9fa88f1dfd2d2fa738a82896763050cd773b3c54b0a818283
|
||||
TERMUX_PKG_DEPENDS="libxcrypt-glibc, gcc-glibc-libs-dev"
|
||||
TERMUX_PKG_RM_AFTER_INSTALL="glibc/bin"
|
||||
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
|
||||
--includedir=$TERMUX_PREFIX/include/security
|
||||
--enable-logind
|
||||
--disable-db
|
||||
"
|
14
gpkg/libverto/build.sh
Normal file
14
gpkg/libverto/build.sh
Normal file
@ -0,0 +1,14 @@
|
||||
TERMUX_PKG_HOMEPAGE=https://github.com/latchset/libverto
|
||||
TERMUX_PKG_DESCRIPTION="Main event loop abstraction library"
|
||||
TERMUX_PKG_LICENSE="MIT"
|
||||
TERMUX_PKG_MAINTAINER="@termux-pacman"
|
||||
TERMUX_PKG_VERSION=0.3.2
|
||||
TERMUX_PKG_SRCURL=https://github.com/latchset/libverto/releases/download/$TERMUX_PKG_VERSION/libverto-$TERMUX_PKG_VERSION.tar.gz
|
||||
TERMUX_PKG_SHA256=8d1756fd704f147549f606cd987050fb94b0b1ff621ea6aa4d6bf0b74450468a
|
||||
TERMUX_PKG_DEPENDS="libevent-glibc"
|
||||
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
|
||||
--disable-static
|
||||
--with-libevent
|
||||
--without-libev
|
||||
--without-glib
|
||||
"
|
@ -3,10 +3,10 @@ TERMUX_PKG_DESCRIPTION="Library implementing the SSL and TLS protocols as well a
|
||||
TERMUX_PKG_LICENSE="Apache-2.0"
|
||||
TERMUX_PKG_MAINTAINER="@termux-pacman"
|
||||
TERMUX_PKG_VERSION=3.1.2
|
||||
TERMUX_PKG_REVISION=1
|
||||
TERMUX_PKG_REVISION=2
|
||||
TERMUX_PKG_SRCURL=https://www.openssl.org/source/openssl-${TERMUX_PKG_VERSION}.tar.gz
|
||||
TERMUX_PKG_SHA256=a0ce69b8b97ea6a35b96875235aa453b966ba3cba8af2de23657d8b6767d6539
|
||||
TERMUX_PKG_DEPENDS="ca-certificates, zlib-glibc, gcc-glibc-libs-dev"
|
||||
TERMUX_PKG_DEPENDS="ca-certificates, resolv-conf, zlib-glibc, gcc-glibc-libs-dev"
|
||||
TERMUX_PKG_CONFFILES="glibc/etc/ssl/openssl.cnf"
|
||||
TERMUX_PKG_BUILD_IN_SRC=true
|
||||
|
||||
|
37
gpkg/util-linux/blk-utils.subpackage.sh
Normal file
37
gpkg/util-linux/blk-utils.subpackage.sh
Normal file
@ -0,0 +1,37 @@
|
||||
TERMUX_SUBPKG_DESCRIPTION="Utilities for handling block device attributes"
|
||||
TERMUX_SUBPKG_DEPENDS="libblkid-glibc, libmount-glibc, libsmartcols-glibc, libuuid-glibc, gcc-glibc-libs-dev"
|
||||
TERMUX_SUBPKG_BREAKS="util-linux-glibc (<< 2.38.1-1)"
|
||||
TERMUX_SUBPKG_REPLACES="util-linux-glibc (<< 2.38.1-1)"
|
||||
TERMUX_SUBPKG_DEPEND_ON_PARENT="no"
|
||||
TERMUX_SUBPKG_INCLUDE="
|
||||
glibc/bin/blkdiscard
|
||||
glibc/bin/blkid
|
||||
glibc/bin/blkzone
|
||||
glibc/bin/findfs
|
||||
glibc/bin/fsck
|
||||
glibc/bin/lsblk
|
||||
glibc/bin/mkswap
|
||||
glibc/bin/partx
|
||||
glibc/bin/swaplabel
|
||||
glibc/bin/wipefs
|
||||
glibc/share/bash-completion/completions/blkdiscard
|
||||
glibc/share/bash-completion/completions/blkid
|
||||
glibc/share/bash-completion/completions/blkzone
|
||||
glibc/share/bash-completion/completions/findfs
|
||||
glibc/share/bash-completion/completions/fsck
|
||||
glibc/share/bash-completion/completions/lsblk
|
||||
glibc/share/bash-completion/completions/mkswap
|
||||
glibc/share/bash-completion/completions/partx
|
||||
glibc/share/bash-completion/completions/swaplabel
|
||||
glibc/share/bash-completion/completions/wipefs
|
||||
glibc/share/man/man8/blkdiscard.8.gz
|
||||
glibc/share/man/man8/blkid.8.gz
|
||||
glibc/share/man/man8/blkzone.8.gz
|
||||
glibc/share/man/man8/findfs.8.gz
|
||||
glibc/share/man/man8/fsck.8.gz
|
||||
glibc/share/man/man8/lsblk.8.gz
|
||||
glibc/share/man/man8/mkswap.8.gz
|
||||
glibc/share/man/man8/partx.8.gz
|
||||
glibc/share/man/man8/swaplabel.8.gz
|
||||
glibc/share/man/man8/wipefs.8.gz
|
||||
"
|
40
gpkg/util-linux/build.sh
Normal file
40
gpkg/util-linux/build.sh
Normal file
@ -0,0 +1,40 @@
|
||||
TERMUX_PKG_HOMEPAGE=https://en.wikipedia.org/wiki/Util-linux
|
||||
TERMUX_PKG_DESCRIPTION="Miscellaneous system utilities"
|
||||
TERMUX_PKG_LICENSE="GPL-3.0, GPL-2.0, LGPL-2.1, BSD 3-Clause, BSD, ISC"
|
||||
TERMUX_PKG_LICENSE_FILE="\
|
||||
Documentation/licenses/COPYING.GPL-3.0-or-later
|
||||
Documentation/licenses/COPYING.GPL-2.0-or-later
|
||||
Documentation/licenses/COPYING.LGPL-2.1-or-later
|
||||
Documentation/licenses/COPYING.BSD-3-Clause
|
||||
Documentation/licenses/COPYING.BSD-4-Clause-UC
|
||||
Documentation/licenses/COPYING.ISC"
|
||||
TERMUX_PKG_MAINTAINER="@termux-pacman"
|
||||
TERMUX_PKG_VERSION=2.39.2
|
||||
TERMUX_PKG_SRCURL=https://www.kernel.org/pub/linux/utils/util-linux/v${TERMUX_PKG_VERSION:0:4}/util-linux-${TERMUX_PKG_VERSION}.tar.xz
|
||||
TERMUX_PKG_SHA256=87abdfaa8e490f8be6dde976f7c80b9b5ff9f301e1b67e3899e1f05a59a1531f
|
||||
TERMUX_PKG_DEPENDS="libcap-ng-glibc, ncurses-glibc, zlib-glibc, libpam-glibc, libsmartcols-glibc, bash-glibc"
|
||||
TERMUX_PKG_ESSENTIAL=true
|
||||
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
|
||||
-Dlibuser=disabled
|
||||
-Dncurses=disabled
|
||||
-Dncursesw=enabled
|
||||
-Deconf=disabled
|
||||
-Dbuild-chfn-chsh=enabled
|
||||
-Dbuild-line=disabled
|
||||
-Dbuild-mesg=enabled
|
||||
-Dbuild-newgrp=enabled
|
||||
-Dbuild-vipw=enabled
|
||||
-Dbuild-write=enabled
|
||||
-Dbuild-lslogins=disabled
|
||||
-Dbuild-login=disabled
|
||||
-Dbuild-nologin=disabled
|
||||
-Dbuild-sulogin=disabled
|
||||
-Dbuild-su=disabled
|
||||
-Dbuild-lsmem=disabled
|
||||
-Dbuild-chmem=disabled
|
||||
-Dbuild-python=disabled
|
||||
"
|
||||
|
||||
termux_step_configure() {
|
||||
termux_step_configure_meson
|
||||
}
|
14
gpkg/util-linux/fdisk.subpackage.sh
Normal file
14
gpkg/util-linux/fdisk.subpackage.sh
Normal file
@ -0,0 +1,14 @@
|
||||
TERMUX_SUBPKG_DESCRIPTION="Utilities to manipulate disk partition tables"
|
||||
TERMUX_SUBPKG_DEPENDS="libfdisk-glibc, libmount-glibc, ncurses-glibc, readline-glibc, libsmartcols-glibc"
|
||||
TERMUX_SUBPKG_DEPEND_ON_PARENT="no"
|
||||
TERMUX_SUBPKG_INCLUDE="
|
||||
glibc/share/man/man8/cfdisk.8.gz
|
||||
glibc/share/man/man8/fdisk.8.gz
|
||||
glibc/share/man/man8/sfdisk.8.gz
|
||||
glibc/share/bash-completion/completions/sfdisk
|
||||
glibc/share/bash-completion/completions/fdisk
|
||||
glibc/share/bash-completion/completions/cfdisk
|
||||
glibc/bin/sfdisk
|
||||
glibc/bin/fdisk
|
||||
glibc/bin/cfdisk
|
||||
"
|
13
gpkg/util-linux/libblkid.subpackage.sh
Normal file
13
gpkg/util-linux/libblkid.subpackage.sh
Normal file
@ -0,0 +1,13 @@
|
||||
TERMUX_SUBPKG_DESCRIPTION="Block device identification library"
|
||||
TERMUX_SUBPKG_DEPENDS="glibc"
|
||||
TERMUX_SUBPKG_BREAKS="util-linux-glibc (<< 2.38.1-1)"
|
||||
TERMUX_SUBPKG_REPLACES="util-linux-glibc (<< 2.38.1-1)"
|
||||
TERMUX_SUBPKG_DEPEND_ON_PARENT="no"
|
||||
TERMUX_SUBPKG_INCLUDE="
|
||||
glibc/include/blkid/blkid.h
|
||||
glibc/lib/libblkid.so
|
||||
glibc/lib/libblkid.so.1
|
||||
glibc/lib/libblkid.so.1.1.0
|
||||
glibc/lib/pkgconfig/blkid.pc
|
||||
glibc/share/man/man3/libblkid.3.gz
|
||||
"
|
10
gpkg/util-linux/libfdisk.subpackage.sh
Normal file
10
gpkg/util-linux/libfdisk.subpackage.sh
Normal file
@ -0,0 +1,10 @@
|
||||
TERMUX_SUBPKG_DESCRIPTION="Library for manipulating disk partition tables"
|
||||
TERMUX_SUBPKG_DEPENDS="libblkid-glibc, libuuid-glibc"
|
||||
TERMUX_SUBPKG_DEPEND_ON_PARENT="no"
|
||||
TERMUX_SUBPKG_INCLUDE="
|
||||
glibc/lib/pkgconfig/fdisk.pc
|
||||
glibc/lib/libfdisk.so
|
||||
glibc/lib/libfdisk.so.1
|
||||
glibc/lib/libfdisk.so.1.1.0
|
||||
glibc/include/libfdisk/libfdisk.h
|
||||
"
|
10
gpkg/util-linux/libmount.subpackage.sh
Normal file
10
gpkg/util-linux/libmount.subpackage.sh
Normal file
@ -0,0 +1,10 @@
|
||||
TERMUX_SUBPKG_DESCRIPTION="Library for (un)mounting filesystems"
|
||||
TERMUX_SUBPKG_DEPENDS="libblkid-glibc, libsmartcols-glibc"
|
||||
TERMUX_SUBPKG_DEPEND_ON_PARENT="no"
|
||||
TERMUX_SUBPKG_INCLUDE="
|
||||
glibc/include/libmount/libmount.h
|
||||
glibc/lib/libmount.so
|
||||
glibc/lib/libmount.so.1
|
||||
glibc/lib/libmount.so.1.1.0
|
||||
glibc/lib/pkgconfig/mount.pc
|
||||
"
|
12
gpkg/util-linux/libsmartcols.subpackage.sh
Normal file
12
gpkg/util-linux/libsmartcols.subpackage.sh
Normal file
@ -0,0 +1,12 @@
|
||||
TERMUX_SUBPKG_DESCRIPTION="Library for smart adaptive formatting of tabular data"
|
||||
TERMUX_SUBPKG_DEPENDS="glibc"
|
||||
TERMUX_SUBPKG_BREAKS="util-linux-glibc (<< 2.38.1-1)"
|
||||
TERMUX_SUBPKG_REPLACES="util-linux-glibc (<< 2.38.1-1)"
|
||||
TERMUX_SUBPKG_DEPEND_ON_PARENT="no"
|
||||
TERMUX_SUBPKG_INCLUDE="
|
||||
glibc/lib/libsmartcols.so
|
||||
glibc/lib/libsmartcols.so.1
|
||||
glibc/lib/libsmartcols.so.1.1.0
|
||||
glibc/lib/pkgconfig/smartcols.pc
|
||||
glibc/include/libsmartcols/libsmartcols.h
|
||||
"
|
10
gpkg/util-linux/libuuid.subpackage.sh
Normal file
10
gpkg/util-linux/libuuid.subpackage.sh
Normal file
@ -0,0 +1,10 @@
|
||||
TERMUX_SUBPKG_DESCRIPTION="Library for handling universally unique identifiers"
|
||||
TERMUX_SUBPKG_DEPENDS="glibc"
|
||||
TERMUX_SUBPKG_DEPEND_ON_PARENT="no"
|
||||
TERMUX_SUBPKG_INCLUDE="
|
||||
glibc/lib/pkgconfig/uuid.pc
|
||||
glibc/lib/libuuid.so
|
||||
glibc/lib/libuuid.so.1
|
||||
glibc/lib/libuuid.so.1.3.0
|
||||
glibc/include/uuid/uuid.h
|
||||
"
|
26
gpkg/util-linux/mount-utils.subpackage.sh
Normal file
26
gpkg/util-linux/mount-utils.subpackage.sh
Normal file
@ -0,0 +1,26 @@
|
||||
TERMUX_SUBPKG_DESCRIPTION="Utilities for (un)mounting filesystems"
|
||||
TERMUX_SUBPKG_DEPENDS="libblkid-glibc, libsmartcols-glibc, libmount-glibc, gcc-glibc-libs-dev"
|
||||
TERMUX_SUBPKG_DEPEND_ON_PARENT="no"
|
||||
TERMUX_SUBPKG_INCLUDE="
|
||||
glibc/bin/findmnt
|
||||
glibc/bin/fstrim
|
||||
glibc/bin/lslocks
|
||||
glibc/bin/mount
|
||||
glibc/bin/swapoff
|
||||
glibc/bin/swapon
|
||||
glibc/bin/umount
|
||||
glibc/share/bash-completion/completions/findmnt
|
||||
glibc/share/bash-completion/completions/fstrim
|
||||
glibc/share/bash-completion/completions/lslocks
|
||||
glibc/share/bash-completion/completions/mount
|
||||
glibc/share/bash-completion/completions/swapoff
|
||||
glibc/share/bash-completion/completions/swapon
|
||||
glibc/share/bash-completion/completions/umount
|
||||
glibc/share/man/man8/findmnt.8.gz
|
||||
glibc/share/man/man8/fstrim.8.gz
|
||||
glibc/share/man/man8/lslocks.8.gz
|
||||
glibc/share/man/man8/mount.8.gz
|
||||
glibc/share/man/man8/swapoff.8.gz
|
||||
glibc/share/man/man8/swapon.8.gz
|
||||
glibc/share/man/man8/umount.8.gz
|
||||
"
|
796
gpkg/util-linux/setdirs.patch
Normal file
796
gpkg/util-linux/setdirs.patch
Normal file
@ -0,0 +1,796 @@
|
||||
diff --git a/disk-utils/fsck.c b/disk-utils/fsck.c
|
||||
index 1b11e82..798528d 100644
|
||||
--- a/disk-utils/fsck.c
|
||||
+++ b/disk-utils/fsck.c
|
||||
@@ -1120,7 +1120,7 @@ static int ignore(struct libmnt_fs *fs)
|
||||
* If this is a bind mount, ignore it.
|
||||
*/
|
||||
if (opt_in_list("bind", mnt_fs_get_options(fs))) {
|
||||
- warnx(_("%s: skipping bad line in /etc/fstab: "
|
||||
+ warnx(_("%s: skipping bad line in @TERMUX_PREFIX@/etc/fstab: "
|
||||
"bind mount with nonzero fsck pass number"),
|
||||
mnt_fs_get_target(fs));
|
||||
return 1;
|
||||
diff --git a/include/pathnames.h b/include/pathnames.h
|
||||
index 56f64c3..877e8c8 100644
|
||||
--- a/include/pathnames.h
|
||||
+++ b/include/pathnames.h
|
||||
@@ -19,77 +19,69 @@
|
||||
/* DEFPATHs from <paths.h> don't include /usr/local */
|
||||
#undef _PATH_DEFPATH
|
||||
|
||||
-#ifdef USE_USRDIR_PATHS_ONLY
|
||||
-# define _PATH_DEFPATH "/usr/local/bin:/usr/bin"
|
||||
-#else
|
||||
-# define _PATH_DEFPATH "/usr/local/bin:/bin:/usr/bin"
|
||||
-#endif
|
||||
+#define _PATH_DEFPATH "@TERMUX_PREFIX@/bin"
|
||||
|
||||
#undef _PATH_DEFPATH_ROOT
|
||||
|
||||
-#ifdef USE_USRDIR_PATHS_ONLY
|
||||
-# define _PATH_DEFPATH_ROOT "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin"
|
||||
-#else
|
||||
-# define _PATH_DEFPATH_ROOT "/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin"
|
||||
-#endif
|
||||
+#define _PATH_DEFPATH_ROOT "@TERMUX_PREFIX@/bin"
|
||||
|
||||
#define _PATH_HUSHLOGIN ".hushlogin"
|
||||
-#define _PATH_HUSHLOGINS "/etc/hushlogins"
|
||||
+#define _PATH_HUSHLOGINS "@TERMUX_PREFIX@/etc/hushlogins"
|
||||
|
||||
-#define _PATH_NOLOGIN_TXT "/etc/nologin.txt"
|
||||
+#define _PATH_NOLOGIN_TXT "@TERMUX_PREFIX@/etc/nologin.txt"
|
||||
|
||||
#ifndef _PATH_MAILDIR
|
||||
-# define _PATH_MAILDIR "/var/spool/mail"
|
||||
+# define _PATH_MAILDIR "@TERMUX_PREFIX@/var/spool/mail"
|
||||
#endif
|
||||
-#define _PATH_MOTDFILE "/usr/share/misc/motd:/run/motd:/etc/motd"
|
||||
+#define _PATH_MOTDFILE "@TERMUX_PREFIX@/share/misc/motd:@TERMUX_PREFIX@/run/motd:@TERMUX_PREFIX@/etc/motd"
|
||||
#ifndef _PATH_NOLOGIN
|
||||
-# define _PATH_NOLOGIN "/etc/nologin"
|
||||
+# define _PATH_NOLOGIN "@TERMUX_PREFIX@/etc/nologin"
|
||||
#endif
|
||||
-#define _PATH_VAR_NOLOGIN "/var/run/nologin"
|
||||
+#define _PATH_VAR_NOLOGIN "@TERMUX_PREFIX@/var/run/nologin"
|
||||
|
||||
#ifndef _PATH_LOGIN
|
||||
-# define _PATH_LOGIN "/bin/login"
|
||||
+# define _PATH_LOGIN "@TERMUX_PREFIX@/bin/login"
|
||||
#endif
|
||||
-#define _PATH_SHUTDOWN "/sbin/shutdown"
|
||||
-#define _PATH_POWEROFF "/sbin/poweroff"
|
||||
+#define _PATH_SHUTDOWN "@TERMUX_PREFIX@/bin/shutdown"
|
||||
+#define _PATH_POWEROFF "@TERMUX_PREFIX@/bin/poweroff"
|
||||
|
||||
#define _PATH_TERMCOLORS_DIRNAME "terminal-colors.d"
|
||||
-#define _PATH_TERMCOLORS_DIR "/etc/" _PATH_TERMCOLORS_DIRNAME
|
||||
+#define _PATH_TERMCOLORS_DIR "@TERMUX_PREFIX@/etc/" _PATH_TERMCOLORS_DIRNAME
|
||||
|
||||
/* login paths */
|
||||
-#define _PATH_PASSWD "/etc/passwd"
|
||||
-#define _PATH_GSHADOW "/etc/gshadow"
|
||||
-#define _PATH_GROUP "/etc/group"
|
||||
-#define _PATH_SHADOW_PASSWD "/etc/shadow"
|
||||
-#define _PATH_SHELLS "/etc/shells"
|
||||
+#define _PATH_PASSWD "/system/etc/passwd"
|
||||
+#define _PATH_GSHADOW "/system/etc/gshadow"
|
||||
+#define _PATH_GROUP "/system/etc/group"
|
||||
+#define _PATH_SHADOW_PASSWD "/system/etc/shadow"
|
||||
+#define _PATH_SHELLS "@TERMUX_PREFIX@/etc/shells"
|
||||
|
||||
#ifndef _PATH_TMP
|
||||
-# define _PATH_TMP "/tmp/"
|
||||
+# define _PATH_TMP "@TERMUX_PREFIX_CLASSICAL@/tmp/"
|
||||
#endif
|
||||
|
||||
#ifndef _PATH_BTMP
|
||||
-# define _PATH_BTMP "/var/log/btmp"
|
||||
+# define _PATH_BTMP "@TERMUX_PREFIX@/var/log/btmp"
|
||||
#endif
|
||||
|
||||
#define _PATH_ISSUE_FILENAME "issue"
|
||||
#define _PATH_ISSUE_DIRNAME _PATH_ISSUE_FILENAME ".d"
|
||||
|
||||
-#define _PATH_ISSUE "/etc/" _PATH_ISSUE_FILENAME
|
||||
-#define _PATH_ISSUEDIR "/etc/" _PATH_ISSUE_DIRNAME
|
||||
+#define _PATH_ISSUE "@TERMUX_PREFIX@/etc/" _PATH_ISSUE_FILENAME
|
||||
+#define _PATH_ISSUEDIR "@TERMUX_PREFIX@/etc/" _PATH_ISSUE_DIRNAME
|
||||
|
||||
-#define _PATH_OS_RELEASE_ETC "/etc/os-release"
|
||||
-#define _PATH_OS_RELEASE_USR "/usr/lib/os-release"
|
||||
+#define _PATH_OS_RELEASE_ETC "@TERMUX_PREFIX@/etc/os-release"
|
||||
+#define _PATH_OS_RELEASE_USR "@TERMUX_PREFIX@/lib/os-release"
|
||||
#define _PATH_NUMLOCK_ON _PATH_RUNSTATEDIR "/numlock-on"
|
||||
-#define _PATH_LOGINDEFS "/etc/login.defs"
|
||||
+#define _PATH_LOGINDEFS "@TERMUX_PREFIX@/etc/login.defs"
|
||||
|
||||
#define _PATH_SD_UNITSLOAD _PATH_RUNSTATEDIR "/systemd/systemd-units-load"
|
||||
|
||||
/* misc paths */
|
||||
-#define _PATH_WORDS "/usr/share/dict/words"
|
||||
-#define _PATH_WORDS_ALT "/usr/share/dict/web2"
|
||||
+#define _PATH_WORDS "@TERMUX_PREFIX@/share/dict/words"
|
||||
+#define _PATH_WORDS_ALT "@TERMUX_PREFIX@/share/dict/web2"
|
||||
|
||||
/* mount paths */
|
||||
-#define _PATH_FILESYSTEMS "/etc/filesystems"
|
||||
+#define _PATH_FILESYSTEMS "@TERMUX_PREFIX@/etc/filesystems"
|
||||
#define _PATH_PROC "/proc"
|
||||
#define _PATH_PROC_SWAPS "/proc/swaps"
|
||||
#define _PATH_PROC_FILESYSTEMS "/proc/filesystems"
|
||||
@@ -101,8 +93,8 @@
|
||||
#define _PATH_PROC_CDROMINFO "/proc/sys/dev/cdrom/info"
|
||||
|
||||
/* unshare paths */
|
||||
-#define _PATH_SUBUID "/etc/subuid"
|
||||
-#define _PATH_SUBGID "/etc/subgid"
|
||||
+#define _PATH_SUBUID "@TERMUX_PREFIX@/etc/subuid"
|
||||
+#define _PATH_SUBGID "@TERMUX_PREFIX@/etc/subgid"
|
||||
#define _PATH_PROC_UIDMAP "/proc/self/uid_map"
|
||||
#define _PATH_PROC_GIDMAP "/proc/self/gid_map"
|
||||
#define _PATH_PROC_SETGROUPS "/proc/self/setgroups"
|
||||
@@ -129,7 +121,7 @@
|
||||
# ifdef MOUNTED /* deprecated */
|
||||
# define _PATH_MOUNTED MOUNTED
|
||||
# else
|
||||
-# define _PATH_MOUNTED "/etc/mtab"
|
||||
+# define _PATH_MOUNTED "@TERMUX_PREFIX@/etc/mtab"
|
||||
# endif
|
||||
#endif
|
||||
|
||||
@@ -137,7 +129,7 @@
|
||||
# ifdef MNTTAB /* deprecated */
|
||||
# define _PATH_MNTTAB MNTTAB
|
||||
# else
|
||||
-# define _PATH_MNTTAB "/etc/fstab"
|
||||
+# define _PATH_MNTTAB "@TERMUX_PREFIX@/etc/fstab"
|
||||
# endif
|
||||
#endif
|
||||
|
||||
@@ -148,26 +140,26 @@
|
||||
# define _PATH_DEV "/dev/"
|
||||
#endif
|
||||
|
||||
-#define _PATH_DEV_MAPPER "/dev/mapper"
|
||||
+#define _PATH_DEV_MAPPER "/dev/block/mapper"
|
||||
|
||||
#define _PATH_DEV_MEM "/dev/mem"
|
||||
|
||||
-#define _PATH_DEV_LOOP "/dev/loop"
|
||||
+#define _PATH_DEV_LOOP "/dev/block/loop"
|
||||
#define _PATH_DEV_LOOPCTL "/dev/loop-control"
|
||||
|
||||
/* udev paths */
|
||||
-#define _PATH_DEV_BYLABEL "/dev/disk/by-label"
|
||||
-#define _PATH_DEV_BYUUID "/dev/disk/by-uuid"
|
||||
-#define _PATH_DEV_BYID "/dev/disk/by-id"
|
||||
-#define _PATH_DEV_BYPATH "/dev/disk/by-path"
|
||||
-#define _PATH_DEV_BYPARTLABEL "/dev/disk/by-partlabel"
|
||||
-#define _PATH_DEV_BYPARTUUID "/dev/disk/by-partuuid"
|
||||
+#define _PATH_DEV_BYLABEL "/dev/block/by-label"
|
||||
+#define _PATH_DEV_BYUUID "/dev/block/by-uuid"
|
||||
+#define _PATH_DEV_BYID "/dev/block/by-id"
|
||||
+#define _PATH_DEV_BYPATH "/dev/block/by-path"
|
||||
+#define _PATH_DEV_BYPARTLABEL "/dev/block/by-partlabel"
|
||||
+#define _PATH_DEV_BYPARTUUID "/dev/block/by-partuuid"
|
||||
|
||||
/* hwclock paths */
|
||||
#ifdef CONFIG_ADJTIME_PATH
|
||||
# define _PATH_ADJTIME CONFIG_ADJTIME_PATH
|
||||
#else
|
||||
-# define _PATH_ADJTIME "/etc/adjtime"
|
||||
+# define _PATH_ADJTIME "@TERMUX_PREFIX@/etc/adjtime"
|
||||
#endif
|
||||
|
||||
#ifdef __ia64__
|
||||
diff --git a/lib/exec_shell.c b/lib/exec_shell.c
|
||||
index 6fef6c7..952f8fc 100644
|
||||
--- a/lib/exec_shell.c
|
||||
+++ b/lib/exec_shell.c
|
||||
@@ -28,7 +28,7 @@
|
||||
|
||||
#include "exec_shell.h"
|
||||
|
||||
-#define DEFAULT_SHELL "/bin/sh"
|
||||
+#define DEFAULT_SHELL "@TERMUX_PREFIX@/bin/sh"
|
||||
|
||||
void __attribute__((__noreturn__)) exec_shell(void)
|
||||
{
|
||||
diff --git a/lib/ismounted.c b/lib/ismounted.c
|
||||
index 31be71a..1160491 100644
|
||||
--- a/lib/ismounted.c
|
||||
+++ b/lib/ismounted.c
|
||||
@@ -182,7 +182,7 @@ static int check_mntent(const char *file, int *mount_flags,
|
||||
int retval;
|
||||
|
||||
#ifdef DEBUG
|
||||
- retval = check_mntent_file("/tmp/mtab", file, mount_flags,
|
||||
+ retval = check_mntent_file("@TERMUX_PREFIX_CLASSICAL@/tmp/mtab", file, mount_flags,
|
||||
mtpt, mtlen);
|
||||
if (retval == 0)
|
||||
return 0;
|
||||
diff --git a/lib/logindefs.c b/lib/logindefs.c
|
||||
index 9563122..ed34dc9 100644
|
||||
--- a/lib/logindefs.c
|
||||
+++ b/lib/logindefs.c
|
||||
@@ -260,7 +260,7 @@ static void load_defaults(void)
|
||||
#else
|
||||
NULL,
|
||||
#endif
|
||||
- "/etc", "login", "defs", "= \t", "#");
|
||||
+ "@TERMUX_PREFIX@/etc", "login", "defs", "= \t", "#");
|
||||
|
||||
if (error)
|
||||
syslog(LOG_NOTICE, _("Error reading login.defs: %s"),
|
||||
@@ -293,7 +293,7 @@ void logindefs_load_file(const char *filename)
|
||||
free (path);
|
||||
#endif
|
||||
|
||||
- xasprintf(&path, "/etc/%s", filename);
|
||||
+ xasprintf(&path, "@TERMUX_PREFIX@/etc/%s", filename);
|
||||
|
||||
if (!econf_readFile(&file_l, path, "= \t", "#")) {
|
||||
if (file == NULL)
|
||||
diff --git a/lib/loopdev.c b/lib/loopdev.c
|
||||
index dd9ead3..c7e0aec 100644
|
||||
--- a/lib/loopdev.c
|
||||
+++ b/lib/loopdev.c
|
||||
@@ -126,13 +126,13 @@ int loopcxt_set_device(struct loopdev_cxt *lc, const char *device)
|
||||
/* set new */
|
||||
if (device) {
|
||||
if (*device != '/') {
|
||||
- const char *dir = _PATH_DEV;
|
||||
+ const char *dir = _PATH_DEV "block/";
|
||||
|
||||
/* compose device name for /dev/loop<n> or /dev/loop/<n> */
|
||||
if (lc->flags & LOOPDEV_FL_DEVSUBDIR) {
|
||||
- if (strlen(device) < 5)
|
||||
+ if (strlen(device) < 11)
|
||||
return -1;
|
||||
- device += 4;
|
||||
+ device += 10;
|
||||
dir = _PATH_DEV_LOOP "/"; /* _PATH_DEV uses tailing slash */
|
||||
}
|
||||
snprintf(lc->device, sizeof(lc->device), "%s%s",
|
||||
diff --git a/libblkid/src/blkidP.h b/libblkid/src/blkidP.h
|
||||
index 007cc35..4e7dc96 100644
|
||||
--- a/libblkid/src/blkidP.h
|
||||
+++ b/libblkid/src/blkidP.h
|
||||
@@ -304,15 +304,15 @@ struct blkid_struct_cache
|
||||
#define BLKID_BIC_FL_CHANGED 0x0004 /* Cache has changed from disk */
|
||||
|
||||
/* config file */
|
||||
-#define BLKID_CONFIG_FILE "/etc/blkid.conf"
|
||||
+#define BLKID_CONFIG_FILE "@TERMUX_PREFIX@/etc/blkid.conf"
|
||||
|
||||
/* cache file on systemds with /run */
|
||||
-#define BLKID_RUNTIME_TOPDIR "/run"
|
||||
+#define BLKID_RUNTIME_TOPDIR "@TERMUX_PREFIX@/run"
|
||||
#define BLKID_RUNTIME_DIR BLKID_RUNTIME_TOPDIR "/blkid"
|
||||
#define BLKID_CACHE_FILE BLKID_RUNTIME_DIR "/blkid.tab"
|
||||
|
||||
/* old systems */
|
||||
-#define BLKID_CACHE_FILE_OLD "/etc/blkid.tab"
|
||||
+#define BLKID_CACHE_FILE_OLD "@TERMUX_PREFIX@/etc/blkid.tab"
|
||||
|
||||
#define BLKID_ERR_IO 5
|
||||
#define BLKID_ERR_SYSFS 9
|
||||
diff --git a/libblkid/src/fuzz.c b/libblkid/src/fuzz.c
|
||||
index 772340b..04f673d 100644
|
||||
--- a/libblkid/src/fuzz.c
|
||||
+++ b/libblkid/src/fuzz.c
|
||||
@@ -21,7 +21,7 @@ static int process_file(const char *name)
|
||||
|
||||
int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
|
||||
int fd;
|
||||
- char name[] = "/tmp/test-script-fuzz.XXXXXX";
|
||||
+ char name[] = "@TERMUX_PREFIX_CLASSICAL@/tmp/test-script-fuzz.XXXXXX";
|
||||
|
||||
fd = mkostemp(name, O_RDWR|O_CREAT|O_EXCL|O_CLOEXEC);
|
||||
if (fd == -1)
|
||||
diff --git a/libfdisk/src/script.c b/libfdisk/src/script.c
|
||||
index f537a7d..0c99cf0 100644
|
||||
--- a/libfdisk/src/script.c
|
||||
+++ b/libfdisk/src/script.c
|
||||
@@ -1636,7 +1636,7 @@ int fdisk_apply_script(struct fdisk_context *cxt, struct fdisk_script *dp)
|
||||
|
||||
int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size)
|
||||
{
|
||||
- char name[] = "/tmp/test-script-fuzz.XXXXXX";
|
||||
+ char name[] = "@TERMUX_PREFIX_CLASSICAL@/tmp/test-script-fuzz.XXXXXX";
|
||||
int fd;
|
||||
struct fdisk_script *dp;
|
||||
struct fdisk_context *cxt;
|
||||
diff --git a/libmount/python/tab.c b/libmount/python/tab.c
|
||||
index 000bc13..f26aaff 100644
|
||||
--- a/libmount/python/tab.c
|
||||
+++ b/libmount/python/tab.c
|
||||
@@ -332,7 +332,7 @@ static PyObject *Table_is_fs_mounted(TableObject *self, PyObject *args, PyObject
|
||||
}
|
||||
|
||||
#define Table_parse_file_HELP "parse_file(file)\n\n" \
|
||||
- "Parses whole table (e.g. /etc/mtab) and appends new records to the tab.\n" \
|
||||
+ "Parses whole table (e.g. @TERMUX_PREFIX@/etc/mtab) and appends new records to the tab.\n" \
|
||||
"\n" \
|
||||
"The libmount parser ignores broken (syntax error) lines, these lines are\n" \
|
||||
"reported to caller by errcb() function (see Tab.parser_errcb).\n" \
|
||||
@@ -352,7 +352,7 @@ static PyObject *Table_parse_file(TableObject *self, PyObject* args, PyObject *k
|
||||
}
|
||||
|
||||
#define Table_parse_fstab_HELP "parse_fstab([fstab])\n\n" \
|
||||
- "This function parses /etc/fstab and appends new lines to the tab. If the\n" \
|
||||
+ "This function parses @TERMUX_PREFIX@/etc/fstab and appends new lines to the tab. If the\n" \
|
||||
"filename is a directory then Tab.parse_dir() is called.\n" \
|
||||
"\n" \
|
||||
"See also Tab.parser_errcb.\n" \
|
||||
@@ -373,7 +373,7 @@ static PyObject *Table_parse_fstab(TableObject *self, PyObject* args, PyObject *
|
||||
}
|
||||
|
||||
#define Table_parse_mtab_HELP "parse_mtab([mtab])\n\n" \
|
||||
- "This function parses /etc/mtab or /proc/self/mountinfo\n" \
|
||||
+ "This function parses @TERMUX_PREFIX@/etc/mtab or /proc/self/mountinfo\n" \
|
||||
"/run/mount/utabs or /proc/mounts.\n" \
|
||||
"\n" \
|
||||
"See also Tab.parser_errcb().\n" \
|
||||
diff --git a/libmount/src/mountP.h b/libmount/src/mountP.h
|
||||
index 339e276..d2ee5f9 100644
|
||||
--- a/libmount/src/mountP.h
|
||||
+++ b/libmount/src/mountP.h
|
||||
@@ -77,7 +77,7 @@ UL_DEBUG_DECLARE_MASK(libmount);
|
||||
#define MNT_MNTTABDIR_EXT ".fstab"
|
||||
|
||||
/* library private paths */
|
||||
-#define MNT_RUNTIME_TOPDIR "/run"
|
||||
+#define MNT_RUNTIME_TOPDIR "@TERMUX_PREFIX@/run"
|
||||
/* private userspace mount table */
|
||||
#define MNT_PATH_UTAB MNT_RUNTIME_TOPDIR "/mount/utab"
|
||||
/* temporary mount target */
|
||||
diff --git a/login-utils/last.c b/login-utils/last.c
|
||||
index 37c6abe..ddbf35a 100644
|
||||
--- a/login-utils/last.c
|
||||
+++ b/login-utils/last.c
|
||||
@@ -925,7 +925,7 @@ int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
|
||||
.tv_usec = 816074
|
||||
}
|
||||
};
|
||||
- char name[] = "/tmp/test-last-fuzz.XXXXXX";
|
||||
+ char name[] = "@TERMUX_PREFIX_CLASSICAL@/tmp/test-last-fuzz.XXXXXX";
|
||||
int fd;
|
||||
|
||||
fd = mkstemp_cloexec(name);
|
||||
diff --git a/login-utils/login.c b/login-utils/login.c
|
||||
index 74bdf38..437c240 100644
|
||||
--- a/login-utils/login.c
|
||||
+++ b/login-utils/login.c
|
||||
@@ -1516,7 +1516,7 @@ int main(int argc, char **argv)
|
||||
char *buff;
|
||||
|
||||
xasprintf(&buff, "exec %s", pwd->pw_shell);
|
||||
- child_argv[child_argc++] = "/bin/sh";
|
||||
+ child_argv[child_argc++] = "@TERMUX_PREFIX@/bin/sh";
|
||||
child_argv[child_argc++] = "-sh";
|
||||
child_argv[child_argc++] = "-c";
|
||||
child_argv[child_argc++] = buff;
|
||||
@@ -1538,7 +1538,7 @@ int main(int argc, char **argv)
|
||||
|
||||
execvp(child_argv[0], child_argv + 1);
|
||||
|
||||
- if (!strcmp(child_argv[0], "/bin/sh"))
|
||||
+ if (!strcmp(child_argv[0], "@TERMUX_PREFIX@/bin/sh"))
|
||||
warn(_("couldn't exec shell script"));
|
||||
else
|
||||
warn(_("no shell"));
|
||||
diff --git a/login-utils/lslogins.c b/login-utils/lslogins.c
|
||||
index 76d2812..3d84e8c 100644
|
||||
--- a/login-utils/lslogins.c
|
||||
+++ b/login-utils/lslogins.c
|
||||
@@ -1446,7 +1446,7 @@ static void __attribute__((__noreturn__)) usage(void)
|
||||
|
||||
fputs(USAGE_OPTIONS, out);
|
||||
fputs(_(" -a, --acc-expiration display info about passwords expiration\n"), out);
|
||||
- fputs(_(" -c, --colon-separate display data in a format similar to /etc/passwd\n"), out);
|
||||
+ fputs(_(" -c, --colon-separate display data in a format similar to /system/etc/passwd\n"), out);
|
||||
fputs(_(" -e, --export display in an export-able output format\n"), out);
|
||||
fputs(_(" -f, --failed display data about the users' last failed logins\n"), out);
|
||||
fputs(_(" -G, --supp-groups display information about groups\n"), out);
|
||||
diff --git a/login-utils/setpwnam.c b/login-utils/setpwnam.c
|
||||
index 3e3c1ab..ff3076d 100644
|
||||
--- a/login-utils/setpwnam.c
|
||||
+++ b/login-utils/setpwnam.c
|
||||
@@ -84,7 +84,7 @@ int setpwnam(struct passwd *pwd, const char *prefix)
|
||||
|
||||
pw_init();
|
||||
|
||||
- if ((fp = xfmkstemp(&tmpname, "/etc", prefix)) == NULL)
|
||||
+ if ((fp = xfmkstemp(&tmpname, "@TERMUX_PREFIX@/etc", prefix)) == NULL)
|
||||
return -1;
|
||||
|
||||
/* ptmp should be owned by root.root or root.wheel */
|
||||
diff --git a/login-utils/setpwnam.h b/login-utils/setpwnam.h
|
||||
index 9578592..883d4b7 100644
|
||||
--- a/login-utils/setpwnam.h
|
||||
+++ b/login-utils/setpwnam.h
|
||||
@@ -22,10 +22,10 @@
|
||||
# define SHADOW_FILE _PATH_SHADOW_PASSWD
|
||||
# define SGROUP_FILE _PATH_GSHADOW
|
||||
#else
|
||||
-# define PASSWD_FILE "/tmp/passwd"
|
||||
-# define GROUP_FILE "/tmp/group"
|
||||
-# define SHADOW_FILE "/tmp/shadow"
|
||||
-# define SGROUP_FILE "/tmp/gshadow"
|
||||
+# define PASSWD_FILE "@TERMUX_PREFIX_CLASSICAL@/tmp/passwd"
|
||||
+# define GROUP_FILE "@TERMUX_PREFIX_CLASSICAL@/tmp/group"
|
||||
+# define SHADOW_FILE "@TERMUX_PREFIX_CLASSICAL@/tmp/shadow"
|
||||
+# define SGROUP_FILE "@TERMUX_PREFIX_CLASSICAL@/tmp/gshadow"
|
||||
#endif
|
||||
|
||||
extern int setpwnam (struct passwd *pwd, const char *prefix);
|
||||
diff --git a/login-utils/su-common.c b/login-utils/su-common.c
|
||||
index b674920..d0c1472 100644
|
||||
--- a/login-utils/su-common.c
|
||||
+++ b/login-utils/su-common.c
|
||||
@@ -99,8 +99,8 @@ UL_DEBUG_DEFINE_MASKNAMES(su) = UL_DEBUG_EMPTY_MASKNAMES;
|
||||
#define _PATH_LOGINDEFS_SU "default/su"
|
||||
#define _PATH_LOGINDEFS_RUNUSER "default/runuser"
|
||||
#else
|
||||
-#define _PATH_LOGINDEFS_SU "/etc/default/su"
|
||||
-#define _PATH_LOGINDEFS_RUNUSER "/etc/default/runuser"
|
||||
+#define _PATH_LOGINDEFS_SU "@TERMUX_PREFIX@/etc/default/su"
|
||||
+#define _PATH_LOGINDEFS_RUNUSER "@TERMUX_PREFIX@/etc/default/runuser"
|
||||
#endif
|
||||
|
||||
#define is_pam_failure(_rc) ((_rc) != PAM_SUCCESS)
|
||||
@@ -874,9 +874,9 @@ static bool is_restricted_shell(const char *shell)
|
||||
return false;
|
||||
}
|
||||
#ifdef USE_VENDORDIR
|
||||
- DBG(MISC, ul_debug("%s is restricted shell (not in e.g. vendor shells file, /etc/shells, ...)", shell));
|
||||
+ DBG(MISC, ul_debug("%s is restricted shell (not in e.g. vendor shells file, @TERMUX_PREFIX@/etc/shells, ...)", shell));
|
||||
#else
|
||||
- DBG(MISC, ul_debug("%s is restricted shell (not in /etc/shells)", shell));
|
||||
+ DBG(MISC, ul_debug("%s is restricted shell (not in @TERMUX_PREFIX@/etc/shells)", shell));
|
||||
#endif
|
||||
return true;
|
||||
}
|
||||
@@ -896,7 +896,7 @@ static void usage_common(void)
|
||||
fputs(_(" --session-command <command> pass a single command to the shell with -c\n"
|
||||
" and do not create a new session\n"), stdout);
|
||||
fputs(_(" -f, --fast pass -f to the shell (for csh or tcsh)\n"), stdout);
|
||||
- fputs(_(" -s, --shell <shell> run <shell> if /etc/shells allows it\n"), stdout);
|
||||
+ fputs(_(" -s, --shell <shell> run <shell> if @TERMUX_PREFIX@/etc/shells allows it\n"), stdout);
|
||||
fputs(_(" -P, --pty create a new pseudo-terminal\n"), stdout);
|
||||
|
||||
fputs(USAGE_SEPARATOR, stdout);
|
||||
diff --git a/login-utils/sulogin.c b/login-utils/sulogin.c
|
||||
index 45a558d..308e853 100644
|
||||
--- a/login-utils/sulogin.c
|
||||
+++ b/login-utils/sulogin.c
|
||||
@@ -813,7 +813,7 @@ static void sushell(struct passwd *pwd)
|
||||
if (pwd->pw_shell[0])
|
||||
su_shell = pwd->pw_shell;
|
||||
else
|
||||
- su_shell = "/bin/sh";
|
||||
+ su_shell = "@TERMUX_PREFIX@/bin/sh";
|
||||
}
|
||||
if ((p = strrchr(su_shell, '/')) == NULL)
|
||||
p = su_shell;
|
||||
@@ -863,9 +863,9 @@ static void sushell(struct passwd *pwd)
|
||||
execl(su_shell, shell, (char *)NULL);
|
||||
warn(_("failed to execute %s"), su_shell);
|
||||
|
||||
- xsetenv("SHELL", "/bin/sh", 1);
|
||||
- execl("/bin/sh", profile ? "-sh" : "sh", (char *)NULL);
|
||||
- warn(_("failed to execute %s"), "/bin/sh");
|
||||
+ xsetenv("SHELL", "@TERMUX_PREFIX@/bin/sh", 1);
|
||||
+ execl("@TERMUX_PREFIX@/bin/sh", profile ? "-sh" : "sh", (char *)NULL);
|
||||
+ warn(_("failed to execute %s"), "@TERMUX_PREFIX@/bin/sh");
|
||||
}
|
||||
|
||||
static void usage(void)
|
||||
diff --git a/login-utils/vipw.c b/login-utils/vipw.c
|
||||
index 5049706..958e044 100644
|
||||
--- a/login-utils/vipw.c
|
||||
+++ b/login-utils/vipw.c
|
||||
@@ -127,7 +127,7 @@ static FILE * pw_tmpfile(int lockfd)
|
||||
char *tmpname = NULL;
|
||||
int res;
|
||||
|
||||
- if ((fd = xfmkstemp(&tmpname, "/etc", ".vipw")) == NULL) {
|
||||
+ if ((fd = xfmkstemp(&tmpname, "@TERMUX_PREFIX@/etc", ".vipw")) == NULL) {
|
||||
ulckpwdf();
|
||||
err(EXIT_FAILURE, _("can't open temporary file"));
|
||||
}
|
||||
diff --git a/misc-utils/whereis.c b/misc-utils/whereis.c
|
||||
index d21b434..108bd15 100644
|
||||
--- a/misc-utils/whereis.c
|
||||
+++ b/misc-utils/whereis.c
|
||||
@@ -101,84 +101,18 @@ struct wh_dirlist {
|
||||
};
|
||||
|
||||
static const char *bindirs[] = {
|
||||
- "/usr/bin",
|
||||
- "/usr/sbin",
|
||||
- "/bin",
|
||||
- "/sbin",
|
||||
-#if defined(MULTIARCHTRIPLET)
|
||||
- "/lib/" MULTIARCHTRIPLET,
|
||||
- "/usr/lib/" MULTIARCHTRIPLET,
|
||||
- "/usr/local/lib/" MULTIARCHTRIPLET,
|
||||
-#endif
|
||||
- "/usr/lib",
|
||||
- "/usr/lib32",
|
||||
- "/usr/lib64",
|
||||
- "/etc",
|
||||
- "/usr/etc",
|
||||
- "/lib",
|
||||
- "/lib32",
|
||||
- "/lib64",
|
||||
- "/usr/games",
|
||||
- "/usr/games/bin",
|
||||
- "/usr/games/lib",
|
||||
- "/usr/emacs/etc",
|
||||
- "/usr/lib/emacs/*/etc",
|
||||
- "/usr/TeX/bin",
|
||||
- "/usr/tex/bin",
|
||||
- "/usr/interviews/bin/LINUX",
|
||||
-
|
||||
- "/usr/X11R6/bin",
|
||||
- "/usr/X386/bin",
|
||||
- "/usr/bin/X11",
|
||||
- "/usr/X11/bin",
|
||||
- "/usr/X11R5/bin",
|
||||
-
|
||||
- "/usr/local/bin",
|
||||
- "/usr/local/sbin",
|
||||
- "/usr/local/etc",
|
||||
- "/usr/local/lib",
|
||||
- "/usr/local/games",
|
||||
- "/usr/local/games/bin",
|
||||
- "/usr/local/emacs/etc",
|
||||
- "/usr/local/TeX/bin",
|
||||
- "/usr/local/tex/bin",
|
||||
- "/usr/local/bin/X11",
|
||||
-
|
||||
- "/usr/contrib",
|
||||
- "/usr/hosts",
|
||||
- "/usr/include",
|
||||
-
|
||||
- "/usr/g++-include",
|
||||
-
|
||||
- "/usr/ucb",
|
||||
- "/usr/old",
|
||||
- "/usr/new",
|
||||
- "/usr/local",
|
||||
- "/usr/libexec",
|
||||
- "/usr/share",
|
||||
-
|
||||
- "/opt/*/bin",
|
||||
+ "@TERMUX_PREFIX@/bin",
|
||||
NULL
|
||||
};
|
||||
|
||||
static const char *mandirs[] = {
|
||||
- "/usr/man/*",
|
||||
- "/usr/share/man/*",
|
||||
- "/usr/X386/man/*",
|
||||
- "/usr/X11/man/*",
|
||||
- "/usr/TeX/man/*",
|
||||
- "/usr/interviews/man/mann",
|
||||
- "/usr/share/info",
|
||||
+ "@TERMUX_PREFIX@/man/*",
|
||||
+ "@TERMUX_PREFIX@/share/info",
|
||||
NULL
|
||||
};
|
||||
|
||||
static const char *srcdirs[] = {
|
||||
- "/usr/src/*",
|
||||
- "/usr/src/lib/libc/*",
|
||||
- "/usr/src/lib/libc/net/*",
|
||||
- "/usr/src/ucb/pascal",
|
||||
- "/usr/src/ucb/pascal/utilities",
|
||||
- "/usr/src/undoc",
|
||||
+ "@TERMUX_PREFIX@/src/*",
|
||||
NULL
|
||||
};
|
||||
|
||||
diff --git a/sys-utils/eject.c b/sys-utils/eject.c
|
||||
index 6037ddc..b42c189 100644
|
||||
--- a/sys-utils/eject.c
|
||||
+++ b/sys-utils/eject.c
|
||||
@@ -152,7 +152,7 @@ static void __attribute__((__noreturn__)) usage(void)
|
||||
" -m, --no-unmount do not unmount device even if it is mounted\n"
|
||||
" -M, --no-partitions-unmount do not unmount another partitions\n"
|
||||
" -n, --noop don't eject, just show device found\n"
|
||||
- " -p, --proc use /proc/mounts instead of /etc/mtab\n"
|
||||
+ " -p, --proc use /proc/mounts instead of @TERMUX_PREFIX@/etc/mtab\n"
|
||||
" -q, --tape eject tape\n"
|
||||
" -r, --cdrom eject CD-ROM\n"
|
||||
" -s, --scsi eject SCSI device\n"
|
||||
@@ -661,11 +661,11 @@ static void umount_one(const struct eject_control *ctl, const char *name)
|
||||
if (drop_permissions() != 0)
|
||||
err(EXIT_FAILURE, _("drop permissions failed"));
|
||||
if (ctl->p_option)
|
||||
- execl("/bin/umount", "/bin/umount", name, "-n", (char *)NULL);
|
||||
+ execl("@TERMUX_PREFIX@/bin/umount", "@TERMUX_PREFIX@/bin/umount", name, "-n", (char *)NULL);
|
||||
else
|
||||
- execl("/bin/umount", "/bin/umount", name, (char *)NULL);
|
||||
+ execl("@TERMUX_PREFIX@/bin/umount", "@TERMUX_PREFIX@/bin/umount", name, (char *)NULL);
|
||||
|
||||
- errexec("/bin/umount");
|
||||
+ errexec("@TERMUX_PREFIX@/bin/umount");
|
||||
|
||||
case -1:
|
||||
warn( _("unable to fork"));
|
||||
diff --git a/sys-utils/fstrim.c b/sys-utils/fstrim.c
|
||||
index 96b7d2d..a97977d 100644
|
||||
--- a/sys-utils/fstrim.c
|
||||
+++ b/sys-utils/fstrim.c
|
||||
@@ -294,7 +294,7 @@ static int fstrim_all_from_file(struct fstrim_control *ctl, const char *filename
|
||||
return -1;
|
||||
}
|
||||
|
||||
- if (streq_paths(filename, "/etc/fstab"))
|
||||
+ if (streq_paths(filename, "@TERMUX_PREFIX@/etc/fstab"))
|
||||
fstab = 1;
|
||||
|
||||
/* de-duplicate by mountpoints */
|
||||
@@ -458,7 +458,7 @@ static void __attribute__((__noreturn__)) usage(void)
|
||||
|
||||
fputs(USAGE_OPTIONS, out);
|
||||
fputs(_(" -a, --all trim mounted filesystems\n"), out);
|
||||
- fputs(_(" -A, --fstab trim filesystems from /etc/fstab\n"), out);
|
||||
+ fputs(_(" -A, --fstab trim filesystems from @TERMUX_PREFIX@/etc/fstab\n"), out);
|
||||
fputs(_(" -I, --listed-in <list> trim filesystems listed in specified files\n"), out);
|
||||
fputs(_(" -o, --offset <num> the offset in bytes to start discarding from\n"), out);
|
||||
fputs(_(" -l, --length <num> the number of bytes to discard\n"), out);
|
||||
diff --git a/sys-utils/mount.c b/sys-utils/mount.c
|
||||
index dba6fca..fc65790 100644
|
||||
--- a/sys-utils/mount.c
|
||||
+++ b/sys-utils/mount.c
|
||||
@@ -498,11 +498,11 @@ static void __attribute__((__noreturn__)) usage(void)
|
||||
fputs(_(" -c, --no-canonicalize don't canonicalize paths\n"), out);
|
||||
fputs(_(" -f, --fake dry run; skip the mount(2) syscall\n"), out);
|
||||
fputs(_(" -F, --fork fork off for each device (use with -a)\n"), out);
|
||||
- fputs(_(" -T, --fstab <path> alternative file to /etc/fstab\n"), out);
|
||||
+ fputs(_(" -T, --fstab <path> alternative file to @TERMUX_PREFIX@/etc/fstab\n"), out);
|
||||
fputs(_(" -i, --internal-only don't call the mount.<type> helpers\n"), out);
|
||||
fputs(_(" -l, --show-labels show also filesystem labels\n"), out);
|
||||
fputs(_(" -m, --mkdir[=<mode>] alias to '-o X-mount.mkdir[=<mode>]'\n"), out);
|
||||
- fputs(_(" -n, --no-mtab don't write to /etc/mtab\n"), out);
|
||||
+ fputs(_(" -n, --no-mtab don't write to @TERMUX_PREFIX@/etc/mtab\n"), out);
|
||||
fputs(_(" --options-mode <mode>\n"
|
||||
" what to do with options loaded from fstab\n"), out);
|
||||
fputs(_(" --options-source <source>\n"
|
||||
diff --git a/sys-utils/setarch.c b/sys-utils/setarch.c
|
||||
index 1a255e4..2f0e6be 100644
|
||||
--- a/sys-utils/setarch.c
|
||||
+++ b/sys-utils/setarch.c
|
||||
@@ -471,7 +471,7 @@ int main(int argc, char *argv[])
|
||||
/* Don't use ifdef sparc here, we get "Unrecognized architecture"
|
||||
* error message later if necessary */
|
||||
if (strcmp(arch, "sparc32bash") == 0) {
|
||||
- shell = "/bin/bash";
|
||||
+ shell = "@TERMUX_PREFIX@/bin/bash";
|
||||
shell_arg = "";
|
||||
goto set_arch;
|
||||
}
|
||||
@@ -594,7 +594,7 @@ set_arch:
|
||||
verify_arch_domain(doms, target, arch);
|
||||
|
||||
if (!argc) {
|
||||
- shell = "/bin/sh";
|
||||
+ shell = "@TERMUX_PREFIX@/bin/sh";
|
||||
shell_arg = "-sh";
|
||||
}
|
||||
if (verbose) {
|
||||
diff --git a/sys-utils/setpriv.c b/sys-utils/setpriv.c
|
||||
index ddc2cc6..34cd0d9 100644
|
||||
--- a/sys-utils/setpriv.c
|
||||
+++ b/sys-utils/setpriv.c
|
||||
@@ -52,7 +52,7 @@
|
||||
#define SETPRIV_EXIT_PRIVERR 127 /* how we exit when we fail to set privs */
|
||||
|
||||
/* The shell to set SHELL env.variable if none is given in the user's passwd entry. */
|
||||
-#define DEFAULT_SHELL "/bin/sh"
|
||||
+#define DEFAULT_SHELL "@TERMUX_PREFIX@/bin/sh"
|
||||
|
||||
static gid_t get_group(const char *s, const char *err);
|
||||
|
||||
diff --git a/sys-utils/swapon.c b/sys-utils/swapon.c
|
||||
index 8735549..54955b8 100644
|
||||
--- a/sys-utils/swapon.c
|
||||
+++ b/sys-utils/swapon.c
|
||||
@@ -810,14 +810,14 @@ static void __attribute__((__noreturn__)) usage(void)
|
||||
fputs(_("Enable devices and files for paging and swapping.\n"), out);
|
||||
|
||||
fputs(USAGE_OPTIONS, out);
|
||||
- fputs(_(" -a, --all enable all swaps from /etc/fstab\n"), out);
|
||||
+ fputs(_(" -a, --all enable all swaps from @TERMUX_PREFIX@/etc/fstab\n"), out);
|
||||
fputs(_(" -d, --discard[=<policy>] enable swap discards, if supported by device\n"), out);
|
||||
fputs(_(" -e, --ifexists silently skip devices that do not exist\n"), out);
|
||||
fputs(_(" -f, --fixpgsz reinitialize the swap space if necessary\n"), out);
|
||||
fputs(_(" -o, --options <list> comma-separated list of swap options\n"), out);
|
||||
fputs(_(" -p, --priority <prio> specify the priority of the swap device\n"), out);
|
||||
fputs(_(" -s, --summary display summary about used swap devices (DEPRECATED)\n"), out);
|
||||
- fputs(_(" -T, --fstab <path> alternative file to /etc/fstab\n"), out);
|
||||
+ fputs(_(" -T, --fstab <path> alternative file to @TERMUX_PREFIX@/etc/fstab\n"), out);
|
||||
fputs(_(" --show[=<columns>] display summary in definable table\n"), out);
|
||||
fputs(_(" --noheadings don't print table heading (with --show)\n"), out);
|
||||
fputs(_(" --raw use the raw output format (with --show)\n"), out);
|
||||
diff --git a/sys-utils/umount.c b/sys-utils/umount.c
|
||||
index e579fb7..84d208e 100644
|
||||
--- a/sys-utils/umount.c
|
||||
+++ b/sys-utils/umount.c
|
||||
@@ -96,7 +96,7 @@ static void __attribute__((__noreturn__)) usage(void)
|
||||
fputs(_(" --fake dry run; skip the umount(2) syscall\n"), out);
|
||||
fputs(_(" -f, --force force unmount (in case of an unreachable NFS system)\n"), out);
|
||||
fputs(_(" -i, --internal-only don't call the umount.<type> helpers\n"), out);
|
||||
- fputs(_(" -n, --no-mtab don't write to /etc/mtab\n"), out);
|
||||
+ fputs(_(" -n, --no-mtab don't write to @TERMUX_PREFIX@/etc/mtab\n"), out);
|
||||
fputs(_(" -l, --lazy detach the filesystem now, clean up things later\n"), out);
|
||||
fputs(_(" -O, --test-opts <list> limit the set of filesystems (use with -a)\n"), out);
|
||||
fputs(_(" -R, --recursive recursively unmount a target with all its children\n"), out);
|
||||
diff --git a/tests/helpers/test_mkfds.c b/tests/helpers/test_mkfds.c
|
||||
index 194c175..772f748 100644
|
||||
--- a/tests/helpers/test_mkfds.c
|
||||
+++ b/tests/helpers/test_mkfds.c
|
||||
@@ -75,7 +75,7 @@ static void __attribute__((__noreturn__)) usage(FILE *out, int status)
|
||||
|
||||
fputs("\n", out);
|
||||
fputs("Examples:\n", out);
|
||||
- fprintf(out, "Using 3, open /etc/group:\n\n $ %s ro-regular-file 3 file=/etc/group\n\n",
|
||||
+ fprintf(out, "Using 3, open /system/etc/group:\n\n $ %s ro-regular-file 3 file=/system/etc/group\n\n",
|
||||
program_invocation_short_name);
|
||||
fprintf(out, "Using 3 and 4, make a pipe:\n\n $ %s pipe-no-fork 3 4\n\n",
|
||||
program_invocation_short_name);
|
||||
@@ -1901,7 +1901,7 @@ static const struct factory factories[] = {
|
||||
.name = "file",
|
||||
.type = PTYPE_STRING,
|
||||
.desc = "file to be opened",
|
||||
- .defv.string = "/etc/passwd",
|
||||
+ .defv.string = "/system/etc/passwd",
|
||||
},
|
||||
{
|
||||
.name = "offset",
|
||||
@@ -2095,7 +2095,7 @@ static const struct factory factories[] = {
|
||||
.name = "path",
|
||||
.type = PTYPE_STRING,
|
||||
.desc = "path for listening-socket bound to",
|
||||
- .defv.string = "/tmp/test_mkfds-unix-stream",
|
||||
+ .defv.string = "@TERMUX_PREFIX_CLASSICAL@/tmp/test_mkfds-unix-stream",
|
||||
},
|
||||
{
|
||||
.name = "backlog",
|
||||
@@ -2142,7 +2142,7 @@ static const struct factory factories[] = {
|
||||
.name = "path",
|
||||
.type = PTYPE_STRING,
|
||||
.desc = "path for unix non-stream bound to",
|
||||
- .defv.string = "/tmp/test_mkfds-unix-dgram",
|
||||
+ .defv.string = "@TERMUX_PREFIX_CLASSICAL@/tmp/test_mkfds-unix-dgram",
|
||||
},
|
||||
{
|
||||
.name = "abstract",
|
||||
@@ -2171,7 +2171,7 @@ static const struct factory factories[] = {
|
||||
.name = "path",
|
||||
.type = PTYPE_STRING,
|
||||
.desc = "path for unix non-stream bound to",
|
||||
- .defv.string = "/tmp/test_mkfds-unix-in-netns",
|
||||
+ .defv.string = "@TERMUX_PREFIX_CLASSICAL@/tmp/test_mkfds-unix-in-netns",
|
||||
},
|
||||
{
|
||||
.name = "abstract",
|
||||
diff --git a/text-utils/pg.c b/text-utils/pg.c
|
||||
index adb3840..6ba0231 100644
|
||||
--- a/text-utils/pg.c
|
||||
+++ b/text-utils/pg.c
|
||||
@@ -1364,7 +1364,7 @@ static void pgfile(FILE *f, const char *name)
|
||||
{
|
||||
const char *sh = getenv("SHELL");
|
||||
if (!sh)
|
||||
- sh = "/bin/sh";
|
||||
+ sh = "@TERMUX_PREFIX@/bin/sh";
|
||||
if (!nobuf)
|
||||
fclose(fbuf);
|
||||
fclose(find);
|
26
gpkg/util-linux/uuid-utils.subpackage.sh
Normal file
26
gpkg/util-linux/uuid-utils.subpackage.sh
Normal file
@ -0,0 +1,26 @@
|
||||
TERMUX_SUBPKG_DESCRIPTION="Utilities for handling universally unique identifiers"
|
||||
TERMUX_SUBPKG_DEPENDS="libsmartcols-glibc, libuuid-glibc, gcc-glibc-libs-dev"
|
||||
TERMUX_SUBPKG_DEPEND_ON_PARENT="no"
|
||||
TERMUX_SUBPKG_INCLUDE="
|
||||
glibc/share/man/man3/uuid_copy.3.gz
|
||||
glibc/share/man/man3/uuid_generate.3.gz
|
||||
glibc/share/man/man3/uuid.3.gz
|
||||
glibc/share/man/man3/uuid_generate_time_safe.3.gz
|
||||
glibc/share/man/man3/uuid_is_null.3.gz
|
||||
glibc/share/man/man3/uuid_compare.3.gz
|
||||
glibc/share/man/man3/uuid_parse.3.gz
|
||||
glibc/share/man/man3/uuid_time.3.gz
|
||||
glibc/share/man/man3/uuid_generate_time.3.gz
|
||||
glibc/share/man/man3/uuid_generate_random.3.gz
|
||||
glibc/share/man/man3/uuid_clear.3.gz
|
||||
glibc/share/man/man3/uuid_unparse.3.gz
|
||||
glibc/share/man/man1/uuidgen.1.gz
|
||||
glibc/share/man/man1/uuidparse.1.gz
|
||||
glibc/share/man/man8/uuidd.8.gz
|
||||
glibc/share/bash-completion/completions/uuidd
|
||||
glibc/share/bash-completion/completions/uuidgen
|
||||
glibc/share/bash-completion/completions/uuidparse
|
||||
glibc/bin/uuidd
|
||||
glibc/bin/uuidgen
|
||||
glibc/bin/uuidparse
|
||||
"
|
Reference in New Issue
Block a user