public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Sam James" <sam@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: net-irc/anope/
Date: Mon, 12 Oct 2020 20:05:42 +0000 (UTC)	[thread overview]
Message-ID: <1602533134.4bf674c6b01a14cb375cbdbb495822f3aa2a0a7f.sam@gentoo> (raw)

commit:     4bf674c6b01a14cb375cbdbb495822f3aa2a0a7f
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Mon Oct 12 20:05:34 2020 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Mon Oct 12 20:05:34 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4bf674c6

net-irc/anope: bump to 2.0.8

Package-Manager: Portage-3.0.8, Repoman-3.0.1
Signed-off-by: Sam James <sam <AT> gentoo.org>

 net-irc/anope/Manifest           |   1 +
 net-irc/anope/anope-2.0.8.ebuild | 152 +++++++++++++++++++++++++++++++++++++++
 2 files changed, 153 insertions(+)

diff --git a/net-irc/anope/Manifest b/net-irc/anope/Manifest
index 335593c6ec6..7f9843c097e 100644
--- a/net-irc/anope/Manifest
+++ b/net-irc/anope/Manifest
@@ -1 +1,2 @@
 DIST anope-2.0.7-source.tar.gz 1817484 BLAKE2B 13a4628db8cb885d4636ab1897aab322f7846740e4a3fccd02a417d84a8eb3c942aebf5e0a51f8ca1108f455b44b4e280e7386b42e03f640c9b0e68943252814 SHA512 22a9f3e0d9fe7f68304062829a19b693a3414f94c90f8da601ab98995cbff7310dc22ca40749d50d6722dfb4649817d2f4b1dbe4afa3254b28980f03a491de65
+DIST anope-2.0.8.tar.gz 1808747 BLAKE2B f4413fdd151498c7521df175b88cc693a00de8ee3960962f79affd8cb821d428f12145dcc444c75e5940ea80ea22591048c313d7cda32570ed7a941e37e27334 SHA512 ddb42a453d72327d2256e5963f720bb310a7524c01661a0a136f18c539813649889e9fb764077c86e0854de8e3da095ebabb1ba53a0538d679bd42ea6403823b

diff --git a/net-irc/anope/anope-2.0.8.ebuild b/net-irc/anope/anope-2.0.8.ebuild
new file mode 100644
index 00000000000..d7c7c0caf69
--- /dev/null
+++ b/net-irc/anope/anope-2.0.8.ebuild
@@ -0,0 +1,152 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit cmake
+
+DESCRIPTION="Anope IRC Services"
+HOMEPAGE="https://anope.org/ https://github.com/anope/anope/"
+SRC_URI="https://github.com/anope/anope/archive/${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~x86"
+IUSE="gnutls ldap mysql pcre sql sqlite ssl tre"
+REQUIRED_USE="sql? ( || ( mysql sqlite ) )"
+
+BDEPEND="sys-devel/gettext"
+DEPEND="
+	acct-group/anope
+	acct-user/anope
+	mysql? ( dev-db/mysql-connector-c:0= )
+	ssl? ( dev-libs/openssl:0= )
+	gnutls? (
+		net-libs/gnutls:0=
+		dev-libs/libgcrypt:0=
+	)
+	ldap? ( net-nds/openldap )
+	pcre? ( dev-libs/libpcre )
+	sqlite? ( dev-db/sqlite:3 )
+	tre? ( dev-libs/tre )
+	virtual/libintl
+"
+RDEPEND="${DEPEND}"
+
+PATCHES=(
+	"${FILESDIR}/${PN}-2.0.6-example.conf-pid-path.patch"
+	"${FILESDIR}/${PN}-2.0.7-example.conf-user.patch"
+)
+
+src_prepare() {
+	anope_enable_mod() {
+		local modulefile=${1}
+		ln -s "extra/${modulefile}" "modules/" || \
+			die "Failed to use ${modulefile}"
+	}
+
+	# These all require MySQL specifically
+	if use mysql ; then
+		anope_enable_mod "m_mysql.cpp"
+		anope_enable_mod "stats/irc2sql/irc2sql.cpp"
+		anope_enable_mod "stats/irc2sql/irc2sql.h"
+		anope_enable_mod "stats/irc2sql/tables.cpp"
+		anope_enable_mod "stats/irc2sql/utils.cpp"
+		anope_enable_mod "stats/m_chanstats.cpp"
+		anope_enable_mod "stats/cs_fantasy_top.cpp"
+		anope_enable_mod "stats/cs_fantasy_stats.cpp"
+		anope_enable_mod "m_sql_log.cpp"
+		anope_enable_mod "m_sql_oper.cpp"
+	fi
+
+	use sqlite && anope_enable_mod "m_sqlite.cpp"
+
+	# Any SQL implementation
+	if use sql ; then
+		anope_enable_mod "m_sql_authentication.cpp"
+	fi
+
+	if use ldap ; then
+		anope_enable_mod "m_ldap.cpp"
+		anope_enable_mod "m_ldap_authentication.cpp"
+		anope_enable_mod "m_ldap_oper.cpp"
+	fi
+
+	use gnutls && anope_enable_mod "m_ssl_gnutls.cpp"
+	use pcre && anope_enable_mod "m_regex_pcre.cpp"
+	use ssl && anope_enable_mod "m_ssl_openssl.cpp"
+	use tre && anope_enable_mod "m_regex_tre.cpp"
+
+	# Unconditional modules
+	anope_enable_mod "m_regex_posix.cpp"
+
+	# Avoid a silly sandbox error - tries to delete /usr/lib/modules
+	sed -i '/install.*REMOVE_RECURSE.*/d' CMakeLists.txt || die
+
+	# Copy anope.conf for fixup to comply w/ prefix
+	cp "${FILESDIR}/anope-conf.d-v2" "${T}" || die
+
+	# Look in the right place for modules
+	sed -i "s~%LIBDIR%~${EPREFIX}/usr/$(get_libdir)/anope/~" \
+		"${T}/anope-conf.d-v2" || die
+
+	cmake_src_prepare
+}
+
+src_configure() {
+	local mycmakeargs=(
+		-DBIN_DIR="libexec/anope"
+		-DDB_DIR="../var/lib/anope"
+		-DDOC_DIR="share/doc/${PF}"
+		-DLIB_DIR="$(get_libdir)/anope"
+		-DLOCALE_DIR="share/locale"
+		-DCONF_DIR="/etc/anope"
+		-DLOGS_DIR="../var/log/anope/"
+	)
+
+	cmake_src_configure
+}
+
+src_install() {
+	cmake_src_install
+
+	newinitd "${FILESDIR}/anope-init.d" "${PN}"
+	newconfd "${T}/anope-conf.d-v2" "${PN}"
+
+	dosym ../libexec/anope/services /usr/bin/services
+	dosym ../libexec/anope/anopesmtp /usr/bin/anopesmtp
+
+	keepdir /var/log/anope /var/lib/anope/backups
+	fowners anope:anope /var/{lib,log}/anope /var/lib/anope/backups
+
+	dodoc -r docs/* data/example.conf
+
+	insinto /etc/anope
+	newins data/example.conf services.conf
+
+	fowners anope:anope /var/log/anope
+	fowners anope:anope /var/lib/anope/backups/
+}
+
+pkg_postinst() {
+	if [[ -z "${REPLACING_VERSIONS}" ]] ; then
+		# Only tell them about this on a fresh install.
+		elog
+		ewarn "Anope won't run out of the box, you still have to configure it to match your IRCd's configuration."
+		ewarn "Edit /etc/anope/services.conf to configure Anope."
+		elog
+	else
+		# We're replacing some versions. Find out which.
+		local ver
+		for ver in "${REPLACING_VERSIONS}" ; do
+			if ver_test ${ver} -lt 2.0.7 ; then
+				# In this version, we introduced correct FHS structure
+				# We need the users to make some changes to their services.conf
+				ewarn "Please modify your services.conf to include the following directive:"
+				ewarn "in options{}, please include user=\"anope\" and group=\"anope\""
+				ewarn "This is needed because Anope now starts as root and drops down."
+				ewarn "Reference: https://wiki.anope.org/index.php/2.0/Configuration#Services_Process_Options"
+			fi
+		done
+	fi
+}


             reply	other threads:[~2020-10-12 20:05 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-12 20:05 Sam James [this message]
  -- strict thread matches above, loose matches on Subject: below --
2023-11-25  4:49 [gentoo-commits] repo/gentoo:master commit in: net-irc/anope/ Sam James
2023-08-07  5:06 Sam James
2023-07-15  6:08 Sam James
2023-07-15  3:10 Sam James
2023-07-13  6:53 Sam James
2023-07-13  6:53 Sam James
2023-06-09 13:40 Sam James
2022-09-23  1:35 Sam James
2022-05-28 16:07 Jakov Smolić
2022-05-28 10:03 Jakov Smolić
2022-05-28 10:03 Jakov Smolić
2022-05-28 10:02 Jakov Smolić
2022-04-23  1:53 Sam James
2022-03-23  0:45 Sam James
2022-02-25 20:53 Sam James
2022-01-01 11:07 Sam James
2022-01-01  9:38 Sam James
2021-09-12 23:00 Sam James
2021-09-12 23:00 Sam James
2021-08-09 22:21 Sam James
2020-12-20  6:29 Sam James
2020-12-16 20:34 Sam James
2020-10-24  6:39 Sam James
2020-08-30  5:44 Sam James
2020-07-08 20:50 Sam James
2020-06-06 18:01 Michał Górny
2020-05-13 11:31 Agostino Sarubbo
2020-05-13 11:27 Agostino Sarubbo
2020-05-08  6:25 Mart Raudsepp
2020-05-05 13:07 Thomas Deutschmann
2019-09-23  8:07 Michał Górny
2019-08-11 11:20 David Seifert
2018-03-13 11:59 Pacho Ramos

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1602533134.4bf674c6b01a14cb375cbdbb495822f3aa2a0a7f.sam@gentoo \
    --to=sam@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox