- builds now auto/th/ant-contrib-1_0-0_b2_1
authorElan Ruusamäe <glen@pld-linux.org>
Fri, 21 Oct 2011 21:46:59 +0000 (21:46 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    ant-contrib.spec -> 1.2

ant-contrib.spec

index 40a6cd0656e1bcd89436d9d97a75f303e76dfc9d..489e828bf42cec6a34433f9e81eb608b78f459f5 100644 (file)
@@ -1,11 +1,9 @@
-# TODO
-# - some deps missing:
-#build_contrib_jar:
-#    [javac] Compiling 88 source files to ant-contrib/build/classes
-#    [javac] ant-contrib/src/net/sf/antcontrib/antserver/server/ConnectionHandler.java:22: package org.apache.xml.serialize does not exist
-
-%define                subver b2
-%define                rel     0.1
+#
+# Conditional build:
+%bcond_without javadoc         # don't build javadoc
+
+%define                subver  b2
+%define                rel             1
 Summary:       Collection of tasks for Ant
 Name:          ant-contrib
 Version:       1.0
@@ -18,6 +16,7 @@ Source0:      http://downloads.sourceforge.net/ant-contrib/%{name}-%{version}%{subver
 Patch0:                build_xml.patch
 Patch2:                antservertest.patch
 BuildRequires: ant-junit >= 1.6.2
+BuildRequires: ant >= 1.6
 BuildRequires: java(jaxp_parser_impl)
 BuildRequires: java-bcel >= 5.0
 BuildRequires: java-junit >= 3.8.0
@@ -53,18 +52,24 @@ install -d test/lib
 
 %build
 junit_jar=$(find-jar junit)
-ln -s $junit_jar test/lib/junit-$(JUNIT_VER).jar
+xerces_jar=$(find-jar xercesImpl)
+ln -sf $junit_jar test/lib
+ln -sf $xerces_jar lib
 
 export OPT_JAR_LIST="ant/ant-junit junit"
 export CLASSPATH=
 CLASSPATH=build/lib/ant-contrib-%{version}.jar:$CLASSPATH
-echo $ANT_HOME
-%ant -Dsource=1.4 -Dversion=%{version} -Dbcel.jar=file://%{_javadir}/bcel.jar all
+%ant jar %{?with_javadoc:docs} \
+       -Djavac.target=1.4 \
+       -Djavac.source=1.4 \
+       -Dversion=%{version} \
+       -Dbcel.jar=file://%{_javadir}/bcel.jar
 
 %install
 rm -rf $RPM_BUILD_ROOT
 
 # jars
+install -d $RPM_BUILD_ROOT%{_javadir}/ant
 cp -p build/lib/%{name}.jar $RPM_BUILD_ROOT%{_javadir}/ant/%{name}.jar
 
 # javadoc
@@ -89,7 +94,9 @@ ln -nfs %{name}-%{version} %{_javadocdir}/%{name}
 %{_sysconfdir}/ant.d/ant-contrib
 %{_javadir}/ant/*.jar
 
+%if %{with javadoc}
 %files javadoc
 %defattr(644,root,root,755)
 %doc %{_javadocdir}/%{name}-%{version}
 %doc %{_javadocdir}/%{name}
+%endif
This page took 0.06345 seconds and 4 git commands to generate.