From a4f4146e8619066683a8101b3ed4a104dd053710 Mon Sep 17 00:00:00 2001 From: small_leek Date: Tue, 17 Dec 2019 10:13:51 +0800 Subject: [PATCH] add spec file --- osgi-compendium.spec | 80 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) create mode 100644 osgi-compendium.spec diff --git a/osgi-compendium.spec b/osgi-compendium.spec new file mode 100644 index 0000000..7375792 --- /dev/null +++ b/osgi-compendium.spec @@ -0,0 +1,80 @@ +Name: osgi-compendium +Version: 6.0.0 +Release: 7 +Summary: Interfaces and Classes for use in compiling bundles +License: ASL 2.0 +URL: http://www.osgi.org + +Source0: https://osgi.org/download/r6/osgi.cmpn-%{version}.jar + +BuildArch: noarch +BuildRequires: maven-local geronimo-jpa glassfish-servlet-api maven-plugin-bundle +BuildRequires: osgi-annotation osgi-core +Provides: %{name}-javadoc = %{version}-%{release} +Obsoletes: %{name}-javadoc < %{version}-%{release} + +%description +%{summary}. + + +%prep +%autosetup -c -n %{name}-%{version} + +rm -r org +find -name '*.class' | xargs rm -f + +mkdir -p src/main/java +mv OSGI-OPT/src/org src/main/java/ +mkdir -p src/main/resources +mv xmlns src/main/resources + +rm -r src/main/java/org/osgi/service/io +mv META-INF/maven/org.osgi/osgi.cmpn/pom.xml . + +%{_bindir}/python3 %{_datadir}/java-utils/pom_editor.py pom_xpath_inject pom:project ' +bundle + + UTF-8 + + + + + org.apache.felix + maven-bundle-plugin + true + + + ${project.artifactId} + ${project.artifactId} + + + + +' + +%{_bindir}/python3 %{_datadir}/java-utils/pom_editor.py pom_add_dep org.osgi:osgi.annotation::provided +%{_bindir}/python3 %{_datadir}/java-utils/pom_editor.py pom_add_dep org.osgi:osgi.core::provided +%{_bindir}/python3 %{_datadir}/java-utils/pom_editor.py pom_add_dep \ + javax.servlet:javax.servlet-api::provided +%{_bindir}/python3 %{_datadir}/java-utils/pom_editor.py pom_add_dep \ + javax.persistence:persistence-api::provided + +%build +%mvn_build + +%install +%mvn_install + + +%files +%defattr(-,root,root) +%doc about.html +%license LICENSE +%{_datadir}/java/* +%{_datadir}/javadoc/* +%{_datadir}/maven-poms/* +%{_datadir}/maven-metadata/* + +%changelog +* Wed Dec 4 2019 openEuler Buildteam - 6.0.0-7 +- Package init \ No newline at end of file