Skip to content

Commit 2a9d399

Browse files
committed
Merge remote-tracking branch 'origin/master'
2 parents eb78a33 + b3a875e commit 2a9d399

File tree

2 files changed

+52
-0
lines changed

2 files changed

+52
-0
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,3 +14,4 @@ out
1414
*.sublime-project
1515
*.sublime-workspace
1616
build-local.properties
17+
deps

perf-build.xml

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,15 @@
77
<property name="dir.resources.sbe" location="perf/resources/sbe"/>
88
<property name="dir.resources.protobuf" location="perf/resources/protobuf"/>
99

10+
<property name="dir.target.perf" location="target/perf"/>
1011
<property name="dir.target.perf.classes" location="target/perf/classes"/>
1112
<property name="dir.target.perf.java" location="target/perf/java"/>
1213
<property name="dir.target.perf.dist" location="target/perf/dist"/>
1314
<property name="dir.target.perf.cpp" location="target/perf/cpp"/>
1415

16+
<property name="dir.deps" location="deps"/>
17+
<property name="dir.deps.protobuf.build" location="deps/pb"/>
18+
1519
<property file="build-local.properties"/>
1620

1721
<path id="perf.tools.classpath">
@@ -123,4 +127,51 @@
123127
</sequential>
124128
</target>
125129

130+
<target name="deps:init" depends="">
131+
<mkdir dir="${dir.deps}"/>
132+
<mkdir dir="${dir.deps.protobuf.build}"/>
133+
</target>
134+
135+
<target name="deps:clean" depends="">
136+
<delete dir="${dir.deps}"/>
137+
</target>
138+
139+
<target name="protobuf:download" depends="deps:init">
140+
<sequential>
141+
<local name="protobuf.name"/>
142+
<local name="sha.fail"/>
143+
<local name="cksum.fail"/>
144+
<property name="protobuf.name" value="protobuf-2.5.0.tar.gz"/>
145+
<get dest="/tmp">
146+
<url url="https://protobuf.googlecode.com/files/${protobuf.name}"/>
147+
</get>
148+
<checksum file="/tmp/${protobuf.name}" algorithm="sha1" property="7f6ea7bc1382202fb1ce8c6933f1ef8fea0c0148" verifyproperty="sha.fail"/>
149+
<condition property="cksum.fail">
150+
<equals arg1="${sha.fail}" arg2="false"/>
151+
</condition>
152+
<fail if="cksum.fail">Checksum failed</fail>
153+
<copy file="/tmp/${protobuf.name}" todir="${dir.deps.protobuf.build}"/>
154+
</sequential>
155+
</target>
156+
157+
<target name="protobuf:unpack" depends="deps:init, protobuf:download">
158+
<!-- untar/unzip, etc. won't preserve executable bits... grumble... -->
159+
<exec executable="tar" dir="${dir.deps.protobuf.build}" failonerror="true">
160+
<arg value="xzf"/>
161+
<arg value="protobuf-2.5.0.tar.gz"/>
162+
</exec>
163+
</target>
164+
165+
<target name="protobuf:build" depends="protobuf:unpack">
166+
<sequential>
167+
<exec executable="./configure" dir="${dir.deps.protobuf.build}/protobuf-2.5.0" output="${dir.deps.protobuf.build}/protobuf-configure.out" failonerror="true">
168+
<arg value="--prefix=${dir.deps}/protobuf-2.5.0"/>
169+
</exec>
170+
<exec executable="make" dir="${dir.deps.protobuf.build}/protobuf-2.5.0" output="${dir.deps.protobuf.build}/protobuf-make.out" failonerror="true"/>
171+
<exec executable="make" dir="${dir.deps.protobuf.build}/protobuf-2.5.0" output="${dir.deps.protobuf.build}/protobuf-make-insta.out" failonerror="true">
172+
<arg value="install"/>
173+
</exec>
174+
</sequential>
175+
</target>
176+
126177
</project>

0 commit comments

Comments
 (0)