Skip to content

Commit 7904ce5

Browse files
committed
build sources jars
1 parent 0880ba5 commit 7904ce5

File tree

1 file changed

+10
-4
lines changed

1 file changed

+10
-4
lines changed

build.xml

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
<zipfileset src="lib/generator/qdox-1.12.jar"/>
2323
<rule pattern="com.thoughtworks.qdox.**" result="org.hamcrest.generator.qdox.@1"/>
2424
</jarjar>
25+
<copy file="build/hamcrest-generator-${version}-nodeps-sources.jar" tofile="build/hamcrest-generator-${version}-sources.jar"/>
2526
</target>
2627

2728
<target name="core" depends="generator" description="Build core Hamcrest library">
@@ -203,13 +204,18 @@
203204
</classpath>
204205
</javac>
205206
<copy file="LICENSE.txt" todir="build/temp/@{modulename}.jar.contents"/>
206-
<!-- Put Java source in Jars for user's convenience. -->
207-
<copy todir="build/temp/@{modulename}.jar.contents">
208-
<fileset dir="@{srcdir}"/>
209-
</copy>
210207
<jar jarfile="build/@{modulename}.jar">
211208
<fileset dir="build/temp/@{modulename}.jar.contents"/>
212209
</jar>
210+
<copy file="LICENSE.txt" todir="build/temp/@{modulename}.jar.contents"/>
211+
212+
<!-- Build sources jar -->
213+
<copy todir="build/temp/@{modulename}-sources.jar.contents">
214+
<fileset dir="@{srcdir}"/>
215+
</copy>
216+
<jar jarfile="build/@{modulename}-sources.jar">
217+
<fileset dir="build/temp/@{modulename}-sources.jar.contents"/>
218+
</jar>
213219
</sequential>
214220
</macrodef>
215221

0 commit comments

Comments
 (0)