!1 添加源代码

Merge pull request !1 from sherlock2010/master
This commit is contained in:
openeuler-ci-bot 2019-12-21 18:26:12 +08:00 committed by Gitee
commit babd3e2b4b
3 changed files with 90 additions and 0 deletions

24
gnu-getopt-1.0.14.pom Normal file
View File

@ -0,0 +1,24 @@
<?xml version="1.0"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>gnu-getopt</groupId>
<artifactId>getopt</artifactId>
<version>1.0.14</version>
<name>ON Enterprise Server JAR</name>
<description>JON enterprise server main JAR</description>
<url>http://www.urbanophile.com/arenn/hacking/download.html</url>
<licenses>
<license>
<name>GNU Lesser General Public License (LGPL)</name>
<url>http://www.gnu.org/licenses/lgpl.html</url>
</license>
</licenses>
</project>

66
gnu-getopt.spec Normal file
View File

@ -0,0 +1,66 @@
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

BIN
java-getopt-1.0.14.tar.gz Normal file

Binary file not shown.