mail-client/s-nail: 14.9.25

Signed-off-by: Sebastian Pipping <sping@gentoo.org>
This commit is contained in:
Sebastian Pipping
2025-02-22 23:50:13 +01:00
parent d085695767
commit 4e416257f9
2 changed files with 107 additions and 0 deletions

View File

@@ -1 +1,2 @@
DIST s-nail-14.9.24.tar.xz 803100 BLAKE2B 4d82c747ff082a1a13d8832eb2bf1e96f05d6b3cf61c77a67bc061b1971032b41d8f5fe5520b96b9b74bc4d0661a4a9ef0f8f93b5e7b9eef66906b78260cef2f SHA512 03f6a6f446391b6f91ed3c8875c3e7fdfac9d4e77ea1d52a7e98aa84cfd0edae137d5b9afba3bdc9a31ab67cee5237930b74b42ae3acb54aee4758553a4f1df2
DIST s-nail-14.9.25.tar.xz 804608 BLAKE2B a1839395318296f0869dd37927bed62d26efa1c0a1ec27fc34e9b951940f56f8ad5802b52f9af2d564c6b99c1e5add3f13e5ed6bd0f13a5cd8cddd29acae4894 SHA512 a0fdcc6af0bbf0611f3e6e20ad81e2a44a0e610d896a3227d2ebf83e78e28faa9414edb79978c88ad396fe804717a5df55728c5a54b0432dca95769ad667950e

View File

@@ -0,0 +1,106 @@
# Copyright 1999-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit toolchain-funcs flag-o-matic
DESCRIPTION="Enhanced mailx-compatible mail client based on Heirloom mailx (nail)"
HOMEPAGE="https://www.sdaoden.eu/code.html"
SRC_URI="https://ftp.sdaoden.eu/${P}.tar.xz"
LICENSE="BSD BSD-4 ISC RSA"
SLOT="0"
KEYWORDS="~amd64 ~loong ~ppc64 ~riscv ~x86 ~amd64-linux ~x86-linux"
IUSE="idn kerberos net +split-usr ssl"
RDEPEND="
sys-libs/ncurses:0=
virtual/libiconv
idn? ( net-dns/libidn2 )
net? (
ssl? ( dev-libs/openssl:0= )
kerberos? ( virtual/krb5 )
)
!mail-client/mailx
!net-mail/mailutils
"
DEPEND="${RDEPEND}"
BDEPEND="
app-arch/xz-utils[extra-filters(+)]
app-alternatives/awk
"
src_configure() {
has_cflag() {
local x var="CFLAGS[*]"
for x in ${!var} ; do
[[ ${x} == $1 ]] && return 0
done
return 1
}
# Fails to build without replace Bug 860357
replace-flags -O[0gs] -O1
# A valid -O option is necessary Bug 888613
has_cflag -O* || append-cflags -O1
append-cflags -std=c99
local confopts=(
CC="$(tc-getCC)"
strip=/bin/true
OPT_AUTOCC=no
VAL_PREFIX="${EPREFIX}"/usr
VAL_SYSCONFDIR="${EPREFIX}"/etc
VAL_MTA="${EPREFIX}/usr/sbin/sendmail"
VAL_MAIL='/var/spool/mail'
VAL_PAGER=less
$(usex idn VAL_IDNA=idn2 OPT_IDNA=no)
VERBOSE=1
)
if use net; then
confopts+=( OPT_TLS=$(usex ssl require no)
OPT_GSSAPI=$(usex kerberos require no)
)
else
confopts+=( OPT_NET=no )
fi
tc-is-cross-compiler && confopts+=( OPT_CROSS_BUILD=yes )
# Cannot use emake or bad options saved Bug 879065
make "${confopts[@]}" config || die
}
src_compile() {
emake build
}
src_install() {
# Use /usr/sbin/sendmail by default and provide an example
cat <<- EOSMTP >> nail.rc
# Use the local sendmail (/usr/sbin/sendmail) binary by default.
# (Uncomment the following line to use a SMTP server)
#set smtp=localhost
# Ask for CC: list too.
set askcc
EOSMTP
emake DESTDIR="${D}" install
dodoc INSTALL NEWS README THANKS
if use split-usr ; then
dodir /bin
dosym ../usr/bin/mailx /bin/mail
fi
dosym s-nail /usr/bin/mailx
dosym mailx /usr/bin/mail
dosym mailx /usr/bin/Mail
dosym s-nail.1 /usr/share/man/man1/mailx.1
dosym mailx.1 /usr/share/man/man1/mail.1
dosym mailx.1 /usr/share/man/man1/Mail.1
}