logo

overlay

My own overlay for experimentations, use with caution, no support is provided git clone https://hacktivis.me/git/overlay.git

opensmtpd-6.7.1_p1.ebuild (1792B)


  1. # Copyright 1999-2020 Gentoo Authors
  2. # Copyright 2018-2020 Haelwenn (lanodan) Monnier <contact@hacktivis.me>
  3. # Distributed under the terms of the GNU General Public License v2
  4. EAPI=7
  5. inherit pam systemd
  6. DESCRIPTION="Lightweight but featured SMTP daemon from OpenBSD"
  7. HOMEPAGE="https://www.opensmtpd.org"
  8. SRC_URI="https://www.opensmtpd.org/archives/${P/_}.tar.gz"
  9. LICENSE="ISC BSD BSD-1 BSD-2 BSD-4"
  10. SLOT="0"
  11. KEYWORDS="~amd64"
  12. IUSE="pam +mta"
  13. DEPEND="
  14. acct-user/smtpd
  15. acct-user/smtpq
  16. >=dev-libs/openssl-1.1.0:0=
  17. sys-libs/zlib
  18. pam? ( sys-libs/pam )
  19. elibc_musl? (
  20. sys-libs/fts-standalone
  21. sys-libs/queue-standalone
  22. )
  23. sys-libs/db:=
  24. dev-libs/libevent
  25. app-misc/ca-certificates
  26. net-mail/mailbase
  27. net-libs/libasr
  28. !mail-mta/courier
  29. !mail-mta/esmtp
  30. !mail-mta/exim
  31. !mail-mta/mini-qmail
  32. !mail-mta/msmtp[mta]
  33. !mail-mta/netqmail
  34. !mail-mta/nullmailer
  35. !mail-mta/postfix
  36. !mail-mta/qmail-ldap
  37. !mail-mta/sendmail
  38. !mail-mta/ssmtp[mta]
  39. "
  40. RDEPEND="${DEPEND}"
  41. S=${WORKDIR}/${P/_}
  42. src_configure() {
  43. econf \
  44. --sysconfdir=/etc/opensmtpd \
  45. --with-path-mbox=/var/spool/mail \
  46. --with-path-empty=/var/empty \
  47. --with-path-socket=/run \
  48. --with-path-CAfile=/etc/ssl/certs/ca-certificates.crt \
  49. --with-user-smtpd=smtpd \
  50. --with-user-queue=smtpq \
  51. --with-group-queue=smtpq \
  52. --with-mantype=doc \
  53. $(use_with pam auth-pam)
  54. }
  55. src_install() {
  56. default
  57. newinitd "${FILESDIR}"/smtpd.initd smtpd
  58. systemd_dounit "${FILESDIR}"/smtpd.{service,socket}
  59. use pam && newpamd "${FILESDIR}"/smtpd.pam smtpd
  60. dosym /usr/sbin/smtpctl /usr/sbin/makemap
  61. dosym /usr/sbin/smtpctl /usr/sbin/newaliases
  62. if use mta ; then
  63. dodir /usr/sbin
  64. dosym /usr/sbin/smtpctl /usr/sbin/sendmail
  65. dosym /usr/sbin/smtpctl /usr/bin/sendmail
  66. dosym /usr/sbin/smtpctl /usr/$(get_libdir)/sendmail
  67. fi
  68. }