|
1 # Copyright 1999-2010 Gentoo Foundation |
|
2 # Distributed under the terms of the GNU General Public License v2 |
|
3 # $Header: $ |
|
4 |
|
5 EAPI="2" |
|
6 PHPCHECKNODIE="yes" |
|
7 inherit webapp depend.php confutils |
|
8 |
|
9 DESCRIPTION="Weblogs management tool written in PHP" |
|
10 HOMEPAGE="http://www.dotclear.net" |
|
11 SRC_URI="http://download.dotclear.org/latest/${P}.tar.gz" |
|
12 |
|
13 LICENSE="GPL-2" |
|
14 KEYWORDS="~amd64 ~x86" |
|
15 IUSE="postgres mysql sqlite gd" |
|
16 |
|
17 DEPEND="dev-lang/php:5[iconv,simplexml,xml,unicode,postgres?,mysql?,sqlite?,gd?]" |
|
18 |
|
19 RDEPEND="${DEPEND}" |
|
20 |
|
21 S="${WORKDIR}/${PN}" |
|
22 |
|
23 need_php5_httpd |
|
24 |
|
25 # Lang Files http://download.dotclear.org/l10n/2.1.6 |
|
26 |
|
27 pkg_setup() { |
|
28 |
|
29 confutils_require_any postgres mysql sqlite |
|
30 |
|
31 local flags="iconv simplexml unicode" |
|
32 use mysql && flags+=" mysql" |
|
33 use postgres && flags+=" postgres" |
|
34 use sqlite && flags+=" sqlite" |
|
35 |
|
36 require_php_with_use "${flags}" || die "Re-install ${PHP_PKG} with ${flags}" |
|
37 |
|
38 webapp_pkg_setup |
|
39 } |
|
40 |
|
41 src_install() { |
|
42 webapp_src_preinst |
|
43 |
|
44 insinto "${MY_HTDOCSDIR}" |
|
45 doins -r . |
|
46 |
|
47 for foo in cache public; |
|
48 do |
|
49 webapp_serverowned -R "${MY_HTDOCSDIR}/${foo}" || die |
|
50 chmod 666 "${D}/${MY_HTDOCSDIR}/${foo}" |
|
51 done |
|
52 for foo in cache db inc plugins; |
|
53 do |
|
54 webapp_configfile "${MY_HTDOCSDIR}/${foo}"/.htaccess |
|
55 done |
|
56 # webapp_configfile "${MY_HTDOCSDIR}"/cache/.htaccess |
|
57 #webapp_configfile "${MY_HTDOCSDIR}"/db/.htaccess |
|
58 # webapp_configfile "${MY_HTDOCSDIR}"/inc/.htaccess |
|
59 # webapp_configfile "${MY_HTDOCSDIR}"/plugins/.htaccess |
|
60 # webapp_configfile "${MY_HTDOCSDIR}"/ |
|
61 |
|
62 webapp_postinst_txt en "${FILESDIR}"/postinst.en.txt |
|
63 webapp_src_install |
|
64 } |