!1 Package init

Merge pull request !1 from lyn/master
This commit is contained in:
openeuler-ci-bot 2020-09-01 18:12:22 +08:00 committed by Gitee
commit d2a62097be
4 changed files with 78 additions and 0 deletions

74
eclipse-license.spec Normal file
View File

@ -0,0 +1,74 @@
%global eplv2_ver 2.0.1
%global eplv2_tag org.eclipse.license-license-%{eplv2_ver}.v20180423-1114
%global eplv1_ver 1.0.1
%global eplv1_tag org.eclipse.license-license-%{eplv1_ver}.v20140414-1359
Name: eclipse-license
Version: 2.0.1
Release: 1
Summary: Shared license features for Eclipse
License: EPL-1.0 and EPL-2.0
URL: http://wiki.eclipse.org/CBI
Source1: http://git.eclipse.org/c/cbi/org.eclipse.license.git/snapshot/%{eplv1_tag}.tar.gz
Source2: http://git.eclipse.org/c/cbi/org.eclipse.license.git/snapshot/%{eplv2_tag}.tar.gz
BuildArch: noarch
ExcludeArch: s390 %{arm} %{ix86}
BuildRequires: tycho
%description
Shared license features for Eclipse. Other features may consume these
features to avoid unnecessary duplication of license boiler plate.
%package -n %{name}1
Version: %{eplv1_ver}
Summary: Shared EPL v1.0 license feature for Eclipse
License: EPL-1.0
Provides: eclipse-license = %{eplv1_ver}-20
Obsoletes: eclipse-license < %{eplv2_ver}-%{release}
%description -n %{name}1
Shared license feature for Eclipse. Other features may consume this
feature to avoid unnecessary duplication of license boiler plate.
%package -n %{name}2
Version: %{eplv2_ver}
Summary: Shared EPL v2.0 license feature for Eclipse
License: EPL-2.0
%description -n %{name}2
Shared license feature for Eclipse. Other features may consume this
feature to avoid unnecessary duplication of license boiler plate.
%prep
%setup -q -c -T
tar xf %{SOURCE1}
tar xf %{SOURCE2}
%pom_remove_plugin ":tycho-packaging-plugin" */pom.xml
%build
pushd %{eplv1_tag}
%mvn_build -j
popd
pushd %{eplv2_tag}
sed -i -e 's/\(-SNAPSHOT\|\.qualifier\)/.v20180423-1114/' pom.xml */*.xml
%mvn_build -j
popd
%install
pushd %{eplv1_tag}
%mvn_package "::pom::" __noinstall
%mvn_package ":" 1
%mvn_install
popd
rm -rf /tmp/tycho-bundles-external*
pushd %{eplv2_tag}
%mvn_package "::pom::" __noinstall
%mvn_package ":" 2
%mvn_install
popd
%files -n %{name}1 -f %{eplv1_tag}/.mfiles-1
%license %{eplv1_tag}/org.eclipse.license/*.html
%files -n %{name}2 -f %{eplv2_tag}/.mfiles-2
%license %{eplv2_tag}/org.eclipse.license/*.html
%changelog
* Thu Aug 13 2020 yanan li <liyanan032@huawei.com> - 2.0.1-1
- Package init

4
eclipse-license.yaml Normal file
View File

@ -0,0 +1,4 @@
version_control: git
src_repo: http://git.eclipse.org/r/cbi/org.eclipse.license.git
tag_prefix: "license-"
seperator: "."