Sync from SUSE:SLFO:Main servletapi4 revision 07a8f7a13400a04ac5bf9fbcbc4f797e

This commit is contained in:
Adrian Schröter 2024-05-04 00:34:10 +02:00
commit 6e3713d78b
5 changed files with 214 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

BIN
jakarta-servletapi-4-src.tar.gz (Stored with Git LFS) Normal file

Binary file not shown.

20
java160_build.patch Normal file
View File

@ -0,0 +1,20 @@
Index: jakarta-servletapi-4-src/build.xml
===================================================================
--- jakarta-servletapi-4-src.orig/build.xml
+++ jakarta-servletapi-4-src/build.xml
@@ -58,6 +58,7 @@
<!-- Java classes -->
<javac srcdir="src/share" destdir="${servletapi.build}/classes"
+ source="1.8" target="1.8"
debug="${compile.debug}" deprecation="${compile.deprecation}"
optimize="${compile.optimize}"/>
@@ -90,6 +91,7 @@
<target name="javadoc" depends="prepare">
<javadoc packagenames="javax.servlet.*"
+ source="1.8"
sourcepath="${basedir}/src/share"
destdir="${servletapi.build}/docs/api"
use="true"

73
servletapi4.changes Normal file
View File

@ -0,0 +1,73 @@
-------------------------------------------------------------------
Sat Mar 19 10:33:53 UTC 2022 - Fridrich Strba <fstrba@suse.com>
- Modified patch:
* java160_build.patch
+ build with source/target levels 8
-------------------------------------------------------------------
Mon Sep 18 12:47:42 UTC 2017 - fstrba@suse.com
- Modified patch:
* java160_build.patch
+ Don't switch off doclint; it is switched off by default
-------------------------------------------------------------------
Sun Sep 10 13:00:57 UTC 2017 - fstrba@suse.com
- Removed patch:
* java150_build.patch
- Added patch:
* java160_build.patch
+ Specify java source and target level 1.6 in order to allow
building with jdk9
+ Disable doclint, since errors of javadoc in jdk9 are fatal
-------------------------------------------------------------------
Tue Sep 29 20:07:26 UTC 2015 - dmueller@suse.com
- build against java-1_8_0-openjdk or newer if available
-------------------------------------------------------------------
Mon Jul 21 10:32:00 UTC 2014 - tchvatal@suse.com
- Cleanup with spec-cleaner
- Fix update-alternatives
-------------------------------------------------------------------
Fri Feb 7 08:46:53 UTC 2014 - fcrozat@suse.com
- Fix license tag, should be Apache-1.1
-------------------------------------------------------------------
Mon Sep 9 11:06:21 UTC 2013 - tchvatal@suse.com
- Move from jpackage-utils to javapackage-tools
-------------------------------------------------------------------
Mon Sep 25 16:34:45 CEST 2006 - dbornkessel@suse.de
- fixes necessary to compile with Java 1.5.0
- set source="1.4" and target="1.4" for ant "javac" tasks
- set source="1.4" for ant "javadoc" tasks
-------------------------------------------------------------------
Wed Jan 25 21:47:49 CET 2006 - mls@suse.de
- converted neededforbuild to BuildRequires
-------------------------------------------------------------------
Thu Sep 29 02:44:41 CEST 2005 - dmueller@suse.de
- add norootforbuild
-------------------------------------------------------------------
Thu Sep 16 20:07:19 CEST 2004 - skh@suse.de
- Fix prerequires
-------------------------------------------------------------------
Thu Sep 2 17:05:19 CEST 2004 - skh@suse.de
- Initial package created with version 4.0.4 (JPackage 1.5)

95
servletapi4.spec Normal file
View File

@ -0,0 +1,95 @@
#
# spec file for package servletapi4
#
# Copyright (c) 2022 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%define base_name servletapi
%define full_name jakarta-%{base_name}
Name: servletapi4
Version: 4.0.4
Release: 0
Summary: Java servlet and JSP implementation classes
License: Apache-1.1
Group: Development/Libraries/Java
URL: http://jakarta.apache.org/tomcat/
Source: %{full_name}-4-src.tar.gz
Patch160: java160_build.patch
BuildRequires: ant
BuildRequires: ant >= 1.2
BuildRequires: java-devel >= 1.8
BuildRequires: javapackages-tools
BuildRequires: xml-commons-apis
Requires(post): %{_sbindir}/update-alternatives
Provides: servlet = %{version}
Obsoletes: servlet22 < %{version}
Obsoletes: servlet4 < %{version}
Provides: servlet22 = %{version}
Provides: servlet4 = %{version}
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildArch: noarch
%description
This subproject contains the source code for the implementation classes
of the Java Servlet and JSP APIs (packages javax.servlet).
%package javadoc
Summary: Javadoc for servletapi4
Group: Development/Libraries/Java
%description javadoc
This subproject contains the source code for the implementation classes
of the Java Servlet and JSP APIs (packages javax.servlet). This package
contains the javadoc documentation for the Java Servlet and JSP APIs.
%prep
%setup -q -n %{full_name}-4-src
%patch160 -p1
%build
ant dist -Dservletapi.build=build -Dservletapi.dist=dist
%install
# jars
install -d -m 755 %{buildroot}%{_javadir}
install -m 644 dist/lib/servlet.jar %{buildroot}%{_javadir}/%{name}-%{version}.jar
(cd %{buildroot}%{_javadir} && for jar in *-%{version}*; do ln -sf ${jar} `echo $jar| sed "s|-%{version}||g"`; done)
# javadoc
install -d -m 755 %{buildroot}%{_javadocdir}/%{name}
cp -pr build/docs/api/* %{buildroot}%{_javadocdir}/%{name}
# alternatives
mkdir -p %{buildroot}%{_sysconfdir}/alternatives/
ln -sf %{_sysconfdir}/alternatives/servlet.jar %{buildroot}%{_javadir}/servlet.jar
%post
update-alternatives --install %{_javadir}/servlet.jar servlet %{_javadir}/%{name}-%{version}.jar 40
%postun
if [ "$1" = "0" ]; then
update-alternatives --remove servlet %{_javadir}/%{name}-%{version}.jar
fi
%files
%defattr(-,root,root)
%doc LICENSE README.txt
%{_javadir}/*
%{_javadir}/servlet.jar
%ghost %{_sysconfdir}/alternatives/servlet.jar
%files javadoc
%defattr(-,root,root)
%{_javadocdir}/%{name}
%changelog