67 lines
2.2 KiB
RPMSpec
67 lines
2.2 KiB
RPMSpec
Name: gnu-getopt
|
|
Version: 1.0.14
|
|
Release: 15
|
|
Summary: Java port of GNU getopt
|
|
License: LGPLv2+
|
|
URL: http://www.urbanophile.com/arenn/hacking/download.html
|
|
Source0: http://www.urbanophile.com/arenn/hacking/getopt/java-getopt-%{version}.tar.gz
|
|
Source1: gnu-getopt-%{version}.pom
|
|
|
|
Provides: gnu.getopt = %{version}-%{release}
|
|
Obsoletes: gnu.getopt < %{version}-%{release}
|
|
BuildArch: noarch
|
|
BuildRequires: ant javapackages-local
|
|
Requires: java-headless jpackage-utils
|
|
|
|
%description
|
|
The GNU Java getopt classes support short and long argument parsing in a manner 100% compatible
|
|
with the version of GNU getopt in glibc 2.0.6 with a mostly compatible programmer's interface as well.
|
|
Note that this is a port, not a new implementation. I am currently unaware of any bugs in this software,
|
|
but there certainly could be some lying about. I would appreciate bug reports as well as
|
|
hearing about positive experiences.
|
|
|
|
%package help
|
|
Summary: Help document for gnu-getopt
|
|
Requires: jpackage-utils
|
|
Provides: gnu.getopt-javadoc = %{version}-%{release}
|
|
Provides: gnu-getopt-javadoc = %{version}-%{release}
|
|
Obsoletes: gnu.getopt-javadoc < %{version}-%{release}
|
|
Obsoletes: gnu-getopt-javadoc < %{version}-%{release}
|
|
|
|
%description help
|
|
Help document for gnu-getopt.
|
|
|
|
%prep
|
|
%autosetup -c -p1
|
|
mv gnu/getopt/buildx.xml build.xml
|
|
|
|
%build
|
|
ant jar javadoc
|
|
|
|
%install
|
|
install -d -m 755 {%{buildroot}%{_javadir},%{buildroot}%{_mavenpomdir},%{buildroot}%{_javadocdir}/gnu-getopt}
|
|
|
|
install -p -m 644 build/lib/gnu.getopt.jar %{buildroot}%{_javadir}/gnu-getopt.jar
|
|
ln -sf gnu-getopt.jar %{buildroot}%{_javadir}/gnu.getopt.jar
|
|
|
|
install -p -m 644 %{SOURCE1} %{buildroot}%{_mavenpomdir}/JPP-gnu-getopt.pom
|
|
%add_maven_depmap -a urbanophile:java-getopt,gnu.getopt:java-getopt
|
|
|
|
cp -pr build/api/* %{buildroot}%{_javadocdir}/gnu-getopt
|
|
|
|
%pre help
|
|
[ $1 -gt 1 ] && [ -L %{_javadocdir}/gnu-getopt ] && \
|
|
rm -rf $(readlink -f %{_javadocdir}/gnu-getopt) %{_javadocdir}/gnu-getopt || :
|
|
|
|
%files -f .mfiles
|
|
%doc gnu/getopt/COPYING.LIB
|
|
%{_javadir}/gnu.getopt.jar
|
|
|
|
%files help
|
|
%doc gnu/getopt/README
|
|
%{_javadocdir}/gnu-getopt
|
|
|
|
%changelog
|
|
* Fri Dec 20 2019 qinjian <qinjian18@huawei.com> - 0:1.0.14-15
|
|
- Package init
|