forked from pool/protobuf
Accepting request 658895 from home:fstrba:branches:devel:tools:building
Add maven pom files to the protobuf-java packages and generate mvn(...) provides OBS-URL: https://build.opensuse.org/request/show/658895 OBS-URL: https://build.opensuse.org/package/show/devel:tools:building/protobuf?expand=0&rev=66
This commit is contained in:
parent
c805aa0de8
commit
34c6e8bb26
@ -1,3 +1,8 @@
|
||||
-------------------------------------------------------------------
|
||||
Mon Dec 17 10:28:51 UTC 2018 - Fridrich Strba <fstrba@suse.com>
|
||||
|
||||
- Add maven pom files to the protobuf-java package
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Sep 12 07:24:48 UTC 2018 - Thomas Bechtold <tbechtold@suse.com>
|
||||
|
||||
|
@ -30,7 +30,7 @@ Release: 0
|
||||
Summary: Protocol Buffers - Google's data interchange format
|
||||
License: BSD-3-Clause
|
||||
Group: Development/Libraries/C and C++
|
||||
Url: https://github.com/google/protobuf/
|
||||
URL: https://github.com/google/protobuf/
|
||||
Source0: https://github.com/google/protobuf/archive/v%{version}.tar.gz#/%{tarname}-%{version}.tar.gz
|
||||
Source1: manifest.txt.in
|
||||
Source2: baselibs.conf
|
||||
@ -52,6 +52,7 @@ BuildRequires: libgmock-devel >= 1.7.0
|
||||
%endif
|
||||
%if %{with java}
|
||||
BuildRequires: java-devel >= 1.6.0
|
||||
BuildRequires: javapackages-local
|
||||
%endif
|
||||
|
||||
%description
|
||||
@ -130,7 +131,7 @@ This package contains the Python bindings for Google Protocol Buffers.
|
||||
%setup -q -n %{tarname}-%{version}
|
||||
mkdir gmock
|
||||
|
||||
%if %{with python2} || %{with python3}
|
||||
%if %{with python2} || %{with python3}
|
||||
# only needed for test suite which we don't call anyways.
|
||||
# googleapis is broken on sle12
|
||||
sed -i '/apputils/d' python/setup.py
|
||||
@ -148,6 +149,7 @@ make %{?_smp_mflags}
|
||||
|
||||
%if %{with java}
|
||||
pushd java
|
||||
%pom_remove_parent
|
||||
../src/protoc --java_out=core/src/main/java -I../src ../src/google/protobuf/descriptor.proto
|
||||
mkdir classes
|
||||
javac $extra_java_flags -d classes core/src/main/java/com/google/protobuf/*.java
|
||||
@ -176,6 +178,10 @@ pushd java
|
||||
install -D -m 0644 %{name}-java-%{version}.jar %{buildroot}%{_javadir}/%{name}-java-%{version}.jar
|
||||
ln -s %{name}-java-%{version}.jar %{buildroot}%{_javadir}/%{name}-java.jar
|
||||
ln -s %{name}-java-%{version}.jar %{buildroot}%{_javadir}/%{name}.jar
|
||||
install -D -m 0644 pom.xml %{buildroot}%{_mavenpomdir}/%{name}-parent-%{version}.pom
|
||||
%add_maven_depmap %{name}-parent-%{version}.pom
|
||||
install -D -m 0644 core/pom.xml %{buildroot}%{_mavenpomdir}/%{name}-java-%{version}.pom
|
||||
%add_maven_depmap %{name}-java-%{version}.pom %{name}-java-%{version}.jar
|
||||
popd
|
||||
%endif
|
||||
|
||||
@ -212,6 +218,12 @@ popd
|
||||
%if %{with java}
|
||||
%files -n %{name}-java
|
||||
%{_javadir}/protobuf*
|
||||
%{_mavenpomdir}/protobuf*
|
||||
%if %{defined _maven_repository}
|
||||
%{_mavendepmapfragdir}/%{name}
|
||||
%else
|
||||
%{_datadir}/maven-metadata/%{name}.xml*
|
||||
%endif
|
||||
%endif
|
||||
|
||||
%if %{with python2}
|
||||
|
Loading…
x
Reference in New Issue
Block a user