add a --root option so we can generate with DESTDIR installs --- a/image/usr/sbin/update-ca-certificates +++ b/image/usr/sbin/update-ca-certificates @@ -30,6 +30,8 @@ LOCALCERTSDIR=/usr/local/share/ca-certificates CERTBUNDLE=ca-certificates.crt ETCCERTSDIR=/etc/ssl/certs HOOKSDIR=/etc/ca-certificates/update.d +ROOT="" +RELPATH="" while [ $# -gt 0 ]; do @@ -59,13 +61,25 @@ do --hooksdir) shift HOOKSDIR="$1";; + --root|-r) + shift + # Needed as c_rehash wants to read the files directly. + # This gets us from $CERTSCONF to $CERTSDIR. + RELPATH="../../.." + ROOT=$(readlink -f "$1");; --help|-h|*) - echo "$0: [--verbose] [--fresh]" + echo "$0: [--verbose] [--fresh] [--root