SPECS: commons-el.spec (NEW) - heavily modified, but based on jpac...

glen glen at pld-linux.org
Wed Apr 11 01:22:22 CEST 2007


Author: glen                         Date: Tue Apr 10 23:22:22 2007 GMT
Module: SPECS                         Tag: HEAD
---- Log message:
- heavily modified, but based on jpackage spec

---- Files affected:
SPECS:
   commons-el.spec (NONE -> 1.1)  (NEW)

---- Diffs:

================================================================
Index: SPECS/commons-el.spec
diff -u /dev/null SPECS/commons-el.spec:1.1
--- /dev/null	Wed Apr 11 01:22:22 2007
+++ SPECS/commons-el.spec	Wed Apr 11 01:22:17 2007
@@ -0,0 +1,119 @@
+# $Revision$, $Date$
+#
+# Conditional build:
+%bcond_with	bootstrap	# bootstrap (using binary servletapi5/jsp)
+#
+%include	/usr/lib/rpm/macros.java
+Summary:	The Jakarta Commons Extension Language
+Name:		commons-el
+Version:	1.0
+Release:	0.1
+License:	Apache Software License
+Group:		Development/Languages/Java
+URL:		http://jakarta.apache.org/commons/el/
+Source0:	http://www.apache.org/dist/jakarta/commons/el/source/%{name}-%{version}-src.tar.gz
+# Source0-md5:	25038283a0b5f638db5e891295d20020
+Source1:	http://www.apache.org/dist/tomcat/tomcat-5/v5.5.23/bin/apache-tomcat-5.5.23.zip
+# Source1-md5:	4a7e5c2ff3c20a114fbfc5a122d7247c
+Patch0:		%{name}-license.patch
+Patch1:		%{name}-ant.patch
+BuildRequires:	ant
+BuildRequires:	jpackage-utils >= 0:1.6
+BuildRequires:	junit
+BuildRequires:	rpm-javaprov
+BuildRequires:	rpmbuild(macros) >= 1.300
+%if %{without bootstrap}
+BuildRequires:	jsp
+BuildRequires:	servletapi5
+%endif
+BuildArch:	noarch
+BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+An implementation of standard interfaces and abstract classes for
+javax.servlet.jsp.el which is part of the JSP 2.0 specification.
+
+%package javadoc
+Summary:	Javadoc for %{name}
+Group:		Documentation
+Requires:	jpackage-utils
+
+%description    javadoc
+Javadoc for %{name}.
+
+%prep
+%setup -q -n %{name}-%{version}-src %{?with_bootstrap:-a1}
+%patch0 -p1
+%patch1 -p1
+%if %{with bootstrap}
+ln -s apache-tomcat-* tomcat
+%endif
+
+%build
+%if %{with bootstrap}
+dir=$(pwd)
+servlet_api=$dir/tomcat/common/lib/servlet-api.jar
+jsp_api=$dir/tomcat/common/lib/jsp-api.jar
+%else
+servlet_api=$(build-classpath build-classpath servletapi5)
+jsp_api=$(build-classpath build-classpath jspapi)
+%endif
+
+cat > build.properties <<EOF
+build.compiler=modern
+junit.jar=$(build-classpath junit)
+servlet-api.jar=$servlet_api
+jsp-api.jar=$jsp_api
+servletapi.build.notrequired=true
+jspapi.build.notrequired=true
+EOF
+
+%ant \
+	-Dcompile.source=1.4 \
+	-Dfinal.name=commons-el \
+	-Dj2se.javadoc=%{_javadocdir}/java \
+	jar javadoc
+
+%install
+rm -rf $RPM_BUILD_ROOT
+install -d $RPM_BUILD_ROOT%{_javadir}
+for a in dist/*.jar; do
+	jar=${a##*/}
+	cp -a dist/$jar $RPM_BUILD_ROOT%{_javadir}/${jar%%.jar}-%{version}.jar
+	ln -s ${jar%%.jar}-%{version}.jar $RPM_BUILD_ROOT%{_javadir}/$jar
+done
+
+# javadoc
+install -d $RPM_BUILD_ROOT%{_javadocdir}/%{name}-%{version}
+cp -pr dist/docs/api/* $RPM_BUILD_ROOT%{_javadocdir}/%{name}-%{version}
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%post javadoc
+rm -f %{_javadocdir}/%{name}
+ln -s %{name}-%{version} %{_javadocdir}/%{name}
+
+%postun javadoc
+if [ "$1" = "0" ]; then
+	rm -f %{_javadocdir}/%{name}
+fi
+
+%files
+%defattr(644,root,root,755)
+%doc LICENSE.txt STATUS.html
+%{_javadir}/*.jar
+
+%files javadoc
+%defattr(644,root,root,755)
+%{_javadocdir}/%{name}-%{version}
+
+%define date	%(echo `LC_ALL="C" date +"%a %b %d %Y"`)
+%changelog
+* %{date} PLD Team <feedback at pld-linux.org>
+All persons listed below can be reached at <cvs_login>@pld-linux.org
+
+$Log$
+Revision 1.1  2007/04/10 23:22:17  glen
+- heavily modified, but based on jpackage spec
+
================================================================


More information about the pld-cvs-commit mailing list