Init jakarta-servlet
(cherry picked from commit c570ea3ebc65148bc9ab3ecb8e4111ae5572fd57)
This commit is contained in:
parent
18e25fd61f
commit
61accc61ca
67
jakarta-servlet.spec
Normal file
67
jakarta-servlet.spec
Normal file
@ -0,0 +1,67 @@
|
|||||||
|
%bcond_with bootstrap
|
||||||
|
|
||||||
|
Name: jakarta-servlet
|
||||||
|
Version: 5.0.0
|
||||||
|
Release: 1
|
||||||
|
Summary: Server-side API for handling HTTP requests and responses
|
||||||
|
License: (EPL-2.0 or GPLv2 with exceptions) and ASL 2.0
|
||||||
|
URL: https://github.com/eclipse-ee4j/servlet-api
|
||||||
|
BuildArch: noarch
|
||||||
|
|
||||||
|
Source0: https://github.com/eclipse-ee4j/servlet-api/archive/%{version}-RELEASE/servlet-api-%{version}.tar.gz
|
||||||
|
|
||||||
|
BuildRequires: maven-local
|
||||||
|
%if %{with bootstrap}
|
||||||
|
BuildRequires: javapackages-bootstrap
|
||||||
|
%else
|
||||||
|
BuildRequires: mvn(org.apache.felix:maven-bundle-plugin)
|
||||||
|
BuildRequires: mvn(org.codehaus.mojo:build-helper-maven-plugin)
|
||||||
|
%endif
|
||||||
|
|
||||||
|
Provides: glassfish-servlet-api = %{version}-%{release}
|
||||||
|
|
||||||
|
%description
|
||||||
|
Jakarta Servlet defines a server-side API for handling HTTP requests
|
||||||
|
and responses.
|
||||||
|
|
||||||
|
%{?javadoc_package}
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%setup -q -n servlet-api-%{version}-RELEASE
|
||||||
|
|
||||||
|
%pom_remove_parent . api
|
||||||
|
|
||||||
|
%pom_disable_module spec
|
||||||
|
|
||||||
|
cp -pr api/src/main/java/jakarta api/src/main/java/javax
|
||||||
|
sed -i -e 's/jakarta\./javax./g' $(find api/src/main/java/javax -name *.java)
|
||||||
|
%pom_xpath_replace pom:instructions/pom:Export-Package \
|
||||||
|
'<Export-Package>jakarta.servlet.*,javax.servlet.*;version="4.0.0"</Export-Package>' api
|
||||||
|
|
||||||
|
%mvn_package jakarta.servlet:servlet-parent __noinstall
|
||||||
|
|
||||||
|
%pom_remove_plugin -r :formatter-maven-plugin
|
||||||
|
%pom_remove_plugin -r :impsort-maven-plugin
|
||||||
|
%pom_remove_plugin -r :maven-enforcer-plugin
|
||||||
|
%pom_remove_plugin -r :maven-javadoc-plugin
|
||||||
|
%pom_remove_plugin -r :maven-source-plugin
|
||||||
|
|
||||||
|
%mvn_alias jakarta.servlet:jakarta.servlet-api \
|
||||||
|
javax.servlet:javax.servlet-api \
|
||||||
|
javax.servlet:servlet-api
|
||||||
|
|
||||||
|
%mvn_file :{*} %{name}/@1 glassfish-servlet-api
|
||||||
|
|
||||||
|
%build
|
||||||
|
%mvn_build
|
||||||
|
|
||||||
|
%install
|
||||||
|
%mvn_install
|
||||||
|
|
||||||
|
%files -f .mfiles
|
||||||
|
%license LICENSE.md NOTICE.md
|
||||||
|
%doc README.md
|
||||||
|
|
||||||
|
%changelog
|
||||||
|
* Thu Dec 23 2021 houyingchao<houyingchao@huawei.com> - 5.0.0-1
|
||||||
|
- Initial package
|
||||||
BIN
servlet-api-5.0.0.tar.gz
Normal file
BIN
servlet-api-5.0.0.tar.gz
Normal file
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user