Gentoo Archives: gentoo-commits

From: "Diego Petteno (flameeyes)" <flameeyes@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in dev-util/perf: perf-2.6.33_rc2.ebuild ChangeLog perf-2.6.33_rc1.ebuild
Date: Mon, 28 Dec 2009 00:47:45
Message-Id: E1NP3lo-00034w-F3@stork.gentoo.org
1 flameeyes 09/12/28 00:47:36
2
3 Modified: ChangeLog
4 Added: perf-2.6.33_rc2.ebuild
5 Removed: perf-2.6.33_rc1.ebuild
6 Log:
7 Version bump and cleanup previous rc.
8 (Portage version: 2.2_rc61/cvs/Linux x86_64)
9
10 Revision Changes Path
11 1.9 dev-util/perf/ChangeLog
12
13 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-util/perf/ChangeLog?rev=1.9&view=markup
14 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-util/perf/ChangeLog?rev=1.9&content-type=text/plain
15 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-util/perf/ChangeLog?r1=1.8&r2=1.9
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/dev-util/perf/ChangeLog,v
20 retrieving revision 1.8
21 retrieving revision 1.9
22 diff -u -r1.8 -r1.9
23 --- ChangeLog 19 Dec 2009 13:14:29 -0000 1.8
24 +++ ChangeLog 28 Dec 2009 00:47:36 -0000 1.9
25 @@ -1,6 +1,12 @@
26 # ChangeLog for dev-util/perf
27 # Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/dev-util/perf/ChangeLog,v 1.8 2009/12/19 13:14:29 flameeyes Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/dev-util/perf/ChangeLog,v 1.9 2009/12/28 00:47:36 flameeyes Exp $
30 +
31 +*perf-2.6.33_rc2 (28 Dec 2009)
32 +
33 + 28 Dec 2009; Diego E. Pettenò <flameeyes@g.o>
34 + -perf-2.6.33_rc1.ebuild, +perf-2.6.33_rc2.ebuild:
35 + Version bump and cleanup previous rc.
36
37 *perf-2.6.33_rc1 (19 Dec 2009)
38
39
40
41
42 1.1 dev-util/perf/perf-2.6.33_rc2.ebuild
43
44 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-util/perf/perf-2.6.33_rc2.ebuild?rev=1.1&view=markup
45 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-util/perf/perf-2.6.33_rc2.ebuild?rev=1.1&content-type=text/plain
46
47 Index: perf-2.6.33_rc2.ebuild
48 ===================================================================
49 # Copyright 1999-2009 Gentoo Foundation
50 # Distributed under the terms of the GNU General Public License v2
51 # $Header: /var/cvsroot/gentoo-x86/dev-util/perf/perf-2.6.33_rc2.ebuild,v 1.1 2009/12/28 00:47:36 flameeyes Exp $
52
53 EAPI=2
54
55 inherit versionator eutils toolchain-funcs linux-info
56
57 MY_PV="${PV/_/-}"
58 MY_PV="${MY_PV/-pre/-git}"
59
60 DESCRIPTION="Userland tools for Linux Performance Counters"
61 HOMEPAGE="http://perf.wiki.kernel.org/"
62
63 LINUX_V=$(get_version_component_range 1-2)
64
65 if [ ${PV/_rc} != ${PV} ]; then
66 LINUX_VER=$(get_version_component_range 1-2).$(($(get_version_component_range 3)-1))
67 PATCH_VERSION=$(get_version_component_range 1-3)
68 LINUX_PATCH=patch-${PV//_/-}.bz2
69 SRC_URI="mirror://kernel/linux/kernel/v${LINUX_V}/testing/${LINUX_PATCH}
70 mirror://kernel/linux/kernel/v${LINUX_V}/testing/v${PATCH_VERSION}/${LINUX_PATCH}"
71 else
72 LINUX_VER=${PV}
73 fi
74
75 LINUX_SOURCES=linux-${LINUX_VER}.tar.bz2
76 SRC_URI="${SRC_URI} mirror://kernel/linux/kernel/v${LINUX_V}/${LINUX_SOURCES}"
77
78 LICENSE="GPL-2"
79 SLOT="0"
80 KEYWORDS="~amd64"
81 IUSE="+demangle +doc"
82
83 RDEPEND="demangle? ( sys-devel/binutils )
84 dev-libs/elfutils"
85 DEPEND="${RDEPEND}
86 ${LINUX_PATH+dev-util/patchutils}
87 doc? ( app-text/asciidoc app-text/xmlto )"
88
89 S="${WORKDIR}/linux-${LINUX_VER}/tools/perf"
90
91 CONFIG_CHECK="~PERF_EVENTS ~KALLSYMS"
92
93 src_unpack() {
94 local _tarpattern=
95 local _filterdiff=
96 for _pattern in {tools/perf,include,lib,"arch/*/include"}; do
97 _tarpattern="${_tarpattern} linux-${LINUX_VER}/${_pattern}"
98 _filterdiff="${_filterdiff} -i ${_pattern}/*"
99 done
100
101 # We expect the tar implementation to support the -j option (both
102 # GNU tar and libarchive's tar support that).
103 ebegin "Unpacking partial source tarball"
104 tar --wildcards -xpf "${DISTDIR}"/${LINUX_SOURCES} ${_tarpattern}
105 eend $? || die "tar failed"
106
107 ebegin "Filtering partial source patch"
108 filterdiff ${_filterdiff} -z "${DISTDIR}"/${LINUX_PATCH} > ${P}.patch || die
109 eend $? || die "filterdiff failed"
110
111 MY_A=
112 for _AFILE in ${A}; do
113 [[ ${_AFILE} == ${LINUX_SOURCES} ]] && continue
114 [[ ${_AFILE} == ${LINUX_PATCH} ]] && continue
115 MY_A="${MY_A} ${_AFILE}"
116 done
117 [[ -n ${MY_A} ]] && unpack ${MY_A}
118 }
119
120 src_prepare() {
121 # Drop some upstream too-developer-oriented flags and fix the
122 # Makefile in general
123 sed -i \
124 -e 's:-Werror::' \
125 -e 's:-ggdb3::' \
126 -e 's:-fstack-protector-all::' \
127 -e 's:^LDFLAGS =:EXTLIBS +=:' \
128 -e '/-x c - /s:\$(ALL_LDFLAGS):\0 $(EXTLIBS):' \
129 -e '/^ALL_CFLAGS =/s:$: $(CFLAGS_OPTIMIZE):' \
130 -e '/^ALL_LDFLAGS =/s:$: $(LDFLAGS_OPTIMIZE):' \
131 "${S}"/Makefile
132
133 if [[ -n ${LINUX_PATCH} ]]; then
134 epatch "${WORKDIR}"/${P}.patch
135 fi
136 }
137
138 src_compile() {
139 local makeargs=
140
141 use demangle || makeargs="${makeargs} NO_DEMANGLE= "
142
143 emake ${makeargs} \
144 CC="$(tc-getCC)" AR="$(tc-getAR)" \
145 prefix="/usr" bindir_relative="sbin" \
146 CFLAGS_OPTIMIZE="${CFLAGS}" \
147 LDFLAGS_OPTIMIZE="${LDFLAGS}" || die
148
149 if use doc; then
150 pushd Documentation
151 emake ${makeargs} || die
152 popd
153 fi
154 }
155
156 src_test() {
157 :
158 }
159
160 src_install() {
161 # Don't use make install or it'll be re-building the stuff :(
162 dobin perf || die
163
164 dodoc CREDITS || die
165
166 if use doc; then
167 dodoc Documentation/*.txt || die
168 dohtml Documentation/*.html || die
169 doman Documentation/*.1 || die
170 fi
171 }
172
173 pkg_postinst() {
174 if ! use doc; then
175 elog "Without the doc USE flag you won't get any documentation nor man pages."
176 elog "And without man pages, you won't get any --help output for perf and its"
177 elog "sub-tools."
178 fi
179 }