summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnthony G. Basile <blueness@gentoo.org>2021-05-23 03:43:41 -0400
committerAnthony G. Basile <blueness@gentoo.org>2021-05-23 03:43:41 -0400
commit9afbbef89d431b8373a95021042b386554be313d (patch)
tree9e1db1f57db85718dc7df920e57f54784759547f /www-apps
parentmedia-video/mkvtoolnix: fix OOM during build (diff)
downloadgentoo-9afbbef89d431b8373a95021042b386554be313d.tar.gz
gentoo-9afbbef89d431b8373a95021042b386554be313d.tar.bz2
gentoo-9afbbef89d431b8373a95021042b386554be313d.zip
www-apps/moodle: add version 3.11
Package-Manager: Portage-3.0.18, Repoman-3.0.2 Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
Diffstat (limited to 'www-apps')
-rw-r--r--www-apps/moodle/Manifest1
-rw-r--r--www-apps/moodle/moodle-3.11.ebuild120
2 files changed, 121 insertions, 0 deletions
diff --git a/www-apps/moodle/Manifest b/www-apps/moodle/Manifest
index 03ea2c6f137a..2d14e2de188d 100644
--- a/www-apps/moodle/Manifest
+++ b/www-apps/moodle/Manifest
@@ -1,4 +1,5 @@
DIST moodle-3.10.3.tgz 57483053 BLAKE2B a5129f45c4fdf101df7c96885a8c5cec7cad797a545d5a3fae621f5868cafcf3e9f1cdf06f16e689ccfe0e2bcab6fabd65a5fd45ef178f313176ca5e23350cd9 SHA512 934d42b6fc29c2c9ebcddf788c3e983c3bade77f5d2dbb28a612b17d263a67fd08c0f2a5983bbc1a87054d965cabc3c7257a940febec73f1df72bc7e586cd321
+DIST moodle-3.11.tgz 59365522 BLAKE2B f9a2f77dd851efd740b924e51de6b882955101834ca4201bf2fd243ddd8dbe403d1054dcebb5c3022e941fe9f7d119b285d6e955cdb871288cb3b0e40eb9de07 SHA512 69509d57990bf9cca7a262b78f6beb0d90d89e5d93018fd306f662d32303dd39cc0a14b2eee0d58e8f420766cf0acbeeaf6e1f7d43de6b99d0999747b438ee5a
DIST moodle-3.5.18.tgz 46812954 BLAKE2B fc13835e9d40236b2d572f344870999cd9ea60d11a043428acacc34362fbf114c2253083a6165dc800bca9c5cbb9cefeb4f7f76111a880348bf7b0988cdda8c7 SHA512 8336ba4dd638410e0697e1ee0c9715f166d934ae1325079e5b14e6e7959e32426103bb1af1e1e80ced3764e5c49ccea254de590f729762e417b21dab3f1b849c
DIST moodle-3.8.9.tgz 53320016 BLAKE2B 5c0c54f5a57eea97c591d75088fe89e8e12df1e233f99c7025fb4e3720a27aa8133ccd25b25876faf2335497827ca748579607dbb2d52c01043fd59854f6dba4 SHA512 ec0bc22d82ae2afb69d491df75011568dba771cc2cbab988dbfe9bc1c4daa6d5e947ca8b9d71acabecd9c57d25202d79321abf1cdda6908ad32511db6c107289
DIST moodle-3.9.6.tgz 57105713 BLAKE2B 26b5334eda2fac641020459b8471db692f7202acc62b72e11a43fdb3893dadcf2150af7c82659c408ab9ee4660b766498c2c3005f8b43ed980ecefd60263e581 SHA512 0c66070f9cf422a6ed11ac6ff067aba294bc7f4d4b5a17f729c4e4fbb060b59ee232a4a87996557afaa7c6646bfcc3c14736ff4cb18b20a8a31386cc40a61d7f
diff --git a/www-apps/moodle/moodle-3.11.ebuild b/www-apps/moodle/moodle-3.11.ebuild
new file mode 100644
index 000000000000..cf74bb2c1bd0
--- /dev/null
+++ b/www-apps/moodle/moodle-3.11.ebuild
@@ -0,0 +1,120 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="7"
+
+inherit webapp
+
+MY_BRANCH="stable$(ver_cut 1)$(ver_cut 2)"
+
+DESCRIPTION="The Moodle Course Management System"
+HOMEPAGE="https://moodle.org"
+SRC_URI="https://download.moodle.org/${MY_BRANCH}/${P}.tgz"
+S="${WORKDIR}/${PN}"
+
+LICENSE="GPL-3+"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86"
+#SLOT empty due to webapp
+
+DB_FLAGS="mysqli?,mssql?,postgres?"
+DB_TYPES=${DB_FLAGS//\?/}
+DB_TYPES=${DB_TYPES//,/ }
+
+AUTHENTICATION_FLAGS="imap?,ldap?,odbc?"
+AUTHENTICATION_MODES=${AUTHENTICATION_FLAGS//\?/}
+AUTHENTICATION_MODES=${AUTHENTICATION_MODES//,/ }
+
+PHP_REQUIRED_FLAGS="ctype,curl,iconv,json,session,simplexml,xml,zip"
+PHP_OPTIONAL_FLAGS="gd,intl,soap,ssl,tokenizer,xmlrpc"
+PHP_FLAGS="${PHP_REQUIRED_FLAGS},${PHP_OPTIONAL_FLAGS}"
+
+IUSE="${DB_TYPES} ${AUTHENTICATION_MODES} vhosts"
+
+# No forced dependency on
+# mssql? - lives on a windows server
+# mysql? ( virtual/mysql )
+# postgres? ( dev-db/postgresql-server-9* )
+# which may live on another server. These USE flags affect the configuration
+# file and the dependency on php. However other dbs are possible. See config.php
+# and the moodle documentation for other possibilities.
+DEPEND=""
+RDEPEND="
+ >=dev-lang/php-7.3[${DB_FLAGS},${AUTHENTICATION_FLAGS},${PHP_FLAGS}]
+ virtual/httpd-php
+ virtual/cron"
+
+pkg_setup() {
+ webapp_pkg_setup
+
+ # How many dbs were selected? If one and only one, which one is it?
+ MYDB=""
+ DB_COUNT=0
+ for db in ${DB_TYPES}; do
+ if use ${db}; then
+ MYDB=${db}
+ DB_COUNT=$(($DB_COUNT+1))
+ fi
+ done
+
+ if [[ ${DB_COUNT} -eq 0 ]]; then
+ eerror
+ eerror "No database selected in your USE flags,"
+ eerror "You must select at least one."
+ eerror
+ die
+ fi
+
+ if [[ ${DB_COUNT} -gt 1 ]]; then
+ MYDB=""
+ ewarn
+ ewarn "Multiple databases selected in your USE flags,"
+ ewarn "You will have to choose your database manually."
+ ewarn
+ fi
+}
+
+src_prepare() {
+ rm COPYING.txt
+ cp "${FILESDIR}"/config-r1.php config.php
+
+ # Moodle expect pgsql, not postgres
+ MYDB=${MYDB/postgres/pgsql}
+
+ if [[ ${DB_COUNT} -eq 1 ]] ; then
+ sed -i -e "s|mydb|${MYDB}|" config.php
+ fi
+
+ eapply_user
+}
+
+src_install() {
+ webapp_src_preinst
+
+ local MOODLEDATA="${MY_HOSTROOTDIR}"/moodle
+ dodir ${MOODLEDATA}
+ webapp_serverowned -R "${MOODLEDATA}"
+
+ local MOODLEROOT="${MY_HTDOCSDIR}"
+ insinto ${MOODLEROOT}
+ doins -r *
+
+ webapp_configfile "${MOODLEROOT}"/config.php
+
+ if [[ ${DB_COUNT} -eq 1 ]]; then
+ webapp_postinst_txt en "${FILESDIR}"/postinstall-en.txt
+ else
+ webapp_postinst_txt en "${FILESDIR}"/postinstall-nodb-en.txt
+ fi
+
+ webapp_src_install
+}
+
+pkg_postinst() {
+ einfo
+ einfo
+ einfo "To see the post install instructions, do"
+ einfo
+ einfo " webapp-config --show-postinst ${PN} ${PVR}"
+ einfo
+ einfo
+}