From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 0B1F658973 for ; Sun, 31 Jan 2016 16:27:42 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 5D25A21C13F; Sun, 31 Jan 2016 16:27:39 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id DDF5F21C13F for ; Sun, 31 Jan 2016 16:27:38 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 76C853408A6 for ; Sun, 31 Jan 2016 16:27:37 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 827708E5 for ; Sun, 31 Jan 2016 16:27:35 +0000 (UTC) From: "Fabian Groffen" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Fabian Groffen" Message-ID: <1454257642.a91187579584c042cdb7de09df71dcdbff5813fc.grobian@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: net-analyzer/graphite-web/ X-VCS-Repository: repo/gentoo X-VCS-Files: net-analyzer/graphite-web/graphite-web-0.9.13-r2.ebuild X-VCS-Directories: net-analyzer/graphite-web/ X-VCS-Committer: grobian X-VCS-Committer-Name: Fabian Groffen X-VCS-Revision: a91187579584c042cdb7de09df71dcdbff5813fc X-VCS-Branch: master Date: Sun, 31 Jan 2016 16:27:35 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 56de60ba-962e-4626-ab7d-dd7972bcb85c X-Archives-Hash: cf79282602bf26cd52a37b458f57400d commit: a91187579584c042cdb7de09df71dcdbff5813fc Author: Fabian Groffen gentoo org> AuthorDate: Sun Jan 31 16:26:53 2016 +0000 Commit: Fabian Groffen gentoo org> CommitDate: Sun Jan 31 16:27:22 2016 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a9118757 net-analyzer/graphite-web: revbump for changed examples installation, bug #556852 Package-Manager: portage-2.2.26 .../graphite-web/graphite-web-0.9.13-r2.ebuild | 99 ++++++++++++++++++++++ 1 file changed, 99 insertions(+) diff --git a/net-analyzer/graphite-web/graphite-web-0.9.13-r2.ebuild b/net-analyzer/graphite-web/graphite-web-0.9.13-r2.ebuild new file mode 100644 index 0000000..134bc3f --- /dev/null +++ b/net-analyzer/graphite-web/graphite-web-0.9.13-r2.ebuild @@ -0,0 +1,99 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=5 +PYTHON_COMPAT=( python2_7 ) + +inherit distutils-r1 python-utils-r1 prefix + +DESCRIPTION="Enterprise scalable realtime graphing" +HOMEPAGE="http://graphite.readthedocs.org/" +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz + https://raw.githubusercontent.com/graphite-project/graphite-web/522d84fed687bd946878e48d85982d59f7bd1267/webapp/content/img/share.png -> ${P}-share.png" + +LICENSE="Apache-2.0" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="ldap mysql memcached +sqlite" + +DEPEND="" +RDEPEND="dev-lang/python[sqlite?] + || ( >=dev-python/django-1.4[sqlite?,mysql?,${PYTHON_USEDEP}] + ( >=dev-python/django-1.6[sqlite?,${PYTHON_USEDEP}] + mysql? ( || ( dev-python/mysql-python dev-python/mysqlclient ) ) ) ) + >=dev-python/twisted-core-10.0[${PYTHON_USEDEP}] + >=dev-python/django-tagging-0.3.1[${PYTHON_USEDEP}] + dev-python/pycairo[${PYTHON_USEDEP}] + dev-python/zope-interface[${PYTHON_USEDEP}] + dev-python/pytz[${PYTHON_USEDEP}] + dev-python/pyparsing[${PYTHON_USEDEP}] + dev-python/txAMQP[${PYTHON_USEDEP}] + dev-python/carbon[${PYTHON_USEDEP}] + dev-python/whisper[${PYTHON_USEDEP}] + media-libs/fontconfig + memcached? ( dev-python/python-memcached[${PYTHON_USEDEP}] ) + ldap? ( dev-python/python-ldap[${PYTHON_USEDEP}] )" + +PATCHES=( + # Do not install the configuration and data files. We install them + # somewhere sensible by hand. + "${FILESDIR}"/${P}-fhs-paths.patch + "${FILESDIR}"/${P}-system-libs.patch +) + +EXAMPLES=( + examples/example-graphite-vhost.conf + conf/dashboard.conf.example + conf/graphite.wsgi.example +) + +src_prepare() { + # use FHS-style paths + rm setup.cfg || die + # make sure we don't use bundled stuff + rm -Rf webapp/graphite/thirdparty + distutils-r1_src_prepare + eprefixify \ + conf/graphite.wsgi.example \ + webapp/graphite/local_settings.py.example +} + +python_install() { + distutils-r1_python_install \ + --install-data="${EPREFIX}"/usr/share/${PN} + + # make manage.py available from an easier location/name + dodir /usr/bin + mv "${D}"/$(python_get_sitedir)/graphite/manage.py \ + "${ED}"/usr/bin/${PN}-manage || die + chmod 0755 "${ED}"/usr/bin/${PN}-manage || die + python_fix_shebang "${ED}"/usr/bin/${PN}-manage + + # shortener image isn't included for some reason + cp "${DISTDIR}"/"${P}"-share.png "${ED}"/usr/share/${PN}/webapp/content/img/ + + insinto /etc/${PN} + newins webapp/graphite/local_settings.py.example local_settings.py + pushd "${D}"/$(python_get_sitedir)/graphite > /dev/null || die + ln -s ../../../../../etc/${PN}/local_settings.py local_settings.py + popd > /dev/null || die +} + +pkg_config() { + "${ROOT}"/usr/bin/${PN}-manage syncdb --noinput + local idx=$(grep 'INDEX_FILE =' "${EROOT}"/etc/local_settings.py 2>/dev/null) + if [[ -n ${idx} ]] ; then + idx=${idx##*=} + idx=$(echo ${idx}) + eval "idx=${idx}" + touch "${ROOT}"/"${idx}"/index + fi +} + +pkg_postinst() { + einfo "You will need to ${PN} it with Apache (mod_wsgi) or nginx (uwsgi)." + einfo "Don't forget to edit local_settings.py in ${EPREFIX}/etc/${PN}" + einfo "See http://graphite.readthedocs.org/en/latest/config-local-settings.html" + einfo "Run emerge --config =${PN}-${PVR} if this is a fresh install." +}