summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSantiago M. Mola <coldwind@gentoo.org>2008-11-22 00:10:44 +0000
committerSantiago M. Mola <coldwind@gentoo.org>2008-11-22 00:10:44 +0000
commit61bb0637d60537ee1130178fd89ef7e80b11ee72 (patch)
tree9ae52d5d4bfa26c671b31a20ba80fc475ec19ba8 /app-misc/nut
parentUpdate to Linux 2.6.27.7 (diff)
downloadgentoo-2-61bb0637d60537ee1130178fd89ef7e80b11ee72.tar.gz
gentoo-2-61bb0637d60537ee1130178fd89ef7e80b11ee72.tar.bz2
gentoo-2-61bb0637d60537ee1130178fd89ef7e80b11ee72.zip
Version bump, use EAPI 2, honor LDFLAGS, fix --as-needed (bug #246904).
(Portage version: 2.2_rc14/cvs/Linux 2.6.27-gentoo-r2 x86_64)
Diffstat (limited to 'app-misc/nut')
-rw-r--r--app-misc/nut/ChangeLog8
-rw-r--r--app-misc/nut/files/nut-14.1-build-fixes.patch14
-rw-r--r--app-misc/nut/nut-14.1.ebuild36
3 files changed, 57 insertions, 1 deletions
diff --git a/app-misc/nut/ChangeLog b/app-misc/nut/ChangeLog
index 1c39b65bf953..1d8d97ad97a1 100644
--- a/app-misc/nut/ChangeLog
+++ b/app-misc/nut/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for app-misc/nut
# Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-misc/nut/ChangeLog,v 1.10 2008/05/11 20:53:32 solar Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-misc/nut/ChangeLog,v 1.11 2008/11/22 00:10:44 coldwind Exp $
+
+*nut-14.1 (22 Nov 2008)
+
+ 22 Nov 2008; Santiago M. Mola <coldwind@gentoo.org>
+ +files/nut-14.1-build-fixes.patch, +nut-14.1.ebuild:
+ Version bump, use EAPI 2, honor LDFLAGS, fix --as-needed (bug #246904).
11 May 2008; <solar@gentoo.org> nut-12.7.ebuild:
- Keyworded ~arm/~amd64 and cross-compile love
diff --git a/app-misc/nut/files/nut-14.1-build-fixes.patch b/app-misc/nut/files/nut-14.1-build-fixes.patch
new file mode 100644
index 000000000000..fba49df6b3af
--- /dev/null
+++ b/app-misc/nut/files/nut-14.1-build-fixes.patch
@@ -0,0 +1,14 @@
+* Use $(CC) instead of gcc.
+* Honor LDFLAGS.
+* Put -l flags at the end so it doesn't break --as-needed linker flag (bug #246904)
+--- a/Makefile
++++ b/Makefile
+@@ -3,7 +3,7 @@
+ CFLAGS= -O3 -s -Wall -DNUTDIR=\".nutdb\" -DFOODDIR=\"/usr/local/lib/nut\" -ansi -pedantic
+
+ nut: $(objects)
+- gcc ${CFLAGS} -lm -o nut $(objects)
++ $(CC) ${CFLAGS} -o nut $(LDFLAGS) $(objects) -lm
+
+ deps:
+ makedepend *.c
diff --git a/app-misc/nut/nut-14.1.ebuild b/app-misc/nut/nut-14.1.ebuild
new file mode 100644
index 000000000000..e20f6b0b145f
--- /dev/null
+++ b/app-misc/nut/nut-14.1.ebuild
@@ -0,0 +1,36 @@
+# Copyright 1999-2008 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-misc/nut/nut-14.1.ebuild,v 1.1 2008/11/22 00:10:44 coldwind Exp $
+
+EAPI=2
+
+inherit eutils flag-o-matic toolchain-funcs
+
+DESCRIPTION="Record what you eat and analyze your nutrient levels"
+HOMEPAGE="http://nut.sourceforge.net/"
+SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~arm ~alpha ~amd64 ~ppc ~x86 ~amd64"
+IUSE=""
+
+DEPEND=""
+RDEPEND=""
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-build-fixes.patch
+}
+
+src_compile() {
+ append-flags '-DNUTDIR=\".nutdb\" -DFOODDIR=\"/usr/share/nut\"'
+ emake CC="$(tc-getCC)" CFLAGS="${CFLAGS}" || die "emake failed"
+}
+
+src_install() {
+ dodir /usr/share/nut
+ insinto /usr/share/nut
+ doins raw.data/*
+ dobin nut
+ doman nut.1
+}