chiark / gitweb /
b0e353342a426399c5a86cc90ddc5867b8dd1d01
[termux-packages] / disabled-packages / apt / cmdline-apt-key.in.patch
1 --- ../cache/apt-1.4.7/cmdline/apt-key.in       2017-07-14 07:45:39.000000000 +1000
2 +++ ./cmdline/apt-key.in        2017-07-19 17:43:09.131197161 +1000
3 @@ -16,10 +16,7 @@
4  aptkey_echo() { echo "$@"; }
5  
6  requires_root() {
7 -       if [ "$(id -u)" -ne 0 ]; then
8 -               apt_error "This command can only be used by root."
9 -               exit 1
10 -       fi
11 +continue
12  }
13  
14  command_available() {
15 @@ -260,7 +257,7 @@
16         if accessible_file_exists "$TRUSTEDFILE"; then
17             $ACTION "$TRUSTEDFILE" "$@"
18         fi
19 -       local TRUSTEDPARTS="/etc/apt/trusted.gpg.d"
20 +       local TRUSTEDPARTS="/data/data/com.termux/files/usr/etc/apt/trusted.gpg.d"
21         eval "$(apt-config shell TRUSTEDPARTS Dir::Etc::TrustedParts/d)"
22         if [ -d "$TRUSTEDPARTS" ]; then
23             TRUSTEDPARTS="$(readlink -f "$TRUSTEDPARTS")"
24 @@ -542,7 +539,7 @@
25  done
26  
27  if [ -z "$TRUSTEDFILE" ]; then
28 -   TRUSTEDFILE="/etc/apt/trusted.gpg"
29 +   TRUSTEDFILE="/data/data/com.termux/files/usr/etc/apt/trusted.gpg"
30     eval $(apt-config shell TRUSTEDFILE Apt::GPGV::TrustedKeyring)
31     eval $(apt-config shell TRUSTEDFILE Dir::Etc::Trusted/f)
32  fi