osi-tools/test/mod-reproducible.sh

21 lines
833 B
Bash

#!/hint/bash -euE
# Copyright (C) 2023-2024 Umorpha Systems
# SPDX-License-Identifier: AGPL-3.0-or-later
post_install+=(79:reproducible:rm)
reproducible:rm() {
local arg_mountpoint=$1
# Base images are not currently reproducible, because of the files:
# - /etc/ssl/certs/java/cacerts
# source: ca-certificate-utils:/usr/share/libalpm/hooks/40-update-ca-trust.hook -> ca-certificate-utils:/usr/bin/update-ca-trust -> p11-kit:/usr/bin/trust
# solution: should contribute a patch to p11-kit to make it reproducible
rm -f -- "$arg_mountpoint"/etc/ssl/certs/java/cacerts
# - /var/cache/ldconfig/aux-cache
# source: /var/lib/pacman/local/glibc-*/install -> glibc:/usr/bin/ldconfig
# solution: should contribute a patch to glibc to make it reproducible
rm -f -- "$arg_mountpoint"/var/cache/ldconfig/aux-cache
}