5682fe1229
Signed-off-by: root <root@dreamon.rixotstudio.cz>
37 lines
1.3 KiB
Bash
37 lines
1.3 KiB
Bash
# shellcheck shell=sh # Paludis doesn't expect shebang here, Written to be POSIX compatible
|
|
|
|
worldFile="/etc/paludis/world"
|
|
|
|
# Source bashrc
|
|
[ ! -d "/etc/paludis/bashrc" ] || . /etc/paludis/bashrc
|
|
|
|
###! This function expects PCRE RegEx expression from the world file
|
|
checkpkg() { ${GREP:-grep} -qP "$1" "$worldFile" ;}
|
|
|
|
# GIT
|
|
##@ +pcre = To get PCRE regex for 'git grep'
|
|
##@ +curl = Allows using http/https URI
|
|
checkpkg "^dev-scm\/git\$" && ${PRINTF:-printf} '%s\n' \
|
|
"dev-scm/git::arbor curl pcre" || true
|
|
|
|
checkpkg "^sys-apps\/sydbox\$" && ${PRINTF:-printf} '%s\n' \
|
|
"sys-apps/sydbox::arbor seccomp" || true
|
|
|
|
# BIND9
|
|
##@ caps = Fails to build without it (https://gitlab.exherbo.org/exherbo/arbor/-/issues/45)
|
|
checkpkg "^net-dns\/bind\$" && ${PRINTF:-printf} '%s\n' \
|
|
"net-dns/bind::arbor caps" || true
|
|
|
|
# SSH
|
|
##@ X509 = To generate X.509 certs
|
|
##@ lsns = For DNSSEC support (according to exherbo)
|
|
checkpkg "^net-misc\/openssh\$" && ${PRINTF:-printf} '%s\n' \
|
|
"net-misc/openssh::arbor X509 ldns" || true
|
|
|
|
# Jobs
|
|
${PRINTF:-printf} "*/* BUILD_OPTIONS: jobs=%s\\n" "$(${NPROC:-nproc} || ${PRINTF:-printf} 1)"
|
|
|
|
# CPU flags
|
|
AMD64_CPU_FEATURES="$(${CAT:-cat} /proc/cpuinfo | ${GREP:-grep} -m 1 flags | ${SED:-sed} 's/^flags.*: //g')"
|
|
X86_CPU_FEATURES="$(${CAT:-cat} /proc/cpuinfo | ${GREP:-grep} -m 1 flags | ${SED:-sed} 's/^flags.*: //g')"
|