packages: java-jargs/java-jargs.spec (NEW) - initial PLD release

pawelz pawelz at pld-linux.org
Mon May 3 02:26:27 CEST 2010


Author: pawelz                       Date: Mon May  3 00:26:27 2010 GMT
Module: packages                      Tag: HEAD
---- Log message:
- initial PLD release

---- Files affected:
packages/java-jargs:
   java-jargs.spec (NONE -> 1.1)  (NEW)

---- Diffs:

================================================================
Index: packages/java-jargs/java-jargs.spec
diff -u /dev/null packages/java-jargs/java-jargs.spec:1.1
--- /dev/null	Mon May  3 02:26:27 2010
+++ packages/java-jargs/java-jargs.spec	Mon May  3 02:26:21 2010
@@ -0,0 +1,135 @@
+# $Revision$, $Date$
+#
+# Conditional build:
+%bcond_without	javadoc		# don't build javadoc
+%bcond_without	source		# don't build source jar
+
+%include	/usr/lib/rpm/macros.java
+
+%define		srcname		jargs
+Summary:	Java command line option parsing suite
+Summary(pl.UTF-8):	Biblioteka do analizy argumentów wiersza poleceń dla Javy
+Name:		java-jargs
+Version:	1.0
+Release:	0.1
+License:	BSD
+Group:		Libraries/Java
+Source0:	http://downloads.sourceforge.net/project/jargs/jargs/1.0/jargs-%{version}.tar.bz2
+# Source0-md5:	9b86c8ebd69069a19e8424df2af349f0
+URL:		http://jargs.sourceforge.net/
+BuildRequires:	ant
+BuildRequires:	jpackage-utils
+BuildRequires:	rpm-javaprov
+BuildRequires:	rpmbuild(macros) >= 1.300
+# for %%undos macro
+BuildRequires:	rpmbuild(macros) >= 1.553
+%if %{with source}
+BuildRequires:	rpmbuild(macros) >= 1.555
+%endif
+BuildRequires:	sed >= 4.0
+# for %{_javadir}
+Requires:	jpackage-utils
+BuildArch:	noarch
+BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+This tiny project provides a convenient, compact, pre-packaged and
+comprehensively documented suite of command line option parsers for
+the use of Java programmers. Initially, parsing compatible with
+GNU-style 'getopt' is provided.
+
+%package javadoc
+Summary:	Online manual for %{srcname}
+Summary(pl.UTF-8):	Dokumentacja online do %{srcname}
+Group:		Documentation
+Requires:	jpackage-utils
+
+%description javadoc
+Documentation for %{srcname}.
+
+%description javadoc -l pl.UTF-8
+Dokumentacja do %{srcname}.
+
+%description javadoc -l fr.UTF-8
+Javadoc pour %{srcname}.
+
+%package source
+Summary:	Source code of %{srcname}
+Summary(pl.UTF-8):	Kod źródłowy %{srcname}
+Group:		Documentation
+Requires:	jpackage-utils >= 1.7.5-2
+
+%description source
+Source code of %{srcname}.
+
+%description source -l pl.UTF-8
+Kod źródłowy %{srcname}.
+
+%prep
+%setup -q -n %{srcname}-%{version}
+find -name '*.class'
+rm -rf docs/api
+
+%build
+export CLASSPATH
+
+export LC_ALL=en_US # source code not US-ASCII
+
+%ant
+
+%if %{with source}
+%jar cf %{srcname}.src.jar -C src .
+%endif
+
+%install
+rm -rf $RPM_BUILD_ROOT
+install -d $RPM_BUILD_ROOT%{_javadir}
+
+# jars
+cp -a lib/%{srcname}.jar $RPM_BUILD_ROOT%{_javadir}/%{srcname}-%{version}.jar
+ln -s %{srcname}-%{version}.jar $RPM_BUILD_ROOT%{_javadir}/%{srcname}.jar
+
+# javadoc
+%if %{with javadoc}
+install -d $RPM_BUILD_ROOT%{_javadocdir}/%{srcname}-%{version}
+cp -a doc/api/* $RPM_BUILD_ROOT%{_javadocdir}/%{srcname}-%{version}
+ln -s %{srcname}-%{version} $RPM_BUILD_ROOT%{_javadocdir}/%{srcname} # ghost symlink
+%endif
+
+# source
+install -d $RPM_BUILD_ROOT%{_javasrcdir}
+cp -a %{srcname}.src.jar $RPM_BUILD_ROOT%{_javasrcdir}/%{srcname}.src.jar
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%post javadoc
+ln -nfs %{srcname}-%{version} %{_javadocdir}/%{srcname}
+
+%files
+%defattr(644,root,root,755)
+%{_javadir}/%{srcname}.jar
+%{_javadir}/%{srcname}-%{version}.jar
+
+%if %{with javadoc}
+%files javadoc
+%defattr(644,root,root,755)
+%{_javadocdir}/%{srcname}-%{version}
+%ghost %{_javadocdir}/%{srcname}
+%endif
+
+%if %{with source}
+%files source
+%defattr(644,root,root,755)
+%{_javasrcdir}/%{srcname}.src.jar
+%endif
+
+%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  2010/05/03 00:26:21  pawelz
+- initial PLD release
+
================================================================


More information about the pld-cvs-commit mailing list