Gentoo Archives: gentoo-commits

From: "Anthony G. Basile" <blueness@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] dev/blueness:master commit in: www-apps/moodle/files/, www-apps/moodle/
Date: Sun, 29 Jan 2012 03:11:25
Message-Id: 077fb0d002bbc03eab41404dfaae872ffc26f9ba.blueness@gentoo
1 commit: 077fb0d002bbc03eab41404dfaae872ffc26f9ba
2 Author: Anthony G. Basile <blueness <AT> gentoo <DOT> org>
3 AuthorDate: Sun Jan 29 03:11:11 2012 +0000
4 Commit: Anthony G. Basile <blueness <AT> gentoo <DOT> org>
5 CommitDate: Sun Jan 29 03:11:11 2012 +0000
6 URL: http://git.overlays.gentoo.org/gitweb/?p=dev/blueness.git;a=commit;h=077fb0d0
7
8 www-apps/moodle: moved to tree
9
10 ---
11 www-apps/moodle/ChangeLog | 17 --
12 www-apps/moodle/Manifest | 13 --
13 www-apps/moodle/files/config.php | 29 ----
14 www-apps/moodle/files/postinstall-en.txt | 220 -------------------------
15 www-apps/moodle/files/postinstall-nodb-en.txt | 6 -
16 www-apps/moodle/metadata.xml | 9 -
17 www-apps/moodle/moodle-1.9.16-r1.ebuild | 122 --------------
18 www-apps/moodle/moodle-2.0.7-r1.ebuild | 126 --------------
19 www-apps/moodle/moodle-2.1.4-r1.ebuild | 126 --------------
20 www-apps/moodle/moodle-2.2.1-r1.ebuild | 126 --------------
21 10 files changed, 0 insertions(+), 794 deletions(-)
22
23 diff --git a/www-apps/moodle/ChangeLog b/www-apps/moodle/ChangeLog
24 deleted file mode 100644
25 index 4069a30..0000000
26 --- a/www-apps/moodle/ChangeLog
27 +++ /dev/null
28 @@ -1,17 +0,0 @@
29 -
30 -
31 - 29 Jan 2012; Anthony G. Basile <blueness@g.o> moodle-1.9.16-r1.ebuild,
32 - moodle-2.0.7-r1.ebuild, moodle-2.1.4-r1.ebuild, moodle-2.2.1-r1.ebuild:
33 - testing bug #400853
34 -
35 -*moodle-2.2.1-r1 (16 Jan 2012)
36 -*moodle-2.1.4-r1 (16 Jan 2012)
37 -*moodle-2.0.7-r1 (16 Jan 2012)
38 -*moodle-1.9.16-r1 (16 Jan 2012)
39 -
40 - 16 Jan 2012; Anthony G. Basile <blueness@g.o>
41 - +moodle-1.9.16-r1.ebuild, +moodle-2.0.7-r1.ebuild, +moodle-2.1.4-r1.ebuild,
42 - +moodle-2.2.1-r1.ebuild, +files/config.php, +files/postinstall-en.txt,
43 - +files/postinstall-nodb-en.txt, +metadata.xml:
44 - Removed gd-external, fix depend on >=php5.3* for moodle 2.1* and 2.2*
45 -
46
47 diff --git a/www-apps/moodle/Manifest b/www-apps/moodle/Manifest
48 deleted file mode 100644
49 index 819b1e5..0000000
50 --- a/www-apps/moodle/Manifest
51 +++ /dev/null
52 @@ -1,13 +0,0 @@
53 -AUX config.php 718 RMD160 9e4b97aafca65da8648466d11728c457fff439ab SHA1 d71fc86158e82f706ca2cdfe1efe2e8de62cc607 SHA256 c62a37c0d81043ee4ca7fc4d7610d19dc2df426d556eb3285d7b1fe367a44a8d
54 -AUX postinstall-en.txt 6524 RMD160 d3799bc5cdc283e787c1b5d08935a8d7851d0c8d SHA1 097744447c046848611bfe53d5191518465f1c6d SHA256 dad8831abc23179ebcd2c2431f11d83346c142175c59da47cf5f913c928de667
55 -AUX postinstall-nodb-en.txt 171 RMD160 88ff71d95c63f1b5d76e398c3566ada75954cdf4 SHA1 26748e5f24207ef5cb145e3668e1f17cdcddf699 SHA256 f39ff660a1cafbbd96ce18c46f056450ace04df5ac401eeccaf16441d54f3b6a
56 -DIST moodle-1.9.16.tgz 14052946 RMD160 4618557f3e8886010713ebfb1bbcd0042f3a1d10 SHA1 eec230b06cf94dfe45eb46e1e04dec78866d7869 SHA256 dbfc75a2fbac1b68520110989347174bd90982caa216a384190f627518bff8ac
57 -DIST moodle-2.0.7.tgz 22512947 RMD160 7ab98f36da35d03aff85f74f4e3392daaecceca5 SHA1 8c2fe470bf3de2150d2ca5878b7deb4457110555 SHA256 6ac7ae83dc5827d2054ab58d6e70a980b18bb28def18704fa5831ca578c6fc12
58 -DIST moodle-2.1.4.tgz 23938102 RMD160 b6c3993cfcbecca25d2c39bac33dc37a91480055 SHA1 6d8032953d94803a92234b6fb2cc57dcfb1fbb51 SHA256 9d0fe131f6a5cee9ba98bfb5ac1dcef703bec43b77cf5f8e0d6377ea45d80cdb
59 -DIST moodle-2.2.1.tgz 24892608 RMD160 d6d5e7c4b6c77ccee05fb794ccdfdfcb9029132e SHA1 051cdc4030b961585029302edc8417a096547c59 SHA256 863b8bc071c3999b2a61ffa86ee8fade6b4c121d4690a0fd74450648f57ac1fc
60 -EBUILD moodle-1.9.16-r1.ebuild 2995 RMD160 5fed7d2df5950c39a57bf5a9fb528d22814484c2 SHA1 fed9dda80b6f68209832225ad737daf68dcd5e1f SHA256 f40892a6969802eafb52bb929b73314fc8d94bd05e9089df4601d85bcfb8e85b
61 -EBUILD moodle-2.0.7-r1.ebuild 3273 RMD160 f9e9f04879d6b4ba6829858aab328004f13657f9 SHA1 f8105f6c688856990b5174c62d7a9ca3c97c578a SHA256 c60694213607832e29cd64b5bc004be7639a835fbb5d730a70cfe87947827dbc
62 -EBUILD moodle-2.1.4-r1.ebuild 3273 RMD160 740fa15ab3cf978e4923fe1b68bc7d7099bdd112 SHA1 279b0ec3635ae8745d4a8f6f80be2480afae4a8c SHA256 b07309597b0bfbaa0a254d900312549c8e05a445e2ab0b19e336952ecda166ed
63 -EBUILD moodle-2.2.1-r1.ebuild 3273 RMD160 b69ea843c995a3abb533cf16ec2c73a9079b06fc SHA1 27c0f007667603e4d7bba9e5418d80735f274340 SHA256 7bce7530f865d66ddbfeb4e35d80227960fe5fa68e82510ffdcc246355bf3d4e
64 -MISC ChangeLog 633 RMD160 6b45e9b8c3cca27bae63690c8ca17566f2b2ee0d SHA1 2e43e29ca13b1e178da2cdd601cc4c1be95b96f9 SHA256 3e04f313dddce514c4489cc731fab29dd3df782634bdaf5e9e9c82193ed7fd60
65 -MISC metadata.xml 256 RMD160 7cd5a16a6eade95f71d40edbb4729baadfbc7649 SHA1 809eeef12d97ae39db024aea151a70c7363475b7 SHA256 8230894d717ea9f2e42f9c7de54671126820f89bf05ca96ec5f03842b12378e1
66
67 diff --git a/www-apps/moodle/files/config.php b/www-apps/moodle/files/config.php
68 deleted file mode 100644
69 index c959b4a..0000000
70 --- a/www-apps/moodle/files/config.php
71 +++ /dev/null
72 @@ -1,29 +0,0 @@
73 -<?PHP
74 -unset($CFG);
75 -$CFG = new stdClass();
76 -
77 -$CFG->dbtype = 'mydb';
78 -$CFG->dbhost = 'localhost';
79 -$CFG->dbname = 'moodle_db';
80 -$CFG->dbuser = 'moodle_user';
81 -$CFG->dbpass = 'moodle_pass';
82 -$CFG->prefix = 'mdl_';
83 -
84 -$CFG->dbpersist = false;
85 -
86 -$CFG->wwwroot = 'http://localhost/moodle';
87 -$CFG->dirroot = '/var/www/localhost/htdocs/moodle';
88 -$CFG->dataroot = '/var/www/localhost/moodle' ;
89 -
90 -$CFG->directorypermissions = 02777;
91 -
92 -$CFG->admin = 'admin';
93 -
94 -if (file_exists("$CFG->dirroot/lib/setup.php")) {
95 - include_once("$CFG->dirroot/lib/setup.php");
96 -} else {
97 - echo "<p>Could not find this file: $CFG->dirroot/lib/setup.php</p>";
98 - echo "<p>Please supply this file or reinstall moodle</p>";
99 - die;
100 -}
101 -?>
102
103 diff --git a/www-apps/moodle/files/postinstall-en.txt b/www-apps/moodle/files/postinstall-en.txt
104 deleted file mode 100644
105 index 6a5b44b..0000000
106 --- a/www-apps/moodle/files/postinstall-en.txt
107 +++ /dev/null
108 @@ -1,220 +0,0 @@
109 -NEW INSTALLS
110 -
111 -0 Check to see if webapp-config automatically installed
112 - moodle for you in /var/www/localhost/htdocs. You should
113 - see a directory in there called moodle. If it didn't
114 - install it manually:
115 -
116 - webapp-config -d moodle -I moodle X.Y.Z
117 -
118 - Replace X.Y.Z with whatever version you just emerged.
119 -
120 -1 Edit the config.php file found at
121 -
122 - /var/www/localhost/htdocs/moodle/config.php
123 -
124 - You should probably change the database password,
125 - $CFG->dbpass = 'moodle_pass' to something more
126 - obscure. Also, if your system has a FQDN, change
127 - the $CFG->wwwroot = 'http://localhost/moodle'
128 - to match the URL of your moodle installation.
129 -
130 -
131 - IF YOU ARE USING MYSQL, do step 2a
132 - IF YOU ARE USING POSTGRESQL, do step 2b
133 -
134 -
135 -2a Create a new mysql database and account with the
136 - appropriate privileges. Make sure the username,
137 - password and database match their values in
138 - config.php from step 1.
139 -
140 - Connect to your mysql server using
141 -
142 - mysql -p -u root
143 -
144 - and at the mysql> prompt issue the following commands
145 -
146 - CREATE DATABASE moodle_db;
147 - GRANT ALL ON moodle_db.*
148 - TO moodle_user@localhost
149 - IDENTIFIED BY 'moodle_pass';
150 - flush privileges;
151 -
152 -2b Issue the following commands at a shell, making sure
153 - the username, password and database match their values
154 - in config.php from step 1.
155 -
156 - su - postgres
157 - psql -c "create user moodle_user createdb;" template1
158 - psql -c "alter user moodle_user with encrypted password 'moodle_pass';" template1
159 - psql -c "create database moodle_db with encoding 'unicode';" -U moodle_user template1
160 - psql -c "alter user moodle_user nocreatedb;" template1
161 - su - root
162 - /etc/init.d/postgresql-X.Y reload
163 -
164 - Replace X.Y with your version postgresql.
165 -
166 - NOTE: Moodle docs say that moodle only works with
167 - postgresql-7, but I've used it with 8 no problems.
168 -
169 -3 Direct your browser to the URL in step 1. You should see
170 - the license agreement. Click "Yes" to continue.
171 -
172 -4 You are now about to install. Click the checkbox for
173 - "Unattended operation" and "Continue" to start. Follow
174 - the wizard as you "Setup administrator account" and configure
175 - the "Front Page settings".
176 -
177 -5 You now have a working installation. Before putting it
178 - into production, you'll probably want to check that
179 - everything is sane. In the "Site Administration" block,
180 - click on
181 -
182 - Server -> Environment
183 -
184 - Make sure that you've got the green okay on all the
185 - Server Checks. If you don't, click on the ? icons for
186 - popup help.
187 -
188 -6 Add a cron-job to root's crontab.
189 -
190 - su - root
191 - crontab -e # fcrontab -e if you use fcron
192 -
193 - then add the line
194 -
195 - */30 * * * * root php -q /var/www/localhost/htdocs/moodle/admin/cron.php > /dev/null
196 -
197 -7 For more information on installing moodle, see
198 -
199 - http://docs.moodle.org/en/Installing_Moodle
200 -
201 - For information on working with moodle, see
202 -
203 - http://moodle.org/support/
204 -
205 -=================================================================
206 -
207 -UPGRADES
208 -
209 -0 Before any upgade you should backup your database in case you have
210 - to roll back. The moodle dirroot directory ($CFG->dirroot in the
211 - config.php file) isn't as critical since you can always reinstall
212 - that with web-apps. The moodle data root ($CFG->dataroot in config.php),
213 - where files are uploaded, will not be touched. But the upgrade will
214 - probably change your db schema, and the new format may not be backward
215 - compatible. For mysql use
216 -
217 - mysqldump -u moodle_user -p -C -Q -e --create-options moodle_db > moodle-backup.sql
218 -
219 - or for postgresql use
220 -
221 - su - postgres
222 - pg_dump moodle_db > moodle-backup.sql
223 -
224 - If you have to fall back, you can do so using
225 -
226 - mysql -p -u moodle_user moodle_db < moodle-backup.sql
227 -
228 - or
229 -
230 - su - postgres
231 - psql moodle_db < moodle-backup.sql
232 -
233 - TEST THIS! PRACTICE THIS! Make sure it will work for you if you
234 - have to fall back.
235 -
236 -1 Emerge the new moodle ebuild. Be prepared to add USE flags for
237 - php and re-emerge it since upgrades may require new functionality
238 - from php. Remember to restart apache after re-emerging php!
239 -
240 -2 If the ebuild didn't do it for you, update using
241 -
242 - webapp-config -d moodle -U moodle X.Y.Z
243 -
244 -3 Aim your browser to the URL in the config.php file defined
245 - by $CFG->wwwroot. You will get a message that you are about
246 - to automatically upgrade your server and cannot go back.
247 - This is why you backed up your db in step 1. You can go back
248 - if you use webapp-config to install the older version AND
249 - drop the new db and restart the old one. You did practice
250 - restoring, right?
251 -
252 -4 Click "Continue" and follow through with the upgrade.
253 -
254 -
255 -=================================================================
256 -
257 -UNINSTALL
258 -
259 -1 Make sure you really want to do this. I mean REALLY!
260 - After step 3 you will be past the point of no return.
261 -
262 -2 If you just want to uninstall the webapp, do the following
263 - and no more!
264 -
265 - emerge --unmerge moodle
266 -
267 - Your data is still in the db and in the moodledata dir.
268 -
269 -
270 - !!!!!!!!! POINT OF NO RETURN !!!!!!!!!
271 -
272 -3 Uninstall the uploaded files
273 -
274 - rm -rf /var/lib/moodledata
275 -
276 -
277 - IF YOU ARE USING MYSQL, do step 4a
278 - IF YOU ARE USING POSTGRESQL, do step 4b
279 -
280 -
281 -4a Connect to your mysql server using 'mysql -p -u root' and
282 - at the mysql> prompt issue the following commands:
283 -
284 - DROP DATABASE moodle_db;
285 - DROP USER moodle_user@localhost ;
286 -
287 -4b Issue the following commands
288 -
289 - su - postgres
290 - psql -c "drop database moodle_db;" template1
291 - psql -c "drop user moodle_user;" template1
292 -
293 -5 Remove the root cron-job
294 -
295 - su - root
296 - crontab -e # fcrontab -e if you use fcron
297 -
298 - and delete the line added above.
299 -
300 -=================================================================
301 -
302 -ADDITIONAL PHP REQUIREMENTS
303 -
304 - Moodle allows for many method of authentication. To see
305 - what these are, in the "Site Administration" block, click
306 - on
307 -
308 - Users -> Authentication -> Manage Authentication
309 -
310 - Moodle will try to authenticate by each method in order
311 - until it either succeeds or exhausts the list and fails.
312 -
313 - In order to use some of these methods, you need to make
314 - sure PHP was compiled with the correct support. You will
315 - know that you do not have the correct support compiled in
316 - if authentication by all previous methods fails, and you
317 - encounter a method for which PHP does not have support.
318 - An error will be thrown and reported in the web page.
319 -
320 - Currently, the ebuild has support for the following
321 -
322 - Auth Method USE flag
323 -
324 - IMAP(S) or POP3(S) imap
325 - LDAP or CAS ldap
326 - External database odbc
327 - RADIUS radius
328 -
329
330 diff --git a/www-apps/moodle/files/postinstall-nodb-en.txt b/www-apps/moodle/files/postinstall-nodb-en.txt
331 deleted file mode 100644
332 index 9126994..0000000
333 --- a/www-apps/moodle/files/postinstall-nodb-en.txt
334 +++ /dev/null
335 @@ -1,6 +0,0 @@
336 -You have not specified which database you are going to use.
337 -You are on your own! Go to
338 -
339 - http://docs.moodle.org/en/Installing_Moodle
340 -
341 -and follow the instructions there.
342
343 diff --git a/www-apps/moodle/metadata.xml b/www-apps/moodle/metadata.xml
344 deleted file mode 100644
345 index 3cf0cd5..0000000
346 --- a/www-apps/moodle/metadata.xml
347 +++ /dev/null
348 @@ -1,9 +0,0 @@
349 -<?xml version="1.0" encoding="UTF-8"?>
350 -<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
351 -<pkgmetadata>
352 -<herd>web-apps</herd>
353 -<maintainer>
354 - <email>blueness@g.o</email>
355 - <name>Anthony G. Basile</name>
356 -</maintainer>
357 -</pkgmetadata>
358
359 diff --git a/www-apps/moodle/moodle-1.9.16-r1.ebuild b/www-apps/moodle/moodle-1.9.16-r1.ebuild
360 deleted file mode 100644
361 index b166e9d..0000000
362 --- a/www-apps/moodle/moodle-1.9.16-r1.ebuild
363 +++ /dev/null
364 @@ -1,122 +0,0 @@
365 -# Copyright 1999-2012 Gentoo Foundation
366 -# Distributed under the terms of the GNU General Public License v2
367 -# $Header: /var/cvsroot/gentoo-x86/www-apps/moodle/moodle-1.9.16.ebuild,v 1.1 2012/01/08 17:47:30 blueness Exp $
368 -
369 -EAPI="4"
370 -
371 -inherit versionator webapp
372 -
373 -AVC=( $(get_version_components) )
374 -MY_BRANCH="stable${AVC[0]}${AVC[1]}"
375 -
376 -DESCRIPTION="The Moodle Course Management System"
377 -HOMEPAGE="http://moodle.org"
378 -SRC_URI="http://download.moodle.org/${MY_BRANCH}/${P}.tgz"
379 -S="${WORKDIR}/${PN}"
380 -
381 -LICENSE="GPL-2"
382 -KEYWORDS="~alpha ~amd64 ~hppa ~ppc ~ppc64 ~sparc ~x86"
383 -#SLOT empty due to webapp
384 -
385 -DBFLAGS="mysql?,postgres?"
386 -DBTYPES=${DBFLAGS//\?/}
387 -DBTYPES=${DBTYPES//,/ }
388 -
389 -AUTHFLAGS="imap?,ldap?,odbc?"
390 -AUTHMODES=${AUTHFLAGS//\?/}
391 -AUTHMODES=${AUTHMODES//,/ }
392 -
393 -PHPFLAGS="ctype,curl,gd,iconv,session,ssl,tokenizer,xml,xmlrpc,zlib"
394 -
395 -IUSE="${DBTYPES} ${AUTHMODES} vhosts"
396 -
397 -# No forced dependency on
398 -# mysql? ( virtual/mysql )
399 -# postgres? ( dev-db/postgresql-server-7* )
400 -# which may live on another server
401 -DEPEND=""
402 -RDEPEND="
403 - >=dev-lang/php-4.3.0[${DBFLAGS},${AUTHFLAGS},${PHPFLAGS}]
404 - virtual/httpd-php
405 - virtual/cron"
406 -
407 -pkg_setup() {
408 - webapp_pkg_setup
409 -
410 - # How many dbs were selected? If one and only one, which one is it?
411 - MYDB=""
412 - DB_COUNT=0
413 - for db in ${DBTYPES}; do
414 - if use ${db}; then
415 - MYDB=${db}
416 - DB_COUNT=$(($DB_COUNT+1))
417 - fi
418 - done
419 -
420 - if [[ ${DB_COUNT} -eq 0 ]]; then
421 - eerror
422 - eerror "\033[1;31m**************************************************\033[1;31m"
423 - eerror "No database selected in your USE flags,"
424 - eerror "You must select at least one."
425 - eerror "\033[1;31m**************************************************\033[1;31m"
426 - eerror
427 - die
428 - fi
429 -
430 - if [[ ${DB_COUNT} -gt 1 ]]; then
431 - MYDB=""
432 - ewarn
433 - ewarn "\033[1;33m**************************************************\033[1;33m"
434 - ewarn "Multiple databases selected in your USE flags,"
435 - ewarn "You will have to choose your database manually."
436 - ewarn "\033[1;33m**************************************************\033[1;33m"
437 - ewarn
438 - fi
439 -}
440 -
441 -src_prepare() {
442 - rm COPYING.txt
443 - cp "${FILESDIR}"/config.php .
444 -
445 - #
446 - # Moodle expect postgres7, not postgres
447 - #
448 - MYDB=${MYDB/postgres/postgres7}
449 - if [[ ${DB_COUNT} -eq 1 ]] ; then
450 - sed -i -e "s|mydb|${MYDB}|" config.php
451 - fi
452 -}
453 -
454 -src_install() {
455 - webapp_src_preinst
456 -
457 - local MOODLEDATA="${MY_HOSTROOTDIR}"/moodle
458 - dodir ${MOODLEDATA}
459 - webapp_serverowned -R "${MOODLEDATA}"
460 -
461 - local MOODLEROOT="${MY_HTDOCSDIR}"
462 - insinto ${MOODLEROOT}
463 - doins -r *
464 -
465 - webapp_configfile "${MOODLEROOT}"/config.php
466 -
467 - if [[ ${DB_COUNT} -eq 1 ]]; then
468 - webapp_postinst_txt en "${FILESDIR}"/postinstall-en.txt
469 - else
470 - webapp_postinst_txt en "${FILESDIR}"/postinstall-nodb-en.txt
471 - fi
472 -
473 - webapp_src_install
474 -}
475 -
476 -pkg_postinst() {
477 - einfo
478 - einfo "\033[1;32m**************************************************\033[1;32m"
479 - einfo
480 - einfo "To see the post install instructions, do"
481 - einfo
482 - einfo " webapp-config --show-postinst ${PN} ${PVR}"
483 - einfo
484 - einfo "\033[1;32m**************************************************\033[1;32m"
485 - einfo
486 -}
487
488 diff --git a/www-apps/moodle/moodle-2.0.7-r1.ebuild b/www-apps/moodle/moodle-2.0.7-r1.ebuild
489 deleted file mode 100644
490 index 54c96b0..0000000
491 --- a/www-apps/moodle/moodle-2.0.7-r1.ebuild
492 +++ /dev/null
493 @@ -1,126 +0,0 @@
494 -# Copyright 1999-2012 Gentoo Foundation
495 -# Distributed under the terms of the GNU General Public License v2
496 -# $Header: /var/cvsroot/gentoo-x86/www-apps/moodle/moodle-2.0.7.ebuild,v 1.1 2012/01/08 17:47:30 blueness Exp $
497 -
498 -EAPI="4"
499 -
500 -inherit versionator webapp
501 -
502 -AVC=( $(get_version_components) )
503 -MY_BRANCH="stable${AVC[0]}${AVC[1]}"
504 -
505 -DESCRIPTION="The Moodle Course Management System"
506 -HOMEPAGE="http://moodle.org"
507 -SRC_URI="http://download.moodle.org/${MY_BRANCH}/${P}.tgz"
508 -S="${WORKDIR}/${PN}"
509 -
510 -LICENSE="GPL-2"
511 -KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86"
512 -#SLOT empty due to webapp
513 -
514 -DB_FLAGS="mysqli?,postgres?"
515 -DB_TYPES=${DB_FLAGS//\?/}
516 -DB_TYPES=${DB_TYPES//,/ }
517 -
518 -AUTHENTICATION_FLAGS="imap?,ldap?,odbc?"
519 -AUTHENTICATION_MODES=${AUTHENTICATION_FLAGS//\?/}
520 -AUTHENTICATION_MODES=${AUTHENTICATION_MODES//,/ }
521 -
522 -PHP_REQUIRED_FLAGS_53="ctype,curl,iconv,json,session,simplexml,xml,zip"
523 -PHP_OPTIONAL_FLAGS_53="gd,intl,soap,ssl,tokenizer,xmlrpc"
524 -PHP_FLAGS_53="${PHP_REQUIRED_FLAGS_53},${PHP_OPTIONAL_FLAGS_53}"
525 -
526 -IUSE="${DB_TYPES} ${AUTHENTICATION_MODES} vhosts"
527 -
528 -# No forced dependency on
529 -# mysql? ( virtual/mysql )
530 -# postgres? ( dev-db/postgresql-server-7* )
531 -# which may live on another server
532 -DEPEND=""
533 -RDEPEND="
534 - =dev-lang/php-5.3*[${DB_FLAGS},${AUTHENTICATION_FLAGS},${PHP_FLAGS_53}]
535 - virtual/httpd-php
536 - virtual/cron"
537 -
538 -pkg_setup() {
539 - webapp_pkg_setup
540 -
541 - # How many dbs were selected? If one and only one, which one is it?
542 - MYDB=""
543 - DB_COUNT=0
544 - for db in ${DB_TYPES}; do
545 - if use ${db}; then
546 - MYDB=${db}
547 - DB_COUNT=$(($DB_COUNT+1))
548 - fi
549 - done
550 -
551 - if [[ ${DB_COUNT} -eq 0 ]]; then
552 - eerror
553 - eerror "\033[1;31m**************************************************\033[1;31m"
554 - eerror "No database selected in your USE flags,"
555 - eerror "You must select at least one."
556 - eerror "\033[1;31m**************************************************\033[1;31m"
557 - eerror
558 - die
559 - fi
560 -
561 - if [[ ${DB_COUNT} -gt 1 ]]; then
562 - MYDB=""
563 - ewarn
564 - ewarn "\033[1;33m**************************************************\033[1;33m"
565 - ewarn "Multiple databases selected in your USE flags,"
566 - ewarn "You will have to choose your database manually."
567 - ewarn "\033[1;33m**************************************************\033[1;33m"
568 - ewarn
569 - fi
570 -}
571 -
572 -src_prepare() {
573 - rm COPYING.txt
574 - cp "${FILESDIR}"/config.php .
575 -
576 - # Moodle expect postgres7, not postgres
577 - MYDB=${MYDB/postgres/postgres7}
578 -
579 - # Moodle expects mysql, not mysqli
580 - MYDB=${MYDB/mysqli/mysql}
581 -
582 - if [[ ${DB_COUNT} -eq 1 ]] ; then
583 - sed -i -e "s|mydb|${MYDB}|" config.php
584 - fi
585 -}
586 -
587 -src_install() {
588 - webapp_src_preinst
589 -
590 - local MOODLEDATA="${MY_HOSTROOTDIR}"/moodle
591 - dodir ${MOODLEDATA}
592 - webapp_serverowned -R "${MOODLEDATA}"
593 -
594 - local MOODLEROOT="${MY_HTDOCSDIR}"
595 - insinto ${MOODLEROOT}
596 - doins -r *
597 -
598 - webapp_configfile "${MOODLEROOT}"/config.php
599 -
600 - if [[ ${DB_COUNT} -eq 1 ]]; then
601 - webapp_postinst_txt en "${FILESDIR}"/postinstall-en.txt
602 - else
603 - webapp_postinst_txt en "${FILESDIR}"/postinstall-nodb-en.txt
604 - fi
605 -
606 - webapp_src_install
607 -}
608 -
609 -pkg_postinst() {
610 - einfo
611 - einfo "\033[1;32m**************************************************\033[1;32m"
612 - einfo
613 - einfo "To see the post install instructions, do"
614 - einfo
615 - einfo " webapp-config --show-postinst ${PN} ${PVR}"
616 - einfo
617 - einfo "\033[1;32m**************************************************\033[1;32m"
618 - einfo
619 -}
620
621 diff --git a/www-apps/moodle/moodle-2.1.4-r1.ebuild b/www-apps/moodle/moodle-2.1.4-r1.ebuild
622 deleted file mode 100644
623 index 670aad7..0000000
624 --- a/www-apps/moodle/moodle-2.1.4-r1.ebuild
625 +++ /dev/null
626 @@ -1,126 +0,0 @@
627 -# Copyright 1999-2012 Gentoo Foundation
628 -# Distributed under the terms of the GNU General Public License v2
629 -# $Header: /var/cvsroot/gentoo-x86/www-apps/moodle/moodle-2.1.4.ebuild,v 1.1 2012/01/08 17:47:30 blueness Exp $
630 -
631 -EAPI="4"
632 -
633 -inherit versionator webapp
634 -
635 -AVC=( $(get_version_components) )
636 -MY_BRANCH="stable${AVC[0]}${AVC[1]}"
637 -
638 -DESCRIPTION="The Moodle Course Management System"
639 -HOMEPAGE="http://moodle.org"
640 -SRC_URI="http://download.moodle.org/${MY_BRANCH}/${P}.tgz"
641 -S="${WORKDIR}/${PN}"
642 -
643 -LICENSE="GPL-2"
644 -KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86"
645 -#SLOT empty due to webapp
646 -
647 -DB_FLAGS="mysqli?,postgres?"
648 -DB_TYPES=${DB_FLAGS//\?/}
649 -DB_TYPES=${DB_TYPES//,/ }
650 -
651 -AUTHENTICATION_FLAGS="imap?,ldap?,odbc?"
652 -AUTHENTICATION_MODES=${AUTHENTICATION_FLAGS//\?/}
653 -AUTHENTICATION_MODES=${AUTHENTICATION_MODES//,/ }
654 -
655 -PHP_REQUIRED_FLAGS_53="ctype,curl,iconv,json,session,simplexml,xml,zip"
656 -PHP_OPTIONAL_FLAGS_53="gd,intl,soap,ssl,tokenizer,xmlrpc"
657 -PHP_FLAGS_53="${PHP_REQUIRED_FLAGS_53},${PHP_OPTIONAL_FLAGS_53}"
658 -
659 -IUSE="${DB_TYPES} ${AUTHENTICATION_MODES} vhosts"
660 -
661 -# No forced dependency on
662 -# mysql? ( virtual/mysql )
663 -# postgres? ( dev-db/postgresql-server-7* )
664 -# which may live on another server
665 -DEPEND=""
666 -RDEPEND="
667 - =dev-lang/php-5.3*[${DB_FLAGS},${AUTHENTICATION_FLAGS},${PHP_FLAGS_53}]
668 - virtual/httpd-php
669 - virtual/cron"
670 -
671 -pkg_setup() {
672 - webapp_pkg_setup
673 -
674 - # How many dbs were selected? If one and only one, which one is it?
675 - MYDB=""
676 - DB_COUNT=0
677 - for db in ${DB_TYPES}; do
678 - if use ${db}; then
679 - MYDB=${db}
680 - DB_COUNT=$(($DB_COUNT+1))
681 - fi
682 - done
683 -
684 - if [[ ${DB_COUNT} -eq 0 ]]; then
685 - eerror
686 - eerror "\033[1;31m**************************************************\033[1;31m"
687 - eerror "No database selected in your USE flags,"
688 - eerror "You must select at least one."
689 - eerror "\033[1;31m**************************************************\033[1;31m"
690 - eerror
691 - die
692 - fi
693 -
694 - if [[ ${DB_COUNT} -gt 1 ]]; then
695 - MYDB=""
696 - ewarn
697 - ewarn "\033[1;33m**************************************************\033[1;33m"
698 - ewarn "Multiple databases selected in your USE flags,"
699 - ewarn "You will have to choose your database manually."
700 - ewarn "\033[1;33m**************************************************\033[1;33m"
701 - ewarn
702 - fi
703 -}
704 -
705 -src_prepare() {
706 - rm COPYING.txt
707 - cp "${FILESDIR}"/config.php .
708 -
709 - # Moodle expect postgres7, not postgres
710 - MYDB=${MYDB/postgres/postgres7}
711 -
712 - # Moodle expects mysql, not mysqli
713 - MYDB=${MYDB/mysqli/mysql}
714 -
715 - if [[ ${DB_COUNT} -eq 1 ]] ; then
716 - sed -i -e "s|mydb|${MYDB}|" config.php
717 - fi
718 -}
719 -
720 -src_install() {
721 - webapp_src_preinst
722 -
723 - local MOODLEDATA="${MY_HOSTROOTDIR}"/moodle
724 - dodir ${MOODLEDATA}
725 - webapp_serverowned -R "${MOODLEDATA}"
726 -
727 - local MOODLEROOT="${MY_HTDOCSDIR}"
728 - insinto ${MOODLEROOT}
729 - doins -r *
730 -
731 - webapp_configfile "${MOODLEROOT}"/config.php
732 -
733 - if [[ ${DB_COUNT} -eq 1 ]]; then
734 - webapp_postinst_txt en "${FILESDIR}"/postinstall-en.txt
735 - else
736 - webapp_postinst_txt en "${FILESDIR}"/postinstall-nodb-en.txt
737 - fi
738 -
739 - webapp_src_install
740 -}
741 -
742 -pkg_postinst() {
743 - einfo
744 - einfo "\033[1;32m**************************************************\033[1;32m"
745 - einfo
746 - einfo "To see the post install instructions, do"
747 - einfo
748 - einfo " webapp-config --show-postinst ${PN} ${PVR}"
749 - einfo
750 - einfo "\033[1;32m**************************************************\033[1;32m"
751 - einfo
752 -}
753
754 diff --git a/www-apps/moodle/moodle-2.2.1-r1.ebuild b/www-apps/moodle/moodle-2.2.1-r1.ebuild
755 deleted file mode 100644
756 index 6744801..0000000
757 --- a/www-apps/moodle/moodle-2.2.1-r1.ebuild
758 +++ /dev/null
759 @@ -1,126 +0,0 @@
760 -# Copyright 1999-2012 Gentoo Foundation
761 -# Distributed under the terms of the GNU General Public License v2
762 -# $Header: /var/cvsroot/gentoo-x86/www-apps/moodle/moodle-2.2.1.ebuild,v 1.1 2012/01/08 18:07:28 blueness Exp $
763 -
764 -EAPI="4"
765 -
766 -inherit versionator webapp
767 -
768 -AVC=( $(get_version_components) )
769 -MY_BRANCH="stable${AVC[0]}${AVC[1]}"
770 -
771 -DESCRIPTION="The Moodle Course Management System"
772 -HOMEPAGE="http://moodle.org"
773 -SRC_URI="http://download.moodle.org/${MY_BRANCH}/${P}.tgz"
774 -S="${WORKDIR}/${PN}"
775 -
776 -LICENSE="GPL-2"
777 -KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86"
778 -#SLOT empty due to webapp
779 -
780 -DB_FLAGS="mysqli?,postgres?"
781 -DB_TYPES=${DB_FLAGS//\?/}
782 -DB_TYPES=${DB_TYPES//,/ }
783 -
784 -AUTHENTICATION_FLAGS="imap?,ldap?,odbc?"
785 -AUTHENTICATION_MODES=${AUTHENTICATION_FLAGS//\?/}
786 -AUTHENTICATION_MODES=${AUTHENTICATION_MODES//,/ }
787 -
788 -PHP_REQUIRED_FLAGS_53="ctype,curl,iconv,json,session,simplexml,xml,zip"
789 -PHP_OPTIONAL_FLAGS_53="gd,intl,soap,ssl,tokenizer,xmlrpc"
790 -PHP_FLAGS_53="${PHP_REQUIRED_FLAGS_53},${PHP_OPTIONAL_FLAGS_53}"
791 -
792 -IUSE="${DB_TYPES} ${AUTHENTICATION_MODES} vhosts"
793 -
794 -# No forced dependency on
795 -# mysql? ( virtual/mysql )
796 -# postgres? ( dev-db/postgresql-server-7* )
797 -# which may live on another server
798 -DEPEND=""
799 -RDEPEND="
800 - =dev-lang/php-5.3*[${DB_FLAGS},${AUTHENTICATION_FLAGS},${PHP_FLAGS_53}]
801 - virtual/httpd-php
802 - virtual/cron"
803 -
804 -pkg_setup() {
805 - webapp_pkg_setup
806 -
807 - # How many dbs were selected? If one and only one, which one is it?
808 - MYDB=""
809 - DB_COUNT=0
810 - for db in ${DB_TYPES}; do
811 - if use ${db}; then
812 - MYDB=${db}
813 - DB_COUNT=$(($DB_COUNT+1))
814 - fi
815 - done
816 -
817 - if [[ ${DB_COUNT} -eq 0 ]]; then
818 - eerror
819 - eerror "\033[1;31m**************************************************\033[1;31m"
820 - eerror "No database selected in your USE flags,"
821 - eerror "You must select at least one."
822 - eerror "\033[1;31m**************************************************\033[1;31m"
823 - eerror
824 - die
825 - fi
826 -
827 - if [[ ${DB_COUNT} -gt 1 ]]; then
828 - MYDB=""
829 - ewarn
830 - ewarn "\033[1;33m**************************************************\033[1;33m"
831 - ewarn "Multiple databases selected in your USE flags,"
832 - ewarn "You will have to choose your database manually."
833 - ewarn "\033[1;33m**************************************************\033[1;33m"
834 - ewarn
835 - fi
836 -}
837 -
838 -src_prepare() {
839 - rm COPYING.txt
840 - cp "${FILESDIR}"/config.php .
841 -
842 - # Moodle expect postgres7, not postgres
843 - MYDB=${MYDB/postgres/postgres7}
844 -
845 - # Moodle expects mysql, not mysqli
846 - MYDB=${MYDB/mysqli/mysql}
847 -
848 - if [[ ${DB_COUNT} -eq 1 ]] ; then
849 - sed -i -e "s|mydb|${MYDB}|" config.php
850 - fi
851 -}
852 -
853 -src_install() {
854 - webapp_src_preinst
855 -
856 - local MOODLEDATA="${MY_HOSTROOTDIR}"/moodle
857 - dodir ${MOODLEDATA}
858 - webapp_serverowned -R "${MOODLEDATA}"
859 -
860 - local MOODLEROOT="${MY_HTDOCSDIR}"
861 - insinto ${MOODLEROOT}
862 - doins -r *
863 -
864 - webapp_configfile "${MOODLEROOT}"/config.php
865 -
866 - if [[ ${DB_COUNT} -eq 1 ]]; then
867 - webapp_postinst_txt en "${FILESDIR}"/postinstall-en.txt
868 - else
869 - webapp_postinst_txt en "${FILESDIR}"/postinstall-nodb-en.txt
870 - fi
871 -
872 - webapp_src_install
873 -}
874 -
875 -pkg_postinst() {
876 - einfo
877 - einfo "\033[1;32m**************************************************\033[1;32m"
878 - einfo
879 - einfo "To see the post install instructions, do"
880 - einfo
881 - einfo " webapp-config --show-postinst ${PN} ${PVR}"
882 - einfo
883 - einfo "\033[1;32m**************************************************\033[1;32m"
884 - einfo
885 -}