Gentoo Archives: gentoo-commits

From: "Michael Januszewski (spock)" <spock@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in dev-libs/protobuf: ChangeLog protobuf-2.0.1.ebuild
Date: Thu, 11 Sep 2008 20:16:58
Message-Id: E1Kdsb0-0002SP-Im@stork.gentoo.org
1 spock 08/09/11 20:16:54
2
3 Modified: ChangeLog
4 Added: protobuf-2.0.1.ebuild
5 Log:
6 Version bump.
7 (Portage version: 2.2_rc8/cvs/Linux 2.6.27-rc5 x86_64)
8
9 Revision Changes Path
10 1.2 dev-libs/protobuf/ChangeLog
11
12 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-libs/protobuf/ChangeLog?rev=1.2&view=markup
13 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-libs/protobuf/ChangeLog?rev=1.2&content-type=text/plain
14 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-libs/protobuf/ChangeLog?r1=1.1&r2=1.2
15
16 Index: ChangeLog
17 ===================================================================
18 RCS file: /var/cvsroot/gentoo-x86/dev-libs/protobuf/ChangeLog,v
19 retrieving revision 1.1
20 retrieving revision 1.2
21 diff -u -r1.1 -r1.2
22 --- ChangeLog 17 Jul 2008 23:16:44 -0000 1.1
23 +++ ChangeLog 11 Sep 2008 20:16:54 -0000 1.2
24 @@ -1,6 +1,12 @@
25 # ChangeLog for dev-libs/protobuf
26 # Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2
27 -# $Header: /var/cvsroot/gentoo-x86/dev-libs/protobuf/ChangeLog,v 1.1 2008/07/17 23:16:44 spock Exp $
28 +# $Header: /var/cvsroot/gentoo-x86/dev-libs/protobuf/ChangeLog,v 1.2 2008/09/11 20:16:54 spock Exp $
29 +
30 +*protobuf-2.0.1 (11 Sep 2008)
31 +
32 + 11 Sep 2008; MichaƂ Januszewski <spock@g.o>
33 + +files/protobuf-2.0.1-python-unittest.patch, +protobuf-2.0.1.ebuild:
34 + Version bump.
35
36 *protobuf-2.0.0_beta (17 Jul 2008)
37
38
39
40
41 1.1 dev-libs/protobuf/protobuf-2.0.1.ebuild
42
43 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-libs/protobuf/protobuf-2.0.1.ebuild?rev=1.1&view=markup
44 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-libs/protobuf/protobuf-2.0.1.ebuild?rev=1.1&content-type=text/plain
45
46 Index: protobuf-2.0.1.ebuild
47 ===================================================================
48 # Copyright 1999-2008 Gentoo Foundation
49 # Distributed under the terms of the GNU General Public License v2
50 # $Header: /var/cvsroot/gentoo-x86/dev-libs/protobuf/protobuf-2.0.1.ebuild,v 1.1 2008/09/11 20:16:54 spock Exp $
51
52 inherit eutils distutils python java-pkg-opt-2
53
54 MY_P=${PN}-${PV//_/}
55
56 DESCRIPTION="Google's Protocol Buffers -- an efficient method of encoding structured data"
57 HOMEPAGE="http://code.google.com/p/protobuf/"
58 SRC_URI="http://protobuf.googlecode.com/files/${MY_P}.tar.bz2"
59
60 LICENSE="Apache-2.0"
61 SLOT="0"
62 KEYWORDS="~amd64 ~x86"
63 IUSE="examples java python vim-syntax"
64
65 DEPEND="${DEPEND} java? ( >=virtual/jdk-1.5 )"
66 RDEPEND="${RDEPEND} java? ( >=virtual/jre-1.5 )"
67
68 S="${WORKDIR}/${MY_P}"
69
70 src_unpack() {
71 unpack ${A}
72 cd "${S}"
73 epatch "${FILESDIR}"/${P}-python-unittest.patch
74 }
75
76 src_compile() {
77 econf || die
78 emake || die
79
80 if use python; then
81 cd python; distutils_src_compile; cd ..
82 fi
83
84 if use java; then
85 src/protoc --java_out=java/src/main/java --proto_path=src src/google/protobuf/descriptor.proto
86 mkdir java/build
87 cd java/src/main/java
88 ejavac -d ../../../build $(find . -name '*.java') || die "java compilation failed"
89 cd ../../../..
90 jar cf ${PN}.jar -C java/build . || die "jar failed"
91 fi
92 }
93
94 src_install() {
95 emake DESTDIR="${D}" install
96 dodoc CHANGES.txt CONTRIBUTORS.txt README.txt
97
98 if use python; then
99 cd python; distutils_src_install; cd ..
100 fi
101
102 if use vim-syntax; then
103 insinto /usr/share/vim/vimfiles
104 doins editors/proto.vim
105 fi
106
107 if use examples; then
108 insinto /usr/share/doc/${PF}/examples
109 doins -r examples/* || die "doins examples failed"
110 fi
111
112 if use java; then
113 java-pkg_dojar ${PN}.jar
114 fi
115 }
116
117 src_test() {
118 emake check
119
120 if use python; then
121 cd python; ${python} setup.py test || die "python test failed"
122 cd ..
123 fi
124 }