forked from pool/protobuf
Accepting request 447591 from devel:tools:building
1 OBS-URL: https://build.opensuse.org/request/show/447591 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/protobuf?expand=0&rev=25
This commit is contained in:
commit
d01e280d88
@ -1,3 +1,20 @@
|
||||
-------------------------------------------------------------------
|
||||
Fri Dec 16 03:33:01 UTC 2016 - stefan.bruens@rwth-aachen.de
|
||||
|
||||
- Use py_sitedir for library installation with setup.py install
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Dec 14 07:32:06 UTC 2016 - mpluskal@suse.com
|
||||
|
||||
- Drop protobuf-libs as it is just workaround for rpmlint issue
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sat Dec 10 19:24:18 UTC 2016 - stefan.bruens@rwth-aachen.de
|
||||
|
||||
- Cleanup specfile:
|
||||
* remove any conditionals for versions predating SLES 12/Leap 42.x
|
||||
* add Provides: protobuf-libs to fix rpmlint warning
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Dec 7 04:17:12 UTC 2015 - lnussel@suse.de
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package protobuf
|
||||
#
|
||||
# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||
# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
@ -18,6 +18,8 @@
|
||||
|
||||
%define soname 9
|
||||
%bcond_without check
|
||||
%bcond_without protobuf_java
|
||||
%bcond_without protobuf_python
|
||||
Name: protobuf
|
||||
Version: 2.6.1
|
||||
Release: 0
|
||||
@ -32,19 +34,9 @@ Patch0: protobuf-setuptools-2.4.1.patch
|
||||
# fix no-return-in-nonvoid-function google/protobuf/extension_set.cc:74
|
||||
Patch1: protobuf-return-no-nonvoid.patch
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
%if 0%{?fedora_version} > 8 || 0%{?mandriva_version} > 2008 || 0%{?suse_version} > 1030
|
||||
%bcond_without protobuf_java
|
||||
%else
|
||||
%bcond_with protobuf_java
|
||||
%endif
|
||||
%if 0%{?suse_version} < 1210
|
||||
%bcond_with protobuf_python
|
||||
%else
|
||||
%bcond_without protobuf_python
|
||||
%endif
|
||||
%if 0%{?suse_version} > 1010
|
||||
BuildRequires: fdupes
|
||||
%endif
|
||||
BuildRequires: gcc-c++
|
||||
BuildRequires: pkg-config
|
||||
%if %{with protobuf_java}
|
||||
BuildRequires: java-devel >= 1.6.0
|
||||
%endif
|
||||
@ -56,8 +48,6 @@ BuildRequires: python-pytz
|
||||
BuildRequires: python-setuptools
|
||||
BuildRequires: zlib-devel
|
||||
%endif
|
||||
BuildRequires: gcc-c++
|
||||
BuildRequires: pkg-config
|
||||
|
||||
%description
|
||||
Protocol Buffers are a way of encoding structured data in an efficient yet
|
||||
@ -157,12 +147,7 @@ make %{?_smp_mflags}
|
||||
pushd java
|
||||
../src/protoc --java_out=src/main/java -I../src ../src/google/protobuf/descriptor.proto
|
||||
mkdir classes
|
||||
%if 0%{?suse_version} == 1110
|
||||
# 11.1 only workaround
|
||||
# http://en.opensuse.org/Java/Packaging/Cookbook#bytecode_version_error
|
||||
extra_java_flags="-target 1.5 -source 1.5"
|
||||
%endif
|
||||
javac $extra_java_flags -d classes src/main/java/com/google/protobuf/*.java
|
||||
javac -d classes src/main/java/com/google/protobuf/*.java
|
||||
sed -e 's/@VERSION@/%{version}/' < %{SOURCE1} > manifest.txt
|
||||
jar cfm %{name}-java-%{version}.jar manifest.txt -C classes com
|
||||
popd
|
||||
@ -195,17 +180,17 @@ popd
|
||||
|
||||
%if %{with protobuf_python}
|
||||
pushd python
|
||||
python setup.py clean
|
||||
python setup.py install --skip-build \
|
||||
--prefix=%{_prefix} \
|
||||
--install-data=%{_datadir} \
|
||||
--root %{buildroot} \
|
||||
--install-lib=%{py_sitedir} \
|
||||
--install-data=%{_datadir} \
|
||||
--record-rpm=INSTALLED_FILES
|
||||
popd
|
||||
%endif
|
||||
|
||||
%if 0%{?suse_version} > 1010
|
||||
%fdupes -s %{buildroot}%{py_sitedir}
|
||||
%endif
|
||||
|
||||
%post -n libprotobuf%{soname} -p /sbin/ldconfig
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user