/[gentoo-x86]/app-laptop/ibam/ibam-0.5.2-r1.ebuild
Gentoo

Contents of /app-laptop/ibam/ibam-0.5.2-r1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (hide annotations) (download)
Tue Oct 19 21:16:33 2010 UTC (9 years, 11 months ago) by chainsaw
Branch: MAIN
Instill LDFLAGS respect into build system. Port to EAPI=2. Closes bug #341479 by Diego Elio "Flameeyes" Pettenò <flameeyes@gentoo.org>.

(Portage version: 2.1.9.20/cvs/Linux x86_64)

1 chainsaw 1.1 # Copyright 1999-2010 Gentoo Foundation
2     # Distributed under the terms of the GNU General Public License v2
3     # $Header: /var/cvsroot/gentoo-x86/app-laptop/ibam/ibam-0.5.2.ebuild,v 1.1 2009/07/29 22:01:07 scarabeus Exp $
4    
5     EAPI=2
6    
7     inherit base toolchain-funcs
8    
9     DESCRIPTION="Intelligent Battery Monitor"
10     HOMEPAGE="http://ibam.sourceforge.net/"
11     SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
12    
13     LICENSE="GPL-2"
14     SLOT="0"
15     KEYWORDS="~amd64 ~x86"
16    
17     IUSE="gkrellm"
18    
19     DEPEND="gkrellm? ( app-admin/gkrellm )"
20     RDEPEND="${DEPEND}"
21     PATCHES=( "${FILESDIR}/${P}-ldflags.patch" )
22    
23     src_prepare() {
24     base_src_prepare
25     sed -i \
26     -e "s:^CFLAGS=-O3:CFLAGS=${CFLAGS}:" \
27     -e "s:^CC=g++:CC=$(tc-getCXX):" \
28     "${S}"/Makefile \
29     || die "Failed to set CFLAGS/compiler"
30     }
31    
32     src_compile() {
33     emake || die "Making ibam failed"
34     if use gkrellm; then
35     emake krell || die "Making krell failed"
36     fi
37     }
38    
39     src_install() {
40     dobin ibam || die "dobin failed"
41     dodoc CHANGES README REPORT || die "dodoc failed"
42    
43     if use gkrellm; then
44     insinto /usr/$(get_libdir)/gkrellm2/plugins
45     doins ibam-krell.so || die "doins gkrellm plugin failed"
46     fi
47     }
48    
49     pkg_postinst() {
50     elog
51     elog "You will need to install sci-visualization/gnuplot if you wish to use"
52     elog "the --plot argument to ibam."
53     elog
54     }

  ViewVC Help
Powered by ViewVC 1.1.20