forked from jengelh/grpc
- Switch to plain makefiles since they generate more shared libs.
OBS-URL: https://build.opensuse.org/package/show/devel:tools/grpc?expand=0&rev=22
This commit is contained in:
parent
45c7394d0c
commit
f234d16caf
@ -1,3 +1,8 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri May 18 14:55:27 UTC 2018 - jengelh@inai.de
|
||||||
|
|
||||||
|
- Switch to plain makefiles since they generate more shared libs.
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Fri May 18 13:26:45 UTC 2018 - tbechtold@suse.com
|
Fri May 18 13:26:45 UTC 2018 - tbechtold@suse.com
|
||||||
|
|
||||||
|
84
grpc.spec
84
grpc.spec
@ -16,6 +16,7 @@
|
|||||||
#
|
#
|
||||||
|
|
||||||
|
|
||||||
|
%define lname libgrpc6
|
||||||
Name: grpc
|
Name: grpc
|
||||||
Version: 1.12.0
|
Version: 1.12.0
|
||||||
Release: 0
|
Release: 0
|
||||||
@ -41,20 +42,11 @@ The reference implementation of the gRPC protocol, done on top of
|
|||||||
HTTP/2 with support for synchronous and asynchronous calls. gRPC uses
|
HTTP/2 with support for synchronous and asynchronous calls. gRPC uses
|
||||||
Protocol Buffers as the Interface Definition Language by default.
|
Protocol Buffers as the Interface Definition Language by default.
|
||||||
|
|
||||||
%package -n libgrpc6
|
%package -n %lname
|
||||||
Summary: HTTP/2-based Remote Procedure Call implementation
|
Summary: HTTP/2-based Remote Procedure Call implementation
|
||||||
Group: System/Libraries
|
Group: System/Libraries
|
||||||
|
|
||||||
%description -n libgrpc6
|
%description -n %lname
|
||||||
The reference implementation of the gRPC protocol, done on top of
|
|
||||||
HTTP/2 with support for synchronous and asynchronous calls. gRPC uses
|
|
||||||
Protocol Buffers as the Interface Definition Language by default.
|
|
||||||
|
|
||||||
%package -n libgrpc++1
|
|
||||||
Summary: C++ interface to grpc, a HTTP/2-based Remote Procedure Call implementation
|
|
||||||
Group: System/Libraries
|
|
||||||
|
|
||||||
%description -n libgrpc++1
|
|
||||||
The reference implementation of the gRPC protocol, done on top of
|
The reference implementation of the gRPC protocol, done on top of
|
||||||
HTTP/2 with support for synchronous and asynchronous calls. gRPC uses
|
HTTP/2 with support for synchronous and asynchronous calls. gRPC uses
|
||||||
Protocol Buffers as the Interface Definition Language by default.
|
Protocol Buffers as the Interface Definition Language by default.
|
||||||
@ -62,8 +54,7 @@ Protocol Buffers as the Interface Definition Language by default.
|
|||||||
%package devel
|
%package devel
|
||||||
Summary: Development files for grpc, a HTTP/2 Remote Procedure Call implementation
|
Summary: Development files for grpc, a HTTP/2 Remote Procedure Call implementation
|
||||||
Group: Development/Tools/Building
|
Group: Development/Tools/Building
|
||||||
Requires: libgrpc++1 = %version
|
Requires: %lname = %version
|
||||||
Requires: libgrpc6 = %version
|
|
||||||
|
|
||||||
%description devel
|
%description devel
|
||||||
This subpackage contains libraries and header files for developing
|
This subpackage contains libraries and header files for developing
|
||||||
@ -74,47 +65,29 @@ applications that want to make use of the gRPC reference implementation.
|
|||||||
%patch -P 1 -P 2 -p1
|
%patch -P 1 -P 2 -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
make LIBDIR=x CONFIG=opt \
|
%make_jobs STRIP=/bin/true V=1 VERBOSE=1 CFLAGS="%optflags" CXXFLAGS="%optflags"
|
||||||
x/opt/pkgconfig/grpc.pc x/opt/pkgconfig/grpc_unsecure.pc \
|
|
||||||
x/opt/pkgconfig/grpc++.pc x/opt/pkgconfig/grpc++_unsecure.pc
|
|
||||||
%cmake \
|
|
||||||
-DgRPC_PROTOBUF_PROVIDER=package \
|
|
||||||
-DgRPC_SSL_PROVIDER=package \
|
|
||||||
-DgRPC_ZLIB_PROVIDER=package \
|
|
||||||
-DgRPC_CARES_PROVIDER=package \
|
|
||||||
-DgRPC_INSTALL_BINDIR="%_bindir" \
|
|
||||||
-DgRPC_INSTALL_INCLUDEDIR="%_includedir" \
|
|
||||||
-DgRPC_INSTALL_LIBDIR="%_libdir"
|
|
||||||
|
|
||||||
#[ 36%] Running gRPC C++ protocol buffer compiler on src/proto/grpc/reflection/v1alpha/reflection.proto
|
|
||||||
#cd /home/abuild/rpmbuild/BUILD/grpc-1.2.3 && /usr/bin/protoc --grpc_out=/home/abuild/rpmbuild/BUILD/grpc-1.2.3/build/gens --cpp_out=/home/abuild/rpmbuild/BUILD/grpc-1.2.3/build/gens --plugin=protoc-gen-grpc=/home/abuild/rpmbuild/BUILD/grpc-1.2.3/build/grpc_cpp_plugin -I . src/proto/grpc/reflection/v1alpha/reflection.proto
|
|
||||||
#/home/abuild/rpmbuild/BUILD/grpc-1.2.3/build/grpc_cpp_plugin: error while loading shared libraries: libgrpc_plugin_support.so: cannot open shared object file: No such file or directory
|
|
||||||
#--grpc_out: protoc-gen-grpc: Plugin failed with status code 127.
|
|
||||||
export LD_LIBRARY_PATH="$PWD"
|
|
||||||
%make_jobs
|
|
||||||
|
|
||||||
%install
|
%install
|
||||||
b="%buildroot"
|
b="%buildroot"
|
||||||
mkdir -p "$b/%_libdir/pkgconfig"
|
%make_install prefix="$b/%_prefix" STRIP=/bin/true V=1 VERBOSE=1
|
||||||
cp x/opt/pkgconfig/*.pc "$b/%_libdir/pkgconfig/"
|
find "$b/%_includedir" -type f -exec chmod a-x {} +
|
||||||
%cmake_install
|
pushd "$b/usr"
|
||||||
#for i in "$b/%_libdir"/libg*-%version.so; do
|
rm -f lib/*.a
|
||||||
# ln -s "${i##*/}" "${i%%-%version.so}.so"
|
perl -i -pe 's{^prefix=.*}{prefix=%_prefix}' lib/pkgconfig/*.pc
|
||||||
#done
|
perl -i -pe 's{^libdir=.*}{libdir=%_libdir}' lib/pkgconfig/*.pc
|
||||||
|
if test ! -d lib64 && test "%_lib" = lib64; then
|
||||||
|
mv lib lib64
|
||||||
|
fi
|
||||||
|
popd
|
||||||
|
|
||||||
%post -n libgrpc6 -p /sbin/ldconfig
|
%post -n %lname -p /sbin/ldconfig
|
||||||
%postun -n libgrpc6 -p /sbin/ldconfig
|
%postun -n %lname -p /sbin/ldconfig
|
||||||
%post -n libgrpc++1 -p /sbin/ldconfig
|
|
||||||
%postun -n libgrpc++1 -p /sbin/ldconfig
|
|
||||||
|
|
||||||
%files -n libgrpc6
|
%files -n %lname
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
%_libdir/libgrpc.so.6*
|
%_libdir/libaddress_sorting.so.*
|
||||||
%_libdir/libgrpc_*.so.6*
|
%_libdir/libgpr*.so.*
|
||||||
|
%_libdir/libgrpc*.so.*
|
||||||
%files -n libgrpc++1
|
|
||||||
%defattr(-,root,root)
|
|
||||||
%_libdir/libgrpc++*.so.1
|
|
||||||
|
|
||||||
%files devel
|
%files devel
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
@ -122,18 +95,7 @@ cp x/opt/pkgconfig/*.pc "$b/%_libdir/pkgconfig/"
|
|||||||
%_bindir/*
|
%_bindir/*
|
||||||
%_includedir/*
|
%_includedir/*
|
||||||
%_libdir/pkgconfig/*.pc
|
%_libdir/pkgconfig/*.pc
|
||||||
%_libdir/libaddress_sorting.so
|
%_libdir/*.so
|
||||||
%_libdir/libgpr.so
|
%_datadir/grpc/
|
||||||
%_libdir/libgrpc++.so
|
|
||||||
%_libdir/libgrpc++_cronet.so
|
|
||||||
%_libdir/libgrpc++_error_details.so
|
|
||||||
%_libdir/libgrpc++_reflection.so
|
|
||||||
%_libdir/libgrpc++_unsecure.so
|
|
||||||
%_libdir/libgrpc.so
|
|
||||||
%_libdir/libgrpc_cronet.so
|
|
||||||
%_libdir/libgrpc_csharp_ext.so
|
|
||||||
%_libdir/libgrpc_plugin_support.so
|
|
||||||
%_libdir/libgrpc_unsecure.so
|
|
||||||
/usr/lib/cmake
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
Loading…
Reference in New Issue
Block a user