diff options
author | Ctibor <ctibor.brancik@seznam.cz> | 2012-10-23 22:23:48 +0200 |
---|---|---|
committer | Ctibor <ctibor.brancik@seznam.cz> | 2012-10-23 22:23:48 +0200 |
commit | b3f80e0306587663a493502e4fcfa1c17c5836fd (patch) | |
tree | cbd97925b8af0d81f04fd8ee064e631ae70a788e /eclass | |
download | brancik-overlay-b3f80e0306587663a493502e4fcfa1c17c5836fd.tar.gz brancik-overlay-b3f80e0306587663a493502e4fcfa1c17c5836fd.tar.bz2 |
Initial import of the local overlay.
Diffstat (limited to 'eclass')
-rwxr-xr-x | eclass/boost-utils.eclass | 36 | ||||
-rwxr-xr-x | eclass/fatrat-plugin.eclass | 41 |
2 files changed, 77 insertions, 0 deletions
diff --git a/eclass/boost-utils.eclass b/eclass/boost-utils.eclass new file mode 100755 index 0000000..d561ae3 --- /dev/null +++ b/eclass/boost-utils.eclass @@ -0,0 +1,36 @@ +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +# +# Author: Hanno Meyer-Thurow +# Purpose: Serve paths to boost libraries & headers +# + +inherit flag-o-matic multilib + +# get_boost_library_path +get_boost_library_path() { + local version="$(grep -o -e "[0-9]_[0-9][0-9]" \ + /usr/include/boost/version.hpp)" + + local path="/usr/$(get_libdir)/boost-${version}" + + [ -d "${path}" ] && echo -n "${path}" +} + +# add_boost_library_path +add_boost_library_path() { + local path="$(get_boost_library_path)" + + if [ "${path}" ] ; then + append-ldflags "-L${path}" + else + die "path not found! (${path})" + fi +} + +# add_boost_paths: convenient wrapper +add_boost_paths() { + add_boost_library_path +} diff --git a/eclass/fatrat-plugin.eclass b/eclass/fatrat-plugin.eclass new file mode 100755 index 0000000..951785c --- /dev/null +++ b/eclass/fatrat-plugin.eclass @@ -0,0 +1,41 @@ +# Copyright 1999-2008 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +# +# Original Author: David Watzke <david@watzke.cz> +# Purpose: simplify creating ebuilds for FatRat's plugins +# + +EAPI="1" + +if [[ "${PV}" == "9999" ]]; then + inherit git + EGIT_REPO_URI="git://git.dolezel.info/${PN}.git" + SRC_URI="" + DEPEND="|| ( ~net-misc/fatrat-9999 ~net-misc/fatrat-1.1.9999 )" +else + SRC_URI="http://www.dolezel.info/download/data/${PN}/${P}.tar.gz" + DEPEND="~net-misc/fatrat-${PV}" +fi + +HOMEPAGE="http://fatrat.dolezel.info/" + +LICENSE="GPL-2" +SLOT="0" +IUSE="-debug" +RESTRICT="mirror" + +RDEPEND="${DEPEND}" + +fatrat-plugin_src_compile() { + use debug && myconf="-DCMAKE_BUILD_TYPE=Debug" + cmake . -DCMAKE_INSTALL_PREFIX="/usr" ${myconf} || die "cmake failed" + emake || die "emake failed" +} + +fatrat-plugin_src_install() { + emake DESTDIR="${D}" install || die "emake install failed" +} + +EXPORT_FUNCTIONS src_compile src_install |