Mercurial > hg > portage
comparison www-apps/redaxo/redaxo-4.2.1.ebuild @ 183:3cdcf4f4578c
replace the version number using portage functions, fetch the source, unpack and clean up works
author | Dirk Olmes <dirk@xanthippe.ping.de> |
---|---|
date | Wed, 17 Feb 2010 09:53:35 +0100 |
parents | 75231bb27b1c |
children | 54b73709801b |
comparison
equal
deleted
inserted
replaced
182:75231bb27b1c | 183:3cdcf4f4578c |
---|---|
1 | 1 |
2 inherit webapp depend.php | 2 EAPI=2 |
3 inherit webapp depend.php versionator | |
3 | 4 |
4 DESCRIPTION="PHP-powered CMS application." | 5 DESCRIPTION="PHP-powered CMS application." |
5 HOMEPAGE="http://www.redaxo.de/" | 6 HOMEPAGE="http://www.redaxo.de/" |
6 | 7 |
7 DOWNLOAD_NAME=`echo ${P} | tr '.' '_'` | 8 # translate redaxo-0.0.0 to redaxo0_0_0 |
8 DOWNLOAD_NAME=`echo ${DOWNLOAD_NAME} | sed -e 's/-//'` | 9 MY_PV=$(replace_all_version_separators '_') |
9 SRC_URI="http://www.redaxo.de/files/${DOWNLOAD_NAME}.zip" | 10 MY_P=${PN}${MY_PV} |
11 SRC_URI="http://www.redaxo.de/files/${MY_P}.zip" | |
10 | 12 |
11 LICENSE="GPL" | 13 LICENSE="GPL" |
12 KEYWORDS="~amd64 ~x86" | 14 KEYWORDS="~amd64 ~x86" |
13 DEPEND="" | 15 DEPEND="" |
14 RDEPEND="virtual/httpd-cgi" | 16 RDEPEND="virtual/httpd-cgi" |
15 | 17 |
16 need_php_httpd | 18 need_php_httpd |
17 | 19 |
18 S="${WORKDIR}/${PN}" | 20 S="${WORKDIR}/${MY_P}" |
19 | 21 |
20 pkg_setup() { | 22 pkg_setup() { |
21 webapp_pkg_setup | 23 webapp_pkg_setup |
22 | 24 |
23 if ! PHPCHECKNODIE="yes" require_php_with_any_use mysql ; then | 25 if ! PHPCHECKNODIE="yes" require_php_with_any_use mysql ; then |
25 eerror "${PHP_PKG} needs to be reinstalled with the mysql USE flag enabled." | 27 eerror "${PHP_PKG} needs to be reinstalled with the mysql USE flag enabled." |
26 die "Reinstall ${PHP_PKG} with the above-stated USE flags." | 28 die "Reinstall ${PHP_PKG} with the above-stated USE flags." |
27 fi | 29 fi |
28 } | 30 } |
29 | 31 |
32 src_unpack() { | |
33 unpack ${A} | |
34 | |
35 # clean up some cruft that comes as part of the install package | |
36 cd ${S} | |
37 find . -name .DS_Store -exec rm {} \; | |
38 } | |
39 | |
30 src_install() { | 40 src_install() { |
31 webapp_src_preinst | 41 webapp_src_preinst |
32 | 42 |
33 find . -name .DS_Store -exec rm {} \; | |
34 # rm docs/INSTALL* | 43 # rm docs/INSTALL* |
35 # local docs="docs/*" | 44 # local docs="docs/*" |
36 # dodoc ${docs} | 45 # dodoc ${docs} |
37 # rm -rf docs/ | 46 # rm -rf docs/ |
38 | 47 |
39 einfo "Installing application files." | 48 einfo "Installing application files." |
40 cp -r . "${D}"${MY_HTDOCSDIR} | 49 cp -r . "${D}"${MY_HTDOCSDIR} |
41 touch "${D}"${MY_HTDOCSDIR}/.htaccess | 50 touch "${D}"${MY_HTDOCSDIR}/.htaccess |
42 # touch "${D}"${MY_HTDOCSDIR}/serendipity_config_local.inc.php | 51 # touch "${D}"${MY_HTDOCSDIR}/serendipity_config_local.inc.php |
43 | 52 |
44 # keepdir ${MY_HTDOCSDIR}/archives/ | 53 # the files directory will be populated by the user |
54 keepdir ${MY_HTDOCSDIR}/files/ | |
45 # webapp_configfile ${MY_HTDOCSDIR}/serendipity_config_local.inc.php | 55 # webapp_configfile ${MY_HTDOCSDIR}/serendipity_config_local.inc.php |
46 | 56 |
47 # archives, templates_c and uploads need to be writable to PHP | 57 # .htaccess, index.php and the redaxo dir are part of the distro |
48 # .htaccess and serendipity_config_local.inc.php need to be too | 58 local SERVEROWNED=".htaccess index.php redaxo" |
49 # plugins and templates need to be writable for spartacus support. | |
50 local SERVEROWNED=".htaccess files index.php redaxo" | |
51 for SFILES in ${SERVEROWNED}; do | 59 for SFILES in ${SERVEROWNED}; do |
52 webapp_serverowned ${MY_HTDOCSDIR}/${SFILES} | 60 webapp_serverowned ${MY_HTDOCSDIR}/${SFILES} |
53 done | 61 done |
54 | 62 |
55 webapp_src_install | 63 webapp_src_install |